mirror of
https://github.com/gelldur/EventBus.git
synced 2024-12-26 10:41:01 +08:00
Secure installed files
We should be able to remove installed stuff but we want to forbid changes in installed files. Thanks to that we do not modify files by mistake directly from e.g. Clion (when we go to header/source)
This commit is contained in:
parent
2bc2858a8a
commit
d0d236dab0
@ -122,6 +122,8 @@ configure_package_config_file(
|
||||
install(
|
||||
FILES "${project_config}" "${version_config}"
|
||||
DESTINATION "${config_install_dir}"
|
||||
# We don't want someone by accident modify his installed files
|
||||
PERMISSIONS OWNER_EXECUTE OWNER_READ
|
||||
)
|
||||
|
||||
# Config
|
||||
@ -129,6 +131,8 @@ install(
|
||||
install(EXPORT "${TARGETS_EXPORT_NAME}"
|
||||
DESTINATION "${config_install_dir}"
|
||||
NAMESPACE "${namespace}"
|
||||
# We don't want someone by accident modify his installed files
|
||||
PERMISSIONS OWNER_EXECUTE OWNER_READ
|
||||
)
|
||||
|
||||
# Export headers (Install public headers)
|
||||
|
@ -8,7 +8,12 @@ macro(install_public_headers_with_directory HEADER_LIST IGNORE_PREFIX)
|
||||
foreach(HEADER ${${HEADER_LIST}})
|
||||
get_filename_component(DIR ${HEADER} DIRECTORY)
|
||||
string(REPLACE ${IGNORE_PREFIX} "" DIR ${DIR})
|
||||
install(FILES ${HEADER} DESTINATION include/${DIR})
|
||||
install(
|
||||
FILES ${HEADER}
|
||||
DESTINATION include/${DIR}
|
||||
# We don't want someone by accident modify his installed files
|
||||
PERMISSIONS OWNER_EXECUTE OWNER_READ
|
||||
)
|
||||
endforeach(HEADER)
|
||||
|
||||
endmacro(install_public_headers_with_directory)
|
||||
|
Loading…
x
Reference in New Issue
Block a user