You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
215 lines
5.7 KiB
215 lines
5.7 KiB
dnl Process this file with autoconf to produce a configure script.
|
|
AC_INIT()
|
|
|
|
AM_INIT_AUTOMAKE(jode, 1.0.91)
|
|
|
|
dnl Checks for programs.
|
|
dnl AC_PROG_CXX
|
|
dnl AC_PROG_AWK
|
|
dnl AC_PROG_CC
|
|
dnl AC_PROG_CPP
|
|
dnl AC_PROG_INSTALL
|
|
dnl AC_PROG_LN_S
|
|
AC_PROG_MAKE_SET
|
|
dnl AC_PROG_RANLIB
|
|
dnl AC_PATH_PROG(ZIP, zip)
|
|
AC_PATH_PROG(UNZIP, unzip)
|
|
AC_PATH_PROG(PERL, perl)
|
|
AC_PATH_PROG(CYGPATH, cygpath)
|
|
|
|
dnl Checks for libraries.
|
|
|
|
dnl Checks for header files.
|
|
|
|
dnl Checks for typedefs, structures, and compiler characteristics.
|
|
|
|
dnl Checks for library functions.
|
|
|
|
dnl hack to quote Makefile lines
|
|
QUOTE=""
|
|
AC_SUBST(QUOTE)
|
|
|
|
AC_SUBST(SHELL)
|
|
|
|
if test -n "$CYGPATH"; then
|
|
# Extra check if java take windows path?
|
|
CLASSPATH=`$CYGPATH --unix --path $CLASSPATH`
|
|
SUBSTCP="$CYGPATH --windows --path"
|
|
else
|
|
SUBSTCP="echo"
|
|
fi
|
|
|
|
AC_SUBST(SUBSTCP)
|
|
|
|
AC_ARG_WITH(java,
|
|
[ --with-java specify path to a java-like program ],
|
|
[
|
|
if test ${withval} != "" || test ${withval} != "yes" || test ${withval} != "no"; then
|
|
# set javac to user input value
|
|
JODE_CHECK_JAVA(${withval})
|
|
else
|
|
JODE_CHECK_JAVA(/usr/lib/java)
|
|
fi
|
|
],
|
|
[
|
|
JODE_CHECK_JAVA(/usr/lib/java)
|
|
])
|
|
|
|
dnl jikes can also handle dependancies.
|
|
AC_ARG_WITH(jikes,
|
|
[ --with-jikes specify location of jikes ],
|
|
[
|
|
USER_SPECIFIED_JIKES=true
|
|
if test "${withval}" = "yes" || test "${withval}" = ""; then
|
|
AC_PATH_PROG(JIKES, jikes, "", $PATH)
|
|
else
|
|
echo "searching jikes in ${withval}:$PATH"
|
|
AC_PATH_PROG(JIKES, jikes, "", ${withval}:$PATH)
|
|
fi
|
|
if test -n "$JIKES"; then
|
|
JAVAC=$JIKES
|
|
fi
|
|
],
|
|
[
|
|
USER_SPECIFIED_JIKES=
|
|
AC_PATH_PROG(JIKES, jikes, "", $PATH)
|
|
])
|
|
AM_CONDITIONAL(HAVE_JIKES, test x"$JIKES" != x)
|
|
|
|
AC_ARG_WITH(javac,
|
|
[ --with-javac specify location of javac ],
|
|
[
|
|
if test x$USER_SPECIFIED_JIKES == xtrue; then
|
|
AC_MSG_ERROR(You must only give one option --with-javac or --with-jikes)
|
|
fi
|
|
if test ${withval} != "" || test ${withval} != "yes" || test ${withval} != "no"; then
|
|
AC_CHECK_FILES(${withval},
|
|
[ JAVAC=${withval} ],
|
|
[ AC_MSG_ERROR(${withval} does not exists) ])
|
|
fi
|
|
], [
|
|
dnl use jikes as default, if javac option not given.
|
|
if test -n "$JIKES"; then
|
|
JAVAC=$JIKES
|
|
fi
|
|
])
|
|
|
|
JODE_CHECK_CLASS(java.lang.Object, $CLASSLIB,
|
|
[ true ],
|
|
[ AC_MSG_ERROR(Please specify location of java class library for jikes) ])
|
|
|
|
AC_MSG_CHECKING(for collection classes)
|
|
JODE_CHECK_CLASS(java.util.Set, $CLASSPATH:$CLASSLIB,
|
|
[ COLLECTIONS="java.util"
|
|
COLLECTIONEXTRA="java.lang" ],
|
|
[ JODE_CHECK_CLASS(com.sun.java.util.collections.Set, $CLASSPATH:$CLASSLIB,
|
|
[ COLLECTIONS="com.sun.java.util.collections"
|
|
COLLECTIONEXTRA="com.sun.java.util.collections" ],
|
|
[ AC_MSG_RESULT(no)
|
|
AC_MSG_ERROR(You need the Java 1.2 collection classes in your classpath)
|
|
])
|
|
] )
|
|
AC_MSG_RESULT($COLLECTIONS)
|
|
AC_SUBST(COLLECTIONS)
|
|
AC_SUBST(COLLECTIONEXTRA)
|
|
|
|
AC_MSG_CHECKING(for gnu.getopt)
|
|
JODE_CHECK_CLASS(gnu.getopt.Getopt, $CLASSPATH:$CLASSLIB,
|
|
[ AC_MSG_RESULT(yes) ],
|
|
[ AC_MSG_RESULT(no)
|
|
AC_MSG_ERROR(You need gnu getopt for java.) ])
|
|
|
|
AC_MSG_CHECKING(for swing)
|
|
JODE_CHECK_CLASS(javax.swing.JFrame, $CLASSPATH:$CLASSLIB,
|
|
[ JAVAX_SWING="javax.swing" ],
|
|
[ JODE_CHECK_CLASS(com.sun.java.swing.JFrame, $CLASSPATH:$CLASSLIB,
|
|
[ JAVAX_SWING="com.sun.java.swing" ],
|
|
[ JAVAX_SWING="no" ]) ] )
|
|
AC_MSG_RESULT($JAVAX_SWING)
|
|
AC_SUBST(JAVAX_SWING)
|
|
if test x"$JAVAX_SWING" != x; then
|
|
SWINGUI="swingui"
|
|
else
|
|
AC_MSG_WARN(Swing is not in classpath ... skipping swingui)
|
|
SWINGUI=""
|
|
fi
|
|
AC_SUBST(SWINGUI)
|
|
|
|
AC_SUBST(CLASSPATH)
|
|
AC_SUBST(JAVAC)
|
|
|
|
AC_OUTPUT(Makefile
|
|
javaDependencies.pl
|
|
jode/Makefile
|
|
jode/bytecode/Makefile
|
|
jode/decompiler/Makefile
|
|
jode/expr/Makefile
|
|
jode/flow/Makefile
|
|
jode/jvm/Makefile
|
|
jode/obfuscator/Makefile
|
|
jode/swingui/Makefile
|
|
jode/type/Makefile
|
|
jode/util/Makefile
|
|
jode/bytecode/BinaryInfo.java
|
|
jode/bytecode/BytecodeInfo.java
|
|
jode/bytecode/ClassInfo.java
|
|
jode/bytecode/Reference.java
|
|
jode/decompiler/ImportHandler.java
|
|
jode/decompiler/MethodAnalyzer.java
|
|
jode/decompiler/DeadCodeAnalysis.java
|
|
jode/expr/Expression.java
|
|
jode/expr/InvokeOperator.java
|
|
jode/expr/Operator.java
|
|
jode/expr/CheckNullOperator.java
|
|
jode/flow/RetBlock.java
|
|
jode/flow/InstructionContainer.java
|
|
jode/flow/LoopBlock.java
|
|
jode/flow/SequentialBlock.java
|
|
jode/flow/SlotSet.java
|
|
jode/flow/StructuredBlock.java
|
|
jode/flow/SynchronizedBlock.java
|
|
jode/flow/VariableSet.java
|
|
jode/flow/CatchBlock.java
|
|
jode/flow/IfThenElseBlock.java
|
|
jode/flow/InstructionBlock.java
|
|
jode/flow/FlowBlock.java
|
|
jode/flow/TransformExceptionHandlers.java
|
|
jode/jvm/CodeVerifier.java
|
|
jode/jvm/Interpreter.java
|
|
jode/jvm/SyntheticAnalyzer.java
|
|
jode/obfuscator/LocalizeFieldTransformer.java
|
|
jode/obfuscator/LocalOptimizer.java
|
|
jode/obfuscator/RemovePopAnalyzer.java
|
|
jode/obfuscator/SimpleAnalyzer.java
|
|
jode/obfuscator/Renamer.java
|
|
jode/obfuscator/StrongRenamer.java
|
|
jode/obfuscator/OptionHandler.java
|
|
jode/obfuscator/ScriptParser.java
|
|
jode/obfuscator/TranslationTable.java
|
|
jode/obfuscator/Main.java
|
|
jode/obfuscator/FieldIdentifier.java
|
|
jode/obfuscator/Identifier.java
|
|
jode/obfuscator/NameSwapper.java
|
|
jode/obfuscator/PackageIdentifier.java
|
|
jode/obfuscator/ClassBundle.java
|
|
jode/obfuscator/ConstantAnalyzer.java
|
|
jode/obfuscator/ConstantRuntimeEnvironment.java
|
|
jode/obfuscator/LocalIdentifier.java
|
|
jode/obfuscator/MethodIdentifier.java
|
|
jode/obfuscator/ClassIdentifier.java
|
|
jode/obfuscator/MultiIdentifierMatcher.java
|
|
jode/obfuscator/UniqueRenamer.java
|
|
jode/obfuscator/WildCard.java
|
|
jode/swingui/Main.java
|
|
jode/swingui/PackagesTreeModel.java
|
|
jode/swingui/HierarchyTreeModel.java
|
|
jode/type/Type.java
|
|
jode/util/SimpleSet.java
|
|
jode/util/SimpleMap.java
|
|
jode/util/UnifyHash.java
|
|
jode/GlobalOptions.java
|
|
bin/Makefile
|
|
bin/jode
|
|
doc/Makefile
|
|
test/Makefile,
|
|
[chmod 755 javaDependencies.pl bin/jode])
|
|
|