Commit 295ef517 authored by Mike Gabriel's avatar Mike Gabriel

debian/patches: Add 1008_gcc-fPIC-on-arm64.patch. Enable -fPIC linker option...

debian/patches: Add 1008_gcc-fPIC-on-arm64.patch. Enable -fPIC linker option for arm64 and armhf builds.
parent b83a38b4
Description: CPU types arm64 and armhf need to be linked with -fPIC.
Author: Mike Gabriel <mike.gabriel@das-netzwerkteam.de>
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -118,6 +118,9 @@
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -march=i686")
endif()
endif()
+ if (CMAKE_SYSTEM_PROCESSOR STREQUAL "armv7l" OR CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC")
+ endif()
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall")
CHECK_C_COMPILER_FLAG (-Wno-unused-result Wno-unused-result)
if(Wno-unused-result)
......@@ -5,4 +5,5 @@
1005_parse-buffer-endianess.patch
1006_test-unicode-endianess.patch
1007_detect-more-architectures.patch
1008_gcc-fPIC-on-arm64.patch
2001_detect-ffmpeg-on-Debian.patch
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment