On 2008-05-05 23:46+0100 Jonathan Riddell wrote:


Is there a way to compile a library without adding the "lib" prefix as
TARGET_LINK_LIBRARIES() does?  This is needed for a C python module.

Yes.  (Actually, it is ADD_LIBRARY that creates the target and the default
"lib" name of that target.)  To override the default use

set_target_properties(<targetname> PROPERTIES PREFIX "")

From the CMake documentation....

"Properties that affect the name of a target's output file are as follows.
The PREFIX and SUFFIX properties override the default target name prefix
(such as "lib") and suffix (such as ".so").

Alan
__________________________
Alan W. Irwin

Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).

Programming affiliations with the FreeEOS equation-of-state implementation
for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of
Linux Links project (loll.sf.net); and the Linux Brochure Project
(lbproject.sf.net).
__________________________

Linux-powered Science
__________________________
_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to