Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 25 additions & 4 deletions builtins/libtextinput/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,31 @@ target_sources(textinput PRIVATE
TextInputContext.cpp
TextInput.cpp
UTF8.cpp
)

target_include_directories(textinput
PUBLIC
./ # to be able to call #include "textinput/header.h" from ROOT core files
FILE_SET HEADERS
TYPE HEADERS
BASE_DIRS ./ # to be able to call #include "textinput/header.h" from ROOT core files
FILES
textinput/Callbacks.h
textinput/Color.h
textinput/Display.h
textinput/Editor.h
textinput/History.h
textinput/InputData.h
textinput/KeyBinding.h
textinput/Range.h
textinput/Reader.h
textinput/SignalHandler.h
textinput/StreamReader.h
textinput/StreamReaderUnix.h
textinput/StreamReaderWin.h
textinput/TerminalConfigUnix.h
textinput/TerminalDisplay.h
textinput/TerminalDisplayUnix.h
textinput/TerminalDisplayWin.h
textinput/Text.h
textinput/TextInputContext.h
textinput/TextInput.h
)

set_property(TARGET textinput PROPERTY POSITION_INDEPENDENT_CODE ON)
26 changes: 13 additions & 13 deletions core/base/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -198,23 +198,23 @@ set(BASE_SOURCES
src/TVirtualX.cxx
)

set(RELATIVE_BASE_INC_HEADERS ${BASE_HEADERS})
list(TRANSFORM RELATIVE_BASE_INC_HEADERS PREPEND inc/)
set(RELATIVE_INC_HEADERS ${BASE_HEADERS})
list(TRANSFORM RELATIVE_INC_HEADERS PREPEND inc/)

# only here complete list of headers can be propogated to parent cmake file
set_property(TARGET Core APPEND PROPERTY DICT_HEADERS ${BASE_HEADERS})

target_sources(Core PRIVATE ${BASE_SOURCES})

