CMake based build system
authorAkos Ladanyi <ladanyi@tmit.bme.hu>
Sun, 13 Apr 2008 13:22:52 +0200
changeset 14196f81c791f0c
parent 137 483bc6ed7292
child 142 8b703d177341
CMake based build system
.hgignore
CMakeLists.txt
benchmark/Makefile
demo/CMakeLists.txt
demo/Makefile
doc/Makefile
lemon/CMakeLists.txt
lemon/Makefile
test/CMakeLists.txt
test/Makefile
tools/Makefile
     1.1 --- a/.hgignore	Fri Apr 18 06:20:32 2008 +0100
     1.2 +++ b/.hgignore	Sun Apr 13 13:22:52 2008 +0200
     1.3 @@ -34,3 +34,8 @@
     1.4  ^objs.*/.*
     1.5  ^test/[a-z_]*$
     1.6  ^demo/.*_demo$
     1.7 +^build/.*
     1.8 +CMakeFiles
     1.9 +DartTestfile.txt
    1.10 +cmake_install.cmake
    1.11 +CMakeCache.txt
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/CMakeLists.txt	Sun Apr 13 13:22:52 2008 +0200
     2.3 @@ -0,0 +1,5 @@
     2.4 +project (LEMON)
     2.5 +enable_testing ()
     2.6 +add_subdirectory (lemon)
     2.7 +add_subdirectory (demo)
     2.8 +add_subdirectory (test)
     3.1 --- a/benchmark/Makefile	Fri Apr 18 06:20:32 2008 +0100
     3.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     3.3 @@ -1,2 +0,0 @@
     3.4 -all:
     3.5 -	$(MAKE) -C ..
     4.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.2 +++ b/demo/CMakeLists.txt	Sun Apr 13 13:22:52 2008 +0200
     4.3 @@ -0,0 +1,13 @@
     4.4 +include_directories (${LEMON_SOURCE_DIR})
     4.5 +
     4.6 +link_directories (${LEMON_BINARY_DIR}/lemon)
     4.7 +
     4.8 +set (DEMOS
     4.9 +  arg_parser_demo
    4.10 +  graph_to_eps_demo
    4.11 +  lgf_demo)
    4.12 +
    4.13 +foreach (DEMO_NAME ${DEMOS})
    4.14 +  add_executable (${DEMO_NAME} ${DEMO_NAME}.cc)
    4.15 +  target_link_libraries (${DEMO_NAME} lemon)
    4.16 +  endforeach (DEMO_NAME)
     5.1 --- a/demo/Makefile	Fri Apr 18 06:20:32 2008 +0100
     5.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     5.3 @@ -1,2 +0,0 @@
     5.4 -all:
     5.5 -	$(MAKE) -C ..
     6.1 --- a/doc/Makefile	Fri Apr 18 06:20:32 2008 +0100
     6.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     6.3 @@ -1,2 +0,0 @@
     6.4 -all:
     6.5 -	$(MAKE) -C ..
     7.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     7.2 +++ b/lemon/CMakeLists.txt	Sun Apr 13 13:22:52 2008 +0200
     7.3 @@ -0,0 +1,2 @@
     7.4 +include_directories (${LEMON_SOURCE_DIR})
     7.5 +add_library (lemon arg_parser.cc base.cc color.cc random.cc)
     8.1 --- a/lemon/Makefile	Fri Apr 18 06:20:32 2008 +0100
     8.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     8.3 @@ -1,2 +0,0 @@
     8.4 -all:
     8.5 -	$(MAKE) -C ..
     9.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     9.2 +++ b/test/CMakeLists.txt	Sun Apr 13 13:22:52 2008 +0200
     9.3 @@ -0,0 +1,24 @@
     9.4 +include_directories (${LEMON_SOURCE_DIR})
     9.5 +
     9.6 +link_directories (${LEMON_BINARY_DIR}/lemon)
     9.7 +
     9.8 +set (TESTS
     9.9 +  bfs_test
    9.10 +  counter_test
    9.11 +  dfs_test
    9.12 +  digraph_test
    9.13 +  dim_test
    9.14 +  error_test
    9.15 +  graph_test
    9.16 +  kruskal_test
    9.17 +  maps_test
    9.18 +  random_test
    9.19 +  path_test
    9.20 +  time_measure_test
    9.21 +  unionfind_test)
    9.22 +
    9.23 +foreach (TEST_NAME ${TESTS})
    9.24 +  add_executable (${TEST_NAME} ${TEST_NAME}.cc)
    9.25 +  target_link_libraries (${TEST_NAME} lemon)
    9.26 +  add_test(${TEST_NAME} ${TEST_NAME})
    9.27 +endforeach (TEST_NAME)
    10.1 --- a/test/Makefile	Fri Apr 18 06:20:32 2008 +0100
    10.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
    10.3 @@ -1,2 +0,0 @@
    10.4 -all:
    10.5 -	$(MAKE) -C ..
    11.1 --- a/tools/Makefile	Fri Apr 18 06:20:32 2008 +0100
    11.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
    11.3 @@ -1,2 +0,0 @@
    11.4 -all:
    11.5 -	$(MAKE) -C ..