-   Ubuntu (
-   -   Cross-compilation issue in Ubuntu 12.04 (

indarkness 02-10-2013 04:21 PM

Cross-compilation issue in Ubuntu 12.04
Hello !

I'm trying to cross-compile some C++ project in Ubuntu12.04 for an arm-mv5sft-linux-gnueabi processor,I have set the ./configure in this way


./configure --build=i686-linux --host=arm-mv5sft-linux-gnueabi --target=arm-mv5sft-linux-gnueabi CC=~/s/arm-mv5sft-linux-gnueabi/SW3.2p1/bin/arm-mv5sft-linux-gnueabi-gcc CXX=~/s/arm-mv5sft-linux-gnueabi/SW3.2p1/bin/arm-mv5sft-linux-gnueabi-g++ LD=~/s/arm-mv5sft-linux-gnueabi/SW3.2p1/arm-mv5sft-linux-gnueabi/bin/arm-mv5sft-linux-gnueabi-ld LDFLAGS=-L/usr/include/libdaemon --with-sysroot=/home/thales/s/arm-mv5sft-linux-gnueabi/SW3.2p1/arm-mv5sft-linux-gnueabi --prefix=/justInstalled --disable-shared --enable-threads=posix --enable-long-long --enable-target-optspace --disable-nls --with-float=soft --disable-multilib --enable-symvers=gn
The configuration succeeded, however when I do make I got an inclusion error


libtool: link: warning: library `/home/j/s/arm-mv5sft-linux-gnueabi/SW3.2p1/bin/../lib/gcc/arm-mv5sft-linux-gnueabi/4.3.2/../../../../arm-mv5sft-linux-gnueabi/lib/' was moved.
CXX Main.o
Main.cpp:28:30: error: libdaemon/daemon.h: No such file or directory
Main.cpp: In function 'int __daemon_run()':
Main.cpp:175: error: 'daemon_retval_send' was not declared in this scope
make[1]: Leaving directory `/home/j/ibrdtn-svn/daemon'
make: *** [all-recursive] Error 1
If I go to the file Main.cpp to see what is going on, it's complains of the include of libdeamon


    #include "config.h"
    #include "Configuration.h"
    #include <ibrcommon/Logger.h>
    #include <ibrcommon/data/File.h>
    #include <libdaemon/daemon.h> //line 28
    #include <string.h>
    #include <csignal>
    #include <set>

I've checked out that I have installed the libdeamon


@ubuntu:~$ pkg-config --libs libdaemon
    @ubuntu:~$locate libdaemon

Why the inclusion is wrong?? I've tried to include using


./configure (as before) LDFLAGS=-llibdeamon (as before)
But the configure tell me that there's an error, and I have to read the conf.log, which says


/home/j/s/arm-mv5sft-linux-gnueabi/SW3.2p1/bin/../lib/gcc/arm-mv5sft-linux-gnueabi/4.3.2/../../../../arm-mv5sft-linux-gnueabi/bin/ld: cannot find -llibdeamon
    collect2: ld returned 1 exit status

Any idea would be very much appreciated!

Thanks in advance,


All times are GMT -5. The time now is 09:25 AM.