]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
configure.ac rev2 for stackprof try-run
authorSerhei Makarov <serhei@serhei.io>
Fri, 12 Jun 2026 14:33:11 +0000 (10:33 -0400)
committerSerhei Makarov <serhei@serhei.io>
Fri, 12 Jun 2026 14:33:11 +0000 (10:33 -0400)
configure.ac

index ec4525708df7e11e1d20a5c4041768f17ffc8491..da61d5f900f24cb081ee7bb30b75ee3fde2b8295 100644 (file)
@@ -930,8 +930,11 @@ AS_IF([test "x$HAVE_CXX20" = "xyes"], [
   AC_LANG_POP
   CXXFLAGS="$old_CXXFLAGS"
 ])
-AM_CONDITIONAL([ENABLE_STACKPROF],[test "x${ac_cv_header_linux_perf_event_h}x${ac_cv_have_cxx20_format_h}x${HAVE_CXX20}" = "xyesxyesxyes" ])
-
+AS_IF([test "x${ac_cv_header_linux_perf_event_h}x${ac_cv_have_cxx20_format_h}x${HAVE_CXX20}" = "xyesxyesxyes" ],[enable_stackprof=yes],[enable_stackprof=no])
+AM_CONDITIONAL(ENABLE_STACKPROF, test "x$enable_stackprof" = "xyes")
+if test "x${ac_cv_header_linux_perf_event_h}x$enable_stackprof" = "xyesxno"; then
+   AC_MSG_WARN([Unable to build eu-stackprof, missing C++20 with format.h])
+fi
 
 AC_CHECK_HEADERS([execinfo.h])