pud: better detection of java jdk
authorFerry Huberts <ferry.huberts@pelagic.nl>
Thu, 28 Feb 2013 15:53:34 +0000 (16:53 +0100)
committerFerry Huberts <ferry.huberts@pelagic.nl>
Thu, 28 Feb 2013 15:53:34 +0000 (16:53 +0100)
It failed on Debian Squeeze 64 bits

Signed-off-by: Ferry Huberts <ferry.huberts@pelagic.nl>
lib/pud/wireformat-java/Makefile

index d960411..0254716 100644 (file)
@@ -58,15 +58,27 @@ INC_DIR_WIREFORMAT_FULL = $(INC_DIR_WIREFORMAT)/$(WIREFORMAT_PROJECT)
 ifneq ($(wildcard /usr/lib/jvm/java),)
   INC_DIR_JVM = /usr/lib/jvm/java/include
 else
-ifneq ($(wildcard /usr/lib/jvm/java-1.7.0-openjdk$(ARCH)),)
-  INC_DIR_JVM = /usr/lib/jvm/java-1.7.0-openjdk$(ARCH)/include
-else
-ifneq ($(wildcard /usr/lib/jvm/java-1.6.0-openjdk$(ARCH)),)
-  INC_DIR_JVM = /usr/lib/jvm/java-1.6.0-openjdk$(ARCH)/include
-else
-  $(error No java detected)
-endif
-endif
+  ifneq ($(wildcard /usr/lib/jvm/default-java),)
+    INC_DIR_JVM = /usr/lib/jvm/default-java/include
+  else
+    ifneq ($(wildcard /usr/lib/jvm/java-1.7.0-openjdk$(ARCH)),)
+      INC_DIR_JVM = /usr/lib/jvm/java-1.7.0-openjdk$(ARCH)/include
+    else
+      ifneq ($(wildcard /usr/lib/jvm/java-1.7.0-openjdk),)
+        INC_DIR_JVM = /usr/lib/jvm/java-1.7.0-openjdk/include
+      else
+        ifneq ($(wildcard /usr/lib/jvm/java-1.6.0-openjdk$(ARCH)),)
+          INC_DIR_JVM = /usr/lib/jvm/java-1.6.0-openjdk$(ARCH)/include
+        else
+          ifneq ($(wildcard /usr/lib/jvm/java-1.6.0-openjdk),)
+            INC_DIR_JVM = /usr/lib/jvm/java-1.6.0-openjdk/include
+          else
+            $(error No java detected)
+          endif
+        endif
+      endif
+    endif
+  endif
 endif
 
 INC_DIR_JVM_OS = $(INC_DIR_JVM)/$(OS)