diff mbox

[FFmpeg-devel] configure: Force pie for Android

Message ID CAB0OVGon7Hi00t9vz2b=Eb29RGSUqi+a=LigEMC8aJ2NorJAug@mail.gmail.com
State Accepted
Headers show

Commit Message

Carl Eugen Hoyos July 13, 2018, 6:52 p.m. UTC
Hi!

A user pointed out that Android requires pie since Lollipop.

Please comment, Carl Eugen

Comments

Carl Eugen Hoyos July 25, 2018, 6:45 p.m. UTC | #1
2018-07-13 20:52 GMT+02:00, Carl Eugen Hoyos <ceffmpeg@gmail.com>:

> A user pointed out that Android requires pie since Lollipop.

Patch applied.

Carl Eugen
diff mbox

Patch

From eb04227c4c2cee59b257b2ef91316d0c674575bf Mon Sep 17 00:00:00 2001
From: Carl Eugen Hoyos <ceffmpeg@gmail.com>
Date: Fri, 13 Jul 2018 20:46:18 +0200
Subject: [PATCH] configure: Force pie for Android.

Position-independet executable are requried since Lollipop.
---
 configure |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/configure b/configure
index b1a4dcf..4592839 100755
--- a/configure
+++ b/configure
@@ -5045,6 +5045,8 @@  case $target_os in
     android)
         disable symver
         enable section_data_rel_ro
+        add_cflags -fPIE
+        add_ldexeflags -fPIE -pie
         SLIB_INSTALL_NAME='$(SLIBNAME)'
         SLIB_INSTALL_LINKS=
         SHFLAGS='-shared -Wl,-soname,$(SLIBNAME)'
-- 
1.7.10.4