mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-04-04 21:17:43 +03:00
parent
8b6d0e4b12
commit
3ecc0c70e2
1 changed files with 3 additions and 1 deletions
|
@ -169,6 +169,9 @@ elseif(KEEPASSXC_DIST_TYPE STREQUAL "Other")
|
||||||
unset(KEEPASSXC_DIST)
|
unset(KEEPASSXC_DIST)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
# Create position independent code for shared libraries and executables
|
||||||
|
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
|
||||||
|
|
||||||
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "4")
|
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "4")
|
||||||
set(IS_32BIT TRUE)
|
set(IS_32BIT TRUE)
|
||||||
endif()
|
endif()
|
||||||
|
@ -292,7 +295,6 @@ check_add_gcc_compiler_flag("-Wcast-align")
|
||||||
|
|
||||||
if(UNIX AND NOT APPLE)
|
if(UNIX AND NOT APPLE)
|
||||||
check_add_gcc_compiler_flag("-Qunused-arguments")
|
check_add_gcc_compiler_flag("-Qunused-arguments")
|
||||||
check_add_gcc_compiler_flag("-fPIC")
|
|
||||||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,--no-add-needed -Wl,--as-needed -Wl,--no-undefined")
|
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,--no-add-needed -Wl,--as-needed -Wl,--no-undefined")
|
||||||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-z,relro,-z,now -pie")
|
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-z,relro,-z,now -pie")
|
||||||
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,--no-add-needed -Wl,--as-needed")
|
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,--no-add-needed -Wl,--as-needed")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue