From d08163b4fe4e74f02b74a1fb69484b00950a149f Mon Sep 17 00:00:00 2001 From: Guillem Jover Date: Tue, 18 Apr 2023 03:56:16 +0200 Subject: [PATCH] build: Check whether we need libperfstat on AIX The getentropy() implementation makes use of this library on AIX. --- configure.ac | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/configure.ac b/configure.ac index 93e3b36..db33043 100644 --- a/configure.ac +++ b/configure.ac @@ -159,6 +159,15 @@ AS_CASE([$host_os], ]) LIBS="$saved_LIBS" ], + [aix*], [ + saved_LIBS="$LIBS" + AC_SEARCH_LIBS([perfstat_cpu_total], [perfstat], [ + AS_IF([test "x$ac_cv_search_perfstat_cpu_total" != "xnone required"], [ + LIBBSD_LIBS="$LIBBSD_LIBS $ac_cv_search_perfstat_cpu_total" + ]) + ]) + LIBS="$saved_LIBS" + ], ) # Checks for header files.