For a vala file 'a.vala' using gtk:
$ valac a.vala --pkg gtk+-3.0
/usr/bin/ld: skipping incompatible /usr/lib/libX11.so when searching for -lX11
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-redhat-linux/7/../../../libX11.so when searching for -lX11
/usr/bin/ld: skipping incompatible //lib/libX11.so when searching for -lX11
/usr/bin/ld: skipping incompatible //usr/lib/libX11.so when searching for -lX11
/usr/bin/ld: cannot find -lX11
/usr/bin/ld: skipping incompatible /usr/lib/libpthread.so when searching for -lpthread
collect2: error: ld returned 1 exit status
error: cc exited with status 256
Compilation failed: 1 error(s), 0 warning(s)
However, the following works..
$ valac a.vala --pkg gtk+-3.0 -C
$ gcc a.c `pkg-config gtk+-3.0 --cflags --libs`
Tried removing/installing glibc-devel.x86_64 and/or glibc-devel.i686 with no use.
I'm not sure if this can help but it worth mentioning that I used to use vala normally on Fedora 26 and this problem appeared after installing a fresh Fedora 27.
Related
rishabh#rishabh-virtual-machine:~/Downloads/jabcode-master/src/jabcodeWriter$ make
gcc jabwriter.o -L../jabcode/build -ljabcode -L../jabcode/lib -ltiff -lpng16 -lz -lm -O2 -std=c11 -o bin/jabcodeWriter
/usr/bin/ld: skipping incompatible ../jabcode/lib/libtiff.a when searching for -ltiff
/usr/bin/ld: cannot find -ltiff
/usr/bin/ld: skipping incompatible ../jabcode/lib/libpng16.a when searching for -lpng16
/usr/bin/ld: cannot find -lpng16
/usr/bin/ld: skipping incompatible ../jabcode/lib/libz.a when searching for -lz
/usr/bin/ld: cannot find -lz
collect2: error: ld returned 1 exit status
make: *** [bin/jabcodeWriter] Error 1
I am building this https://github.com/jabcode/jabcode
but facing problem with it
jabcode folder building was completed but other two folder giving me problem.
trying to get the build done so i can run this program
While compiling my project on Ubuntu 14.04 I got the following error:
/usr/bin/ld: /tmp/ccpU0kVX.o: undefined reference to symbol '_ZN7IceUtil19NullHandleExceptionC1EPKci'
//usr/lib/x86_64-linux-gnu/libIceUtil.so.36: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
While compiling ICE project with a command:
g++ -I. server.cpp -lIce -lpthread
This is propably some problem with linking but I can't figure it out.
With Ice 3.6, you need to link with Ice and IceUtil:
g++ -o server server.cpp -pthread -lIce -lIceUtil
See https://doc.zeroc.com/ice/3.6/ice-release-notes/using-the-linux-binary-distributions#id-.UsingtheLinuxBinaryDistributionsv3.6-C++
I am facing a issue when i run the following command while installing caffe on fedora 21
make all
Output:
AR -o .build_release/lib/libcaffe.a
LD -o .build_release/lib/libcaffe.so
/usr/bin/ld: skipping incompatible /usr/lib/libleveldb.so when searching for -lleveldb
/usr/bin/ld: skipping incompatible /usr/lib/libleveldb.so when searching for -lleveldb
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-redhat-linux/4.9.2/../../../libleveldb.so when searching for -lleveldb
/usr/bin/ld: skipping incompatible /lib/libleveldb.so when searching for -lleveldb
/usr/bin/ld: skipping incompatible /usr/lib/libleveldb.so when searching for -lleveldb
/usr/bin/ld: cannot find -lleveldb
/usr/bin/ld: cannot find -lsnappy
/usr/bin/ld: cannot find -lcblas
/usr/bin/ld: cannot find -latlas
collect2: error: ld returned 1 exit status
Makefile:544: recipe for target '.build_release/lib/libcaffe.so' failed
make: *** [.build_release/lib/libcaffe.so] Error 1
[root#parags-pc caffe]#
Some help please!
I still can't get rid of the last two (-lcblas and -latlas) errors. I have installed atlas and OpenBLAS long ago. Also I tried the following commands but with no success
echo "/usr/lib64/atlas" >/etc/ld.so.conf.d/atlas-x86_64.conf
ldconfig -v
Need some inputs!!
The leveldb present in your system seems to be of a different architecture, most probably a 32bit compiled leveldb and 64bit compiled caffe, or vice-versa.
The rest of the libraries are to be installed in Fedora before compiling Caffe.
After I've installed boost for cufflinks, I ran ./configure. I am getting the following error:
checking for exit in -lboost_thread... no
checking for exit in -lboost_thread... (cached) no
checking for exit in -lboost_thread... (cached) no
error: Could not link against boost_thread !
check your config.log, it will show you in more detail why it failed:
configure:11032: checking for exit in -lboost_thread
configure:11057: g++ -o conftest -I/home/jcomeau/include -Wstack-protector -fstack-protector-all -fPIE -DBOOST_SPIRIT_THREADSAFE -DHAVE_BUILD_INFO -D__STDC_FORMAT_MACROS -D_FILE_OFFSET_BITS=64 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -L/home/jcomeau/lib -Wl,-z,relro -Wl,-z,now -pie -L/home/jcomeau/lib conftest.cpp -lboost_thread -lminiupnpc -lminiupnpc -lminiupnpc -lminiupnpc >&5
/usr/bin/ld: warning: libboost_system.so.1.54.0, needed by /home/jcomeau/lib/libboost_thread.so, not found (try using -rpath or -rpath-link)
/home/jcomeau/lib/libboost_thread.so: undefined reference to `boost::system::system_category()'
/home/jcomeau/lib/libboost_thread.so: undefined reference to `boost::system::generic_category()'
collect2: error: ld returned 1 exit status
configure:11057: $? = 1
in this case I had to change my ./configure command from:
./configure CXXFLAGS="-I$HOME/include" LDFLAGS="-L$HOME/lib" --prefix=$HOME --with-boost-libdir=$HOME/lib
to:
./configure CXXFLAGS="-I$HOME/include" LDFLAGS="-L$HOME/lib -Wl,-rpath-link,$HOME/lib" --with-boost-libdir=$HOME/lib --prefix=$HOME
in accordance with the advice here: Get rid of "gcc - /usr/bin/ld: warning lib not found"
I'm attempting to assemble some 32-bit code using NASM and GCC on a 64-bit system. I use the following two commands
nasm -f elf32 -g -F stabs coc.asm
gcc -m32 -o coc coc.o
NASM appears to do fine, but LD complains:
/usr/bin/ld: cannot find crt1.o: No such file or directory
/usr/bin/ld: cannot find crti.o: No such file or directory
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.6.1/libgcc.a when searching for -lgcc
/usr/bin/ld: cannot find -lgcc
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.6.1/libgcc_s.so when searching for -lgcc_s
/usr/bin/ld: cannot find -lgcc_s
/usr/bin/ld: cannot find -lc
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.6.1/libgcc.a when searching for -lgcc
/usr/bin/ld: cannot find -lgcc
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.6.1/libgcc_s.so when searching for -lgcc_s
/usr/bin/ld: cannot find -lgcc_s
/usr/bin/ld: cannot find crtn.o: No such file or directory
collect2: ld returned 1 exit status
I'm running Ubuntu 11.10, and I checked and I'm pretty sure libc is installed.
You are not assembling, but linking an executable, which needs OS startup files.
It seems you don't have gcc-*-multilib installed, which contains the necessary files: http://packages.ubuntu.com/oneiric/amd64/gcc-4.6-multilib/filelist
You need to install gcc-multilib to get the proper 32-Bit lib
I had a very similar problem on ubuntu 11.10. See my question on SO about this. What helped for me, was linking the crt*.o to /lib/. After that I never had other problems with this issue. A bit more of a cludge, but for me it solved the problems.