[vlc-devel] [PATCH] configure: fix --disable-branch-protection

Thomas Guillem thomas at gllm.fr
Thu Jan 30 16:02:19 CET 2020


"enable_brprot" was never set when --disable-branch-protection was passed, so
the test != "no" was always true.

Use the name "enable_branch_protection" instead that will be initialized by
autoconf.

PS: --disable-branch-protection seems to be needed to get symbols via gdb.
---
 configure.ac | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/configure.ac b/configure.ac
index aeb2bb23e43..d0bd45318ef 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1699,9 +1699,10 @@ AM_CONDITIONAL([HAVE_SVE], [test "${ac_cv_arm_sve}" = "yes"])
 AC_ARG_ENABLE([branch-protection],
   AS_HELP_STRING([--disable-branch-protection],
     [disable AArch64 branch protection (default auto)]),, [
-  AS_IF([test "${host_cpu}" = "aarch64"], [enable_brprot="yes"] ,[enable_brprot="no"])
+  AS_IF([test "${host_cpu}" = "aarch64"],
+    [enable_branch_protection="yes"], [enable_branch_protection="no"])
 ])
-AS_IF([test "${enable_brprot}" != "no"], [
+AS_IF([test "${enable_branch_protection}" != "no"], [
   AX_CHECK_COMPILE_FLAG([-mbranch-protection=standard], [
     AX_APPEND_FLAG([-mbranch-protection=standard], [CFLAGS])
     AX_APPEND_FLAG([-mbranch-protection=standard], [CXXFLAGS])
-- 
2.20.1



More information about the vlc-devel mailing list