- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I'm trying to build libpng with x86-icc. I already built it using the x86 standard toolchain from the ndk, but want to use the intel compiler now.
Therefore I try to make a new standalone toolchain with the following command:
$ANDROID_NDK_ROOT/build/tools/make-standalone-toolchain.sh --platform=android-9 --install-dir=$PLATFORM_PREFIX --toolchain=x86-icc --verbose
Wich fails with the following output:
Auto-config: --arch=x86
Targetting CPU: x86
Using GCC version:
Toolchain /<path to my android ndk>/android-ndk-r9d/toolchains/x86-icc/prebuilt/darwin-x86_64/bin/i686-linux-android-gcc is missing!
I've checked and there is no prebuilt directory in .../x86-icc. How do I get a standalone build chain for android ndk that uses he intel compiler? Any help is greatly appreciated!
I'm running this on macos x with android ndk-r9d
- Tags:
- Android* OS
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
That sounds good, however I'm still not sure how to configure the cross compilation build correctly.
The library in question is libpng and currently for android x86 builds I'm doing the following to build libpng.a
1. make-standalone-toolchain.sh --platform=android-9 --install-dir=$PLATFORM_PREFIX --toolchain=x86-4.6
2. ./configure --host=i686-linux-android --prefix=$PLATFORM_PREFIX
3. make
4. make install
I've changed this now for the ICC to:
1. source /opt/intel/cc_android_14.0.2.024/bin/compilervars.sh
2. ./configure --host=i686-linux-android --prefix=/opt/intel/cc_android_14.0.2.024/toolchains/r9/x86-icc
3. make
--> from the output I can see it is still using gcc
e.g.
libtool: compile: gcc -DHAVE_CONFIG_H -I. -DPNG_CONFIGURE_LIBPNG -g -O2 -MT libpng14_la-pngwutil.lo -MD -MP -MF .deps/libpng14_la-pngwutil.Tpo -c pngwutil.c -o libpng14_la-pngwutil.o
Am I missing a step?
Thanks,
Wolfgang
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Got it, I was missing the CC, CCX, LD and AR environment variables before running configure.
Setting:
export CC="icc -m32 -march=ia32"
export CXX="icpc -m32 -march=ia32"
export LD="xild"
export AR="xiar"
and running:
./configure --host=i686-linux-android --prefix=`pwd`/android-x86-icc
now works.
Thanks for the assistance.
As you asked for feedback on the documentation. I think a note stating that running make-standalone-toolchain.sh isn't necessary as long as you source the compilervars.sh would have helped me to better understand the differences between gcc x86 and icc.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Wolfang,
I'm glad that you solved it.
Thanks for your feedback. I will try to get it in the next release.
Alex

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page