From: Jay Freeman (saurik) Date: Wed, 6 Jan 2016 10:44:43 +0000 (-0800) Subject: Compile Java support for armv6 where we use JamVM. X-Git-Tag: v0.9.590~48 X-Git-Url: https://git.saurik.com/cycript.git/commitdiff_plain/4b5dc402335c630735ef8e790e6d117e10275a56 Compile Java support for armv6 where we use JamVM. --- diff --git a/Java/Execute.cpp b/Java/Execute.cpp index 8840906..8e7acbf 100644 --- a/Java/Execute.cpp +++ b/Java/Execute.cpp @@ -25,7 +25,7 @@ #include -#ifdef __APPLE__ +#if defined(__APPLE__) && !defined(__arm__) #include #else #include @@ -1342,6 +1342,7 @@ static JavaVM *CYGetJavaVM(JSContextRef context) { guesses.push_back("/Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home/lib/jli/libjli.dylib"); //guesses.push_back("/System/Library/Frameworks/JavaVM.framework/JavaVM"); + guesses.push_back("libjvm.dylib"); guesses.push_back("libart.so"); guesses.push_back("libdvm.so"); diff --git a/build.mk b/build.mk index 0aa2b59..7f0d890 100644 --- a/build.mk +++ b/build.mk @@ -97,6 +97,7 @@ $(deb): Cycript.lib/cycript-apl Cycript.lib/libcycript.dylib Cycript.lib/libcycr $(lipo) -extract armv6 -extract arm64 -output package/usr/lib/libcycript.dylib Cycript.lib/libcycript.dylib ln -s libcycript.dylib package/usr/lib/libcycript.0.dylib cp -a libcycript.cy package/usr/lib/libcycript.cy + cp -a Cycript.lib/libcycript.jar package/usr/lib/libcycript.jar cp -a Cycript.lib/libcycript.db package/usr/lib/libcycript.db sqlite3 package/usr/lib/libcycript.db "delete from cache where system & $$(($$(cat build.ios-arm{v6,64}/Makefile | sed -e '/^CY_SYSTEM = \([0-9]*\)$$/{s//\1/;p;};d;' | tr $$'\n' '|') 0)) == 0; vacuum full;" ./dpkg-deb.sh -Zlzma -b package $@ diff --git a/sysroot.sh b/sysroot.sh index 6699c2b..2681c0d 100755 --- a/sysroot.sh +++ b/sysroot.sh @@ -35,3 +35,7 @@ done mv sysroot.ios/usr/lib/_ncurses/* sysroot.ios/usr/lib rmdir sysroot.ios/usr/lib/_ncurses + +for h in jni.h jni_md.h; do + ln -s /System/Library/Frameworks/JavaVM.framework/Versions/A/Headers/"${h}" sysroot.ios/usr/include +done