autoconf.m4 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. # This file is part of Autoconf. -*- Autoconf -*-
  2. # Driver that loads the Autoconf macro files.
  3. #
  4. # Copyright (C) 1994, 1999-2002, 2006, 2008-2012 Free Software
  5. # Foundation, Inc.
  6. # This file is part of Autoconf. This program is free
  7. # software; you can redistribute it and/or modify it under the
  8. # terms of the GNU General Public License as published by the
  9. # Free Software Foundation, either version 3 of the License, or
  10. # (at your option) any later version.
  11. #
  12. # This program is distributed in the hope that it will be useful,
  13. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  15. # GNU General Public License for more details.
  16. #
  17. # Under Section 7 of GPL version 3, you are granted additional
  18. # permissions described in the Autoconf Configure Script Exception,
  19. # version 3.0, as published by the Free Software Foundation.
  20. #
  21. # You should have received a copy of the GNU General Public License
  22. # and a copy of the Autoconf Configure Script Exception along with
  23. # this program; see the files COPYINGv3 and COPYING.EXCEPTION
  24. # respectively. If not, see <http://www.gnu.org/licenses/>.
  25. # Written by David MacKenzie and many others.
  26. #
  27. # Do not sinclude acsite.m4 here, because it may not be installed
  28. # yet when Autoconf is frozen.
  29. # Do not sinclude ./aclocal.m4 here, to prevent it from being frozen.
  30. # general includes some AU_DEFUN.
  31. m4_include([autoconf/autoupdate.m4])
  32. m4_include([autoconf/autoscan.m4])
  33. m4_include([autoconf/general.m4])
  34. m4_include([autoconf/status.m4])
  35. m4_include([autoconf/autoheader.m4])
  36. m4_include([autoconf/autotest.m4])
  37. m4_include([autoconf/programs.m4])
  38. m4_include([autoconf/lang.m4])
  39. m4_include([autoconf/c.m4])
  40. m4_include([autoconf/erlang.m4])
  41. m4_include([autoconf/fortran.m4])
  42. m4_include([autoconf/go.m4])
  43. m4_include([autoconf/functions.m4])
  44. m4_include([autoconf/headers.m4])
  45. m4_include([autoconf/types.m4])
  46. m4_include([autoconf/libs.m4])
  47. m4_include([autoconf/specific.m4])
  48. m4_include([autoconf/oldnames.m4])
  49. # We discourage the use of the non prefixed macro names: M4sugar maps
  50. # all the builtins into `m4_'. Autoconf has been converted to these
  51. # names too. But users may still depend upon these, so reestablish
  52. # them.
  53. # In order to copy pushdef stacks, m4_copy temporarily destroys the
  54. # current pushdef stack. But these builtins are so primitive that:
  55. # 1. they should not have more than one pushdef definition
  56. # 2. undefining the pushdef stack to copy breaks m4_copy
  57. # Hence, we temporarily restore a simpler m4_copy.
  58. m4_pushdef([m4_copy], [m4_define([$2], m4_defn([$1]))])
  59. m4_copy_unm4([m4_builtin])
  60. m4_copy_unm4([m4_changequote])
  61. m4_copy_unm4([m4_decr])
  62. m4_copy_unm4([m4_define])
  63. m4_copy_unm4([m4_defn])
  64. m4_copy_unm4([m4_divert])
  65. m4_copy_unm4([m4_divnum])
  66. m4_copy_unm4([m4_errprint])
  67. m4_copy_unm4([m4_esyscmd])
  68. m4_copy_unm4([m4_ifdef])
  69. m4_copy([m4_if], [ifelse])
  70. m4_copy_unm4([m4_incr])
  71. m4_copy_unm4([m4_index])
  72. m4_copy_unm4([m4_indir])
  73. m4_copy_unm4([m4_len])
  74. m4_copy([m4_bpatsubst], [patsubst])
  75. m4_copy_unm4([m4_popdef])
  76. m4_copy_unm4([m4_pushdef])
  77. m4_copy([m4_bregexp], [regexp])
  78. m4_copy_unm4([m4_sinclude])
  79. m4_copy_unm4([m4_syscmd])
  80. m4_copy_unm4([m4_sysval])
  81. m4_copy_unm4([m4_traceoff])
  82. m4_copy_unm4([m4_traceon])
  83. m4_copy_unm4([m4_translit])
  84. m4_copy_unm4([m4_undefine])
  85. m4_copy_unm4([m4_undivert])
  86. m4_popdef([m4_copy])
  87. # Yet some people have started to use m4_patsubst and m4_regexp.
  88. m4_define([m4_patsubst],
  89. [m4_expand_once([m4_warn([syntax],
  90. [do not use m4_patsubst: use patsubst or m4_bpatsubst])])dnl
  91. patsubst($@)])
  92. m4_define([m4_regexp],
  93. [m4_expand_once([m4_warn([syntax],
  94. [do not use m4_regexp: use regexp or m4_bregexp])])dnl
  95. regexp($@)])