aclocal.m4 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. # generated automatically by aclocal 1.17 -*- Autoconf -*-
  2. # Copyright (C) 1996-2024 Free Software Foundation, Inc.
  3. # This file is free software; the Free Software Foundation
  4. # gives unlimited permission to copy and/or distribute it,
  5. # with or without modifications, as long as this notice is preserved.
  6. # This program is distributed in the hope that it will be useful,
  7. # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
  8. # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  9. # PARTICULAR PURPOSE.
  10. m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
  11. # ===========================================================================
  12. # https://www.gnu.org/software/autoconf-archive/ax_check_link_flag.html
  13. # ===========================================================================
  14. #
  15. # SYNOPSIS
  16. #
  17. # AX_CHECK_LINK_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS], [INPUT])
  18. #
  19. # DESCRIPTION
  20. #
  21. # Check whether the given FLAG works with the linker or gives an error.
  22. # (Warnings, however, are ignored)
  23. #
  24. # ACTION-SUCCESS/ACTION-FAILURE are shell commands to execute on
  25. # success/failure.
  26. #
  27. # If EXTRA-FLAGS is defined, it is added to the linker's default flags
  28. # when the check is done. The check is thus made with the flags: "LDFLAGS
  29. # EXTRA-FLAGS FLAG". This can for example be used to force the linker to
  30. # issue an error when a bad flag is given.
  31. #
  32. # INPUT gives an alternative input source to AC_LINK_IFELSE.
  33. #
  34. # NOTE: Implementation based on AX_CFLAGS_GCC_OPTION. Please keep this
  35. # macro in sync with AX_CHECK_{PREPROC,COMPILE}_FLAG.
  36. #
  37. # LICENSE
  38. #
  39. # Copyright (c) 2008 Guido U. Draheim <guidod@gmx.de>
  40. # Copyright (c) 2011 Maarten Bosmans <mkbosmans@gmail.com>
  41. #
  42. # Copying and distribution of this file, with or without modification, are
  43. # permitted in any medium without royalty provided the copyright notice
  44. # and this notice are preserved. This file is offered as-is, without any
  45. # warranty.
  46. #serial 6
  47. AC_DEFUN([AX_CHECK_LINK_FLAG],
  48. [AC_PREREQ(2.64)dnl for _AC_LANG_PREFIX and AS_VAR_IF
  49. AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_ldflags_$4_$1])dnl
  50. AC_CACHE_CHECK([whether the linker accepts $1], CACHEVAR, [
  51. ax_check_save_flags=$LDFLAGS
  52. LDFLAGS="$LDFLAGS $4 $1"
  53. AC_LINK_IFELSE([m4_default([$5],[AC_LANG_PROGRAM()])],
  54. [AS_VAR_SET(CACHEVAR,[yes])],
  55. [AS_VAR_SET(CACHEVAR,[no])])
  56. LDFLAGS=$ax_check_save_flags])
  57. AS_VAR_IF(CACHEVAR,yes,
  58. [m4_default([$2], :)],
  59. [m4_default([$3], :)])
  60. AS_VAR_POPDEF([CACHEVAR])dnl
  61. ])dnl AX_CHECK_LINK_FLAGS
  62. m4_include([macros/ax_nagios_get_distrib.m4])
  63. m4_include([macros/ax_nagios_get_files.m4])
  64. m4_include([macros/ax_nagios_get_inetd.m4])
  65. m4_include([macros/ax_nagios_get_init.m4])
  66. m4_include([macros/ax_nagios_get_os.m4])
  67. m4_include([macros/ax_nagios_get_paths.m4])
  68. m4_include([macros/ax_nagios_get_ssl.m4])