target_link_libraries not linking requested libraries?

Tanner Lovelace clubjuggler at gmail.com
Sun Apr 2 07:00:37 CEST 2006


On 4/1/06, Benjamin Reed <rangerrick at gmail.com> wrote:
> When building kdesu, for some reason it's not linking against -lkdesu.
>  The CMakeFile.txt in kdesu/kdesu specifies:
>
> ---(snip!)---
> set(kdesu_SRCS kdesu.cpp sudlg.cpp )
> kde4_automoc(${kdesu_SRCS})
> kde4_add_executable(kdesu ${kdesu_SRCS})
> target_link_libraries(kdesu ${KDE4_KIO_LIBS} kdesu )
> install_targets(/bin kdesu )
> ---(snip!)---

I seem to remember CMake having problems when two
targets have the same name.  Perhaps the library
kdesu target needs to have a different name or just
use the sources from the kdesu library?  If I recall
correctly, even if the target has a different name, you
can set the output name to still be libkdesu.

Can anyone confirm, please?

Cheers,
Tanner


--
Tanner Lovelace
clubjuggler at gmail dot com
http://wtl.wayfarer.org/
(fieldless) In fess two roundels in pale, a billet fesswise and an
increscent, all sable.


More information about the Kde-buildsystem mailing list