Mercurial > hg > freeDiameter
annotate CMakeLists.txt @ 249:6e6ada749a11
Replaced clock_nanosleep since it is missing on FreeBSD platform
author | Sebastien Decugis <sdecugis@nict.go.jp> |
---|---|
date | Fri, 02 Apr 2010 15:55:26 +0900 |
parents | fc7c18867cf7 |
children | 71e508379671 |
rev | line source |
---|---|
0 | 1 # This file is the source for generating the Makefile for the project, using cmake tool (cmake.org) |
2 | |
3 # Name of the project, and language | |
1
bafb831ba688
Fix names to proper case for freeDiameter
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
0
diff
changeset
|
4 PROJECT("freeDiameter" C) |
0 | 5 |
8
3e143f047f78
Backup for the week-end
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
1
diff
changeset
|
6 # Informations to display in daemon's help |
3e143f047f78
Backup for the week-end
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
1
diff
changeset
|
7 SET(FD_PROJECT_NAME freeDiameter) |
3e143f047f78
Backup for the week-end
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
1
diff
changeset
|
8 SET(FD_PROJECT_BINARY freeDiameterd) |
3e143f047f78
Backup for the week-end
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
1
diff
changeset
|
9 SET(FD_PROJECT_VERSION_MAJOR 0) |
3e143f047f78
Backup for the week-end
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
1
diff
changeset
|
10 SET(FD_PROJECT_VERSION_MINOR 1) |
3e143f047f78
Backup for the week-end
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
1
diff
changeset
|
11 SET(FD_PROJECT_VERSION_REV 0) |
3e143f047f78
Backup for the week-end
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
1
diff
changeset
|
12 SET(FD_PROJECT_COPYRIGHT "Copyright (c) 2008-2009, WIDE Project (www.wide.ad.jp) and NICT (www.nict.go.jp)") |
3e143f047f78
Backup for the week-end
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
1
diff
changeset
|
13 |
0 | 14 # Some subfolders may have tests |
15 ENABLE_TESTING() | |
16 | |
17 # CMake version | |
18 CMAKE_MINIMUM_REQUIRED(VERSION 2.6) | |
19 | |
20 # Location of additional CMake modules | |
21 SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/Modules/") | |
22 | |
23 # All source code should be POSIX 200112L compatible, but some other extensions might be used, so: | |
24 ADD_DEFINITIONS(-D_GNU_SOURCE) | |
9
fc7c18867cf7
New extension mechanism committed
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
8
diff
changeset
|
25 IF (CMAKE_BUILD_TYPE MATCHES "Debug") |
fc7c18867cf7
New extension mechanism committed
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
8
diff
changeset
|
26 SET(DEBUG 1) |
fc7c18867cf7
New extension mechanism committed
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
8
diff
changeset
|
27 ENDIF (CMAKE_BUILD_TYPE MATCHES "Debug") |
0 | 28 |
29 # some subfolders use yacc and lex parsers | |
30 SET(BISON_GENERATE_DEFINES TRUE) | |
31 SET(BISON_PREFIX_OUTPUTS TRUE) | |
32 INCLUDE(CMakeUserUseBison) | |
33 SET(FLEX_PREFIX_OUTPUTS TRUE) | |
34 INCLUDE(CMakeUserUseFlex) | |
35 IF( NOT BISON_EXECUTABLE OR NOT FLEX_EXECUTABLE ) | |
36 MESSAGE( SEND_ERROR "Bison and Flex are required" ) | |
37 ENDIF( NOT BISON_EXECUTABLE OR NOT FLEX_EXECUTABLE ) | |
38 # Check that flex is at least 2.5.20 to support bison-bridge | |
39 # how to do the check with cmake??? | |
40 | |
8
3e143f047f78
Backup for the week-end
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
1
diff
changeset
|
41 # Location for the include files |
3e143f047f78
Backup for the week-end
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
1
diff
changeset
|
42 INCLUDE_DIRECTORIES(include) |
3e143f047f78
Backup for the week-end
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
1
diff
changeset
|
43 INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}/include) |
3e143f047f78
Backup for the week-end
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
1
diff
changeset
|
44 SUBDIRS(include/freeDiameter) |
3e143f047f78
Backup for the week-end
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
1
diff
changeset
|
45 |
0 | 46 # Location for the source code |
1
bafb831ba688
Fix names to proper case for freeDiameter
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
0
diff
changeset
|
47 SUBDIRS(libfreeDiameter) |
bafb831ba688
Fix names to proper case for freeDiameter
Sebastien Decugis <sdecugis@nict.go.jp>
parents:
0
diff
changeset
|
48 SUBDIRS(freeDiameter) |
0 | 49 |
50 # Do we build the extensions? | |
51 OPTION(IGNORE_ALL_EXTENSIONS "Ignore the extensions completly?") | |
52 IF(NOT IGNORE_ALL_EXTENSIONS) | |
53 SUBDIRS(extensions) | |
54 ENDIF(NOT IGNORE_ALL_EXTENSIONS) |