]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
configure: fail when missing junit dependency
authorNoah Watkins <noahwatkins@gmail.com>
Fri, 2 Nov 2012 19:52:38 +0000 (12:52 -0700)
committerJoe Buck <jbbuck@gmail.com>
Thu, 8 Nov 2012 17:28:26 +0000 (09:28 -0800)
Signed-off-by: Noah Watkins <noahwatkins@gmail.com>
configure.ac

index 0d5eb9a38d9df59344f7347206ba4544d05266fb..4fa0c0d463ae8a3aa2d4d1888a09c54836f14646 100644 (file)
@@ -285,12 +285,19 @@ AS_IF([test "x$enable_cephfs_java" = "xyes"], [
 
   # cephfs_java_test only makes sense if java is already turned on
        # setup CLASSPATH for Debian default junit4.jar package 
+    #
+    # Configuring --with-debug and --enable-cephfs-java will throw an error if
+    # JUnit4 cannot be found. While currently this works for users who have
+    # installed via the package manager on Ubuntu, we need to expand this
+    # check to 1) support other distrubtions and 2) allow users to influence
+    # the search path.
   AS_IF([test "x$with_debug" = "xyes"], [
       dir='/usr/share/java'
       junit4_jar=`find $dir -name junit4.jar | head -n 1`
                  AS_IF([test -r "$junit4_jar"], [
              EXTRA_CLASSPATH_JAR=`dirname $junit4_jar`/junit4.jar
-      AC_SUBST(EXTRA_CLASSPATH_JAR)])])
+      AC_SUBST(EXTRA_CLASSPATH_JAR)], [
+      AC_MSG_ERROR([Cannot find junit4.jar (apt-get install junit4)])])])
 
        # Check for Java programs: javac, javah, jar
     PATH_save=$PATH