Skip to content

Commit

Permalink
Added support for Copyright* (#6)
Browse files Browse the repository at this point in the history
  • Loading branch information
bilke authored Apr 18, 2023
1 parent 40d1b7f commit ca42334
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
1 change: 1 addition & 0 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,4 @@ jobs:
grep -q fmt build/third_party.txt
grep -q sol2 build/third_party.txt
grep -q expected build/third_party.txt
grep -q CMake build/third_party.txt
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ function(write_license_disclaimer FILE_NAME PACKAGES)
set(PRINT_DELIMITER OFF)
foreach(package ${PACKAGES})
file(GLOB licenses "${${package}_SOURCE_DIR}/LICENSE*" "${${package}_SOURCE_DIR}/LICENCE*"
"${${package}_SOURCE_DIR}/COPYING*"
"${${package}_SOURCE_DIR}/COPYING*" "${${package}_SOURCE_DIR}/Copyright*"
)
list(LENGTH licenses LICENSE_COUNT)
if(LICENSE_COUNT GREATER_EQUAL 1)
Expand Down
7 changes: 7 additions & 0 deletions test/project/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,13 @@ CPMAddPackage(
DOWNLOAD_ONLY YES
)

CPMAddPackage(
NAME CMake
URL https://github.com/Kitware/CMake/archive/v3.25.3.zip
VERSION 3.25.3
DOWNLOAD_ONLY YES
)

cpm_licenses_create_disclaimer_target(
write-licenses "${CMAKE_CURRENT_BINARY_DIR}/third_party.txt" "${CPM_PACKAGES}"
)

0 comments on commit ca42334

Please sign in to comment.