My environment is arm-linux-androideabi (Android 2.2 on a Toshiba AC100). I have 2 sets of GCC compilers for my environment(installed at separate locations on the device):
- 4.4.3 (Android NDK on Android)
- 4.6.0 (R + GCC on Android)
The problem I face is that the gcc-4.6.0 segfaults whenever it runs (however it runs every task successfully, just segfaulting at the end,probably in the exit routines), while ld-4.4.3 and ar-4.4.3 fail to run on my environment. On the other hand gcc-4.4.3 runs beautifully, as does ld-4.6.0 and ar-4.6.0.
Thus, while building on my device, if I run configure using 4.4.3, it'll fail at the configure step because even if the configure test programs are compiled successfully, gcc segfaults and returns a non-zero value(139). However if I run configure with 4.6.0, configure runs well enough, but the build (make all
) fails miserably at linking and static library creation.
My questions are:
- Is it possible to use gcc-4.4.3 to compile my object files (
gcc-4.4.3 -c input.c
) and then link with ld-4.6.0 (ld-4.6.0 -o input input.o -lc
)? That is, I'll remove the problematic binaries and use a combination of the working binaries to build projects. - If there are caveats, then what are they?