Re: [CMake] How can link to a library just like the system libs?

2009-03-14 Thread Philip Lowman
On Sat, Mar 14, 2009 at 10:43 AM, Kermit Mei wrote: > Hello, I have a library which had been installed into my system > under /usr/lib/. When I manually compile it, I must type: > cc -Wall udpcli.c -o cli -lapue > > Now, I wrote my cmakelists.txt like this: > CMAKE_MINIMUM_REQUIRED(VERSION 2.6) >

[CMake] How can link to a library just like the system libs?

2009-03-14 Thread Kermit Mei
Hello, I have a library which had been installed into my system under /usr/lib/. When I manually compile it, I must type: cc -Wall udpcli.c -o cli -lapue Now, I wrote my cmakelists.txt like this: CMAKE_MINIMUM_REQUIRED(VERSION 2.6) PROJECT(UDPCS) FIND_LIBRARY(APUE_LIB, /usr/lib/) ADD_EXECUTABLE(se