forked from I2P_Developers/i2p.i2p
* jbigi / NBI / wrapper / installer:
jbigi and wrapper files for arm. Compiled on trimslice with gcc version 4.4.5 (Ubuntu/Linaro 4.4.4-14ubuntu5) Log postinstall errors to postinstall.log. java version "1.6.0_18" OpenJDK Runtime Environment (IcedTea6 1.8.7) (6b18-1.8.7-0ubuntu2.1) OpenJDK Zero VM (build 14.0-b16, mixed mode) GMP 4.3.2 (half the size of 5.0.2, and no speed difference) LGPLv3 Wrapper 3.5.9 GPLv2 All binaries stripped. As on the Android emulator, the stock BigInteger.modPow() has some serious bug on arm. Without the libjbigi checked in here, the JVM crashes almost immediately.
This commit is contained in:
@ -493,6 +493,9 @@
|
|||||||
<copy todir="pkg-temp/lib/wrapper/solaris/">
|
<copy todir="pkg-temp/lib/wrapper/solaris/">
|
||||||
<fileset dir="installer/lib/wrapper/solaris/" />
|
<fileset dir="installer/lib/wrapper/solaris/" />
|
||||||
</copy>
|
</copy>
|
||||||
|
<copy todir="pkg-temp/lib/wrapper/linux-arm/">
|
||||||
|
<fileset dir="installer/lib/wrapper/linux-arm/" />
|
||||||
|
</copy>
|
||||||
</target>
|
</target>
|
||||||
|
|
||||||
<target name="preppkg-windows" depends="preppkg-base, buildexe">
|
<target name="preppkg-windows" depends="preppkg-base, buildexe">
|
||||||
@ -521,6 +524,7 @@
|
|||||||
<copy file="installer/lib/wrapper/all/wrapper.jar" todir="pkg-temp/lib" />
|
<copy file="installer/lib/wrapper/all/wrapper.jar" todir="pkg-temp/lib" />
|
||||||
</target>
|
</target>
|
||||||
|
|
||||||
|
<!-- x86 linux only -->
|
||||||
<target name="preppkg-linux" depends="preppkg-base">
|
<target name="preppkg-linux" depends="preppkg-base">
|
||||||
<copy file="installer/resources/runplain.sh" todir="pkg-temp/" />
|
<copy file="installer/resources/runplain.sh" todir="pkg-temp/" />
|
||||||
<!-- <copy file="apps/i2psnark/launch-i2psnark" todir="pkg-temp/" /> old feature that per zzz isn't used-->
|
<!-- <copy file="apps/i2psnark/launch-i2psnark" todir="pkg-temp/" /> old feature that per zzz isn't used-->
|
||||||
|
@ -140,6 +140,15 @@ public class NativeBigInteger extends BigInteger {
|
|||||||
/** all libjbibi builds are identical to pentium3, case handled in getMiddleName2() */
|
/** all libjbibi builds are identical to pentium3, case handled in getMiddleName2() */
|
||||||
private final static String JBIGI_OPTIMIZATION_VIAC32 = "viac32";
|
private final static String JBIGI_OPTIMIZATION_VIAC32 = "viac32";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Non-x86, no fallbacks to older libs or to "none"
|
||||||
|
* @since 0.8.7
|
||||||
|
*/
|
||||||
|
private final static String JBIGI_OPTIMIZATION_ARM = "arm";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Operating systems
|
||||||
|
*/
|
||||||
private static final boolean _isWin = System.getProperty("os.name").startsWith("Win");
|
private static final boolean _isWin = System.getProperty("os.name").startsWith("Win");
|
||||||
private static final boolean _isOS2 = System.getProperty("os.name").startsWith("OS/2");
|
private static final boolean _isOS2 = System.getProperty("os.name").startsWith("OS/2");
|
||||||
private static final boolean _isMac = System.getProperty("os.name").startsWith("Mac");
|
private static final boolean _isMac = System.getProperty("os.name").startsWith("Mac");
|
||||||
@ -164,6 +173,8 @@ public class NativeBigInteger extends BigInteger {
|
|||||||
private static final boolean _isX86 = System.getProperty("os.arch").contains("86") ||
|
private static final boolean _isX86 = System.getProperty("os.arch").contains("86") ||
|
||||||
System.getProperty("os.arch").equals("amd64");
|
System.getProperty("os.arch").equals("amd64");
|
||||||
|
|
||||||
|
private static final boolean _isArm = System.getProperty("os.arch").startsWith("arm");
|
||||||
|
|
||||||
/* libjbigi.so vs jbigi.dll */
|
/* libjbigi.so vs jbigi.dll */
|
||||||
private static final String _libPrefix = (_isWin || _isOS2 ? "" : "lib");
|
private static final String _libPrefix = (_isWin || _isOS2 ? "" : "lib");
|
||||||
private static final String _libSuffix = (_isWin || _isOS2 ? ".dll" : _isMac ? ".jnilib" : ".so");
|
private static final String _libSuffix = (_isWin || _isOS2 ? ".dll" : _isMac ? ".jnilib" : ".so");
|
||||||
@ -173,12 +184,16 @@ public class NativeBigInteger extends BigInteger {
|
|||||||
static {
|
static {
|
||||||
if (_isX86) // Don't try to resolve CPU type on PPC and other non x86 hardware
|
if (_isX86) // Don't try to resolve CPU type on PPC and other non x86 hardware
|
||||||
sCPUType = resolveCPUType();
|
sCPUType = resolveCPUType();
|
||||||
|
else if (_isArm)
|
||||||
|
sCPUType = JBIGI_OPTIMIZATION_ARM;
|
||||||
else
|
else
|
||||||
sCPUType = null;
|
sCPUType = null;
|
||||||
loadNative();
|
loadNative();
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Tries to resolve the best type of CPU that we have an optimized jbigi-dll/so for.
|
/**
|
||||||
|
* Tries to resolve the best type of CPU that we have an optimized jbigi-dll/so for.
|
||||||
|
* This is for x86 only.
|
||||||
* @return A string containing the CPU-type or null if CPU type is unknown
|
* @return A string containing the CPU-type or null if CPU type is unknown
|
||||||
*/
|
*/
|
||||||
private static String resolveCPUType() {
|
private static String resolveCPUType() {
|
||||||
@ -639,10 +654,13 @@ public class NativeBigInteger extends BigInteger {
|
|||||||
rv.add(_libPrefix + getMiddleName1() + JBIGI_OPTIMIZATION_ATHLON64 + _libSuffix);
|
rv.add(_libPrefix + getMiddleName1() + JBIGI_OPTIMIZATION_ATHLON64 + _libSuffix);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// add libjbigi-xxx-none.so
|
// Add libjbigi-xxx-none_64.so
|
||||||
if (_is64)
|
if (_is64)
|
||||||
rv.add(_libPrefix + getMiddleName1() + "none_64" + _libSuffix);
|
rv.add(_libPrefix + getMiddleName1() + "none_64" + _libSuffix);
|
||||||
rv.add(getResourceName(false));
|
// Add libjbigi-xxx-none.so
|
||||||
|
// Note that libjbigi-osx-none.jnilib is a 'fat binary' with both PPC and x86-32
|
||||||
|
if (!_isArm)
|
||||||
|
rv.add(getResourceName(false));
|
||||||
return rv;
|
return rv;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,3 +1,10 @@
|
|||||||
|
2011-06-14 zzz
|
||||||
|
* Jbigi / NBI / wrapper / installer:
|
||||||
|
jbigi and wrapper files for arm.
|
||||||
|
Compiled on trimslice with gcc version 4.4.5 (Ubuntu/Linaro 4.4.4-14ubuntu5)
|
||||||
|
Log postinstall errors to postinstall.log.
|
||||||
|
* RateStat: final
|
||||||
|
|
||||||
2011-06-13 duck
|
2011-06-13 duck
|
||||||
* Finnish, Italian, Polish and Vietnamese translations, thanks Transifex teams.
|
* Finnish, Italian, Polish and Vietnamese translations, thanks Transifex teams.
|
||||||
|
|
||||||
|
BIN
installer/lib/jbigi/libjbigi-linux-arm.so
Normal file
BIN
installer/lib/jbigi/libjbigi-linux-arm.so
Normal file
Binary file not shown.
6
installer/lib/wrapper/linux-arm/README.txt
Normal file
6
installer/lib/wrapper/linux-arm/README.txt
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
Wrapper build instructions (Ubuntu):
|
||||||
|
|
||||||
|
export ANT_HOME=/usr/share/ant
|
||||||
|
export JAVA_HOME=/usr/lib/jvm/java-6-openjdk
|
||||||
|
cp src/c/Makefile-linux-x86-32.make src/c/Makefile-linux-arm-32.make
|
||||||
|
build32.sh
|
BIN
installer/lib/wrapper/linux-arm/i2psvc
Normal file
BIN
installer/lib/wrapper/linux-arm/i2psvc
Normal file
Binary file not shown.
BIN
installer/lib/wrapper/linux-arm/libwrapper.so
Normal file
BIN
installer/lib/wrapper/linux-arm/libwrapper.so
Normal file
Binary file not shown.
@ -23,11 +23,15 @@ chmod 755 ./runplain.sh
|
|||||||
# chmod 755 ./uninstall_i2p_service_unix
|
# chmod 755 ./uninstall_i2p_service_unix
|
||||||
|
|
||||||
ERROR_MSG="Cannot determine operating system type. From the subdirectory in lib/wrapper matching your operating system, please move i2psvc to your base I2P directory, and move the remaining two files to the lib directory."
|
ERROR_MSG="Cannot determine operating system type. From the subdirectory in lib/wrapper matching your operating system, please move i2psvc to your base I2P directory, and move the remaining two files to the lib directory."
|
||||||
|
LOGFILE=./postinstall.log
|
||||||
|
|
||||||
HOST_OS=`./osid`
|
HOST_OS=`./osid`
|
||||||
|
|
||||||
if [ "X$HOST_OS" = "X" -o $HOST_OS = "unknown" ]; then
|
if [ "X$HOST_OS" = "X" -o "X$HOST_OS" = "Xunknown" ]; then
|
||||||
echo "$ERROR_MSG"
|
echo "$ERROR_MSG"
|
||||||
|
echo "Host OS is $HOST_OS" >> $LOGFILE
|
||||||
|
echo "Host architecture is $OS_ARCH" >> $LOGFILE
|
||||||
|
echo "$ERROR_MSG" >> $LOGFILE
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@ -36,7 +40,10 @@ X86_64=`echo "${OS_ARCH}" | grep x86_64`
|
|||||||
|
|
||||||
case $HOST_OS in
|
case $HOST_OS in
|
||||||
debian | fedora | gentoo | linux | mandrake | redhat | suse )
|
debian | fedora | gentoo | linux | mandrake | redhat | suse )
|
||||||
if [ "X$X86_64" = "X" ]; then
|
if [ `echo $OS_ARCH |grep arm` ]; then
|
||||||
|
wrapperpath="./lib/wrapper/linux-arm"
|
||||||
|
cp ${wrapperpath}/libwrapper.so ./lib/
|
||||||
|
elif [ "X$X86_64" = "X" ]; then
|
||||||
wrapperpath="./lib/wrapper/linux"
|
wrapperpath="./lib/wrapper/linux"
|
||||||
cp ${wrapperpath}/libwrapper.so ./lib/
|
cp ${wrapperpath}/libwrapper.so ./lib/
|
||||||
else
|
else
|
||||||
@ -47,7 +54,7 @@ case $HOST_OS in
|
|||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
freebsd )
|
freebsd )
|
||||||
if [ ! `uname -m |grep amd64` ]; then
|
if [ ! `echo $OS_ARCH | grep amd64` ]; then
|
||||||
wrapperpath="./lib/wrapper/freebsd"
|
wrapperpath="./lib/wrapper/freebsd"
|
||||||
cp ${wrapperpath}/libwrapper.so ./lib/
|
cp ${wrapperpath}/libwrapper.so ./lib/
|
||||||
else
|
else
|
||||||
@ -67,6 +74,9 @@ case $HOST_OS in
|
|||||||
;;
|
;;
|
||||||
* )
|
* )
|
||||||
echo "${ERROR_MSG}"
|
echo "${ERROR_MSG}"
|
||||||
|
echo "Host OS is $HOST_OS" >> $LOGFILE
|
||||||
|
echo "Host architecture is $OS_ARCH" >> $LOGFILE
|
||||||
|
echo "$ERROR_MSG" >> $LOGFILE
|
||||||
exit 1
|
exit 1
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
@ -18,7 +18,7 @@ public class RouterVersion {
|
|||||||
/** deprecated */
|
/** deprecated */
|
||||||
public final static String ID = "Monotone";
|
public final static String ID = "Monotone";
|
||||||
public final static String VERSION = CoreVersion.VERSION;
|
public final static String VERSION = CoreVersion.VERSION;
|
||||||
public final static long BUILD = 26;
|
public final static long BUILD = 27;
|
||||||
|
|
||||||
/** for example "-test" */
|
/** for example "-test" */
|
||||||
public final static String EXTRA = "";
|
public final static String EXTRA = "";
|
||||||
|
Reference in New Issue
Block a user