RFC: Test set for systemtap instrumentation

jon.vanalten at redhat.com jon.vanalten at redhat.com
Wed Mar 3 09:08:03 PST 2010


----- "Andrew John Hughes" <gnu_andrew at member.fsf.org> wrote:
> 
> I'll leave Mark to comment on the actual SystemTap usage.  I don't
> see
> any additions to the Makefile.am to make this test build and run.
> Assuming it can be automated, it needs a check-systemtap target which
> check-local depends on and whose body is inside an if
> ENABLE_SYSTEMTAP.  

Right, I wasn't sure if it should be added to the automated testing.

>The script seems to have hardcoded locations:
> 
> +JAVA_EXEC="java"
> +JAVAC_EXEC="javac"
> +JVM_DIR="/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/jre/lib/amd64/server/"
> +JVM_SO="-ljvm"
> +INCLUDE_DIR="-I/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/include/
> -I/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/include/linux/"
> 
> These are only likely to work on x86_64 Fedora boxes.  The script
> should take the JAVA_HOME as an argument and calculate the paths from
> this.  The Makefile can pass the location of the just-built IcedTea
> to
> the script.
>

Yes, this is a problem.  Although, there is already such an argument; these would only be used if the script was called without the argument.  I'm actually rewriting the script in perl for various reasons, and will be making use of Config{archname} to get around this in both the no-argument (testing system-installed java) and with-argument (testing local build) case.  Note that even with $JAVA_HOME, script would still need to know the arch to find the directory in which libjvm.so lives; (jre/lib/<ARCH>/server), needed to compile and run JNI code.

Thanks for taking a look.  I'll re-post soon with updates.

jon




More information about the distro-pkg-dev mailing list