@ai-ecoverse/wasix-autoconf 0.0.0-stage → 2.72.0-2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +338 -0
- package/README.md +2 -2
- package/bin/autoconf +215 -0
- package/bin/autoheader +335 -0
- package/bin/autom4te +1174 -0
- package/bin/autoreconf +937 -0
- package/bin/autoscan +686 -0
- package/bin/autoupdate +1074 -0
- package/bin/ifnames +158 -0
- package/package.json +75 -4
- package/share/autoconf/Autom4te/C4che.pm +263 -0
- package/share/autoconf/Autom4te/ChannelDefs.pm +549 -0
- package/share/autoconf/Autom4te/Channels.pm +856 -0
- package/share/autoconf/Autom4te/Config.pm +43 -0
- package/share/autoconf/Autom4te/Configure_ac.pm +112 -0
- package/share/autoconf/Autom4te/FileUtils.pm +429 -0
- package/share/autoconf/Autom4te/General.pm +413 -0
- package/share/autoconf/Autom4te/Getopt.pm +99 -0
- package/share/autoconf/Autom4te/Request.pm +121 -0
- package/share/autoconf/Autom4te/XFile.pm +304 -0
- package/share/autoconf/INSTALL +368 -0
- package/share/autoconf/autoconf/autoconf.m4 +105 -0
- package/share/autoconf/autoconf/autoconf.m4f +15460 -0
- package/share/autoconf/autoconf/autoheader.m4 +78 -0
- package/share/autoconf/autoconf/autoscan.m4 +51 -0
- package/share/autoconf/autoconf/autotest.m4 +81 -0
- package/share/autoconf/autoconf/autoupdate.m4 +123 -0
- package/share/autoconf/autoconf/c.m4 +2794 -0
- package/share/autoconf/autoconf/erlang.m4 +270 -0
- package/share/autoconf/autoconf/fortran.m4 +1933 -0
- package/share/autoconf/autoconf/functions.m4 +2127 -0
- package/share/autoconf/autoconf/general.m4 +3374 -0
- package/share/autoconf/autoconf/go.m4 +177 -0
- package/share/autoconf/autoconf/headers.m4 +839 -0
- package/share/autoconf/autoconf/lang.m4 +730 -0
- package/share/autoconf/autoconf/libs.m4 +493 -0
- package/share/autoconf/autoconf/oldnames.m4 +92 -0
- package/share/autoconf/autoconf/programs.m4 +1015 -0
- package/share/autoconf/autoconf/specific.m4 +763 -0
- package/share/autoconf/autoconf/status.m4 +1787 -0
- package/share/autoconf/autoconf/trailer.m4 +4 -0
- package/share/autoconf/autoconf/types.m4 +1133 -0
- package/share/autoconf/autom4te.cfg +169 -0
- package/share/autoconf/autoscan/autoscan.list +264 -0
- package/share/autoconf/autotest/autotest.m4 +27 -0
- package/share/autoconf/autotest/autotest.m4f +3915 -0
- package/share/autoconf/autotest/general.m4 +2292 -0
- package/share/autoconf/autotest/specific.m4 +74 -0
- package/share/autoconf/build-aux/config.guess +1807 -0
- package/share/autoconf/build-aux/config.sub +1960 -0
- package/share/autoconf/build-aux/install-sh +541 -0
- package/share/autoconf/m4sugar/foreach.m4 +362 -0
- package/share/autoconf/m4sugar/m4sh.m4 +2217 -0
- package/share/autoconf/m4sugar/m4sh.m4f +2046 -0
- package/share/autoconf/m4sugar/m4sugar.m4 +3307 -0
- package/share/autoconf/m4sugar/m4sugar.m4f +868 -0
- package/share/autoconf/version.m4 +12 -0
package/bin/autoheader
ADDED
|
@@ -0,0 +1,335 @@
|
|
|
1
|
+
#!/usr/bin/perl
|
|
2
|
+
# -*- Perl -*-
|
|
3
|
+
# Generated from bin/autoheader.in; do not edit by hand.
|
|
4
|
+
|
|
5
|
+
eval 'case $# in 0) exec /usr/bin/perl -S "$0";; *) exec /usr/bin/perl -S "$0" "$@";; esac'
|
|
6
|
+
if 0;
|
|
7
|
+
|
|
8
|
+
# autoheader -- create 'config.h.in' from 'configure.ac'.
|
|
9
|
+
|
|
10
|
+
# Copyright (C) 1992-1994, 1996, 1998-2017, 2020-2023 Free Software
|
|
11
|
+
# Foundation, Inc.
|
|
12
|
+
|
|
13
|
+
# This program is free software: you can redistribute it and/or modify
|
|
14
|
+
# it under the terms of the GNU General Public License as published by
|
|
15
|
+
# the Free Software Foundation, either version 3 of the License, or
|
|
16
|
+
# (at your option) any later version.
|
|
17
|
+
|
|
18
|
+
# This program is distributed in the hope that it will be useful,
|
|
19
|
+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
20
|
+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
21
|
+
# GNU General Public License for more details.
|
|
22
|
+
|
|
23
|
+
# You should have received a copy of the GNU General Public License
|
|
24
|
+
# along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
25
|
+
|
|
26
|
+
# Written by Roland McGrath.
|
|
27
|
+
# Rewritten in Perl by Akim Demaille.
|
|
28
|
+
|
|
29
|
+
use 5.006;
|
|
30
|
+
use strict;
|
|
31
|
+
use warnings FATAL => 'all';
|
|
32
|
+
|
|
33
|
+
BEGIN
|
|
34
|
+
{
|
|
35
|
+
my $pkgdatadir = $ENV{'autom4te_perllibdir'} || do { require File::Basename; require File::Spec; File::Spec->catdir(File::Basename::dirname(File::Basename::dirname(File::Spec->rel2abs($0))), 'share', 'autoconf') };
|
|
36
|
+
unshift @INC, "$pkgdatadir";
|
|
37
|
+
|
|
38
|
+
# Override SHELL. On DJGPP SHELL may not be set to a shell
|
|
39
|
+
# that can handle redirection and quote arguments correctly,
|
|
40
|
+
# e.g.: COMMAND.COM. For DJGPP always use the shell that configure
|
|
41
|
+
# has detected.
|
|
42
|
+
$ENV{'SHELL'} = '/bin/sh' if ($^O eq 'dos');
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
use Autom4te::ChannelDefs;
|
|
46
|
+
use Autom4te::Channels;
|
|
47
|
+
use Autom4te::Configure_ac;
|
|
48
|
+
use Autom4te::FileUtils;
|
|
49
|
+
use Autom4te::General;
|
|
50
|
+
use Autom4te::XFile;
|
|
51
|
+
|
|
52
|
+
# These vars must be package globals so they can be accessed by code
|
|
53
|
+
# evaluated via 'do FILE', below.
|
|
54
|
+
our ($config_h, %symbol, %verbatim);
|
|
55
|
+
|
|
56
|
+
# Lib files.
|
|
57
|
+
my $autom4te = $ENV{'AUTOM4TE'} || do { require File::Basename; File::Basename::dirname($0).'/autom4te' };
|
|
58
|
+
my $config_h_in;
|
|
59
|
+
my @prepend_include;
|
|
60
|
+
my @include;
|
|
61
|
+
my @warnings;
|
|
62
|
+
|
|
63
|
+
# $HELP
|
|
64
|
+
# -----
|
|
65
|
+
$help = "Usage: $0 [OPTION]... [TEMPLATE-FILE]
|
|
66
|
+
|
|
67
|
+
Create a template file of C '\#define' statements for 'configure' to
|
|
68
|
+
use. To this end, scan TEMPLATE-FILE, or 'configure.ac' if present,
|
|
69
|
+
or else 'configure.in'.
|
|
70
|
+
|
|
71
|
+
-h, --help print this help, then exit
|
|
72
|
+
-V, --version print version number, then exit
|
|
73
|
+
-v, --verbose verbosely report processing
|
|
74
|
+
-d, --debug don\'t remove temporary files
|
|
75
|
+
-f, --force consider all files obsolete
|
|
76
|
+
-W, --warnings=CATEGORY report the warnings falling in CATEGORY
|
|
77
|
+
(comma-separated list accepted)
|
|
78
|
+
|
|
79
|
+
" . Autom4te::ChannelDefs::usage . "
|
|
80
|
+
|
|
81
|
+
Library directories:
|
|
82
|
+
-B, --prepend-include=DIR prepend directory DIR to search path
|
|
83
|
+
-I, --include=DIR append directory DIR to search path
|
|
84
|
+
|
|
85
|
+
Report bugs to <bug-autoconf\@gnu.org>.
|
|
86
|
+
|
|
87
|
+
The full documentation for Autoconf can be read via 'info autoconf',
|
|
88
|
+
or on the Web at <https://www.gnu.org/software/autoconf/manual/>.
|
|
89
|
+
";
|
|
90
|
+
|
|
91
|
+
|
|
92
|
+
# $VERSION
|
|
93
|
+
# --------
|
|
94
|
+
$version = "autoheader (GNU Autoconf) 2.72
|
|
95
|
+
Copyright (C) 2023 Free Software Foundation, Inc.
|
|
96
|
+
License GPLv3+/Autoconf: GNU GPL version 3 or later
|
|
97
|
+
<https://gnu.org/licenses/gpl.html>, <https://gnu.org/licenses/exceptions.html>
|
|
98
|
+
This is free software: you are free to change and redistribute it.
|
|
99
|
+
There is NO WARRANTY, to the extent permitted by law.
|
|
100
|
+
|
|
101
|
+
Written by Roland McGrath and Akim Demaille.
|
|
102
|
+
";
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
## ---------- ##
|
|
106
|
+
## Routines. ##
|
|
107
|
+
## ---------- ##
|
|
108
|
+
|
|
109
|
+
|
|
110
|
+
# parse_args ()
|
|
111
|
+
# -------------
|
|
112
|
+
# Process any command line arguments.
|
|
113
|
+
sub parse_args ()
|
|
114
|
+
{
|
|
115
|
+
my $srcdir;
|
|
116
|
+
|
|
117
|
+
getopt ('I|include=s' => \@include,
|
|
118
|
+
'B|prepend-include=s' => \@prepend_include,
|
|
119
|
+
'W|warnings=s' => \@warnings);
|
|
120
|
+
|
|
121
|
+
parse_WARNINGS;
|
|
122
|
+
parse_warnings @warnings;
|
|
123
|
+
|
|
124
|
+
if (! @ARGV)
|
|
125
|
+
{
|
|
126
|
+
my $configure_ac = require_configure_ac;
|
|
127
|
+
push @ARGV, $configure_ac;
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
|
|
132
|
+
## -------------- ##
|
|
133
|
+
## Main program. ##
|
|
134
|
+
## -------------- ##
|
|
135
|
+
|
|
136
|
+
mktmpdir ('ah');
|
|
137
|
+
parse_args;
|
|
138
|
+
|
|
139
|
+
# Preach.
|
|
140
|
+
my $config_h_top = find_file ("config.h.top?",
|
|
141
|
+
reverse (@prepend_include), @include);
|
|
142
|
+
my $config_h_bot = find_file ("config.h.bot?",
|
|
143
|
+
reverse (@prepend_include), @include);
|
|
144
|
+
my $acconfig_h = find_file ("acconfig.h?",
|
|
145
|
+
reverse (@prepend_include), @include);
|
|
146
|
+
if ($config_h_top || $config_h_bot || $acconfig_h)
|
|
147
|
+
{
|
|
148
|
+
my $msg = << "END";
|
|
149
|
+
Using auxiliary files such as 'acconfig.h', 'config.h.bot'
|
|
150
|
+
and 'config.h.top', to define templates for 'config.h.in'
|
|
151
|
+
is deprecated and discouraged.
|
|
152
|
+
|
|
153
|
+
Using the third argument of 'AC_DEFINE_UNQUOTED' and
|
|
154
|
+
'AC_DEFINE' allows one to define a template without
|
|
155
|
+
'acconfig.h':
|
|
156
|
+
|
|
157
|
+
AC_DEFINE([NEED_FUNC_MAIN], 1,
|
|
158
|
+
[Define if a function 'main' is needed.])
|
|
159
|
+
|
|
160
|
+
More sophisticated templates can also be produced, see the
|
|
161
|
+
documentation.
|
|
162
|
+
END
|
|
163
|
+
$msg =~ s/^ /WARNING: /gm;
|
|
164
|
+
msg 'obsolete', $msg;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
# Set up autoconf.
|
|
168
|
+
my $autoconf = "'$autom4te' --language=autoconf ";
|
|
169
|
+
$autoconf .= join (' --include=', '', map { shell_quote ($_) } @include);
|
|
170
|
+
$autoconf .= join (' --prepend-include=', '', map { shell_quote ($_) } @prepend_include);
|
|
171
|
+
$autoconf .= ' --debug' if $debug;
|
|
172
|
+
$autoconf .= ' --force' if $force;
|
|
173
|
+
$autoconf .= ' --verbose' if $verbose;
|
|
174
|
+
|
|
175
|
+
# ----------------------- #
|
|
176
|
+
# Real work starts here. #
|
|
177
|
+
# ----------------------- #
|
|
178
|
+
|
|
179
|
+
# Source what the traces are trying to tell us.
|
|
180
|
+
verb "$me: running $autoconf to trace from $ARGV[0]";
|
|
181
|
+
my $quoted_tmp = shell_quote ($tmp);
|
|
182
|
+
{
|
|
183
|
+
# Suppress all warnings from the subsidiary autoconf invocation.
|
|
184
|
+
local $ENV{WARNINGS} = 'none';
|
|
185
|
+
xsystem ("$autoconf"
|
|
186
|
+
# If you change this list, update the
|
|
187
|
+
# 'Autoheader-preselections' section of autom4te.in.
|
|
188
|
+
. ' --trace AC_CONFIG_HEADERS:\'$$config_h ||= \'"\'"\'$1\'"\'"\';\''
|
|
189
|
+
. ' --trace AH_OUTPUT:\'$$verbatim{\'"\'"\'$1\'"\'"\'} = \'"\'"\'$2\'"\'"\';\''
|
|
190
|
+
. ' --trace AC_DEFINE_TRACE_LITERAL:\'$$symbol{\'"\'"\'$1\'"\'"\'} = 1;\''
|
|
191
|
+
. " " . shell_quote ($ARGV[0]) . " >$quoted_tmp/traces.pl");
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
local (%verbatim, %symbol);
|
|
195
|
+
debug "$me: 'do'ing $tmp/traces.pl:\n" . `sed 's/^/| /' $quoted_tmp/traces.pl`;
|
|
196
|
+
do "$tmp/traces.pl";
|
|
197
|
+
warn "couldn't parse $tmp/traces.pl: $@" if $@;
|
|
198
|
+
unless ($config_h)
|
|
199
|
+
{
|
|
200
|
+
error "error: AC_CONFIG_HEADERS not found in $ARGV[0]";
|
|
201
|
+
exit 1;
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
# Support "outfile[:infile]", defaulting infile="outfile.in".
|
|
205
|
+
sub templates_for_header
|
|
206
|
+
{
|
|
207
|
+
my ($spec) = @_;
|
|
208
|
+
my ($header, @templates) = split(':', $spec);
|
|
209
|
+
|
|
210
|
+
return @templates if @templates;
|
|
211
|
+
return $header . '.in';
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
my @config_templates = map(templates_for_header($_), split(' ', $config_h));
|
|
215
|
+
|
|
216
|
+
# We template only the first CONFIG_HEADER.
|
|
217
|
+
$config_h_in = shift(@config_templates);
|
|
218
|
+
$config_h =~ s/[ :].*//;
|
|
219
|
+
|
|
220
|
+
# %SYMBOL might contain things like 'F77_FUNC(name,NAME)', but we keep
|
|
221
|
+
# only the name of the macro.
|
|
222
|
+
%symbol = map { s/\(.*//; $_ => 1 } keys %symbol;
|
|
223
|
+
|
|
224
|
+
my $out = new Autom4te::XFile ("$tmp/config.hin", ">");
|
|
225
|
+
|
|
226
|
+
# Don't write "do not edit" -- it will get copied into the
|
|
227
|
+
# config.h, which it's ok to edit.
|
|
228
|
+
print $out "/* $config_h_in. Generated from $ARGV[0] by autoheader. */\n";
|
|
229
|
+
|
|
230
|
+
# Dump the top.
|
|
231
|
+
if ($config_h_top)
|
|
232
|
+
{
|
|
233
|
+
my $in = new Autom4te::XFile ($config_h_top, "<");
|
|
234
|
+
while ($_ = $in->getline)
|
|
235
|
+
{
|
|
236
|
+
print $out $_;
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
# Dump 'acconfig.h', except for its bottom portion.
|
|
241
|
+
if ($acconfig_h)
|
|
242
|
+
{
|
|
243
|
+
my $in = new Autom4te::XFile ($acconfig_h, "<");
|
|
244
|
+
while ($_ = $in->getline)
|
|
245
|
+
{
|
|
246
|
+
last if /\@BOTTOM\@/;
|
|
247
|
+
next if /\@TOP\@/;
|
|
248
|
+
print $out $_;
|
|
249
|
+
}
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
# Dump the templates from 'configure.ac'.
|
|
253
|
+
foreach (sort keys %verbatim)
|
|
254
|
+
{
|
|
255
|
+
print $out "\n$verbatim{$_}\n";
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
# Dump bottom portion of 'acconfig.h'.
|
|
259
|
+
if ($acconfig_h)
|
|
260
|
+
{
|
|
261
|
+
my $in = new Autom4te::XFile ($acconfig_h, "<");
|
|
262
|
+
my $dump = 0;
|
|
263
|
+
while ($_ = $in->getline)
|
|
264
|
+
{
|
|
265
|
+
print $out $_ if $dump;
|
|
266
|
+
$dump = 1 if /\@BOTTOM\@/;
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
# Dump the bottom.
|
|
271
|
+
if ($config_h_bot)
|
|
272
|
+
{
|
|
273
|
+
my $in = new Autom4te::XFile ($config_h_bot, "<");
|
|
274
|
+
while ($_ = $in->getline)
|
|
275
|
+
{
|
|
276
|
+
print $out $_;
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
$out->close;
|
|
281
|
+
|
|
282
|
+
# Check that all the symbols have a template.
|
|
283
|
+
{
|
|
284
|
+
foreach my $template ("$tmp/config.hin", @config_templates)
|
|
285
|
+
{
|
|
286
|
+
if (! -r $template)
|
|
287
|
+
{
|
|
288
|
+
msg 'syntax', "cannot read $template: $!";
|
|
289
|
+
}
|
|
290
|
+
else
|
|
291
|
+
{
|
|
292
|
+
my $in = new Autom4te::XFile ($template, "<");
|
|
293
|
+
|
|
294
|
+
while ($_ = $in->getline)
|
|
295
|
+
{
|
|
296
|
+
my ($sym) = /^\#\s*\w+\s+(\w+)/
|
|
297
|
+
or next;
|
|
298
|
+
delete $symbol{$sym};
|
|
299
|
+
}
|
|
300
|
+
}
|
|
301
|
+
}
|
|
302
|
+
|
|
303
|
+
my $suggest_ac_define = 1;
|
|
304
|
+
|
|
305
|
+
foreach (sort keys %symbol)
|
|
306
|
+
{
|
|
307
|
+
msg 'syntax', "missing template: $_";
|
|
308
|
+
if ($suggest_ac_define)
|
|
309
|
+
{
|
|
310
|
+
msg 'syntax', "Use AC_DEFINE([$_], [], [Description])";
|
|
311
|
+
$suggest_ac_define = 0;
|
|
312
|
+
}
|
|
313
|
+
}
|
|
314
|
+
exit 1
|
|
315
|
+
if keys %symbol;
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
update_file ("$tmp/config.hin", "$config_h_in", $force);
|
|
319
|
+
|
|
320
|
+
### Setup "GNU" style for perl-mode and cperl-mode.
|
|
321
|
+
## Local Variables:
|
|
322
|
+
## perl-indent-level: 2
|
|
323
|
+
## perl-continued-statement-offset: 2
|
|
324
|
+
## perl-continued-brace-offset: 0
|
|
325
|
+
## perl-brace-offset: 0
|
|
326
|
+
## perl-brace-imaginary-offset: 0
|
|
327
|
+
## perl-label-offset: -2
|
|
328
|
+
## cperl-indent-level: 2
|
|
329
|
+
## cperl-brace-offset: 0
|
|
330
|
+
## cperl-continued-brace-offset: 0
|
|
331
|
+
## cperl-label-offset: -2
|
|
332
|
+
## cperl-extra-newline-before-brace: t
|
|
333
|
+
## cperl-merge-trailing-else: nil
|
|
334
|
+
## cperl-continued-statement-offset: 2
|
|
335
|
+
## End:
|