Revision: 40489
http://brlcad.svn.sourceforge.net/brlcad/?rev=40489&view=rev
Author: starseeker
Date: 2010-09-07 18:23:37 +0000 (Tue, 07 Sep 2010)
Log Message:
-----------
Since we're never going to want liblib as our prefix on a file name, have our
add_library wrapper catch target names with lib in them and turn off the lib
PREFIX in the target properties. Now if we decide to rename all the lib
targets (e.g. bu->libbu, bn->libbn, etc.) all we have to do is rename them.
Modified Paths:
--------------
brlcad/branches/cmake/CMakeLists.txt
brlcad/branches/cmake/src/libicv/CMakeLists.txt
brlcad/branches/cmake/src/librt/CMakeLists.txt
brlcad/branches/cmake/src/rt/CMakeLists.txt
Modified: brlcad/branches/cmake/CMakeLists.txt
===================================================================
--- brlcad/branches/cmake/CMakeLists.txt 2010-09-07 18:08:41 UTC (rev
40488)
+++ brlcad/branches/cmake/CMakeLists.txt 2010-09-07 18:23:37 UTC (rev
40489)
@@ -103,8 +103,11 @@
# versions in order to keep track of targets and
# define rules for all products.
function(add_library name)
+ _add_library(${name} ${ARGN})
+ IF(${name} MATCHES "^lib*")
+ set_target_properties(${name} PROPERTIES PREFIX "")
+ ENDIF(${name} MATCHES "^lib*")
SET(CMAKE_LIBRARY_TARGET_LIST "${CMAKE_LIBRARY_TARGET_LIST};${name}" CACHE
STRING "list of lib targets" FORCE)
- _add_library(${name} ${ARGN})
get_target_property(targetfile ${name} LOCATION)
STRING(REGEX REPLACE "liblib" "lib" targetvar "${targetfile}")
SET(CMAKE_LIBRARY_TARGET_FILE_LIST
"${CMAKE_LIBRARY_TARGET_FILE_LIST};${targetfile}" CACHE STRING "list of lib
target files" FORCE)
Modified: brlcad/branches/cmake/src/libicv/CMakeLists.txt
===================================================================
--- brlcad/branches/cmake/src/libicv/CMakeLists.txt 2010-09-07 18:08:41 UTC
(rev 40488)
+++ brlcad/branches/cmake/src/libicv/CMakeLists.txt 2010-09-07 18:23:37 UTC
(rev 40489)
@@ -13,4 +13,4 @@
-DBRLCADBUILD
)
-BRLCAD_ADDLIB(libicv "${LIBICV_SOURCES}" bu)
+BRLCAD_ADDLIB(icv "${LIBICV_SOURCES}" bu)
Modified: brlcad/branches/cmake/src/librt/CMakeLists.txt
===================================================================
--- brlcad/branches/cmake/src/librt/CMakeLists.txt 2010-09-07 18:08:41 UTC
(rev 40488)
+++ brlcad/branches/cmake/src/librt/CMakeLists.txt 2010-09-07 18:23:37 UTC
(rev 40489)
@@ -255,6 +255,5 @@
endif(MSVC)
BRLCAD_ADDLIB(librt "${LIBRT_SOURCES}" "bu bn ${BRLCAD_OPENNURBS_LIBRARY}
${BRLCAD_REGEX_LIBRARY} ${BRLCAD_ZLIB_LIBRARY}")
-set_target_properties(librt PROPERTIES PREFIX "")
install(FILES librt.3 DESTINATION ${BRLCAD_INSTALL_MAN_DIR}/man3)
Modified: brlcad/branches/cmake/src/rt/CMakeLists.txt
===================================================================
--- brlcad/branches/cmake/src/rt/CMakeLists.txt 2010-09-07 18:08:41 UTC (rev
40488)
+++ brlcad/branches/cmake/src/rt/CMakeLists.txt 2010-09-07 18:23:37 UTC (rev
40489)
@@ -187,11 +187,9 @@
BRLCAD_ADDEXEC(rtxray "${rtxray_SRCS}" "${CMAKE_THREAD_LIBS_INIT} fb librt
optical")
add_library(libremrt STATIC ${LIBREMRT_SOURCES})
-set_target_properties(libremrt PROPERTIES PREFIX "")
INSTALL(TARGETS libremrt ARCHIVE DESTINATION ${BRLCAD_INSTALL_LIB_DIR})
add_library(librttherm STATIC ${RT_COMMON_SRCS})
-set_target_properties(librttherm PROPERTIES PREFIX "")
INSTALL(TARGETS librttherm ARCHIVE DESTINATION ${BRLCAD_INSTALL_LIB_DIR})
SET_TARGET_PROPERTIES(librttherm PROPERTIES LINKER_LANGUAGE C)
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
This SF.net Dev2Dev email is sponsored by:
Show off your parallel programming skills.
Enter the Intel(R) Threading Challenge 2010.
http://p.sf.net/sfu/intel-thread-sfd
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits