From 1a70977a83c30d58282ec75a1b2352e775209074 Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Fri, 20 Jun 2025 09:20:45 +0200 Subject: [PATCH] build: drop explicit curlx from hdr paths, refer headers with `curlx/` prefix To make all src and test code refer to curlx headers the same way. Also: - src: move `curlx.h` include to `tool_setup.h`. - src/tool_setup.h: drop stray `curlx/timeval.h`. - servers: de-duplicate `curlx.h` and `curl_setup.h` includes. - libtests, units: drop stray curlx sub-headers in favor of ``. - tests: include `curlx.h` with `<>` instead of `""`. To match other parts of the codebase. Closes #17680 --- src/CMakeLists.txt | 3 +-- src/Makefile.am | 1 - src/terminal.c | 1 - src/tool_cb_dbg.c | 2 -- src/tool_cb_hdr.c | 2 -- src/tool_cb_prg.c | 2 -- src/tool_cb_rea.c | 2 -- src/tool_cb_see.c | 2 -- src/tool_cb_wrt.c | 2 -- src/tool_cfgable.c | 1 - src/tool_dirhie.c | 2 -- src/tool_doswin.c | 1 - src/tool_easysrc.c | 2 -- src/tool_filetime.c | 1 - src/tool_findfile.c | 2 -- src/tool_formparse.c | 2 -- src/tool_getparam.c | 1 - src/tool_help.c | 2 -- src/tool_helpers.c | 2 -- src/tool_ipfs.c | 1 - src/tool_libinfo.c | 1 - src/tool_main.c | 2 -- src/tool_msgs.c | 2 -- src/tool_operate.c | 2 -- src/tool_operhlp.c | 1 - src/tool_paramhlp.c | 2 -- src/tool_parsecfg.c | 1 - src/tool_progress.c | 1 - src/tool_setopt.c | 1 - src/tool_setup.h | 2 +- src/tool_ssls.c | 1 - src/tool_urlglob.c | 1 - src/tool_util.c | 1 - src/tool_vms.c | 1 - src/tool_writeout.c | 1 - src/tool_writeout_json.c | 1 - src/var.c | 1 - src/var.h | 1 - tests/client/CMakeLists.txt | 3 +-- tests/client/Makefile.am | 1 - tests/client/first.h | 2 +- tests/libtest/CMakeLists.txt | 3 +-- tests/libtest/Makefile.am | 1 - tests/libtest/first.h | 2 +- tests/server/CMakeLists.txt | 3 +-- tests/server/Makefile.am | 1 - tests/server/first.h | 2 +- tests/server/sockfilt.c | 3 +-- tests/tunit/CMakeLists.txt | 3 +-- tests/tunit/Makefile.am | 1 - tests/unit/CMakeLists.txt | 3 +-- tests/unit/Makefile.am | 1 - tests/unit/unit1302.c | 2 +- tests/unit/unit1305.c | 2 -- tests/unit/unit1323.c | 2 +- tests/unit/unit1602.c | 2 -- tests/unit/unit1603.c | 2 +- tests/unit/unit1616.c | 4 ++-- tests/unit/unit1650.c | 3 ++- tests/unit/unit1664.c | 2 +- tests/unit/unit1979.c | 3 ++- tests/unit/unit1980.c | 3 ++- tests/unit/unit2600.c | 2 +- tests/unit/unit2602.c | 3 ++- 64 files changed, 26 insertions(+), 90 deletions(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 1089b70148..b9a6329596 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -80,8 +80,7 @@ endif() set_property(DIRECTORY APPEND PROPERTY INCLUDE_DIRECTORIES "${PROJECT_BINARY_DIR}/lib" # for "curl_config.h" - "${PROJECT_SOURCE_DIR}/lib" # for "curl_setup.h" - "${PROJECT_SOURCE_DIR}/lib/curlx" # for curlx functions + "${PROJECT_SOURCE_DIR}/lib" # for "curl_setup.h", curlx "${CMAKE_CURRENT_SOURCE_DIR}" # for "tool_hugehelp.c" ) diff --git a/src/Makefile.am b/src/Makefile.am index bf7a44bed7..377d4b31a3 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -45,7 +45,6 @@ EXTRA_DIST = mk-file-embed.pl mkhelp.pl \ AM_CPPFLAGS = -I$(top_srcdir)/include \ -I$(top_builddir)/lib \ -I$(top_srcdir)/lib \ - -I$(top_srcdir)/lib/curlx \ -I$(srcdir) bin_PROGRAMS = curl diff --git a/src/terminal.c b/src/terminal.c index 384afd8cb3..ccd5bbf62a 100644 --- a/src/terminal.c +++ b/src/terminal.c @@ -28,7 +28,6 @@ #endif #include "terminal.h" -#include #include /* keep this as LAST include */ #ifdef HAVE_TERMIOS_H diff --git a/src/tool_cb_dbg.c b/src/tool_cb_dbg.c index 2cf889c51c..b9504f5825 100644 --- a/src/tool_cb_dbg.c +++ b/src/tool_cb_dbg.c @@ -23,8 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include - #include "tool_cfgable.h" #include "tool_msgs.h" #include "tool_cb_dbg.h" diff --git a/src/tool_cb_hdr.c b/src/tool_cb_hdr.c index 151fd5c0ff..41d8b80d76 100644 --- a/src/tool_cb_hdr.c +++ b/src/tool_cb_hdr.c @@ -27,8 +27,6 @@ #include #endif -#include - #include "tool_cfgable.h" #include "tool_doswin.h" #include "tool_msgs.h" diff --git a/src/tool_cb_prg.c b/src/tool_cb_prg.c index 108bf9536d..e4e3a709a0 100644 --- a/src/tool_cb_prg.c +++ b/src/tool_cb_prg.c @@ -23,8 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include - #include "tool_cfgable.h" #include "tool_cb_prg.h" #include "tool_util.h" diff --git a/src/tool_cb_rea.c b/src/tool_cb_rea.c index 8fdd7db9d9..eb2717f71f 100644 --- a/src/tool_cb_rea.c +++ b/src/tool_cb_rea.c @@ -27,8 +27,6 @@ #include #endif -#include - #include "tool_cfgable.h" #include "tool_cb_rea.h" #include "tool_operate.h" diff --git a/src/tool_cb_see.c b/src/tool_cb_see.c index dcd1f2537c..ca6091f86b 100644 --- a/src/tool_cb_see.c +++ b/src/tool_cb_see.c @@ -23,8 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include - #include "tool_cfgable.h" #include "tool_operate.h" #include "tool_cb_see.h" diff --git a/src/tool_cb_wrt.c b/src/tool_cb_wrt.c index e0dbe2c9c7..8f39cae102 100644 --- a/src/tool_cb_wrt.c +++ b/src/tool_cb_wrt.c @@ -30,8 +30,6 @@ #include -#include - #include "tool_cfgable.h" #include "tool_msgs.h" #include "tool_cb_wrt.h" diff --git a/src/tool_cfgable.c b/src/tool_cfgable.c index 99fc91b097..0d2b80a1a7 100644 --- a/src/tool_cfgable.c +++ b/src/tool_cfgable.c @@ -27,7 +27,6 @@ #include "tool_formparse.h" #include "tool_paramhlp.h" #include "tool_main.h" -#include #include /* keep this as LAST include */ void config_init(struct OperationConfig *config) diff --git a/src/tool_dirhie.c b/src/tool_dirhie.c index 88e4daffb7..6d0dac01c3 100644 --- a/src/tool_dirhie.c +++ b/src/tool_dirhie.c @@ -29,8 +29,6 @@ # include #endif -#include - #include "tool_dirhie.h" #include "tool_msgs.h" diff --git a/src/tool_doswin.c b/src/tool_doswin.c index 82c8e9ae3c..58508603f1 100644 --- a/src/tool_doswin.c +++ b/src/tool_doswin.c @@ -40,7 +40,6 @@ #include "tool_doswin.h" #include "tool_msgs.h" -#include #include /* keep this as LAST include */ #ifdef _WIN32 diff --git a/src/tool_easysrc.c b/src/tool_easysrc.c index fa264606fc..432e614d1c 100644 --- a/src/tool_easysrc.c +++ b/src/tool_easysrc.c @@ -27,8 +27,6 @@ #ifndef CURL_DISABLE_LIBCURL_OPTION -#include - #include "tool_cfgable.h" #include "tool_easysrc.h" #include "tool_msgs.h" diff --git a/src/tool_filetime.c b/src/tool_filetime.c index 44b23b9ad9..1b62e7add7 100644 --- a/src/tool_filetime.c +++ b/src/tool_filetime.c @@ -24,7 +24,6 @@ #include "tool_filetime.h" #include "tool_cfgable.h" #include "tool_msgs.h" -#include #ifdef HAVE_UTIME_H # include diff --git a/src/tool_findfile.c b/src/tool_findfile.c index 02bdefea87..20d2c0bd93 100644 --- a/src/tool_findfile.c +++ b/src/tool_findfile.c @@ -36,8 +36,6 @@ #include #endif -#include - #include "tool_findfile.h" #include "tool_cfgable.h" diff --git a/src/tool_formparse.c b/src/tool_formparse.c index 748bcb29a2..b3a12edf2b 100644 --- a/src/tool_formparse.c +++ b/src/tool_formparse.c @@ -23,8 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include - #include "tool_cfgable.h" #include "tool_msgs.h" #include "tool_getparam.h" diff --git a/src/tool_getparam.c b/src/tool_getparam.c index cc1cd3f3b1..f453d90b03 100644 --- a/src/tool_getparam.c +++ b/src/tool_getparam.c @@ -23,7 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include #include "tool_cfgable.h" #include "tool_cb_prg.h" #include "tool_filetime.h" diff --git a/src/tool_help.c b/src/tool_help.c index 3d0336f22d..3ccb15ab72 100644 --- a/src/tool_help.c +++ b/src/tool_help.c @@ -23,8 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include - #include "tool_help.h" #include "tool_libinfo.h" #include "tool_util.h" diff --git a/src/tool_helpers.c b/src/tool_helpers.c index 5026fcf1c6..7a9ccb4d35 100644 --- a/src/tool_helpers.c +++ b/src/tool_helpers.c @@ -23,8 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include - #include "tool_cfgable.h" #include "tool_msgs.h" #include "tool_getparam.h" diff --git a/src/tool_ipfs.c b/src/tool_ipfs.c index 0d870bef30..b96a7e4dd6 100644 --- a/src/tool_ipfs.c +++ b/src/tool_ipfs.c @@ -24,7 +24,6 @@ #include "tool_setup.h" #ifndef CURL_DISABLE_IPFS -#include #include "tool_cfgable.h" #include "tool_msgs.h" diff --git a/src/tool_libinfo.c b/src/tool_libinfo.c index 4f9485350f..a1888c00a2 100644 --- a/src/tool_libinfo.c +++ b/src/tool_libinfo.c @@ -23,7 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include #include "tool_libinfo.h" #include /* keep this as LAST include */ diff --git a/src/tool_main.c b/src/tool_main.c index b78fe28b50..5f453a32d7 100644 --- a/src/tool_main.c +++ b/src/tool_main.c @@ -37,8 +37,6 @@ #include #endif -#include - #include "tool_cfgable.h" #include "tool_doswin.h" #include "tool_msgs.h" diff --git a/src/tool_msgs.c b/src/tool_msgs.c index 520bb90872..026c77a465 100644 --- a/src/tool_msgs.c +++ b/src/tool_msgs.c @@ -23,8 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include - #include "tool_cfgable.h" #include "tool_msgs.h" #include "tool_cb_prg.h" diff --git a/src/tool_operate.c b/src/tool_operate.c index 467fd36ea5..3fbe85ee3b 100644 --- a/src/tool_operate.c +++ b/src/tool_operate.c @@ -54,8 +54,6 @@ #include #endif -#include - #include "tool_cfgable.h" #include "tool_cb_dbg.h" #include "tool_cb_hdr.h" diff --git a/src/tool_operhlp.c b/src/tool_operhlp.c index 6a6cf202c8..a9571e881f 100644 --- a/src/tool_operhlp.c +++ b/src/tool_operhlp.c @@ -24,7 +24,6 @@ #include "tool_setup.h" #include "tool_operate.h" -#include #include "tool_cfgable.h" #include "tool_doswin.h" #include "tool_operhlp.h" diff --git a/src/tool_paramhlp.c b/src/tool_paramhlp.c index 0a3bc91fb9..5b819a7413 100644 --- a/src/tool_paramhlp.c +++ b/src/tool_paramhlp.c @@ -23,8 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include - #include "tool_cfgable.h" #include "tool_getparam.h" #include "tool_getpass.h" diff --git a/src/tool_parsecfg.c b/src/tool_parsecfg.c index d5f144274a..defadc0da0 100644 --- a/src/tool_parsecfg.c +++ b/src/tool_parsecfg.c @@ -23,7 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include #include "tool_cfgable.h" #include "tool_getparam.h" #include "tool_helpers.h" diff --git a/src/tool_progress.c b/src/tool_progress.c index 5c75e4e92c..635f8e25ee 100644 --- a/src/tool_progress.c +++ b/src/tool_progress.c @@ -25,7 +25,6 @@ #include "tool_operate.h" #include "tool_progress.h" #include "tool_util.h" -#include /* The point of this function would be to return a string of the input data, but never longer than 5 columns (+ one zero byte). diff --git a/src/tool_setopt.c b/src/tool_setopt.c index a782b33ea2..f29183425c 100644 --- a/src/tool_setopt.c +++ b/src/tool_setopt.c @@ -25,7 +25,6 @@ #ifndef CURL_DISABLE_LIBCURL_OPTION -#include #include "tool_cfgable.h" #include "tool_easysrc.h" #include "tool_setopt.h" diff --git a/src/tool_setup.h b/src/tool_setup.h index d1d5ad9d79..c744ea6b72 100644 --- a/src/tool_setup.h +++ b/src/tool_setup.h @@ -47,7 +47,7 @@ extern FILE *tool_stderr; #include /* external interface */ -#include "timeval.h" +#include /* * Platform specific stuff. diff --git a/src/tool_ssls.c b/src/tool_ssls.c index 20768ed54b..e7ac3be476 100644 --- a/src/tool_ssls.c +++ b/src/tool_ssls.c @@ -23,7 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include #include "tool_cfgable.h" #include "tool_cb_dbg.h" #include "tool_msgs.h" diff --git a/src/tool_urlglob.c b/src/tool_urlglob.c index c8fa301b99..40d69a4b66 100644 --- a/src/tool_urlglob.c +++ b/src/tool_urlglob.c @@ -23,7 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include #include "tool_cfgable.h" #include "tool_doswin.h" #include "tool_urlglob.h" diff --git a/src/tool_util.c b/src/tool_util.c index 27c2df1b6c..e6188cecb0 100644 --- a/src/tool_util.c +++ b/src/tool_util.c @@ -24,7 +24,6 @@ #include "tool_setup.h" #include "tool_util.h" -#include #include /* keep this as LAST include */ #ifdef _WIN32 diff --git a/src/tool_vms.c b/src/tool_vms.c index 6788928339..ecf01eb5b2 100644 --- a/src/tool_vms.c +++ b/src/tool_vms.c @@ -30,7 +30,6 @@ #include #endif -#include #include "curlmsg_vms.h" #include "tool_vms.h" #include /* keep this as LAST include */ diff --git a/src/tool_writeout.c b/src/tool_writeout.c index 3081b7082d..9036c14044 100644 --- a/src/tool_writeout.c +++ b/src/tool_writeout.c @@ -23,7 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include #include "tool_cfgable.h" #include "tool_writeout.h" #include "tool_writeout_json.h" diff --git a/src/tool_writeout_json.c b/src/tool_writeout_json.c index 1f10942378..cfa2d1c901 100644 --- a/src/tool_writeout_json.c +++ b/src/tool_writeout_json.c @@ -23,7 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include #include "tool_cfgable.h" #include "tool_writeout_json.h" #include "tool_writeout.h" diff --git a/src/var.c b/src/var.c index 9dba7e4c1a..01ea03918e 100644 --- a/src/var.c +++ b/src/var.c @@ -23,7 +23,6 @@ ***************************************************************************/ #include "tool_setup.h" -#include #include "tool_cfgable.h" #include "tool_getparam.h" #include "tool_helpers.h" diff --git a/src/var.h b/src/var.h index 8e5b685085..4a304acbb9 100644 --- a/src/var.h +++ b/src/var.h @@ -25,7 +25,6 @@ ***************************************************************************/ #include "tool_getparam.h" -#include struct tool_var { struct tool_var *next; diff --git a/tests/client/CMakeLists.txt b/tests/client/CMakeLists.txt index a2a67eea67..0aabacd70e 100644 --- a/tests/client/CMakeLists.txt +++ b/tests/client/CMakeLists.txt @@ -43,8 +43,7 @@ add_dependencies(testdeps ${BUNDLE}) target_link_libraries(${BUNDLE} ${LIB_SELECTED} ${CURL_LIBS}) target_include_directories(${BUNDLE} PRIVATE "${PROJECT_BINARY_DIR}/lib" # for "curl_config.h" - "${PROJECT_SOURCE_DIR}/lib" # for "curl_setup.h" - "${PROJECT_SOURCE_DIR}/lib/curlx" # for curlx + "${PROJECT_SOURCE_DIR}/lib" # for "curl_setup.h", curlx "${CMAKE_CURRENT_SOURCE_DIR}" # for the generated bundle source to find included test sources ) set_property(TARGET ${BUNDLE} APPEND PROPERTY COMPILE_DEFINITIONS "CURL_NO_OLDIES") diff --git a/tests/client/Makefile.am b/tests/client/Makefile.am index b9490dc7b2..26ecf866a7 100644 --- a/tests/client/Makefile.am +++ b/tests/client/Makefile.am @@ -36,7 +36,6 @@ AUTOMAKE_OPTIONS = foreign nostdinc AM_CPPFLAGS = -I$(top_srcdir)/include \ -I$(top_builddir)/lib \ -I$(top_srcdir)/lib \ - -I$(top_srcdir)/lib/curlx \ -I$(srcdir) # Get BUNDLE, FIRSTFILES, CURLX_CFILES, TESTFILES variables diff --git a/tests/client/first.h b/tests/client/first.h index 3c13338297..0785bc7460 100644 --- a/tests/client/first.h +++ b/tests/client/first.h @@ -36,7 +36,7 @@ extern const struct entry_s s_entries[]; #include -#include "curlx.h" +#include #define ERR() \ do { \ diff --git a/tests/libtest/CMakeLists.txt b/tests/libtest/CMakeLists.txt index 7a7e919e33..bf7f9476f1 100644 --- a/tests/libtest/CMakeLists.txt +++ b/tests/libtest/CMakeLists.txt @@ -52,8 +52,7 @@ add_dependencies(testdeps ${BUNDLE}) target_link_libraries(${BUNDLE} ${LIB_SELECTED} ${CURL_LIBS}) target_include_directories(${BUNDLE} PRIVATE "${PROJECT_BINARY_DIR}/lib" # for "curl_config.h" - "${PROJECT_SOURCE_DIR}/lib" # for "curl_setup.h" - "${PROJECT_SOURCE_DIR}/lib/curlx" # for curlx + "${PROJECT_SOURCE_DIR}/lib" # for "curl_setup.h", curlx "${CMAKE_CURRENT_SOURCE_DIR}" # for the generated bundle source to find included test sources "${PROJECT_SOURCE_DIR}/tests/unit" # for "curlcheck.h" ) diff --git a/tests/libtest/Makefile.am b/tests/libtest/Makefile.am index a0407f6990..6b83ff8f2a 100644 --- a/tests/libtest/Makefile.am +++ b/tests/libtest/Makefile.am @@ -36,7 +36,6 @@ AUTOMAKE_OPTIONS = foreign nostdinc AM_CPPFLAGS = -I$(top_srcdir)/include \ -I$(top_builddir)/lib \ -I$(top_srcdir)/lib \ - -I$(top_srcdir)/lib/curlx \ -I$(srcdir) \ -I$(top_srcdir)/tests/unit diff --git a/tests/libtest/first.h b/tests/libtest/first.h index fcb623290c..3a73d37094 100644 --- a/tests/libtest/first.h +++ b/tests/libtest/first.h @@ -34,6 +34,6 @@ struct entry_s { extern const struct entry_s s_entries[]; -#include "curlx.h" +#include #endif /* HEADER_LIBTEST_FIRST_H */ diff --git a/tests/server/CMakeLists.txt b/tests/server/CMakeLists.txt index 9467a89c33..d8d48d42ff 100644 --- a/tests/server/CMakeLists.txt +++ b/tests/server/CMakeLists.txt @@ -39,8 +39,7 @@ add_dependencies(testdeps ${BUNDLE}) target_link_libraries(${BUNDLE} ${CURL_LIBS}) target_include_directories(${BUNDLE} PRIVATE "${PROJECT_BINARY_DIR}/lib" # for "curl_config.h" - "${PROJECT_SOURCE_DIR}/lib" # for "curl_setup.h" - "${PROJECT_SOURCE_DIR}/lib/curlx" # for curlx + "${PROJECT_SOURCE_DIR}/lib" # for "curl_setup.h", curlx "${CMAKE_CURRENT_SOURCE_DIR}" # for the generated bundle source to find included test sources ) set_property(TARGET ${BUNDLE} APPEND PROPERTY COMPILE_DEFINITIONS "WITHOUT_LIBCURL") diff --git a/tests/server/Makefile.am b/tests/server/Makefile.am index 190265b6a7..2a4d20602b 100644 --- a/tests/server/Makefile.am +++ b/tests/server/Makefile.am @@ -36,7 +36,6 @@ AUTOMAKE_OPTIONS = foreign nostdinc AM_CPPFLAGS = -I$(top_srcdir)/include \ -I$(top_builddir)/lib \ -I$(top_srcdir)/lib \ - -I$(top_srcdir)/lib/curlx \ -I$(srcdir) # Get BUNDLE, FIRSTFILES, UTILS, CURLX_CFILES, TESTFILES variables diff --git a/tests/server/first.h b/tests/server/first.h index 1fc31f8ebc..4fb32c44bd 100644 --- a/tests/server/first.h +++ b/tests/server/first.h @@ -50,7 +50,7 @@ extern const struct entry_s s_entries[]; #include #endif -#include /* from the private lib dir */ +#include /* adjust for old MSVC */ #if defined(_MSC_VER) && (_MSC_VER < 1900) diff --git a/tests/server/sockfilt.c b/tests/server/sockfilt.c index c611b9d3bc..477e433f8e 100644 --- a/tests/server/sockfilt.c +++ b/tests/server/sockfilt.c @@ -85,9 +85,8 @@ * it! */ - /* buffer is this excessively large only to be able to support things like - test 1003 which tests exceedingly large server response lines */ + test 1003 which tests exceedingly large server response lines */ #define BUFFER_SIZE 17010 static bool verbose = FALSE; diff --git a/tests/tunit/CMakeLists.txt b/tests/tunit/CMakeLists.txt index 5a8ece4acf..03353a9519 100644 --- a/tests/tunit/CMakeLists.txt +++ b/tests/tunit/CMakeLists.txt @@ -39,8 +39,7 @@ add_dependencies(testdeps ${BUNDLE}) target_link_libraries(${BUNDLE} curltool curlu) target_include_directories(${BUNDLE} PRIVATE "${PROJECT_BINARY_DIR}/lib" # for "curl_config.h" - "${PROJECT_SOURCE_DIR}/lib" # for "curl_setup.h" - "${PROJECT_SOURCE_DIR}/lib/curlx" # for curlx + "${PROJECT_SOURCE_DIR}/lib" # for "curl_setup.h", curlx "${PROJECT_SOURCE_DIR}/src" # for tool headers "${PROJECT_SOURCE_DIR}/tests/libtest" # for "first.h" "${PROJECT_SOURCE_DIR}/tests/unit" # for "curlcheck.h" diff --git a/tests/tunit/Makefile.am b/tests/tunit/Makefile.am index 1b01b85a80..23472085ed 100644 --- a/tests/tunit/Makefile.am +++ b/tests/tunit/Makefile.am @@ -36,7 +36,6 @@ AUTOMAKE_OPTIONS = foreign nostdinc AM_CPPFLAGS = -I$(top_srcdir)/include \ -I$(top_builddir)/lib \ -I$(top_srcdir)/lib \ - -I$(top_srcdir)/lib/curlx \ -I$(top_srcdir)/src \ -I$(top_srcdir)/tests/libtest \ -I$(top_srcdir)/tests/unit \ diff --git a/tests/unit/CMakeLists.txt b/tests/unit/CMakeLists.txt index acad3fa388..39f1443cd9 100644 --- a/tests/unit/CMakeLists.txt +++ b/tests/unit/CMakeLists.txt @@ -39,8 +39,7 @@ add_dependencies(testdeps ${BUNDLE}) target_link_libraries(${BUNDLE} curlu) target_include_directories(${BUNDLE} PRIVATE "${PROJECT_BINARY_DIR}/lib" # for "curl_config.h" - "${PROJECT_SOURCE_DIR}/lib" # for "curl_setup.h" - "${PROJECT_SOURCE_DIR}/lib/curlx" # for curlx + "${PROJECT_SOURCE_DIR}/lib" # for "curl_setup.h", curlx "${PROJECT_SOURCE_DIR}/tests/libtest" # for "first.h" "${CMAKE_CURRENT_SOURCE_DIR}" # for the generated bundle source to find included test sources ) diff --git a/tests/unit/Makefile.am b/tests/unit/Makefile.am index 23a5cb68d5..20385016fc 100644 --- a/tests/unit/Makefile.am +++ b/tests/unit/Makefile.am @@ -36,7 +36,6 @@ AUTOMAKE_OPTIONS = foreign nostdinc AM_CPPFLAGS = -I$(top_srcdir)/include \ -I$(top_builddir)/lib \ -I$(top_srcdir)/lib \ - -I$(top_srcdir)/lib/curlx \ -I$(top_srcdir)/tests/libtest \ -I$(srcdir) diff --git a/tests/unit/unit1302.c b/tests/unit/unit1302.c index 58b0e12518..f161cf29e3 100644 --- a/tests/unit/unit1302.c +++ b/tests/unit/unit1302.c @@ -25,7 +25,7 @@ #include "urldata.h" #include "url.h" /* for Curl_safefree */ -#include "curlx/base64.h" +#include #include "memdebug.h" /* LAST include file */ static CURLcode test_unit1302(char *arg) diff --git a/tests/unit/unit1305.c b/tests/unit/unit1305.c index cf8090c304..0ad1e00ee4 100644 --- a/tests/unit/unit1305.c +++ b/tests/unit/unit1305.c @@ -33,8 +33,6 @@ #include #endif -#include - #include "hash.h" #include "hostip.h" diff --git a/tests/unit/unit1323.c b/tests/unit/unit1323.c index a112e06c40..4717559f2e 100644 --- a/tests/unit/unit1323.c +++ b/tests/unit/unit1323.c @@ -23,7 +23,7 @@ ***************************************************************************/ #include "curlcheck.h" -#include "timeval.h" +#include static CURLcode test_unit1323(char *arg) { diff --git a/tests/unit/unit1602.c b/tests/unit/unit1602.c index 020d57f458..126cf8d806 100644 --- a/tests/unit/unit1602.c +++ b/tests/unit/unit1602.c @@ -23,8 +23,6 @@ ***************************************************************************/ #include "curlcheck.h" -#include - #include "hash.h" #include /* LAST include file */ diff --git a/tests/unit/unit1603.c b/tests/unit/unit1603.c index 37700af9b6..c3f99b6ca2 100644 --- a/tests/unit/unit1603.c +++ b/tests/unit/unit1603.c @@ -23,8 +23,8 @@ ***************************************************************************/ #include "curlcheck.h" -#include #include "hash.h" + #include /* LAST include file */ static const size_t slots = 3; diff --git a/tests/unit/unit1616.c b/tests/unit/unit1616.c index 67757fba09..8040809a3e 100644 --- a/tests/unit/unit1616.c +++ b/tests/unit/unit1616.c @@ -23,8 +23,8 @@ ***************************************************************************/ #include "curlcheck.h" -#include -#include +#include "uint-hash.h" + #include /* LAST include file */ static void t1616_mydtor(unsigned int id, void *elem) diff --git a/tests/unit/unit1650.c b/tests/unit/unit1650.c index 0abcd99a51..ad5dfa1900 100644 --- a/tests/unit/unit1650.c +++ b/tests/unit/unit1650.c @@ -23,8 +23,9 @@ ***************************************************************************/ #include "curlcheck.h" +#include + #include "doh.h" -#include "dynbuf.h" static CURLcode test_unit1650(char *arg) { diff --git a/tests/unit/unit1664.c b/tests/unit/unit1664.c index b4e7e383f0..49e00b3235 100644 --- a/tests/unit/unit1664.c +++ b/tests/unit/unit1664.c @@ -30,7 +30,7 @@ #include #endif -#include "curlx/strparse.h" +#include #include "memdebug.h" /* LAST include file */ diff --git a/tests/unit/unit1979.c b/tests/unit/unit1979.c index c1a53560c5..d670364a3a 100644 --- a/tests/unit/unit1979.c +++ b/tests/unit/unit1979.c @@ -23,8 +23,9 @@ ***************************************************************************/ #include "curlcheck.h" +#include + #include "http_aws_sigv4.h" -#include "dynbuf.h" static CURLcode test_unit1979(char *arg) { diff --git a/tests/unit/unit1980.c b/tests/unit/unit1980.c index 5cb81e99c1..acb4b2f470 100644 --- a/tests/unit/unit1980.c +++ b/tests/unit/unit1980.c @@ -23,8 +23,9 @@ ***************************************************************************/ #include "curlcheck.h" +#include + #include "http_aws_sigv4.h" -#include "dynbuf.h" static CURLcode test_unit1980(char *arg) { diff --git a/tests/unit/unit2600.c b/tests/unit/unit2600.c index cc2c5922b5..47459477a4 100644 --- a/tests/unit/unit2600.c +++ b/tests/unit/unit2600.c @@ -23,7 +23,7 @@ ***************************************************************************/ #include "curlcheck.h" -#include +#include #ifdef HAVE_NETINET_IN_H #include diff --git a/tests/unit/unit2602.c b/tests/unit/unit2602.c index ee0cac08da..1834412e73 100644 --- a/tests/unit/unit2602.c +++ b/tests/unit/unit2602.c @@ -23,8 +23,9 @@ ***************************************************************************/ #include "curlcheck.h" +#include + #include "urldata.h" -#include "dynbuf.h" #include "dynhds.h" #include "curl_trc.h" -- 2.47.2