From 10e87931b1a6dc20ad83c7d99c9754f83700e67f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Bylica?= Date: Thu, 28 Nov 2019 19:34:17 +0100 Subject: [PATCH] cmake: Always build instructions lib with PIC --- lib/instructions/CMakeLists.txt | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/lib/instructions/CMakeLists.txt b/lib/instructions/CMakeLists.txt index 70990de..a50fd25 100644 --- a/lib/instructions/CMakeLists.txt +++ b/lib/instructions/CMakeLists.txt @@ -10,9 +10,14 @@ add_library( ) add_library(evmc::instructions ALIAS instructions) -set_target_properties(instructions PROPERTIES OUTPUT_NAME evmc-instructions) -target_include_directories(instructions PUBLIC $$) +set_target_properties(instructions PROPERTIES + OUTPUT_NAME evmc-instructions + POSITION_INDEPENDENT_CODE TRUE +) +target_include_directories(instructions PUBLIC + $$ +) if(EVMC_INSTALL) install(TARGETS instructions EXPORT evmcTargets DESTINATION ${CMAKE_INSTALL_LIBDIR}) -endif() \ No newline at end of file +endif()