Add .note.gnu.property runtime verification and merge support
[external/binutils.git] / bfd / configure.ac
index 0ecbf08..0bd5008 100644 (file)
@@ -105,6 +105,27 @@ AS_IF([ test x"$enable_leading_mingw64_underscores" = xyes ],
   [AC_DEFINE(USE_MINGW64_LEADING_UNDERSCORES, 1,
     [Define if we should use leading underscore on 64 bit mingw targets])])
 
+AC_ARG_ENABLE(annobin_verification,
+[AS_HELP_STRING([[--enable-annobin-verification[=warn|strict]]],
+[enable runtime checks with dynamic notes generated by annobin plugin])],
+[case "${enableval}" in
+  yes | warn | "" ) annobin_verification=warn ;;
+  strict ) annobin_verification=strict ;;
+  no) annobin_verification=no ;;
+  *) annobin_verification=no ;;
+ esac],
+[annobin_verification=no])
+if test "$annobin_verification" = "yes" ||
+   test "$annobin_verification" = "warn" ||
+   test "$annobin_verification" = "strict"; then
+   AC_DEFINE(ENABLE_ANNOBIN_VERIFICATION, 1,
+           [Define to enable annobin runtime checks for static linker (warnings only)])
+   if test "$annobin_verification" = "strict"; then
+     AC_DEFINE(ENABLE_ANNOBIN_VERIFICATION_STRICT, 1,
+             [Define to enable annobin runtime strict checks (error mode)])
+   fi
+fi
+
 DEBUGDIR=${libdir}/debug
 AC_ARG_WITH(separate-debug-dir,
   AS_HELP_STRING([--with-separate-debug-dir=DIR],