Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Complete initial implementation for treating internal packages as external found with find_package() (#63) #560

Merged
merged 49 commits into from
Mar 29, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
ccb222a
Add printing of <Package>_PACAKGE_BUILD_STATUS (#63)
bartlettroscoe Dec 22, 2022
afcea28
Add documentation for <Package>_SUBPACKAGES varaible (#63)
bartlettroscoe Jan 12, 2023
ee5f2ce
Small doc update (#63)
bartlettroscoe Jan 13, 2023
0fc3973
Change tribits_print_prefix_string_and_list() to pass in list name (#63)
bartlettroscoe Jan 17, 2023
f3f9356
WIP: Add basic logic for setting <Package>_PACKAGE_BUILD_STATUS=EXTER…
bartlettroscoe Jan 24, 2023
09e61e5
WIP: rename some local vars away from UPPPER-CASE (#63)
bartlettroscoe Jan 18, 2023
5648cf7
WIP: Replace bool arg includeEmpty with enum arg enableEmptyStatus (#63)
bartlettroscoe Jan 18, 2023
abd846a
WIP: Small doc and format changes (#63)
bartlettroscoe Jan 18, 2023
cc8d5b7
WIP: Add internalOrExternal arg to tribits_print_packages_list_enable…
bartlettroscoe Jan 19, 2023
f85cc17
WIP: Change name from TribitsGetEnabledSublists.cmake to TribitsPacka…
bartlettroscoe Jan 19, 2023
e30b5bf
WIP: Change printing of package set lists based in INTERNAL/EXTERNAL …
bartlettroscoe Jan 20, 2023
e14b0d2
WIP: Add printing of Final set of [non-]enabled top-level external pa…
bartlettroscoe Jan 20, 2023
864ad9f
Factor out tribits_filter_package_list_from_var() (#63)
bartlettroscoe Jan 20, 2023
7ab3809
MockTrilinos: Set <Project>_TRACE_DEPENDENCY_HANDLING_ONLY=ON (#63)
bartlettroscoe Jan 21, 2023
aaec210
WIP: Adjust processing of internal and external packages (#63)
bartlettroscoe Jan 21, 2023
b9b4567
Finish basic implentation for building against external packages (#63)
bartlettroscoe Jan 24, 2023
33902f7
Process TPLs at base project level, pass info through <Package>Config…
bartlettroscoe Jan 27, 2023
a2790c8
Make WrapExernal work with external TribitsExProj packages (#63)
bartlettroscoe Jan 25, 2023
3065298
Add option <Project>_SKIP_INSTALL_PROJECT_CMAKE_CONFIG_FILES (#63)
bartlettroscoe Jan 25, 2023
aa843a4
WIP: Rename TribitsProcessEnabledTpl.cmake to TribitsProcessEnabledTp…
bartlettroscoe Jan 27, 2023
8e112e0
Add basic special handling for fully TriBITS-compliant external packa…
bartlettroscoe Jan 26, 2023
56b0845
WIP: Add initial failing test case for stagged package installs (#63)
bartlettroscoe Jan 27, 2023
cddd9f1
Initial implementation of pre-building/pre-installing stages of packa…
bartlettroscoe Jan 27, 2023
0c959bb
Revise how internal and external <Package>Config.cmake files are link…
bartlettroscoe Jan 28, 2023
2075dd6
WIP: Improve names of functions and variables (#63)
bartlettroscoe Feb 6, 2023
3b63fbd
WIP: Improve documentation (#63)
bartlettroscoe Feb 6, 2023
3389ceb
WIP: Move functions writing <tplName>Config.cmake files to TribitsExt…
bartlettroscoe Feb 6, 2023
28d1beb
WIP: Rename TribitsExternalPackageFindTplHelpers to TribitsExternalPa…
bartlettroscoe Feb 6, 2023
9a1eba1
WIP: Rename TribitsWriteClientExportFiles.cmake to TribitsInternalPac…
bartlettroscoe Feb 7, 2023
d8d60ae
WIP: Factor out TribitsProjectWriteConfigFile.cmake, reorder funcs (#63)
bartlettroscoe Feb 7, 2023
f14bba2
WIP: Rename func, remove unused funcs (#63)
bartlettroscoe Feb 7, 2023
bdd12c9
WIP: Remove 'Fully' from 'Fully TriBITS-Compliant' (and variations) (…
bartlettroscoe Feb 7, 2023
a2a5b99
Move 'CMake Language Overview and Gotchas' to appendix
bartlettroscoe Feb 9, 2023
61eaf6a
Remove debug print statement that got commited by accident
bartlettroscoe Feb 9, 2023
ba9de28
Adjust logic and printing for setting INTTERNAL packages as EXTERNAL …
bartlettroscoe Feb 18, 2023
80bd994
Update some outputing for TriBITS-compliant external packages (#63)
bartlettroscoe Feb 19, 2023
31de1fe
Add definitions of TriBITS-compliant packages (#63)
bartlettroscoe Feb 20, 2023
652d189
Add links to TriBITS-compliant external package in requirements for F…
bartlettroscoe Feb 20, 2023
8fc1e25
Add build ref item for treating internal packages as external (#634)
bartlettroscoe Feb 21, 2023
2bcc17f
Add CHANGLOG.md entry for -D<Project>_ENABLE_<TplName>=ON (#63, #546)
bartlettroscoe Feb 21, 2023
68c83ef
Add documentation for TriBITS-compliant external packages TRIBITS_PKG…
bartlettroscoe Feb 21, 2023
f8c1ea5
Add CHANGLOG.md entry for supporting pre-installed packages (#63)
bartlettroscoe Feb 21, 2023
f75343e
Merge remote-tracking branch 'github/master' into 63-combined-package…
bartlettroscoe Feb 25, 2023
2de8ca1
Merge branch 'master' into 63-combined-package-data-structures-6
bartlettroscoe Feb 25, 2023
f58975f
Merge remote-tracking branch 'github/master' into 63-combined-package…
bartlettroscoe Feb 28, 2023
90b96ee
Fix some documentation and add new functions to generated docs (#63, …
bartlettroscoe Mar 29, 2023
16b1817
Fix spelling of TribitsCMakeLanguageOverviewAndGotchas.rst (#63, #560)
bartlettroscoe Mar 29, 2023
014a153
Remove unused legacy RELATIVE_PATH code (#63, #560)
bartlettroscoe Mar 29, 2023
ee67e05
Merge remote-tracking branch 'github/master' into 63-combined-package…
bartlettroscoe Mar 29, 2023
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
57 changes: 57 additions & 0 deletions tribits/core/package_arch/TribitsGetPackageSublists.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,53 @@
include(TribitsGetPackageEnableStatus)


# @FUNCTION: tribits_filter_package_list_from_var()
#
# Filter a list of packages based on several criteria including
# internal/external, enable status (with empty or non-empty)
#
# Usage::
#
# tribits_filter_package_list_from_var( <packageListVarName>
# <internalOrExternal> <enabledFlag> <enableEmptyStatus>
# <packageSublistOut> )
#
# Where:
#
# * ``<packageListVarName>``: Name of input list var of packages
# * ``<internalOrExternal>``: ``INTERNAL``, ``EXTERNAL`` or "" (i.e.
# INTERNAL or EXTERNAL) (matches ``<Package>_PACKAGE_BUILD_STATUS``)
bartlettroscoe marked this conversation as resolved.
Show resolved Hide resolved
# * ``<enabledFlag>``: ``ON`` for elements that match ``TRUE`` , ``OFF``
# for elements that match ``FALSE``
# * ``<enableEmptyStatus>``: Determines if allowed enable status is ``NONEMPTY``
# or ``INCLUDE_EMPTY``.
# * ``<packageSublistOut>``: The name of the var that will store the filtered
# sublist of packages.
#
function(tribits_filter_package_list_from_var packageListVarName
internalOrExternal enabledFlag enableEmptyStatus packageSublistOut
)
tribits_assert_include_empty_param(${enableEmptyStatus})
tribits_get_sublist_internal_external(${packageListVarName} "${internalOrExternal}"
packageListTmp "")
if (enabledFlag AND (enableEmptyStatus STREQUAL "NONEMPTY"))
tribits_get_sublist_enabled(packageListTmp
packageSublist "")
elseif (enabledFlag AND (enableEmptyStatus STREQUAL "INCLUDE_EMPTY"))
tribits_get_sublist_nondisabled(${packageListTmp} packageSublist "")
elseif (NOT enabledFlag AND (enableEmptyStatus STREQUAL "NONEMPTY"))
tribits_get_sublist_disabled(packageListTmp
packageSublist "")
elseif (NOT enabledFlag AND (enableEmptyStatus STREQUAL "INCLUDE_EMPTY"))
tribits_get_sublist_nonenabled(packageListTmp
packageSublist "")
else()
message(FATAL_ERROR "Should never get here!")
endif()
set(${packageSublistOut} ${packageSublist} PARENT_SCOPE)
endfunction()


# @FUNCTION: tribits_get_sublist_enabled()
#
# Get sub-list of enabled packages
Expand Down Expand Up @@ -211,3 +258,13 @@ function(tribits_assert_internal_or_external_arg internalOrExternal)
${allowedValuesList} )
endif()
endfunction()


function(tribits_assert_include_empty_param enableEmptyStatus)
if ((NOT enableEmptyStatus STREQUAL "NONEMPTY") AND
(NOT enableEmptyStatus STREQUAL "INCLUDE_EMPTY")
)
message(FATAL_ERROR "Error, argument enableEmptyStatus='${enableEmptyStatus}'"
" is invalid! Use 'NONEMPTY' or 'INCLUDE_EMPTY'.")
endif()
endfunction()
31 changes: 3 additions & 28 deletions tribits/core/package_arch/TribitsPrintEnabledPackagesLists.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -131,34 +131,9 @@ endfunction()
function(tribits_print_packages_list_enable_status_from_var packageListVarName
docString internalOrExternal enabledFlag enableEmptyStatus
)
tribits_assert_include_empty_param(${enableEmptyStatus})
tribits_get_sublist_internal_external(${packageListVarName} "${internalOrExternal}"
packageListTmp "")
if (enabledFlag AND (enableEmptyStatus STREQUAL "NONEMPTY"))
tribits_get_sublist_enabled(packageListTmp
enableStatusList "")
elseif (enabledFlag AND (enableEmptyStatus STREQUAL "INCLUDE_EMPTY"))
tribits_get_sublist_nondisabled(${packageListTmp} enableStatusList "")
elseif (NOT enabledFlag AND (enableEmptyStatus STREQUAL "NONEMPTY"))
tribits_get_sublist_disabled(packageListTmp
enableStatusList "")
elseif (NOT enabledFlag AND (enableEmptyStatus STREQUAL "INCLUDE_EMPTY"))
tribits_get_sublist_nonenabled(packageListTmp
enableStatusList "")
else()
message(FATAL_ERROR "Should never get here!")
endif()
tribits_print_prefix_string_and_list("${docString}" enableStatusList)
endfunction()


function(tribits_assert_include_empty_param enableEmptyStatus)
if ((NOT enableEmptyStatus STREQUAL "NONEMPTY") AND
(NOT enableEmptyStatus STREQUAL "INCLUDE_EMPTY")
)
message(FATAL_ERROR "Error, argument enableEmptyStatus='${enableEmptyStatus}'"
" is invalid! Use 'NONEMPTY' or 'INCLUDE_EMPTY'.")
endif()
tribits_filter_package_list_from_var(${packageListVarName}
"${internalOrExternal}" "${enabledFlag}" ${enableEmptyStatus} packageSublist)
tribits_print_prefix_string_and_list("${docString}" packageSublist)
endfunction()


Expand Down