target_sources(
Core
PRIVATE
FILE_SET private_header_files
TYPE HEADERS
BASE_DIRS inc/ src/
FILES
${RELATIVE_BASE_INC_HEADERS}
src/TListOfTypes.h
target_sources(Core
PRIVATE
${BASE_SOURCES}
PRIVATE
FILE_SET private_header_files
TYPE HEADERS
BASE_DIRS inc/ src/
FILES
${RELATIVE_INC_HEADERS}
inc/LinkDef.h
src/TListOfTypes.h
)

target_include_directories(Core PUBLIC
Expand Down
13 changes: 13 additions & 0 deletions core/clingutils/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,19 @@ ROOT_OBJECT_LIBRARY(ClingUtils
src/TClingUtils.cxx
)

set(RELATIVE_RES_HEADERS RStl.h TClingUtils.h)
list(TRANSFORM RELATIVE_RES_HEADERS PREPEND res/)

target_sources(ClingUtils
PRIVATE
FILE_SET private_header_files
TYPE HEADERS
BASE_DIRS res/ inc/
FILES
${RELATIVE_RES_HEADERS}
inc/root_std_complex.h
)

if(NOT MSVC)
target_compile_options(ClingUtils PRIVATE -Wno-error)
endif()
Expand Down
17 changes: 14 additions & 3 deletions core/cont/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@
############################################################################
# CMakeLists.txt file for building ROOT core/cont package
############################################################################

set_property(TARGET Core APPEND PROPERTY DICT_HEADERS
set(CONT_HEADERS
ROOT/TSeq.hxx
TArrayC.h
TArrayD.h
Expand Down Expand Up @@ -40,7 +39,13 @@ set_property(TARGET Core APPEND PROPERTY DICT_HEADERS
TVirtualCollectionProxy.h
)

target_sources(Core PRIVATE
set_property(TARGET Core APPEND PROPERTY DICT_HEADERS ${CONT_HEADERS})

set(RELATIVE_INC_HEADERS ${CONT_HEADERS})
list(TRANSFORM RELATIVE_INC_HEADERS PREPEND inc/)

target_sources(Core
PRIVATE
src/TArrayC.cxx
src/TArray.cxx
src/TArrayD.cxx
Expand All @@ -67,6 +72,12 @@ target_sources(Core PRIVATE
src/TRefTable.cxx
src/TSeqCollection.cxx
src/TSortedList.cxx
PRIVATE
FILE_SET private_header_files
TYPE HEADERS
BASE_DIRS inc/
FILES
${RELATIVE_INC_HEADERS}
)

target_include_directories(Core
Expand Down
26 changes: 26 additions & 0 deletions core/dictgen/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,32 @@ ROOT_OBJECT_LIBRARY(Dictgen
XMLReader.cxx
)

set(DICTGEN_HEADERS
BaseSelectionRule.h
ClassSelectionRule.h
cygpath.h
DictSelectionReader.h
LinkdefReader.h
rootcling_impl.h
Scanner.h
SelectionRules.h
TModuleGenerator.h
VariableSelectionRule.h
XMLReader.h
)

set(RELATIVE_RES_HEADERS ${DICTGEN_HEADERS})
list(TRANSFORM RELATIVE_RES_HEADERS PREPEND res/)

target_sources(Dictgen
PRIVATE
FILE_SET private_header_files
TYPE HEADERS
BASE_DIRS res/
FILES
${RELATIVE_RES_HEADERS}
)

# This directory contains files that include llvm, which can give warnings.
if(NOT MSVC)
target_compile_options(Dictgen PRIVATE -Wno-error)
Expand Down
27 changes: 26 additions & 1 deletion core/foundation/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# CMakeLists.txt file for building ROOT core/foundation package
############################################################################

set_property(TARGET Core APPEND PROPERTY DICT_HEADERS
set(FOUNDATION_HEADERS
ESTLType.h
TClassEdit.h
TError.h
Expand All @@ -25,6 +25,8 @@ set_property(TARGET Core APPEND PROPERTY DICT_HEADERS
ROOT/TypeTraits.hxx
)

set_property(TARGET Core APPEND PROPERTY DICT_HEADERS ${FOUNDATION_HEADERS})

set(FOUNDATION_SOURCES
src/FoundationUtils.cxx
src/RConversionRuleParser.cxx
Expand Down Expand Up @@ -61,5 +63,28 @@ set_target_properties(Foundation_Stage1 PROPERTIES
VISIBILITY_INLINES_HIDDEN "ON"
)


set(RELATIVE_INC_HEADERS ${FOUNDATION_HEADERS})
list(TRANSFORM RELATIVE_INC_HEADERS PREPEND inc/)

target_sources(
Foundation_Stage1
PRIVATE
FILE_SET private_header_files
TYPE HEADERS
BASE_DIRS inc/
FILES
${RELATIVE_INC_HEADERS}
)
target_sources(
Core
PRIVATE
FILE_SET private_header_files
TYPE HEADERS
BASE_DIRS inc/
FILES
${RELATIVE_INC_HEADERS}
)

ROOT_INSTALL_HEADERS(${FOUNDATION_HEADER_DIRS})
ROOT_ADD_TEST_SUBDIRECTORY(test)
16 changes: 14 additions & 2 deletions core/gui/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# CMakeLists.txt file for building ROOT core/meta package
############################################################################

set_property(TARGET Core APPEND PROPERTY DICT_HEADERS
set(GUI_HEADERS
GuiTypes.h
TApplicationImp.h
TBrowser.h
Expand All @@ -25,7 +25,13 @@ set_property(TARGET Core APPEND PROPERTY DICT_HEADERS
TToggle.h
)

target_sources(Core PRIVATE
set_property(TARGET Core APPEND PROPERTY DICT_HEADERS ${GUI_HEADERS})

set(RELATIVE_INC_HEADERS ${GUI_HEADERS})
list(TRANSFORM RELATIVE_INC_HEADERS PREPEND inc/)

target_sources(Core
PRIVATE
src/InitGui.cxx
src/TApplicationImp.cxx
src/TBrowser.cxx
Expand All @@ -40,6 +46,12 @@ target_sources(Core PRIVATE
src/TObjectSpy.cxx
src/TToggle.cxx
src/TToggleGroup.cxx
PRIVATE
FILE_SET private_header_files
TYPE HEADERS
BASE_DIRS inc/
FILES
${RELATIVE_INC_HEADERS}
)

target_include_directories(Core PUBLIC
Expand Down
24 changes: 21 additions & 3 deletions core/imt/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,16 @@ target_link_libraries(Imt PRIVATE Thread INTERFACE Core)

if(imt)
target_link_libraries(Imt PRIVATE TBB::tbb)

ROOT_GENERATE_DICTIONARY(G__Imt STAGE1
set(IMT_HEADERS
ROOT/TTaskGroup.hxx
ROOT/RTaskArena.hxx
ROOT/RSlotStack.hxx
ROOT/TExecutor.hxx
ROOT/TThreadExecutor.hxx
ROOT/InternalIMTUtils.hxx
)
ROOT_GENERATE_DICTIONARY(G__Imt STAGE1
${IMT_HEADERS}
LINKDEF
LinkDef.h
MODULE
Expand All @@ -53,8 +55,11 @@ if(imt)

ROOT_ADD_TEST_SUBDIRECTORY(test)
else()
ROOT_GENERATE_DICTIONARY(G__Imt STAGE1
set(IMT_HEADERS
ROOT/TExecutor.hxx
)
ROOT_GENERATE_DICTIONARY(G__Imt STAGE1
${IMT_HEADERS}
LINKDEF
LinkDef.h
MODULE
Expand All @@ -65,4 +70,17 @@ else()
)
endif()

set(RELATIVE_INC_HEADERS ${IMT_HEADERS})
list(TRANSFORM RELATIVE_INC_HEADERS PREPEND inc/)

target_sources(Imt
PRIVATE
FILE_SET private_header_files
TYPE HEADERS
BASE_DIRS inc/
FILES
${RELATIVE_INC_HEADERS}
inc/LinkDef.h
)

ROOT_INSTALL_HEADERS()
11 changes: 10 additions & 1 deletion core/lz4/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,16 @@
# For the licensing terms see $ROOTSYS/LICENSE.
# For the list of contributors see $ROOTSYS/README/CREDITS.

target_sources(Core PRIVATE src/ZipLZ4.cxx)
target_sources(Core
PRIVATE
src/ZipLZ4.cxx
PRIVATE
FILE_SET private_header_files
TYPE HEADERS
BASE_DIRS inc/
FILES
inc/ZipLZ4.h
)
target_link_libraries(Core PRIVATE xxHash::xxHash LZ4::LZ4)
target_include_directories(Core PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/inc>
Expand Down
11 changes: 10 additions & 1 deletion core/lzma/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,16 @@
# CMakeLists.txt file for building ROOT core/lzma package
############################################################################

target_sources(Core PRIVATE src/ZipLZMA.c)
target_sources(Core
PRIVATE
src/ZipLZMA.c
PRIVATE
FILE_SET private_header_files
TYPE HEADERS
BASE_DIRS inc/
FILES
inc/ZipLZMA.h
)

target_link_libraries(Core PRIVATE LibLZMA::LibLZMA)

Expand Down
11 changes: 11 additions & 0 deletions core/macosx/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,17 @@ if(cocoa)

target_sources(Core PRIVATE $<TARGET_OBJECTS:Macosx>)

target_sources(Macosx
PRIVATE
FILE_SET private_header_files
TYPE HEADERS
BASE_DIRS inc/
FILES
inc/CocoaUtils.h
inc/TMacOSXSystem.h
inc/LinkDef.h
)

endif()

ROOT_INSTALL_HEADERS()
16 changes: 14 additions & 2 deletions core/meta/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# CMakeLists.txt file for building ROOT core/meta package
############################################################################

set_property(TARGET Core APPEND PROPERTY DICT_HEADERS
set(META_HEADERS
TBaseClass.h
TClassGenerator.h
TClass.h
Expand Down Expand Up @@ -52,7 +52,13 @@ set_property(TARGET Core APPEND PROPERTY DICT_HEADERS
TVirtualObject.h
)

target_sources(Core PRIVATE
set_property(TARGET Core APPEND PROPERTY DICT_HEADERS ${META_HEADERS})

set(RELATIVE_INC_HEADERS ${META_HEADERS})
list(TRANSFORM RELATIVE_INC_HEADERS PREPEND inc/)

target_sources(Core
PRIVATE
src/TBaseClass.cxx
src/TClass.cxx
src/TClassGenerator.cxx
Expand Down Expand Up @@ -86,6 +92,12 @@ target_sources(Core PRIVATE
src/TViewPubDataMembers.cxx
src/TViewPubFunctions.cxx
src/TVirtualStreamerInfo.cxx
PRIVATE
FILE_SET private_header_files
TYPE HEADERS
BASE_DIRS inc/
FILES
${RELATIVE_INC_HEADERS}
)

target_include_directories(Core
Expand Down
Loading
Loading