3 CONFIGURE_FILE(${CURL_SOURCE_DIR}/include/curl/curlbuild.h.cmake
4 ${CURL_BINARY_DIR}/include/curl/curlbuild.h)
5 CONFIGURE_FILE(config.h.cmake
6 ${CMAKE_CURRENT_BINARY_DIR}/config.h)
9 ${CMAKE_CURRENT_BINARY_DIR}/config.h
10 ${CURL_BINARY_DIR}/include/curl/curlbuild.h
11 arpa_telnet.h netrc.h file.h timeval.h qssl.h hostip.h
12 progress.h formdata.h cookie.h http.h sendf.h ftp.h url.h dict.h
13 if2ip.h speedcheck.h urldata.h curl_ldap.h ssluse.h escape.h telnet.h
14 getinfo.h strequal.h krb4.h memdebug.h http_chunks.h
15 strtok.h connect.h llist.h hash.h content_encoding.h share.h
16 curl_md5.h http_digest.h http_negotiate.h http_ntlm.h inet_pton.h
17 strtoofft.h strerror.h inet_ntop.h curlx.h memory.h setup.h
18 transfer.h select.h easyif.h multiif.h parsedate.h sslgen.h gtls.h
19 tftp.h sockaddr.h splay.h strdup.h setup_once.h socks.h ssh.h nssg.h
20 curl_base64.h rawstr.h curl_addrinfo.h curl_sspi.h slist.h
24 # amigaos.c - does not build on AmigaOS
60 # memdebug.c -not used
82 # strtok.c - specify later
83 # strtoofft.c - specify later
93 LIST(APPEND libCurl_SRCS libcurl.rc)
96 # if we have Kerberos 4, right now this is never on
97 #OPTION(CURL_KRB4 "Use Kerberos 4" OFF)
99 SET(libCurl_SRCS ${libCurl_SRCS}
105 #OPTION(CURL_MALLOC_DEBUG "Debug mallocs in Curl" OFF)
106 MARK_AS_ADVANCED(CURL_MALLOC_DEBUG)
107 IF(CURL_MALLOC_DEBUG)
108 SET(libCurl_SRCS ${libCurl_SRCS}
111 ENDIF(CURL_MALLOC_DEBUG)
113 IF(CURL_ZLIB AND ZLIB_FOUND)
114 INCLUDE_DIRECTORIES(${ZLIB_INCLUDE_DIR})
118 SET_SOURCE_FILES_PROPERTIES(
132 COMPILE_FLAGS -D_BSD_SOURCE)
133 ENDIF(HAVE_FEATURES_H)
172 # only build compat strtok if we need to
173 IF (NOT HAVE_STRTOK_R)
174 SET(libCurl_SRCS ${libCurl_SRCS}
177 ENDIF (NOT HAVE_STRTOK_R)
179 # only build compat strtoofft if we need to
180 IF(NOT HAVE_STRTOLL AND NOT HAVE__STRTOI64)
181 SET(libCurl_SRCS ${libCurl_SRCS}
184 ENDIF(NOT HAVE_STRTOLL AND NOT HAVE__STRTOI64)
186 # The rest of the build
188 INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}/../include)
189 INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR}/..)
190 INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR}/../include)
191 INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}/..)
192 INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR})
193 INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR})
196 SET(CURL_USER_DEFINED_DYNAMIC_OR_STATIC STATIC)
198 SET(CURL_USER_DEFINED_DYNAMIC_OR_STATIC SHARED)
203 ${CURL_USER_DEFINED_DYNAMIC_OR_STATIC}
204 ${libCurl_HEADERS} ${libCurl_SRCS}
207 TARGET_LINK_LIBRARIES(${LIB_NAME} ${CURL_LIBS})
210 ADD_DEFINITIONS( -D_USRDLL )
213 IF(CURL_ZLIB AND ZLIB_FOUND)
214 TARGET_LINK_LIBRARIES(${LIB_NAME} ${ZLIB_LIBRARIES})
215 #ADD_DEFINITIONS( -DHAVE_ZLIB_H -DHAVE_ZLIB -DHAVE_LIBZ )
218 # IF(CURL_SSL AND CURL_CONFIG_HAS_BEEN_RUN_BEFORE)
219 # LIST(APPEND DEPENDENCIES_NAMES OpenSSL)
220 # ADD_DEFINITIONS( -DUSE_SSLEAY )
224 # IF(NOT BUILD_RELEASE_DEBUG_DIRS)
225 # # Ugly workaround to remove the "/debug" or "/release" in each output
226 # SET_TARGET_PROPERTIES(${LIB_NAME} PROPERTIES PREFIX "../")
227 # SET_TARGET_PROPERTIES(${LIB_NAME} PROPERTIES IMPORT_PREFIX "../")
229 # # Add "_imp" as a suffix before the extension
230 # SET_TARGET_PROPERTIES(${LIB_NAME} PROPERTIES IMPORT_SUFFIX "_imp.lib")