[ 
https://issues.apache.org/jira/browse/THRIFT-2127?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14085603#comment-14085603
 ] 

Robert J. Gebis commented on THRIFT-2127:
-----------------------------------------

I added --disable-tests to my configure parameters Since this was causing a 
problem to run arm image on intel.

./configure CPPFLAGS='-static -I/opt/cross/openssl/include 
-I/opt/cross/zlib/include -I/opt/cross/libevent/include' CFLAGS='-static 
-I/opt/cross/openssl/include -I/opt/cross/zlib/include 
-I/opt/cross/libevent/include' LDFLAGS='-static -L/opt/cross/openssl/lib 
-L/opt/cross/zlib/lib -L/opt/cross/libevent/lib' --host=arm-linux-musleabihf 
--disable-tests --disable-shared --enable-zlib=yes --enable-openssl=yes 
--enable-libevent=yes --enable-boost=yes -with-zlib=/opt/cross/zlib 
--with-openssl=/opt/cross/openssl --with-libevent=/opt/cross/libevent 
--with-boost=/opt/cross/boost --with-cpp --with-python --with-java 
--without-qt4 --without-csharp --without-erlang --without-perl --without-php 
--without-php_extension --without-ruby --without-haskell --without-go 
--without-d --prefix=/opt/cross/thrift-0.9.2

Now I get this error.  arm-linux-musleabihf-gcc does not understand x86_64 nor 
i386

building 'thrift.protocol.fastbinary' extension
creating build/temp.macosx-10.9-intel-2.7
creating build/temp.macosx-10.9-intel-2.7/src
creating build/temp.macosx-10.9-intel-2.7/src/protocol
/opt/cross/arm-linux-musleabihf/bin/arm-linux-musleabihf-gcc -DNDEBUG -g 
-fwrapv -Os -Wall -Wstrict-prototypes -static -I/opt/cross/openssl/include 
-I/opt/cross/zlib/include -I/opt/cross/libevent/include -arch x86_64 -arch i386 
-pipe 
-I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c 
src/protocol/fastbinary.c -o 
build/temp.macosx-10.9-intel-2.7/src/protocol/fastbinary.o
arm-linux-musleabihf-gcc: error: x86_64: No such file or directory
arm-linux-musleabihf-gcc: error: i386: No such file or directory
arm-linux-musleabihf-gcc: error: unrecognized command line option '-arch'
arm-linux-musleabihf-gcc: error: unrecognized command line option '-arch'

> Autoconf scripting does not properly account for cross-compile
> --------------------------------------------------------------
>
>                 Key: THRIFT-2127
>                 URL: https://issues.apache.org/jira/browse/THRIFT-2127
>             Project: Thrift
>          Issue Type: Bug
>          Components: Build Process
>    Affects Versions: 0.9
>         Environment: Ubuntu 12.04 running OpenEmbedded Dylan
>            Reporter: Frank Earl
>            Assignee: Jake Farrell
>         Attachments: fix_autoconf_crosscompile_leaks.patch
>
>
> Trying to get Thrift to Cross-compile within OpenEmbedded to get an ARM based 
> build combined with a full-on SDK for our embedded target.  So far, I'm 
> getting this:
> configure:16347: checking for boostlib >= 1.40.0
> configure:16401: arm-poky-linux-gnueabi-g++  -march=armv7-a -mthumb-interwork 
> -mfloat-abi=softfp -mfpu=neon 
> --sysroot=/home/fearl/git/dc_image_build/poky/build/tmp/sysroots/beaglebone 
> -c -O2 -pipe -g -feliminate-unused-debug-types -fpermissive 
> -fvisibility-inlines-hidden  -I/usr/include conftest.cpp >&5
> cc1plus: warning: include location "/usr/include" is unsafe for 
> cross-compilation [-Wpoison-system-directories]
> configure:16401: $? = 0
> This means it's grabbing from outside the sysroot- which can present bad 
> results on the cross-compile pass.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to