Skip to content

Commit

Permalink
Applied updates
Browse files Browse the repository at this point in the history
  • Loading branch information
joachimmetz committed Oct 10, 2024
1 parent 355a006 commit 0d5f020
Show file tree
Hide file tree
Showing 16 changed files with 734 additions and 3,403 deletions.
39 changes: 35 additions & 4 deletions m4/common.m4
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
dnl Checks for common headers and functions
dnl
dnl Version: 20240511
dnl Version: 20240513

dnl Function to test if a certain feature was disabled
AC_DEFUN([AX_COMMON_ARG_DISABLE],
Expand Down Expand Up @@ -564,11 +564,42 @@ AC_DEFUN([AX_COMMON_CHECK_LOCAL],
AX_COMMON_CHECK_FUNC_PRINTF_ZD
])

dnl Function to test if a library with a specific definition is available
AC_DEFUN([AX_CHECK_LIB_DEFINITION],
[AC_CACHE_CHECK(
[if `$2' is defined],
[ac_cv_$1_definition_$2],
[AC_LANG_PUSH(C)
AC_LINK_IFELSE(
[AC_LANG_PROGRAM(
[[#include <$1.h>]],
[[int test = $2;
return( 0 ); ]]
)],
[ac_cv_$1_definition_$2=yes],
[ac_cv_$1_definition_$2=no])
AC_LANG_POP(C)])
AS_IF(
[test "x$ac_cv_$1_definition_$2" != xyes],
[ac_cv_$1=no])
])

dnl Function to test if a library with specific definitions is available
AC_DEFUN([AX_CHECK_LIB_DEFINITIONS],
[m4_foreach(
[definition],
[$2],
[AX_CHECK_LIB_DEFINITION(
[$1],
[definition])
])
])

dnl Function to test if a library with specific functions is available
AC_DEFUN([AX_CHECK_LIB_FUNCTIONS],
[ac_cv_$1=yes
m4_foreach(
[m4_foreach(
[function],
[$3],
[AC_CHECK_LIB(
Expand Down
Loading

0 comments on commit 0d5f020

Please sign in to comment.