licenses and readme
This commit is contained in:
+12
-1
@@ -603,9 +603,20 @@ generate_export_header(${BRAVAIS_EXPORT_HEADER_TARGET}
|
||||
NO_EXPORT_MACRO_NAME BRAVAIS_LOCAL
|
||||
DEPRECATED_MACRO_NAME BRAVAIS_DEPRECATED
|
||||
STATIC_DEFINE BRAVAIS_STATIC_DEFINE
|
||||
EXPORT_FILE_NAME ${CMAKE_CURRENT_BINARY_DIR}/include/bravais/export.h
|
||||
EXPORT_FILE_NAME ${CMAKE_CURRENT_BINARY_DIR}/export.h.raw
|
||||
)
|
||||
|
||||
# generate_export_header() cannot put anything above its include guard
|
||||
# (CUSTOM_CONTENT_FROM_VARIABLE lands at the bottom), so it writes to a scratch
|
||||
# file and the SPDX line is stamped on here. configure_file() only rewrites the
|
||||
# real header when its content changes, so reconfiguring does not force a
|
||||
# rebuild of everything that includes it.
|
||||
file(READ ${CMAKE_CURRENT_BINARY_DIR}/export.h.raw _export_h)
|
||||
file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/export.h.stamped
|
||||
"// SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR MIT\n${_export_h}")
|
||||
configure_file(${CMAKE_CURRENT_BINARY_DIR}/export.h.stamped
|
||||
${CMAKE_CURRENT_BINARY_DIR}/include/bravais/export.h COPYONLY)
|
||||
|
||||
foreach(_target IN LISTS BRAVAIS_LIB_TARGETS)
|
||||
set_target_properties(${_target} PROPERTIES
|
||||
C_VISIBILITY_PRESET hidden
|
||||
|
||||
Reference in New Issue
Block a user