STYLE: Add a lot of comments for the CMake build system
authorMathieu Malaterre <mathieu.malaterre@gmail.com>
Wed, 25 Jan 2006 16:32:48 +0000 (16:32 +0000)
committerMathieu Malaterre <mathieu.malaterre@gmail.com>
Wed, 25 Jan 2006 16:32:48 +0000 (16:32 +0000)
CMakeLists.txt
ChangeLog
DartConfig.cmake
codec/CMakeLists.txt
libopenjpeg/CMakeLists.txt

index efabbe952b1a1f8758de7a7da77dbf4c1596d0a0..a2b8d36e92fb639e753860a6984662f4795c1972 100644 (file)
@@ -1,4 +1,17 @@
+# Main CMakeLists.txt to build the OpenJPEG project using CMake (www.cmake.org)
+# Written by Mathieu Malaterre
+
+# This CMake project will by default create a library called openjpeg
+# But if you want to use this project within your own (CMake) project
+# you will eventually like to prefix the library to avoid linking confusion
+# For this purpose you can define a CMake var: OPJ_PREFIX to whatever you like
+# e.g.:
+# SET(OPJ_PREFIX "gdcm")
+# Also if you want to test (CTest driven) you need to define :
+# OPJ_STANDALONE to 1, e.g
+# OPJ_STANDALONE:BOOL=1
 PROJECT(OPENJPEG C)
+CMAKE_MINIMUM_REQUIRED(VERSION 2.0)
 
 #-----------------------------------------------------------------------------
 # OPENJPEG version number, usefull for packaging and doxygen doc:
index a8103cfcff66849b2ddffdfa28c6d7ab4f838ebe..37136a6cc80efc90619d6f1818efab75e06da78c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -6,6 +6,7 @@ What's New for OpenJPEG
 + : added
 
 January 25, 2006
+! [Mathieu Malaterre] Add a lot of comments on the CMake build system
 ! [Mathieu Malaterre] Fix MINGW32 and BORLAND compilation problems.
 
 January 25, 2006
index 421763f5ca7cd3672c8d1662fabfc86b38c1f131..ec6b0f91a56f9f22e12b4a3ea4174b2f3552d13c 100644 (file)
@@ -9,3 +9,12 @@ SET (DROP_LOCATION "/cgi-bin/HTTPUploadDartFile.cgi")
 SET (TRIGGER_SITE 
     "http://${DROP_SITE}/cgi-bin/Submit-Public-TestingResults.cgi")
 
+# Not used right now, since on public:
+# Project Home Page
+SET (PROJECT_URL "http://www.openjpeg.org")
+
+# Dart server configuration
+#SET (ROLLUP_URL "http://${DROP_SITE}/cgi-bin/openjpeg-rollup-dashboard.sh")
+SET (CVS_WEB_URL "http://euterpe.tele.ucl.ac.be/cgi-bin/viewcvs.cgi/")
+SET (CVS_WEB_CVSROOT "OpenJPEG")
+
index ee496e33a488269a56ecdc65bccc5f21d02a3697..3ed8bedd8ffc9eed16eb4d1a3de301eb70bd135c 100644 (file)
@@ -34,6 +34,7 @@ INCLUDE_DIRECTORIES(
 FOREACH(exe j2k_to_image image_to_j2k)
   ADD_EXECUTABLE(${exe} ${exe}.c ${common_SRCS})
   TARGET_LINK_LIBRARIES(${exe} ${OPJ_PREFIX}openjpeg)
+  # On unix you need to link to the math library:
   IF(UNIX)
     TARGET_LINK_LIBRARIES(${exe} -lm)
   ENDIF(UNIX)
index 08a072edfaa98edbedeac0a22bd270f97092db46..bd3dcbc517cd71467a1316161955b91178c63444 100644 (file)
@@ -1,5 +1,5 @@
 INCLUDE_REGULAR_EXPRESSION("^.*$")
-# Create the lib
+# Defines the source code for the library
 SET(openjpeg_SRCS
   bio.c
   cio.c
@@ -23,6 +23,7 @@ SET(openjpeg_SRCS
   tgt.c
 )
 
+# Handle the dllimport/dllexport for building shared lib on Win32
 IF (WIN32)
   IF (BUILD_SHARED_LIBS)
     ADD_DEFINITIONS(-DOPJ_SHARED)
@@ -31,5 +32,6 @@ IF (WIN32)
   ENDIF (BUILD_SHARED_LIBS)
 ENDIF (WIN32)
 
+# Create the library
 ADD_LIBRARY(${OPJ_PREFIX}openjpeg ${openjpeg_SRCS})