Index: aot-compile.in =================================================================== RCS file: /cvs/rhug/java-gcj-compat/aot-compile.in,v retrieving revision 1.1 diff -u -r1.1 aot-compile.in --- aot-compile.in 14 Apr 2005 22:12:54 -0000 1.1 +++ aot-compile.in 22 Apr 2005 15:34:44 -0000 @@ -4,12 +4,21 @@ : ${1?" aot-compile: Natively-compile a given JAR - Usage: $0 SRC_JARFILE DEST_SO_NAME BUILD_OPTIONS - SRC_JARFILE - the jar file we want to process - DEST_SO_NAME - the destination name of the .so of the compiled JAR + Usage: $0 [BUILD_OPTIONS] JARS + JARS - jar files we want to process BUILD_OPTIONS - a list of gcj options (outside of -findirect-dispatch -shared -Wl,-Bsymbolic) "} -@GCJ_BIN_DIR@/gcj@gcc_suffix@ $3 -findirect-dispatch \ - -shared -Wl,-Bsymbolic -o $2 $1 +unset opts +while [ ! -z "$1" ]; do + (echo -- "$1" | grep -q '\.jar$') && break + opts="$opts${opts:+ }$1" + shift +done +while [ ! -z "$1" ]; do + @GCJ_BIN_DIR@/gcj@gcc_suffix@ \ + $opts -findirect-dispatch -shared -Wl,-Bsymbolic \ + -o `dirname $1`/lib`basename $1`.so $1 + shift +done