______________________________________ From: [email protected] [[email protected]] on behalf of Gary Thomas [[email protected]] Sent: Thursday, April 02, 2015 11:58 AM To: [email protected] Subject: Re: [yocto] How to find libraries when building software
On 2015-04-02 11:36, Andy Falanga (afalanga) wrote: > HI, > > Thanks to Gary Thomas' response, I was able to get the python libraries from > Boost built. Now, when I'm building my own library, which requires > libboost_python, the configure script isn't able to find it. How do I work > with these cross compilation environments? > > What I have is this. I added the line below to local.conf as Gary instructed. > > PACKAGECONFIG_pn-boost = "python" > > I then ran > > bitbake core-image-minimal > > This built both python and the full set of boost (include libboost_python). > I see this in <output_dir>/sysroots/zc706-zynq7/usr/lib. (In case it's > relevant, this environment was constructed using > /opt/yocto/poky-dizzy-12.0.1/oe-init-build-env.) I then use a script that a > co-worker wrote (quite simple) which configures the paths accordingly to use > the cross compiler toolset. My path is as follows: > > /home/afalanga/src/crisscross/tmp/sysroots/x86_64-linux/usr/bin/arm-poky-linux-gnueabi:/home/afalanga/src/crisscross/tmp/sysroots/x86_64-linux/usr/bin:/opt/yocto/poky-dizzy-12.0.1/scripts:/opt/yocto/poky-dizzy-12.0.1/bitbake/bin:/opt/petalinux-v2014.4-final/tools/linux-i386/arm-xilinx-linux-gnueabi/bin:/opt/petalinux-v2014.4-final/tools/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games > > In my own library project, I run my configure script with this: > > ./configure --host=arm-poky-linux-gnueabi > > All is working quite well except that I run into this error: > ... > checking for Boost headers version >= 1.47.0... yes > checking for Boost's header version... 1_56 > checking for the toolset name used by Boost for arm-poky-linux-gnueabi-g++... > gcc49 -gcc > checking boost/system/error_code.hpp usability... yes > checking boost/system/error_code.hpp presence... yes > checking for boost/system/error_code.hpp... yes > checking for the Boost system library... yes > checking boost/filesystem/path.hpp usability... yes > checking boost/filesystem/path.hpp presence... yes > checking for boost/filesystem/path.hpp... yes > checking for the Boost filesystem library... (cached) yes > checking boost/python.hpp usability... no > checking boost/python.hpp presence... no > checking for boost/python.hpp... no > configure: error: cannot find boost/python.hpp > > I can find this file in <output_dir>/sysroots/zx706-zinq7/usr/include/boost, > why can't the configure script? What's wrong with how I've done things? Or, > and probably much more beneficial, when I say, > "--host=arm-poky-linux-gnueabi" what does that actually mean? Where are > these things installed? Why is it saying that it cannot find the header when > I can? The only rational explanation is that it's looking somewhere other > than where I am. Thus, I don't understand as much as I should. What should > I read in the manual? Another thing to look at is the 'config.log' in your build (for your "library" recipe). It should tell you more about why it can't find boost/python.hpp I want to ensure I've been clear enough. I fear I didn’t explain well how I'm trying to build my library. (It's a C++ library exposed in python.) I have a standard GNU configure script which I'm trying to use with the cross compiler that was built. I'm not using recipes in bitbake to make this library. Also, I have been reviewing the config.log file. It appears to me that the real problem is that the build cannot find python.h. This is rather strange because the file does exist and it's in .../sysroots/zc706-zynq7/usr/include/python2.7. I would have assumed that the automate macro AM_PATH_PYTHON. At any rate, this does seem to be the problem. Curiously, I haven't yet been able to workaround it by supplying a customized "CPPFLAGS=" argument. I've tried both CPPFLAGS= and "BOOST_PYTHON_CPPFLAGS=" to the same effect. Any pointers are most appreciated. Thanks, Andy -- _______________________________________________ yocto mailing list [email protected] https://lists.yoctoproject.org/listinfo/yocto
