This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Linking error when building

Tags: None
(comma "," separated)
User avatar
Alec
Registered Member
Posts
565
Karma
1
OS

Linking error when building

Fri Sep 25, 2009 11:11 pm
Hi,

I wanted to try Gluon, but I get a linking error during the build:

Code: Select all
...
[ 58%] Building CXX object kgl/CMakeFiles/kgl.dir/kglscreenconfig.o
[ 59%] Building CXX object kgl/CMakeFiles/kgl.dir/kglinfowidget.o
In file included from /usr/include/eigen2/Eigen/Core:96,
                 from /usr/include/eigen2/Eigen/Geometry:4,
                 from /home/alec/Desktop/gluon/kgl/kglbaseitem.h:24,
                 from /home/alec/Desktop/gluon/kgl/kglengine.h:26,
                 from /home/alec/Desktop/gluon/kgl/kglinfowidget.h:7,
                 from /home/alec/Desktop/gluon/kgl/kglinfowidget.cpp:1:
/usr/include/eigen2/Eigen/src/Core/util/Memory.h: In function 'void* Eigen::ei_aligned_malloc(size_t)':
/usr/include/eigen2/Eigen/src/Core/util/Memory.h:81: warning: ignoring return value of 'int posix_memalign(void**, size_t, size_t)', declared with attribute warn_unused_result
[ 60%] Building CXX object kgl/CMakeFiles/kgl.dir/qrc_shaders.o
Linking CXX shared library ../lib/libkgl.so
/usr/lib/gcc/i686-pc-linux-gnu/4.4.1/../../../../i686-pc-linux-gnu/bin/ld: warning: creating a DT_TEXTREL in object.
collect2: ld returned 1 exit status
make[2]: *** [lib/libkgl.so.4.3.0] Error 1
make[1]: *** [kgl/CMakeFiles/kgl.dir/all] Error 2
make: *** [all] Error 2


Is it supposed to build against KDE 4.3.1, or would I need trunk to do that?


Get problems solved faster - get reply notifications through Jabber!
User avatar
dridk
Moderator
Posts
59
Karma
0
OS

Re: Linking error when building

Sat Sep 26, 2009 12:43 am
Strange error ... I ve never seen that... ! I will take a look on it.
User avatar
Alec
Registered Member
Posts
565
Karma
1
OS

Re: Linking error when building

Tue Sep 29, 2009 4:21 am
If you need any additional information, feel free to ask :)


Get problems solved faster - get reply notifications through Jabber!
User avatar
Alec
Registered Member
Posts
565
Karma
1
OS

Re: Linking error when building

Tue Sep 29, 2009 6:09 pm
Looks like this is the problem:

Code: Select all
creating a DT_TEXTREL in object.


And this is the solution.


Get problems solved faster - get reply notifications through Jabber!
ahiemstra
Moderator
Posts
6
Karma
0
OS

Re: Linking error when building

Thu Oct 01, 2009 2:52 pm
Hmm, what system are you building gluon on? Errors with PIC usually are something related to the distro's libraries and not likely something we can do anything about.
User avatar
Alec
Registered Member
Posts
565
Karma
1
OS

Re: Linking error when building

Thu Oct 01, 2009 5:00 pm
The system is Gentoo Linux (x86), GCC 4.4.1, Binutils 2.19.1... Not sure what exactly you want to know.

What apparently is happening is that the library is being created without position-independent code, which, from my understanding, is a requirement for a shared library. So if I add the -fpic flag, everything actually compiles fine (although I haven't tried to see if it actually works).


Get problems solved faster - get reply notifications through Jabber!
angry
Registered Member
Posts
3
Karma
0

Re: Linking error when building

Sat Mar 22, 2014 9:05 am
you want to build linking principles must be true, slowly,
slowly fast time can not be too fast without error happens.


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], kesang, Yahoo [Bot]