mirror of
https://github.com/curl/curl.git
synced 2026-08-11 20:50:57 +03:00
cmake: whitespace, formatting/tidy-up in comments
Also correct casing in a few option descriptions. Closes #13711
This commit is contained in:
parent
9866e2e16e
commit
0e176cabe4
15 changed files with 156 additions and 158 deletions
|
|
@ -23,7 +23,7 @@
|
|||
###########################################################################
|
||||
set(TARGET_LABEL_PREFIX "Test ")
|
||||
|
||||
function(setup_test TEST_NAME) # ARGN are the files in the test
|
||||
function(setup_test TEST_NAME) # ARGN are the files in the test
|
||||
|
||||
if(LIB_SELECTED STREQUAL LIB_STATIC)
|
||||
# These are part of the libcurl static lib. Do not compile/link them again.
|
||||
|
|
@ -35,10 +35,10 @@ function(setup_test TEST_NAME) # ARGN are the files in the test
|
|||
string(TOUPPER ${TEST_NAME} UPPER_TEST_NAME)
|
||||
|
||||
include_directories(
|
||||
${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/curl.h"
|
||||
${CURL_SOURCE_DIR}/tests/libtest # To be able to build generated tests
|
||||
${CURL_SOURCE_DIR}/lib # for "curl_setup_once.h"
|
||||
${CURL_BINARY_DIR}/lib # for "curl_config.h"
|
||||
${CURL_BINARY_DIR}/include # for "curl/curl.h"
|
||||
${CURL_SOURCE_DIR}/tests/libtest # to be able to build generated tests
|
||||
)
|
||||
if(USE_ARES)
|
||||
include_directories(${CARES_INCLUDE_DIR})
|
||||
|
|
@ -72,7 +72,7 @@ if(NOT WIN32)
|
|||
# Output to .libs for compatibility with autotools, the test data expects a
|
||||
# library at (tests)/libtest/.libs/libhostname.so
|
||||
set_target_properties(hostname PROPERTIES
|
||||
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/.libs)
|
||||
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/.libs)
|
||||
if(HIDES_CURL_PRIVATE_SYMBOLS)
|
||||
set_property(TARGET hostname APPEND PROPERTY COMPILE_DEFINITIONS "CURL_HIDDEN_SYMBOLS")
|
||||
set_property(TARGET hostname APPEND PROPERTY COMPILE_FLAGS ${CURL_CFLAG_SYMBOLS_HIDE})
|
||||
|
|
|
|||
|
|
@ -27,16 +27,16 @@ if(MSVC)
|
|||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /wd4306")
|
||||
endif()
|
||||
|
||||
function(SETUP_EXECUTABLE TEST_NAME) # ARGN are the files in the test
|
||||
function(SETUP_EXECUTABLE TEST_NAME) # ARGN are the files in the test
|
||||
add_executable(${TEST_NAME} EXCLUDE_FROM_ALL ${ARGN})
|
||||
add_dependencies(testdeps ${TEST_NAME})
|
||||
string(TOUPPER ${TEST_NAME} UPPER_TEST_NAME)
|
||||
|
||||
include_directories(
|
||||
${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/curl.h"
|
||||
${CURL_SOURCE_DIR}/src # To be able to reach "tool_xattr.h"
|
||||
${CURL_SOURCE_DIR}/lib # for "curl_setup_once.h"
|
||||
${CURL_BINARY_DIR}/lib # for "curl_config.h"
|
||||
${CURL_BINARY_DIR}/include # for "curl/curl.h"
|
||||
${CURL_SOURCE_DIR}/src # for "tool_xattr.h"
|
||||
)
|
||||
if(USE_ARES)
|
||||
include_directories(${CARES_INCLUDE_DIR})
|
||||
|
|
@ -51,7 +51,7 @@ function(SETUP_EXECUTABLE TEST_NAME) # ARGN are the files in the test
|
|||
# files on Win32 targets it is necessary to build the test servers
|
||||
# with CURL_STATICLIB defined, independently of how libcurl is built.
|
||||
set_target_properties(${TEST_NAME} PROPERTIES
|
||||
COMPILE_DEFINITIONS CURL_STATICLIB) # ${UPPER_TEST_NAME}
|
||||
COMPILE_DEFINITIONS CURL_STATICLIB) # ${UPPER_TEST_NAME}
|
||||
set_target_properties(${TEST_NAME} PROPERTIES
|
||||
PROJECT_LABEL "${TARGET_LABEL_PREFIX}${TEST_NAME}")
|
||||
endfunction()
|
||||
|
|
@ -66,17 +66,17 @@ foreach(EXECUTABLE_NAME ${noinst_PROGRAMS})
|
|||
endforeach()
|
||||
|
||||
|
||||
# SET(useful
|
||||
# getpart.c getpart.h
|
||||
# ${CURL_SOURCE_DIR}/lib/strequal.c
|
||||
# ${CURL_SOURCE_DIR}/lib/base64.c
|
||||
# ${CURL_SOURCE_DIR}/lib/mprintf.c
|
||||
# ${CURL_SOURCE_DIR}/lib/memdebug.c
|
||||
# ${CURL_SOURCE_DIR}/lib/timeval.c
|
||||
# set(useful
|
||||
# getpart.c getpart.h
|
||||
# ${CURL_SOURCE_DIR}/lib/strequal.c
|
||||
# ${CURL_SOURCE_DIR}/lib/base64.c
|
||||
# ${CURL_SOURCE_DIR}/lib/mprintf.c
|
||||
# ${CURL_SOURCE_DIR}/lib/memdebug.c
|
||||
# ${CURL_SOURCE_DIR}/lib/timeval.c
|
||||
# )
|
||||
|
||||
# SETUP_EXECUTABLE(sws sws.c util.c util.h ${useful})
|
||||
# SETUP_EXECUTABLE(resolve resolve.c util.c util.h ${useful})
|
||||
# SETUP_EXECUTABLE(sockfilt sockfilt.c util.c util.h ${useful} ${CURL_SOURCE_DIR}/lib/inet_pton.c)
|
||||
# SETUP_EXECUTABLE(getpart testpart.c ${useful})
|
||||
# SETUP_EXECUTABLE(tftpd tftpd.c util.c util.h ${useful} tftp.h)
|
||||
# setup_executable(sws sws.c util.c util.h ${useful})
|
||||
# setup_executable(resolve resolve.c util.c util.h ${useful})
|
||||
# setup_executable(sockfilt sockfilt.c util.c util.h ${useful} ${CURL_SOURCE_DIR}/lib/inet_pton.c)
|
||||
# setup_executable(getpart testpart.c ${useful})
|
||||
# setup_executable(tftpd tftpd.c util.c util.h ${useful} tftp.h)
|
||||
|
|
|
|||
|
|
@ -26,11 +26,11 @@ transform_makefile_inc("Makefile.inc" "${CMAKE_CURRENT_BINARY_DIR}/Makefile.inc.
|
|||
include(${CMAKE_CURRENT_BINARY_DIR}/Makefile.inc.cmake)
|
||||
|
||||
include_directories(
|
||||
${CURL_SOURCE_DIR}/lib # To be able to reach "curl_setup_once.h"
|
||||
${CURL_SOURCE_DIR}/lib # for "curl_setup_once.h"
|
||||
${CURL_SOURCE_DIR}/tests/libtest
|
||||
${CURL_SOURCE_DIR}/src
|
||||
${CURL_BINARY_DIR}/lib # To be able to reach "curl_config.h"
|
||||
${CURL_BINARY_DIR}/include # To be able to reach "curl/curl.h"
|
||||
${CURL_BINARY_DIR}/lib # for "curl_config.h"
|
||||
${CURL_BINARY_DIR}/include # for "curl/curl.h"
|
||||
)
|
||||
|
||||
if(ENABLE_CURLDEBUG) # running unittests require curl to compiled with CURLDEBUG
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue