-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
x86 & MIPS binaries #4
Comments
I think it is unlikely that you will ever get it to compile on Windows. In any case, a Windows-based cross compile is not something I'm willing to support. Once you've got the Ubuntu 12.04 virtual machine up and running, you'll need to ensure that you have an appropriate build environment. You'll need, at a minimum, build-essential, autotools, and m4. Then you have to consider the target architecture. Does the NDK specify any required flags for the compiler and/or the linker, as it does for the ARM architecture? What CFLAGS should you use when optimizing the code? Do you build binaries with debugging symbols? Are there multiple MIPS targets (as with ARM, where there are two different ABIs)? Does the GMP platform itself require specific CFLAGS in addition to those specified by Google in the NDK documentation? Even if you get all of the above questions right, or even close to correct, how do you test and validate the generated binaries? There have been many reported cases where GMP compiles and links cleanly, but generates incorrect results at runtime. They even say so on their website - GMP tends to test the unexplored corners of compiler optimizers, so it is crucial that you find a way to test the shared object prior to distribution. I guess what I'm saying here is that targeting a new cross-compiled architecture with GMP is not a trivial task. You cannot just take the script from this git repository, replace the toolchain, and expect it to work. I guarantee you that it will not. I will consider doing this work, but it probably won't happen for several weeks at a minimum. |
Initial mips & x86 support has been added under tag bin_5.0.5_r3. Please proceed with caution as these builds have not been tested. If you're able to run them and they work (i.e. they do not crash and they generate correct results), please let me know. I'll leave the issue open in the hopes that you report back. |
Hi, |
Thanks for testing. I spent some time tonight to run the armeabi test suite binaries on a Galaxy Nexus running Jelly Bean. As far as I can tell everything runs fine, so I think I'll call it good. |
Hi,
Thanks for the latest repo update it works a treat.
Would you please if possible include x86 and MIPS compiled binaries to the set.
I have tried to build gmp-5.0.5 myself using Cygwin under Win 7 Ultimate x64 but have got errors I have not been able to resolve.
I am busy building an Ubuntu v12.04 machine (using VM Virtual box) so that I have the same build environment you describe but have not completed it yet.
In the meantime I would apreciate any pointers with where my problem may be in building the library,
I changed the first export command (in compile-gmp.sh) to export NDK="/cygdrive/f/Android/android-ndk-r8b" (which is the correct path for the NDK) and I get the following when running the script,
Deon Marais@Deon-Desktop-Ne /cygdrive/f/Android/gmp-5.0.5
$ ./compile-gmp.sh
checking build system type... i686-pc-linux-gnu
checking host system type... arm-unknown-linux-androideabi
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for arm-linux-androideabi-strip... arm-linux-androideabi-strip
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking ABI=standard
checking compiler arm-linux-androideabi-gcc -O2 -pedantic -fomit-frame-pointer -march=armv7-a -mfloat-abi=softfp -mfpu=neon -ftree-vectorize -ftree-vectorizer-verbose=2 ... yes
checking whether ARM gcc unsigned division works... yes
checking for arm-linux-androideabi-gcc... arm-linux-androideabi-gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... yes
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether arm-linux-androideabi-gcc accepts -g... yes
checking for arm-linux-androideabi-gcc option to accept ISO C89... none needed
checking for arm-linux-androideabi-gcc option to accept ISO C99... -std=gnu99
checking for arm-linux-androideabi-gcc -std=gnu99 option to accept ISO Standard C... (cached) -std=gnu99
checking how to run the C preprocessor... arm-linux-androideabi-gcc -std=gnu99 -E
checking build system compiler arm-linux-androideabi-gcc -std=gnu99... no
checking build system compiler arm-linux-androideabi-gcc -std=gnu99 -O2 -pedantic -fomit-frame-pointer -march=armv7-a -mfloat-abi=softfp -mfpu=neon -ftree-vectorize -ftree-vectorizer-verbose=2 ... no
checking build system compiler cc... no
checking build system compiler gcc... no
checking build system compiler c89... no
checking build system compiler c99... no
configure: error: Cannot find a build system compiler
make: *** No targets specified and no makefile found. Stop.
make: Nothing to be done for
install'. ./compile-gmp.sh: line 45: cd: armeabi-v7a-neon: No such file or directory make: *** No rule to make target
distclean'. Stop.checking build system type... i686-pc-linux-gnu
checking host system type... arm-unknown-linux-androideabi
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for arm-linux-androideabi-strip... arm-linux-androideabi-strip
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking ABI=standard
checking compiler arm-linux-androideabi-gcc -O2 -pedantic -fomit-frame-pointer -march=armv7-a -mfloat-abi=softfp ... yes
checking whether ARM gcc unsigned division works... yes
checking for arm-linux-androideabi-gcc... arm-linux-androideabi-gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... yes
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether arm-linux-androideabi-gcc accepts -g... yes
checking for arm-linux-androideabi-gcc option to accept ISO C89... none needed
checking for arm-linux-androideabi-gcc option to accept ISO C99... -std=gnu99
checking for arm-linux-androideabi-gcc -std=gnu99 option to accept ISO Standard C... (cached) -std=gnu99
checking how to run the C preprocessor... arm-linux-androideabi-gcc -std=gnu99 -E
checking build system compiler arm-linux-androideabi-gcc -std=gnu99... no
checking build system compiler arm-linux-androideabi-gcc -std=gnu99 -O2 -pedantic -fomit-frame-pointer -march=armv7-a -mfloat-abi=softfp ... no
checking build system compiler cc... no
checking build system compiler gcc... no
checking build system compiler c89... no
checking build system compiler c99... no
configure: error: Cannot find a build system compiler
make: *** No targets specified and no makefile found. Stop.
make: Nothing to be done for
install'. ./compile-gmp.sh: line 53: cd: armeabi-v7a: No such file or directory make: *** No rule to make target
distclean'. Stop.checking build system type... i686-pc-linux-gnu
checking host system type... arm-unknown-linux-androideabi
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for arm-linux-androideabi-strip... arm-linux-androideabi-strip
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking ABI=standard
checking compiler arm-linux-androideabi-gcc -O2 -pedantic -fomit-frame-pointer ... yes
checking whether ARM gcc unsigned division works... yes
checking for arm-linux-androideabi-gcc... arm-linux-androideabi-gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... yes
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether arm-linux-androideabi-gcc accepts -g... yes
checking for arm-linux-androideabi-gcc option to accept ISO C89... none needed
checking for arm-linux-androideabi-gcc option to accept ISO C99... -std=gnu99
checking for arm-linux-androideabi-gcc -std=gnu99 option to accept ISO Standard C... (cached) -std=gnu99
checking how to run the C preprocessor... arm-linux-androideabi-gcc -std=gnu99 -E
checking build system compiler arm-linux-androideabi-gcc -std=gnu99... no
checking build system compiler arm-linux-androideabi-gcc -std=gnu99 -O2 -pedantic -fomit-frame-pointer ... no
checking build system compiler cc... no
checking build system compiler gcc... no
checking build system compiler c89... no
checking build system compiler c99... no
configure: error: Cannot find a build system compiler
make: *** No targets specified and no makefile found. Stop.
make: Nothing to be done for
install'. ./compile-gmp.sh: line 61: cd: armeabi: No such file or directory make: *** No rule to make target
distclean'. Stop.Thanks again.
The text was updated successfully, but these errors were encountered: