Add install targets to CMake files

This commit is contained in:
Nikolaj Schlej 2023-02-12 13:08:35 -08:00
parent 11e00f7113
commit 4053a8fe72
4 changed files with 28 additions and 11 deletions

View File

@ -64,3 +64,8 @@ ADD_DEFINITIONS(-DU_ENABLE_NVRAM_PARSING_SUPPORT -DU_ENABLE_ME_PARSING_SUPPORT
ADD_EXECUTABLE(UEFIExtract ${PROJECT_SOURCES})
IF(UNIX)
SET_TARGET_PROPERTIES(UEFIExtract PROPERTIES OUTPUT_NAME uefiextract)
ENDIF()
INSTALL(TARGETS UEFIExtract)

View File

@ -63,3 +63,8 @@ ADD_DEFINITIONS(-DU_ENABLE_NVRAM_PARSING_SUPPORT -DU_ENABLE_FIT_PARSING_SUPPORT
ADD_EXECUTABLE(UEFIFind ${PROJECT_SOURCES})
IF(UNIX)
SET_TARGET_PROPERTIES(UEFIFind PROPERTIES OUTPUT_NAME uefifind)
ENDIF()
INSTALL(TARGETS UEFIFind)

View File

@ -12,17 +12,18 @@ IF (CMAKE_CXX_COMPILER_ID MATCHES "Clang")
# Enable sanitizers for debug builds done by Clang
IF(CMAKE_BUILD_TYPE MATCHES Debug)
MESSAGE("-- Clang sanitizers enabled")
ADD_COMPILE_OPTIONS(-fsanitize=undefined)
ADD_COMPILE_OPTIONS(-fsanitize=integer)
ADD_COMPILE_OPTIONS(-fsanitize=nullability)
ADD_COMPILE_OPTIONS(-fsanitize=implicit-conversion)
ADD_COMPILE_OPTIONS(-fsanitize=array-bounds)
ADD_COMPILE_OPTIONS(-fno-omit-frame-pointer)
ADD_LINK_OPTIONS(-fsanitize=integer)
ADD_LINK_OPTIONS(-fsanitize=nullability)
ADD_LINK_OPTIONS(-fsanitize=implicit-conversion)
ADD_LINK_OPTIONS(-fsanitize=array-bounds)
ADD_LINK_OPTIONS(-fno-omit-frame-pointer)
ADD_COMPILE_OPTIONS(-fsanitize=undefined)
ADD_LINK_OPTIONS(-fsanitize=undefined)
ADD_COMPILE_OPTIONS(-fsanitize=integer)
ADD_LINK_OPTIONS(-fsanitize=integer)
ADD_COMPILE_OPTIONS(-fsanitize=nullability)
ADD_LINK_OPTIONS(-fsanitize=nullability)
ADD_COMPILE_OPTIONS(-fsanitize=implicit-conversion)
ADD_LINK_OPTIONS(-fsanitize=implicit-conversion)
ADD_COMPILE_OPTIONS(-fsanitize=array-bounds)
ADD_LINK_OPTIONS(-fsanitize=array-bounds)
ENDIF()
ENDIF()
@ -138,3 +139,10 @@ SET_TARGET_PROPERTIES(UEFITool PROPERTIES
AUTOMOC ON
AUTOUIC ON
)
IF(UNIX AND (NOT APPLE))
SET_TARGET_PROPERTIES(UEFITool PROPERTIES
OUTPUT_NAME uefitool)
ENDIF()
INSTALL(TARGETS UEFITool BUNDLE DESTINATION "/Applications" )

View File

@ -3,9 +3,8 @@ Type=Application
Version=1.0
Name=UEFITool
Comment=UEFI firmware image viewer and editor
Path=/usr/bin
Exec=uefitool
Icon=uefitool
Terminal=false
Categories=Development;System;Utility;HardwareSettings;Electronics;Engineering;
Keywords=BIOS;
Keywords=BIOS;UEFI;