string(TOUPPER ${TEST_NAME} UPPER_TEST_NAME)
include_directories(
- ${CURL_SOURCE_DIR}/lib # To be able to reach "setup_once.h"
- ${CURL_BINARY_DIR}/lib # To be able to reach "curl_config.h"
+ ${CURL_SOURCE_DIR}/lib # To be able to reach "curl_setup_once.h"
+ ${CURL_BINARY_DIR}/lib # To be able to reach "curl_config.h"
${CURL_BINARY_DIR}/include # To be able to reach "curl/curlbuild.h"
)
+ if(USE_ARES)
+ include_directories(${CARES_INCLUDE_DIR})
+ endif()
- setup_curl_dependencies(${TEST_NAME})
- #TARGET_LINK_LIBRARIES( ${TEST_NAME} libcurl )
+ target_link_libraries(${TEST_NAME} ${CURL_LIBS})
# Test servers simply are standalone programs that do not use libcurl
# library. For convinience and to ease portability of these servers,
# files on Win32 targets it is necessary to build the test servers
# with CURL_STATICLIB defined, independently of how libcurl is built.
if(NOT CURL_STATICLIB)
- set_target_properties(${TEST_NAME} PROPERTIES
+ set_target_properties(${TEST_NAME} PROPERTIES
COMPILE_DEFINITIONS CURL_STATICLIB) # ${UPPER_TEST_NAME}
endif()
- set_target_properties(${TEST_NAME} PROPERTIES
+ set_target_properties(${TEST_NAME} PROPERTIES
PROJECT_LABEL "${TARGET_LABEL_PREFIX}${TEST_NAME}")
- # Add the postfix to the executable since it is not added
+ # Add the postfix to the executable since it is not added
# automatically as for modules and shared libraries
set_target_properties(${TEST_NAME} PROPERTIES
DEBUG_POSTFIX "${CMAKE_DEBUG_POSTFIX}")
- if(MSVC)
- if(NOT BUILD_RELEASE_DEBUG_DIRS)
- # Ugly workaround to remove the "/debug" or "/release" in each output
- set_target_properties(${TEST_NAME} PROPERTIES PREFIX "../")
- set_target_properties(${TEST_NAME} PROPERTIES IMPORT_PREFIX "../")
- endif()
- endif()
-
endfunction()
-transform_makefile_inc("Makefile.inc"
+transform_makefile_inc("Makefile.inc"
"${CMAKE_CURRENT_BINARY_DIR}/Makefile.inc.cmake")
include(${CMAKE_CURRENT_BINARY_DIR}/Makefile.inc.cmake)