|
From: <rus...@us...> - 2008-10-25 03:47:02
|
Revision: 341
http://gearbox.svn.sourceforge.net/gearbox/?rev=341&view=rev
Author: russo2503v
Date: 2008-10-25 03:46:59 +0000 (Sat, 25 Oct 2008)
Log Message:
-----------
minor changes related to GBX_DEFAULT_LIB_TYPE
Modified Paths:
--------------
gearbox/trunk/doc/buildsys.dox
Modified: gearbox/trunk/doc/buildsys.dox
===================================================================
--- gearbox/trunk/doc/buildsys.dox 2008-10-25 03:46:06 UTC (rev 340)
+++ gearbox/trunk/doc/buildsys.dox 2008-10-25 03:46:59 UTC (rev 341)
@@ -55,7 +55,7 @@
FILE( GLOB hdrs *.h )
FILE( GLOB srcs *.cpp )
- GBX_ADD_LIBRARY( ${lib_name} ${srcs} )
+ GBX_ADD_LIBRARY( ${lib_name} DEFAULT ${srcs} )
TARGET_LINK_LIBRARIES( ${lib_name} ${dep_libs} )
GBX_ADD_HEADERS( gbxadvanced ${hdrs} )
@@ -163,15 +163,18 @@
GBX_ADD_LIBRARY( ${lib_name} DEFAULT ${srcs} )
TARGET_LINK_LIBRARIES( ${lib_name} ${dep_libs} )
@endverbatim
-Here we tell CMake to create rules for building a library of the default type (shared or static) and to specify dependencies. Now you can see why we bothered with defining variables. These commands are generic and can be easily used for other libraries.
+
@c GBX_ADD_LIBRARY is a custom GearBox macro. It does several things:
- Actually defines a library target (with a standard command @c ADD_LIBRARY ). In Linux, this will produce @c libGbxAdvanced.so or @c libGbxAdvanced.a
+- Specifies library type. Valid options are SHARED, STATIC, or DEFAULT (the prefered option). DEFAULT is resolved to the user-specified variable GBX_DEFAULT_LIB_TYPE (which initially is set to SHARED).
- Specifies standard installation directory: @c [PREFIX]/lib/gearbox/
- Adds the name of the library to the global list of libraries which will be built (for feedback).
@c TARGET_LINK_LIBRARIES is a standard CMake command. It specifies that our library is to be linked to our dependencies.
+Now you can see why we bothered with defining variables. These commands are generic and can be easily used for other libraries.
+
@verbatim
GBX_ADD_HEADERS( gbxadvanced ${hdrs} )
@endverbatim
@@ -185,6 +188,11 @@
@section gbx_doc_buildsys_varlist A list of useful CMake variables defined by GearBox
+Build system configuration:
+@verbatim
+GBX_DEFAULT_LIB_TYPE # Valid options {SHARED, STATIC}. Defaults to SHARED.
+@endverbatim
+
OS variables: evaluate to TRUE when running on the corresponding OS, otherwise to FALSE. We define our own because the standard CMake ones are inconsistently named and the one for Linux is not defined.
@verbatim
GBX_OS_LINUX
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|