build: tidy up header paths, use srcdir where possible

To improve readability.

Also add more comments on why each is necessary.

Closes #17630
This commit is contained in:
Viktor Szakats 2025-06-14 17:06:58 +02:00
parent 548873921c
commit 8e47c8a764
No known key found for this signature in database
GPG key ID: B5ABD165E2AEF201
13 changed files with 30 additions and 25 deletions

View file

@ -47,7 +47,7 @@ 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
"${CMAKE_CURRENT_SOURCE_DIR}" # for "first.h"
"${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")
set_target_properties(${BUNDLE} PROPERTIES OUTPUT_NAME "${BUNDLE}" PROJECT_LABEL "Test ${BUNDLE}" UNITY_BUILD OFF)

View file

@ -31,6 +31,7 @@ AUTOMAKE_OPTIONS = foreign nostdinc
# $(top_srcdir)/include is for libcurl's external include files
# $(top_builddir)/lib is for libcurl's generated lib/curl_config.h file
# $(top_srcdir)/lib for libcurl's lib/curl_setup.h and other "borrowed" files
# $(srcdir) for the generated bundle source to find included test sources
AM_CPPFLAGS = -I$(top_srcdir)/include \
-I$(top_builddir)/lib \