mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-07 14:20:06 -06:00
Add `LICENSE` and `DEFAULT_LICENSE` arguments to the `PACKAGE_INFO` modes of the `install` and `export` commands. If not otherwise specified, the `LICENSE` will be taken from the project's `SPDX_LICENSE`, if available.
16 lines
400 B
CMake
16 lines
400 B
CMake
add_library(foo INTERFACE)
|
|
install(TARGETS foo EXPORT foo DESTINATION .)
|
|
export(
|
|
EXPORT foo
|
|
PACKAGE_INFO foo
|
|
VERSION 1.2.3
|
|
VERSION_SCHEMA simple
|
|
COMPAT_VERSION 1.2.0
|
|
DEFAULT_TARGETS foo
|
|
DEFAULT_CONFIGURATIONS release debug
|
|
LICENSE "BSD-3-Clause AND CC-BY-SA-4.0"
|
|
DEFAULT_LICENSE "BSD-3-Clause"
|
|
DESCRIPTION "Sample package"
|
|
HOMEPAGE_URL "https://www.example.com/package/foo"
|
|
)
|