projects
/
platform
/
upstream
/
iotjs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7583818
)
Add pie flag to support ASLR
accepted/tizen/unified/20200623.123916
submit/tizen/20200623.171731
author
Haesik Jun
<haesik.jun@samsung.com>
Tue, 23 Jun 2020 16:32:04 +0000
(
01:32
+0900)
committer
Haesik Jun
<haesik.jun@samsung.com>
Tue, 23 Jun 2020 16:32:04 +0000
(
01:32
+0900)
Change-Id: I290f3d929d77605a5efc692e4dff8de1a02b71cb
Signed-off-by: Haesik Jun <haesik.jun@samsung.com>
CMakeLists.txt
patch
|
blob
|
history
diff --git
a/CMakeLists.txt
b/CMakeLists.txt
index
c8321e0
..
b3266a4
100644
(file)
--- a/
CMakeLists.txt
+++ b/
CMakeLists.txt
@@
-82,6
+82,13
@@
if("${CMAKE_BUILD_TYPE}" STREQUAL "Debug")
if(HAS_NO_PIE AND NOT "${TARGET_OS}" STREQUAL "darwin")
iotjs_add_link_flags(-no-pie)
endif()
+else()
+ iotjs_add_compile_flags(-fPIE)
+ if("${TARGET_OS}" STREQUAL "darwin")
+ iotjs_add_link_flags(-Wl,-pie)
+ else()
+ iotjs_add_link_flags(-pie)
+ endif()
endif()
if (CREATE_SHARED_LIB)