72
72
set (WITHOUT_DOC false)
77
include_directories (BEFORE ${CMAKE_CURRENT_SOURCE_DIR}/include)
77
81
include (FindPkgConfig)
79
pkg_check_modules (quvi libquvi>=0.2.0 REQUIRED)
83
pkg_check_modules (quvi libquvi>=0.2.0 REQUIRED QUIET)
80
84
include_directories (AFTER ${quvi_INCLUDE_DIRS})
81
85
link_directories (${quvi_LIBRARY_DIRS})
83
pkg_check_modules (curl libcurl>=7.20 REQUIRED)
87
if (quvi_VERSION VERSION_GREATER 0.2.7)
88
set (HAVE_QUVIOPT_NOSHORTENED true)
91
if (quvi_VERSION VERSION_GREATER 0.2.11)
92
set (HAVE_QUVIOPT_CATEGORY true)
95
pkg_check_modules (curl libcurl>=7.20 REQUIRED QUIET)
84
96
include_directories (AFTER ${curl_INCLUDE_DIRS})
85
97
link_directories (${curl_LIBRARY_DIRS})
87
pkg_check_modules (pcre libpcrecpp>=8.02 REQUIRED)
99
pkg_check_modules (pcre libpcre>=8.02 REQUIRED QUIET)
88
100
include_directories (AFTER ${pcre_INCLUDE_DIRS})
89
101
link_directories (${pcre_LIBRARY_DIRS})
91
pkg_check_modules (pcrecpp libpcrecpp>=8.02 REQUIRED)
103
pkg_check_modules (pcrecpp libpcrecpp>=8.02 REQUIRED QUIET)
92
104
include_directories (AFTER ${pcrecpp_INCLUDE_DIRS})
93
105
link_directories (${pcrecpp_LIBRARY_DIRS})
116
129
set (boost_VERSION
117
130
"${Boost_MAJOR_VERSION}.${Boost_MINOR_VERSION}.${Boost_SUBMINOR_VERSION}")
132
# Version 3 is a major revision with many new and improved features. It
133
# may, however, break some user code written for Version 2.
135
# To ease the transition, Boost releases 1.44 through 1.47 will supply
136
# both V2 and V3. Version 2 is the default version for Boost release 1.44
137
# and 1.45. Version 3 will be the default starting with release 1.46.
138
# <http://www.boost.org/libs/filesystem/index.html>
140
if (boost_VERSION VERSION_GREATER 1.43.0)
141
set (HAVE_BOOST_FILESYSTEM_VERSION_3 true)
119
144
# Check for headers.
121
146
include (CheckIncludeFile)
132
157
check_function_exists (strerror HAVE_STRERROR)
133
158
check_function_exists (fork HAVE_FORK)
134
159
check_function_exists (getcwd HAVE_GETCWD)
160
check_function_exists (getpid HAVE_GETPID)
161
check_function_exists (signal HAVE_SIGNAL)
138
subdirs (lib cclive man1)
143
message (STATUS "Configuration for")
170
message (STATUS "Configured:")
144
171
message (STATUS " cclive ${VERSION_LONG}")
146
message (STATUS "Options:")
147
message (STATUS " Install prefix: ${CMAKE_INSTALL_PREFIX}")
148
message (STATUS " Host setup : ${HOST_SETUP}")
149
message (STATUS " Build type : ${CMAKE_BUILD_TYPE}")
150
message (STATUS " (debug, release, relwithdebinfo, minsizerel)")
151
message (STATUS " Verbose make : ${CMAKE_VERBOSE_MAKEFILE}")
152
message (STATUS " Without doc : ${WITHOUT_DOC}")
154
173
message (STATUS "Found:")
155
174
message (STATUS " Compiler: ${CMAKE_CXX_COMPILER}")
156
175
message (STATUS " Linker : ${CMAKE_LINKER}")
176
message (STATUS " CMake : ${CMAKE_VERSION}")
157
177
message (STATUS " Make : ${CMAKE_MAKE_PROGRAM}")
178
message (STATUS " Host : ${HOST_SETUP}")
158
179
message (STATUS " quvi : ${quvi_VERSION}")
159
180
message (STATUS " curl : ${curl_VERSION}")
160
181
message (STATUS " pcre : ${pcre_VERSION}")
182
message (STATUS " pcrecpp : ${pcrecpp_VERSION}")
161
183
message (STATUS " boost : ${boost_VERSION}")
185
message (STATUS "Options:")
186
message (STATUS " Install prefix: ${CMAKE_INSTALL_PREFIX}")
187
message (STATUS " Verbose make : ${CMAKE_VERBOSE_MAKEFILE}")
188
message (STATUS " Without doc : ${WITHOUT_DOC}")
189
message (STATUS " Build type : ${CMAKE_BUILD_TYPE}")
190
message (STATUS " (debug, release, relwithdebinfo, minsizerel)")
164
193
# Force these variables to be written to cache.
182
211
"${CMAKE_CURRENT_BINARY_DIR}/config.h"
187
include (InstallRequiredSystemLibraries)
189
set (CPACK_SOURCE_PACKAGE_FILE_NAME
195
set (CPACK_PACKAGE_FILE_NAME ${CPACK_SOURCE_PACKAGE_FILE_NAME})
196
set (CPACK_GENERATOR "TGZ")
197
set (CPACK_SOURCE_GENERATOR "TGZ")
198
set (CPACK_RESOURCE_FILE_LICENSE ${CMAKE_CURRENT_SOURCE_DIR}/COPYING)
199
set (CPACK_RESOURCE_FILE_README ${CMAKE_CURRENT_SOURCE_DIR}/README)
201
set (CPACK_SOURCE_IGNORE_FILES
214
# Notice the inclusion here, after setting the cpack variables.
221
git log --stat --after="Thu Aug 12 15:54:58 2010" >
222
"${CMAKE_CURRENT_SOURCE_DIR}/ChangeLog" && make package_source
214
include_directories (${CMAKE_CURRENT_BINARY_DIR})