ltib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Ltib] Problem including external libraries


From: Ricardo Ungerer
Subject: Re: [Ltib] Problem including external libraries
Date: Thu, 15 Dec 2011 15:33:15 -0200

On Thu, Dec 15, 2011 at 11:30 AM, Stuart Hughes <address@hidden> wrote:
> Hi Ricardo,
>
> Take a look at the example helloworld package, which has c/cpp examples.
>
> You can try this with:
>
> ./ltib -p helloworld -m prep           # unpack for inspection in rpm/BUILD/
> ./ltib -p helloworld                         # build it
>
> Look in dist/lfs-5.1/helloworld/helloworld.spec for the build instructions.
>
> The problem you have is that you don't need to use CROSS in ltib as within
> the build environment gcc etc is already spoofed to the cross compiler.
>
> Regards, Stuart
>
>
>
>
> On 15/12/11 12:00, Ricardo Ungerer wrote:
>>
>> Hello list,
>>
>> I'm trying to build a very very simple c program:
>>
>> ========= main.cpp
>> #include<stdio.h>
>> #include<boost/filesystem.hpp>
>>
>> int main( int argc, char* argv[] )
>> {
>>     printf("Hello world \n" );
>>     return 0;
>> }
>> =========
>>
>>
>> with this makefile:
>>
>> ========== Makefile
>> CROSS=arm-none-linux-gnueabi-
>>
>> all: link_test
>> link_test: main.cpp
>>        $(CROSS)g++ -lboost_filesystem -o link_test main.cpp
>> ===========
>>
>> the error reported i got is:
>>
>> $ make ARCH=arm CROSS_COMPILER=arm-none-linux-gnueabi- KERNELDIR=../linux
>> main.cpp:6:32: error: boost/filesystem.hpp: No such file or directory
>>
>> My objetive is to successfully include and link the link_test with
>> boost_filesystem. I included the boost package with "ltib
>> --configure"->package list->boost.
>>
>> What i'm not catching here?
>> And how would i do the same with cmake?
>>
>

Hi Stewart,

Removing the variable CROSS on the makefile and compiling it through
ltib *did* work.

Thanks!


-- 
Ricardo Ungerer Garcia Simoes



reply via email to

[Prev in Thread] Current Thread [Next in Thread]