Compare commits

..

1739 Commits
Beta2 ... 3.80

Author SHA1 Message Date
Paul Smith
d1d9c0274b Update version info. 2002-10-04 03:17:56 +00:00
Paul Smith
ee9584dc8d Don't put .cvsignore files in the distributed tar file. 2002-10-04 02:28:59 +00:00
Paul Smith
9dc79463a9 Fix K&R-isms found on SunOS 4.1.4 builds. 2002-10-04 02:12:52 +00:00
Paul Smith
1d3dfeb74b Some updates for automake 1.7 and prep for releasing 3.80. 2002-10-03 05:46:12 +00:00
Paul Smith
2de1b62112 Add VMS updates from Martin Zinser. 2002-10-01 15:32:14 +00:00
Paul Smith
ae003efd61 Fix a bug handling target/prerequisite names containing comment
characters.
2002-09-23 22:16:40 +00:00
Paul Smith
ebd05dbeb3 Fix a bug exporting/unexporting multiple variables in one command.
Update the text about reporting bugs.
2002-09-18 20:51:58 +00:00
Paul Smith
76652d5d02 Add some indexing to the manual.
Fix a few simple casting warnings, etc.
2002-09-18 04:35:52 +00:00
Paul Smith
dac7b49de4 Fix bug #940 (from the Savannah bug tracker): make sure that target-
specific variables work correctly in conjunction with double-colon
targets.
2002-09-17 21:52:45 +00:00
Paul Smith
d7ebcadadb Fixups for the release. One bug fix, some automake complaint fixes,
and a function return type fix for older systems.
2002-09-12 22:15:58 +00:00
Paul Smith
4a11acf047 Fix HAVE_BROKEN_RESTART logic.
Fix hash.h typos (only noticed when using Windows).
Update .cvsignore files.
2002-09-11 16:55:44 +00:00
Paul Smith
5df75e7265 Fix regex matching for modification time warnings.
The ones we had were weird, and failed for multiple warnings in a
single file.
2002-09-10 22:39:18 +00:00
Paul Smith
bc91c0b23f A few test bug fixes:
* Never use "touch" in make rules; it breaks on most sub-second
    supporting systems.  Use echo "" > $@ instead.
  * Forgot to close test makefiles before using them!

All the above worked fine on Linux but failed miserably on Solaris.
2002-09-10 22:23:20 +00:00
Paul Smith
5297a83b27 Have the test driver check for the new format of the time skew error
messages.
2002-09-10 20:59:03 +00:00
Paul Smith
7ea029a07c Add support for broken SA_RESTART on PTX.
Fix bug #103: allow ifdef, export, and unexport to expand their arguments.
2002-09-10 07:27:28 +00:00
Paul Smith
9b41488ad1 Whoops; configure wasn't looking for memmove. 2002-09-09 21:20:41 +00:00
Paul Smith
988deb489b Fix for complex situations where directories are declared as prerequisites.
Info on this fix from barkalow@reputation.com: thanks!

Some updates/cleanups of some of the tests; added a forgotten -t test, etc.
2002-09-04 07:26:19 +00:00
Paul Smith
d2429d7508 Update some NEWS and README nits, and add new gettext macros to config's
Makefile.am.
2002-09-03 21:43:04 +00:00
Paul Smith
299c72e6ed Update to a new version of automake and gettext.
Invent a new macro HAVE_DOS_PATHS and change various instances of:
  #if defined(WINDOWS) || defined(__MSDOS__)
to use the new macro instead.  This should help make the OS/2 port
cleaner, as well.
Invent a cvs-clean maintainer target that tries to get the workspace
back to the state it was in after a CVS checkout.
New language.
2002-08-10 01:27:16 +00:00
Paul Smith
ee3a4f9dd6 Change the version.
Update to require new gettext.
Change hash.c to by K&R.
Redo some strings to make i18n simpler.
2002-08-08 05:39:17 +00:00
Paul Smith
f2ceb0d68a Incorporate some VMS fixes.
Add -B option docs.
Add .VARIABLES variable.
Add a few new tests.
Add a new translation: Swedish
2002-08-08 00:11:19 +00:00
Paul Smith
bccb277dda New variables, .VARIABLES and .TARGETS. 2002-08-01 13:16:57 +00:00
Paul Smith
a56563badd Make sure templates are built. 2002-07-14 02:57:04 +00:00
Paul Smith
21cf8c6444 Install Greg McGary's patches to port the id-utils hashing functions to
GNU make.  Also he provides some other performance fixups after doing
some profiling of make on large makefiles.

Modify the test suite to allow the use of Valgrind to find memory problems.
2002-07-11 06:38:57 +00:00
Paul Smith
4d72c4c11e Implement SysV-style $$@ support. I looked at E.Parmelan's patch but
decided to implement this a different way, and didn't use it.
2002-07-10 12:59:07 +00:00
Paul Smith
6c9a393f95 Documentation and tests for order-only prerequisites.
Add a new test suite for automatic variables.
2002-07-09 06:35:56 +00:00
Paul Smith
724925be2b Various cleanups reported by people using the alpha release.
Incorporate "order-only" prerequisites patch.  Wrote a test for it.
The test shows what might be a bug in the code; I need to look at it
more closely (anyway it doesn't behave as I expected).  Also I haven't
done the docs yet.
2002-07-08 13:05:02 +00:00
Paul Smith
2f20fc1cc7 Remove .po files; we'll retrieve them directly from the translation site. 2002-07-08 03:25:34 +00:00
Paul Smith
8572d6adf0 Major updates in preparation for 3.80.
New version of the manual, put into the doc subdir.
Enhancements: $(eval ...) and $(value ...) functions, various bug
fixes, etc.  See the ChangeLog.
More to come.
2002-07-08 02:26:47 +00:00
Paul Smith
4a07398023 Update the README template. 2002-05-29 22:24:09 +00:00
Paul Smith
99e01f61fd Install newest German translation. 2002-05-13 14:40:16 +00:00
Paul Smith
9052b52dfc Fix Debian bug #144306: pass target-specific variables into the environment
properly.

Fix configure: allow cross-compilation; fix getloadavg (still needs _lots_
of work!)

Let $(call ...) functions to be self-referencing.  Lets us do transitive
closures, for example.
2002-05-10 03:15:07 +00:00
Paul Smith
5dedf7be63 Remove our local copy so we can use the standard version. 2002-04-24 21:52:21 +00:00
Paul Smith
2276c37ae7 Add back initial "\" which was accidentally removed a year ago! :-/. 2002-04-24 21:36:38 +00:00
Paul Smith
306462f0bd Updates for new tools. Everything works now building on Linux,
including creating make packages.  I'll try some other systems tomorrow.
Also added a new translation: Croatian.  Thanks!
2002-04-22 04:35:19 +00:00
Paul Smith
3a8a7a5d00 Updates and fixes for CVS builds.
Created a README.cvs describing the procedure.
2002-04-22 02:11:31 +00:00
Paul Smith
7ed1a08985 Update GNU make to use Autoconf 2.53, Automake 1.6.1, Gettext 0.11.1.
We're using Gettext's "external" feature to avoid including the intl
code in the GNU make distribution.
2002-04-21 23:57:24 +00:00
Paul Smith
cae1db6ecd Installed a new translation for Hebrew. 2002-04-20 19:35:15 +00:00
Paul Smith
dad29566b3 Updates to translaations.
Fix an assert() in an obscure use of -q
Handling of double-colon timestamp updates was broken in a bizarre way.
Store arguments to $(call ...) functions in simple variables, not recursive
variables.
2002-04-20 19:25:54 +00:00
Paul Smith
d242ee9053 Install updated translations. 2002-03-12 01:36:17 +00:00
Paul Smith
1d9d40a209 Install a new Japanese translation. 2001-12-04 18:47:02 +00:00
Paul Smith
c0312423d9 Update copyright info. 2001-11-18 18:38:02 +00:00
Paul Smith
9302338304 Installed the da.po (Danish) translation file.
Fixed some translation string issues.
2001-08-19 04:55:51 +00:00
Paul Smith
74f08c639d Installed a new French translation (resolves Debian Bug #106720) 2001-08-03 19:02:51 +00:00
Paul Smith
635a784ebf New/updated translations; minor update to the index of the manual. 2001-07-05 00:35:03 +00:00
Paul Smith
4c28600a50 New translation. 2001-06-01 03:57:19 +00:00
Paul Smith
ce2c6eadf1 Fix for EINTR problems when using jobserver.
New translation files.
Fix for @+ inside define macros being applied too widely.
Various other bug fixes.
2001-06-01 03:56:50 +00:00
Paul Smith
5d582d4ba0 Some VMS fixes sent by John Fowler.
Fix: make flags on some lines of define/endef don't affect other lines
2001-05-21 06:16:00 +00:00
Paul Smith
8f2b1e2c7c Some bug fixes and document updates. 2001-01-21 06:49:11 +00:00
Paul Smith
e5324a8c6a * Fix FAT handling on Windows to match the DJGPP port's FAT handling.
* Fix a potential hole in readline if lines end in ^M (CRLF).
2000-11-17 06:59:08 +00:00
Paul Smith
d5a04ee984 * Various bug fixes.
* New Galician translation.
2000-10-05 16:27:06 +00:00
Paul Smith
50ba270762 * Rework phrasing to allow for better translations.
# New Japanese translation file.
2000-09-21 04:14:38 +00:00
Paul Smith
8ddf04c627 Fix PR/1831. See the ChangeLog. 2000-08-21 06:18:35 +00:00
Paul Smith
1a82956eae * Various fixes; see the ChangeLog. 2000-07-30 18:26:42 +00:00
Paul Smith
3c132f10f3 * Minor code cleanups
* Fix for PR/1811, from Paul Eggert.
2000-07-07 17:34:56 +00:00
Paul Smith
88187d9f4b * Fix PR/1791. 2000-06-23 19:43:11 +00:00
Paul Smith
775b644765 * Released 3.79.1 2000-06-23 18:55:43 +00:00
Paul Smith
fcbfe98cbe * Fix -q so it works more correctly.
* Don't print "nothing to do" messages for ":" commands
* Update the version to 3.79.1
2000-06-23 15:55:46 +00:00
Paul Smith
cbe92a2241 * Fix PR/1709. 2000-06-22 00:45:34 +00:00
Paul Smith
d5f7eb2897 * A couple of nits. 2000-06-20 21:32:40 +00:00
Paul Smith
3e6f48b444 * More updates and fixes. 2000-06-20 05:48:40 +00:00
Paul Smith
0d70d05458 * Various fixes for problems in the 3.79.0.1 pretest. 2000-06-19 21:22:44 +00:00
Paul Smith
f04e78f11b * Typo. 2000-06-14 22:29:48 +00:00
Paul Smith
c392c19335 * More fixes for configuring gettext correctly. 2000-06-14 22:29:30 +00:00
Paul Smith
4972b017b6 * Some timestamp fixes from Paul Eggert.
* Fix compilation on Linux; use libintl.h and not gettext.h when using
  the system gettext.
2000-06-13 05:22:52 +00:00
Paul Smith
4a5550c822 * Lots of bug fixes and cleanup; new i18n files, etc. 2000-06-07 05:43:37 +00:00
Paul Smith
e5c40f6e5a New translation files. 2000-06-01 14:37:58 +00:00
Paul Smith
5ed9fb46b2 * Various bug fixes. 2000-04-22 02:11:17 +00:00
Paul Smith
f9c91ec34d * Some final cleanups, and release 3.79. 2000-04-05 16:02:55 +00:00
Paul Smith
f3a974bf32 * Fix bug handling archive members: convert timestamp to nsec properly
on those systems that support it.
2000-04-03 05:58:41 +00:00
Paul Smith
c67266ceac * New config.sub and config.guess
* Update version number for release
* Fixes to the build.sh to handle i18n/gettext
* Make dash-n more robust.
2000-03-29 03:23:18 +00:00
Paul Smith
4145bcbcda * Handle case of empty static pattern rule prerequisites.
* Fix linenumbers in error messages for rule definitions.
2000-03-27 20:53:50 +00:00
Paul Smith
c637af71d9 * A large number of fixes/enhancements. See the ChangeLog.
* Added a new version of the German translation file.
2000-03-27 06:54:37 +00:00
Paul Smith
a81013175c * Ignore attempt to change a file into itself.
* Define COFLAGS to avoid unknown variable warning.
* Fix some usec problems on UnixWare.
* Don't remove .INTERMEDIATE targets specified on the command line.
2000-03-26 06:56:54 +00:00
Paul Smith
75f879f37f * Fix backslash-escape in targets.
* Release 3.78.91.
2000-02-09 19:57:15 +00:00
Paul Smith
e68a27ec7b * Fix some warnings in gettext.c and function.c
* Don't try to execute tests which are actually directories.
2000-02-09 07:02:18 +00:00
Paul Smith
17f2dda0ac * Fix for dir.c from Andreas Schwab.
* Fix += target-specific variables: if your direct parent doesn't have a
  setting for the variable but his parent does, you'll get recursive
  expansion errors.
2000-02-07 19:54:04 +00:00
Paul Smith
90f23f1ea6 * Updates for VMS, Windows, and DOS ports.
* Clean up some warnings.
2000-02-05 07:50:47 +00:00
Paul Smith
9b0a3d91ea * Fix PR/1407.
* Keep filename/lineno information for variables, for debugging.
2000-02-05 07:37:40 +00:00
Paul Smith
95a09e94f7 * Some pre-pretest release cleanup. 2000-01-27 00:00:27 +00:00
Paul Smith
de2a8fc730 * Updated gettext to use more advanced libit 0.7 version.
* Various cleanups.
2000-01-25 07:42:51 +00:00
Paul Smith
447c76f601 * A few fixes. 2000-01-23 07:05:16 +00:00
Paul Smith
24aec1878b * Mention it in NEWS. 2000-01-22 08:59:09 +00:00
Paul Smith
2fd5b943d1 * Implement GNU gettext internationalization support in GNU make. 2000-01-22 08:57:17 +00:00
Paul Smith
74fca88bf3 * More fixes to VMS by Hartmut Becker. 2000-01-22 05:59:28 +00:00
Paul Smith
5577cdc261 * Merge VMS patches by Hartmut Becker. 2000-01-22 05:43:03 +00:00
Paul Smith
b7b83d6398 * Change $(call...) to not expand arguments by default.
* Unify the way arguments are passed to builtin functions in function.c.
2000-01-11 07:31:42 +00:00
Paul Smith
af44f16799 * Fix problems with double-colon rules.
* Fix problems with INTERMEDIATE rules.
1999-12-18 17:43:47 +00:00
Paul Smith
1a35bfb45b * Various changes and fixes. See ChangeLog. 1999-12-08 20:13:50 +00:00
Paul Smith
4d5c556f00 * Update debugging to use string flags instead of integers. 1999-11-27 08:09:42 +00:00
Paul Smith
ce3413f883 * Add new debug header file. 1999-11-22 06:16:48 +00:00
Paul Smith
217ca5d910 * Add new debugging output level selection feature. 1999-11-22 06:15:35 +00:00
Paul Smith
ebb733c0f9 * Many cleanups and bugfixes.
* New handling of += in target-specific variables.
1999-11-17 07:33:47 +00:00
Paul Smith
3e26bde6db * Fix PR/1394.
* Apply changes from Paul Eggert.
* Many other cleanups (index/rindex --> strchr/strrchr, etc.)
1999-10-15 07:00:58 +00:00
Paul Smith
c71200d022 * Ensure -Iglob comes before any user-specified CPPFLAGS. 1999-10-14 23:20:12 +00:00
Paul Smith
281951154b * Fix PR/1379: -n/-q behaves correctly when all commands are recursive. 1999-10-13 07:00:23 +00:00
Paul Smith
829f4fd04b * Fix test suite on DOS (PR/1344)
* Fix target-specific vars bug (PR/1378)
1999-10-08 06:32:24 +00:00
Paul Smith
f26e413b12 * Fix for DOS short filenames. 1999-09-29 06:29:38 +00:00
Paul Smith
dbb8f3e30b * Ouch: found a bug where re-exec from changed makefiles turned off
jobserver :(.
1999-09-23 18:23:33 +00:00
Paul Smith
c828aeaa98 * Oops. Fix a problem running submakes like $(MAKE) $(MFLAGS). 1999-09-22 05:57:52 +00:00
Paul Smith
3c83c469e4 * Fix escaping from perl to the shell. 1999-09-17 04:20:45 +00:00
Paul Smith
a63f51340b * A few script fixes and updates for 3.78. 1999-09-17 03:15:37 +00:00
Paul Smith
45e04a5860 * Some minor pre-release updates. 1999-09-16 05:58:44 +00:00
Paul Smith
6ec7d1881c * Fix some tests. 1999-09-16 03:43:10 +00:00
Paul Smith
c800367385 * Cleanup the test suite. 1999-09-15 22:23:35 +00:00
Paul Smith
0d366b6682 * Added the test suite to the main distribution. 1999-09-14 02:03:19 +00:00
Paul Smith
4121dea6a5 * Some configuration fixes. 1999-09-14 00:17:58 +00:00
Paul Smith
b88c1d3a3d * Various cleanups for release. 1999-09-11 05:44:53 +00:00
Paul Smith
373dbb43da * Various pre-release cleanups. 1999-09-11 05:10:27 +00:00
Paul Smith
5e9a3e34ac * Some doc and help changes. 1999-09-06 05:21:52 +00:00
Paul Smith
860a30ae1e * Fix for infinite recursion. 1999-09-04 22:05:18 +00:00
Paul Smith
e49b2f15c9 * Removed a memory stomp (reading freed memory).
* Fixed some infinite recursion on rebuilt makefiles bugs.
1999-09-03 22:46:28 +00:00
Paul Smith
10fee1c03c * A few W32 fixes for backslash support. 1999-09-02 00:31:21 +00:00
Paul Smith
82f0c5495a * A bugfix on MAKEFLAGS options creation that broke jobserver.
* Put the host info in the --version output.
* Don't croak if the user forces -jN on submakes.
1999-09-01 08:04:30 +00:00
Paul Smith
bf7cc546dd * Added config.guess/config.sub for new autoconf tests. 1999-09-01 03:58:04 +00:00
Paul Smith
27255c5b51 * Large file support for AIX, HP-UX, and IRIX.
* W32 support for Cygnus Cygwin shell (bash).
1999-08-31 17:02:31 +00:00
Paul Smith
b134da5505 * A few cleanups, and 3.77.94 release. 1999-08-25 21:39:28 +00:00
Paul Smith
d0b03e9355 * Terminology change in docs and code. 1999-08-24 04:49:39 +00:00
Paul Smith
5dc4b92b60 * Fix jobserver algorithm again.
* A couple of nits.
* Fix considered pruning for double-colon rules.
1999-08-23 22:15:17 +00:00
Paul Smith
b3fa4b3c7e * Start rewrite of jobserver to avoid unique tokens for debugging. 1999-08-23 05:35:14 +00:00
Paul Smith
6fa76a7d15 * Various changes. 1999-08-22 17:50:57 +00:00
Paul Smith
4ff6c62456 * Code cleanup. 1999-08-19 04:43:46 +00:00
Paul Smith
cbb9e38d10 * Rework jobserver yet one more time.
* Install the $(if ...) function and document it.  Still need some examples.
1999-08-13 07:36:26 +00:00
Paul Smith
9e79637ec3 * Some DOS fixes. 1999-08-12 23:16:42 +00:00
Paul Smith
e34540f79b * Release 3.77.92.
* Complete implementation of new jobserver algorithm.
* A few minor fixups.
1999-08-01 08:12:06 +00:00
Paul Smith
09f1e4cf83 * Applied some DOS updates.
* Started reworking the jobserver algorithm; not complete yet.
1999-08-01 06:05:17 +00:00
Paul Smith
28ef4c4dac * Add gettext macros to start i18n support. 1999-07-28 06:23:37 +00:00
Paul Smith
3a945a665e * Update the manual. 1999-07-26 05:06:58 +00:00
Paul Smith
6dbd348522 * Forgot ChangeLog. 1999-07-24 04:56:06 +00:00
Paul Smith
a9166bb7bc * Some configure fixes. 1999-07-24 04:55:08 +00:00
Paul Smith
4e7ee4fc01 * Bugfix for NT archive support.
* Rework how the jobserver stuff works.
1999-07-23 22:46:47 +00:00
Paul Smith
b05cb1d99e * Make some portability fixes. 1999-07-22 06:29:02 +00:00
Paul Smith
c8a60e7431 * Update the AUTHORS file. 1999-07-22 04:41:51 +00:00
Paul Smith
6d2984e0b2 * Fix backward incompatibility in new function implementation.
* Add support for ARFZMAG archive formats.
1999-07-22 04:31:11 +00:00
Paul Smith
ec50fe2a2b * Installed new versions of GLIBC glob library.
* Installed Tim Magill's "graph pruning" performance enhancement.
* Update version to 3.77.90 for the release.
* Require automake 1.4.
1999-07-22 04:20:14 +00:00
Paul Smith
c69d4c95bf * Installed VMS fixes. 1999-07-21 16:06:18 +00:00
Paul Smith
588da9812e * Add configure option to enable dmalloc library.
* Various code cleanups.
1999-07-21 05:53:23 +00:00
Paul Smith
73846549f6 * Fix memory leaks, fd leaks, and some long-standing bugs recognizing when
targets need to have their modtimes rechecked (-n, etc.)
1999-07-20 22:34:41 +00:00
Karl Berry
169e6b8c3d pdfimage takes braces 1999-07-18 18:19:53 +00:00
Paul Smith
826ab14b26 * Fix some memory and file descriptor leaks. 1999-07-16 22:28:46 +00:00
Paul Smith
a3cf773e29 * Various bug fixes. 1999-07-16 02:25:03 +00:00
Paul Smith
9d89ad56bf * Fix up and document $(apply ...) function. 1999-07-15 07:36:44 +00:00
Paul Eggert
adb1632033 Sync to ftp.gnu.org version of 1999-07-06. 1999-07-13 04:50:09 +00:00
Paul Smith
8df9d54020 * Fixed error rebuilding makefiles with -j>1
* Fixed problem with job pipe and -j>1 when waiting on -l loads.
1999-07-09 22:55:44 +00:00
Paul Smith
9035aa27b7 * Minor code cleanup. 1999-07-08 22:32:38 +00:00
Paul Smith
e1d72ad3f1 * Added -R / --no-builtin-variables flag. 1999-07-08 06:49:52 +00:00
Paul Smith
012254e81e * Various bugfixes/updates. See ChangeLog. 1999-07-06 21:09:32 +00:00
Paul Smith
2858f7a8f1 * Various bug fixes. 1999-06-14 06:50:28 +00:00
Paul Smith
187787286d * Various bug fixes. 1999-06-14 05:26:28 +00:00
Paul Smith
fc0fe4103a * Add new jobserver feature.
* Small updates to the manual
* E.Zaretskii fix for new DJGPP version.
1999-04-25 04:30:55 +00:00
Paul Smith
7f3ffd4019 Clean up some logic. 1999-04-13 02:28:27 +00:00
Paul Smith
a2ea1bd27f If a file declared .INTERMEDIATE already exists before make starts, we
won't delete it--this is how normal intermediate files behave, too.
1999-04-09 05:57:35 +00:00
Paul Smith
3d1cdf4106 * Fix possible memory stomp.
* A few admin file cleanups.
1999-04-02 06:19:33 +00:00
Paul Smith
7052a57152 * Ignore CR in CRLF line terminators for compatibility with DOSsy
makefiles.
1999-03-31 23:25:13 +00:00
Karl Berry
47922a5a65 * texinfo.tex (\defopheader): missing word space before `on'.
Report from: Chris Hanson <cph@martigny.ai.mit.edu>.
1999-03-31 18:30:14 +00:00
Paul Smith
e005a48b9f * More build fixes. I think a vanilla CVS checkout should build OK now. 1999-03-30 06:19:17 +00:00
Karl Berry
0798a61169 * texinfo.tex (\imagexxx): Equalize space above and below if in
vmode.  From rms.
.,
1999-03-27 10:32:23 +00:00
Paul Smith
ecb3bca9f5 * Manual updates: added xrefs, some typos sent by users.
* Change the build env. to not link libglob.a unless we need it.
1999-03-26 07:08:57 +00:00
Paul Smith
c4353af3f9 * Reworked function.c to use separate functions instead of a huge case stmt.
* Added new functions $(error ...) and $(warning ...) and documented same.
* In windows/dos shells, only treat \ as an escape for special chars.
1999-03-26 04:04:42 +00:00
Karl Berry
8363e0496d * texinfo.tex (&): be sure active & is defined for @deftypefn
operator&.
	Report from: Nathan Sidwell <nathan@acm.org>.
1999-03-24 16:04:27 +00:00
Karl Berry
4025030d96 * texinfo.tex: Changes from Andreas to use \sl\$ inside italics
and to avoid extra spaces around @anchor.
	* texinfo.tex (\image, \imagexx): move pdf test to imagexxx for
 		correct filename parsing.
1999-03-20 21:49:38 +00:00
Paul Smith
1e0513335f * Add strneq() (streq only n chars) macro
* fix return type of xstrdup.
1999-03-19 04:27:56 +00:00
Karl Berry
e3d0d562da * texinfo.tex (\imagexxx): reset catcode ^^M in case we're inside
in an example.  Report from kama.
1999-03-16 12:49:21 +00:00
Karl Berry
db865774df * texinfo.tex (\putwordin): new macro for word `in'.
(\xrefX): use it.
1999-03-15 22:34:20 +00:00
Paul Smith
a6a9ebb54f * Define and use xstrdup() instead of strdup(). 1999-03-05 07:13:12 +00:00
Paul Smith
9e6ba6a148 * Update FSF address info in copyright notices.
* Update maintainers build process; remove GNUmakefile.  Require builders to
  run automake && autoreconf by hand.
* Use AC_SUBST_FILE to get the maintMakefile included, rather than GNU
  make's include directive, which conflicts with automake 1.4's include
  directive.
1999-03-05 05:55:11 +00:00
Paul Smith
ede263043c Fix a bug where conditional variables weren't being expanded correctly. 1999-03-04 17:03:56 +00:00
Karl Berry
a8f7173799 * texinfo.tex: Expand tabs. 1999-02-22 12:59:43 +00:00
Paul Smith
a66668aabc * New feature: .LIBPATTERNS controls the way -lfoo dependencies are expanded.
* A few tweaks to the system glob test, after trying it on a system where
  it's true.
* Installed patches to archive handling for AIX 4.3 big archives.
* Fix a memory stomp in target-specific variables.
* Fix a memory leak in foreach functions.
1999-02-22 07:23:30 +00:00
Paul Smith
84f38c9c6f * Updates for automake 1.4 and autoconf 2.13
* Check for a libc version of GNU glob and, if found, don't use the local
  glob headers.
* Fix a bug in OpenVMS archive handling.
* Fix a bug in VMS siglist processing.
1999-02-19 18:07:49 +00:00
Karl Berry
5808507144 * texinfo.tex (\paragraphindent): implement.
Suggestion from: Paul DuBois <dubois@primate.wisc.edu>.
	* texinfo.tex (\alias): use def rather than \let.
	Change timestamp format to include hours.
1999-02-15 13:15:05 +00:00
Karl Berry
e3ef8e974c * texinfo.tex: New commands @alias and @definfoenclose.
From: "Eric S. Raymond" <esr@snark.thyrsus.com>.
1999-02-09 15:10:17 +00:00
Karl Berry
281cdd5d74 * texinfo.tex (\scanmacro): Use \endinput to avoid spurious space,
and various other space fixes.  From: Andreas Schwab
 		<schwab@ls5.informatik.uni-dortmund.de>.
1999-02-08 19:55:39 +00:00
Karl Berry
3634e15fe3 * texinfo.tex (\uref): implement optional third arg.
* texinfo.tex (\dosubind): Include index entry in third arg to
		\entry instead of writing as bogus fourth arg.
	Report from: kama@hippo.fido.de (Karl Heinz Marbaise).
	* texinfo.tex (\setemergencystretch): Increase somewhat.
	* texinfo.tex (\putwordof): rename from \putwordOf.
	* texinfo.tex (defivarhead, \defcvarheader): Use \putwordof.
1999-02-05 10:33:07 +00:00
Karl Berry
9c95acec4b * texinfo.tex (\documentlanguage, \documentencoding): new
commands.  \documentlanguage based on an implementation by kama.
1999-02-03 11:35:04 +00:00
Karl Berry
8b55cda094 * texinfo.tex: Fix @macro expansion inside @section. Patch from
Andreas:
	From: Andreas Schwab <schwab@ls5.informatik.uni-dortmund.de>
	The general idea is to construct a list a all defined macros in
 		the form \do\macro1\do\macro2..., then temporarily define
 		\do to something appropriate and execute the list to do
 		whatever is needed.  Here is a patch, and i have also
 		fixed a few other bugs that i found while browsing through
 		the @macro implementation.  Additionally i have added a
 		check to prevent the user from doing silly things like
 		@macro shipout.
1999-01-30 13:16:18 +00:00
Karl Berry
9d9111c450 * texinfo.tex (\obstexwarn): Don't use *** in message, it
interferes with make output parsing.
1999-01-24 16:04:24 +00:00
Karl Berry
0f686c1e6b * texinfo.tex: Internationalization improvements from kama. 1999-01-22 10:24:18 +00:00
Karl Berry
6eeae809a8 * texinfo.tex (\contents, \shortcontents): Run \contentspagealignmacro.
From: Trond Endrestol <trond@agamemnon.gtf.ol.no>
1999-01-21 10:37:08 +00:00
Karl Berry
5b16b3c015 * texinfo.tex (\begindoublecolumns): Ship out \partialpage
immediately if it is nonvoid, instead of saving it.  This avoids a
	bug where the index could end up printing one line per page (see
	the indexspread.tex test).
	From: Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>

	* texinfo.tex (\image): If running pdftex, do \pdfimage{imagefile.pdf}.
 	From: Samuel Tardieu <sam@inf.enst.fr>

 	Also, update copyright year.
1999-01-15 09:29:00 +00:00
Karl Berry
c0ec561e37 * texinfo.tex (\enddoublecolumns): Move \pagegoal reset to after
the \endgroup so we get the restored single-column \vsize
 		as intended.
1999-01-06 11:11:58 +00:00
Karl Berry
71aacd9fe0 * texinfo.tex (\indexdummies): Set \{ and \} to \mylbrace and
\mybrace to avoid braces in the index file, which
	texindex can't handle.
1998-12-21 15:36:12 +00:00
Karl Berry
dc7cf1c4b2 * texinfo.tex (\pickupwholefraction): Ignore whole-number part.
(\setuptable): Always pass whole-number part and decimal point.  This
	allows leading zeroes.
	Suggestion from: Ben Bullock <ben@hayamasa.demon.co.uk>.
	Date: Fri, 21 Aug 1998 14:06:50 +0100 (BST)
1998-12-20 12:55:40 +00:00
Karl Berry
7f83bfe911 * texinfo.tex (\indexdummies): set \{ and \} to \lbracecmd and
\rbracecmd to avoid lossage if @tex is active during \shipout.
	Report from: "Peter Kabal" <Kabal@ece.mcgill.ca>.
1998-12-15 21:48:39 +00:00
Karl Berry
45406fc744 doc fix 1998-12-12 20:44:40 +00:00
Karl Berry
76468fbaa1 update date 1998-11-13 23:00:02 +00:00
Karl Berry
2116c80dc7 1998-11-11 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
* doc/texinfo.tex (\onepageout): Put the cropmarks in vboxes of
	zero height so that they don't contribute space themselves.
	Compensate for \topandbottommargin.
	(\internalpagesizes): Advance \outervsize by 2\topandbottommargin,
	not only 0.6in.
1998-11-13 22:49:41 +00:00
Karl Berry
28eecbb94f * texinfo.tex: Use standard time-stamp.el package instead of
update-date.el.
.,
1998-11-08 18:39:08 +00:00
Karl Berry
9ad3cb03b7 * texinfo.tex (\indexnofonts,\indexdummies): add \url and \uref to
list.
1998-11-01 12:43:32 +00:00
Karl Berry
0be25c6986 * texinfo.tex (@env, @command, @option): Must disable for index
and xref commands.  Also, \input plain if necessary before
 		using {} in the version number.
1998-10-27 16:59:40 +00:00
Richard M. Stallman
4dfe38353e Mention Automake.
Mention DESTDIR.
Comment on changing prefix or exec_prefix.
1998-10-15 15:29:00 +00:00
Paul Smith
3948640154 Ignore non-empty lines which become empty after variable expansion.
Don't choke on invalid pattern rules if we fail during makefile parsing.
Don't dump core if a non-empty command becomes empty after expansion.
1998-10-13 20:59:08 +00:00
Paul Smith
2c64fb221a Checkpoint changes. Bug fixes, mostly. 1998-10-03 05:39:55 +00:00
Paul Smith
e90887e68a Don't use a separate configure.in for the glob directory. It now uses
the configure script for make proper.
1998-10-03 05:23:25 +00:00
Karl Berry
321b447568 * texinfo.tex: Use date as version number instead of RCS, and
update-date to update it.
1998-09-30 15:43:32 +00:00
Richard M. Stallman
b5722838c2 Treat __GNU__ line NeXT: undefine BSD and FSCALE. 1998-09-27 07:29:59 +00:00
Karl Berry
7a43e6cd30 * texinfo.tex: Fix @macro expansion of @code with _ in the
argument.
 	From: Zack Weinberg <zack@rabi.columbia.edu>.
1998-09-17 17:25:42 +00:00
Karl Berry
84d159bb64 * texinfo.tex (\itemzzz): take \itemmargin into account when
unhboxing.  Reported by Bob.
1998-08-28 14:29:37 +00:00
Karl Berry
050f9d9f5d * texinfo.tex: Change @defun environments so that right margin is
not changed, and instead the defun type label is outdented
 		into the margin.
1998-08-14 20:54:46 +00:00
Karl Berry
50b5c15b54 * texinfo.tex (\smartslanted): define this separately from
\smartitalic.
	(\emph, \i): use \smartitalic for true italics.
1998-08-13 17:33:06 +00:00
Karl Berry
fc6cca1c7c * texinfo.tex (\value): handle active _ or - in argument (happens
if called from @code).
 	Report from: Dave Love <d.love@dl.ac.uk>.
1998-08-10 19:17:34 +00:00
Paul Smith
5d1d6aa6de Attempt to add back ^M's. 1998-07-31 05:18:21 +00:00
Paul Smith
e2403327e9 GNU make release 3.77. 1998-07-30 20:54:47 +00:00
Karl Berry
65a7296e2c * texinfo.tex (\dosubind): Don't do \vskip to preserve \lastskip
unless we are in vertical mode.  Otherwise we might end a
 		paragraph prematurely, and \folio won't get expanded by
 		\output.
 	Report from: "Richard E. Stone" <res@rstone.mn.org>
1998-07-19 14:20:42 +00:00
Karl Berry
99454e6a1e * texinfo.tex: Keep track of how negative the page numbers have
gotten:
	(\lastnegativepageno): New \count register.
	(\startcontents): Use it.
	(\contents, \summarycontents): set it.
1998-07-17 12:00:43 +00:00
Karl Berry
411a01acce * texinfo.tex (\imagexxx): Add some space around the image if it's
by itself.
1998-07-14 19:03:08 +00:00
Karl Berry
33654a7af4 1998-07-09 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* texinfo.tex (chapterzzz): Put a space before the chapter number
	in the message.
	(appendixzzz): Use \putwordAppendix in the message.

Thu Jul  9 08:39:53 1998  Karl Berry  <karl@cs.umb.edu>

	* texinfo.tex (\macro): Globalize assignments since it's done
		inside a group.  From Zack.

Mon Jul  6 17:21:25 1998  Karl Berry  <karl@cs.umb.edu>

	* texinfo.tex (\comment): Speed up.
	(\loggingall): Turn on eTeX's extended tracing.
	More macro fixes.
	Date: Sat, 04 Jul 1998 14:51:49 -0400
	From: Zack Weinberg <zack@rabi.phys.columbia.edu>
1998-07-12 17:28:02 +00:00
Karl Berry
fa1ec9e1f3 * texinfo.tex (\contents, \summarycontents, \startcontents): Use
roman numerals for toc, arabic outside, even when toc is
 		at the beginning.
1998-07-02 14:22:24 +00:00
Karl Berry
fefeb0f7bd * texinfo.tex (\anchor): New command @anchor.
(\xrefX): Avoid double space when xref to an @anchor or an @unnumbered.

	* texinfo.tex (\itemzzz): Use kerns and \unhbox when item text
		fits in the space, so footnotes can work.
1998-07-01 14:28:14 +00:00
Karl Berry
6cca2382f0 * texinfo.tex (\setref): Take additional argument for the -snt
xref.  Call \indexdummies.
	(\donoderef, \appendixnoderef, \unnumbnoderef): Change \setref calls.
1998-06-29 14:07:11 +00:00
Karl Berry
44309109fe * texinfo.tex (\contents, \summarycontents): Must not be \outer. 1998-06-27 23:30:48 +00:00
Karl Berry
d153373039 * texinfo.tex (\writetocentry): New macro.
(\chapternofonts): No longer needed.
	(\chapter, ..., \unnumberedsubsubsec): Change all the sectioning
		commands to call \writetocentry instead of doing it inline.
	Also, do not call \chapternofonts, we avoid expansion with
		\the\toks instead.
	(\opencontents): No longer needed, instead \writetocentry opens
		the file when necessary.
	(\setfilename): Don't call \opencontents.
	(\ifsetcontentsaftertitlepage, \ifsetshortcontentsaftertitlepage):
		New conditionals.
	(\Etitlepage): Call \contents and/or \shortcontents if
		conditionals are set.

	Global: use \nobreak instead of \penalty 10000 for epsilon efficiency.
1998-06-27 19:12:04 +00:00
Karl Berry
ccac245bf5 * texinfo.tex (\acronym): New Texinfo command. 1998-06-25 12:31:28 +00:00
Karl Berry
f106953139 * texinfo.tex (\dots, \enddots): Missing \leavevmode.
Report from: Thomas Esken <esken@nmlab.informatik.fh-dortmund.de>
	Date: Tue, 23 Jun 1998 14:22:27 +0200 (MET DST)
1998-06-24 11:45:50 +00:00
Karl Berry
54727192c0 * texinfo.tex: Rewrite of index stuff to do better column breaking
and balancing.
	The old code failed miserably when the index was just the wrong size,
	e.g., the Autoconf manual with @afourpaper.
	Bug report from: Wilhelm Mueller <muewi@hb.senbvs43.uni-bremen.de>
	Date: Fri, 12 Jun 1998 16:34:49 +0200 (MET DST)
	(\initial): Add more glue around the initial, and make it a
		multiple of \baselineskip.
	(\entry): Add glue before each entry so the columns can always be the
	 same height.
	(\doublecolumnout): Available space no longer needs to handle
	 \partialpage specially.
	(\pagesofar): Take \ht\partialpage into account with \vsize.
	(\enddoublecolumns): Reset \output to avoid calling
		\balancecolumns twice
	(\balancecolumns): Format for readability.
	(\initialskipamount): No longer needed, remove.

	(\hbadness): Increase a bit, boxes that are a little underfull look ok.
1998-06-23 14:28:30 +00:00
Karl Berry
20258f42d4 * texinfo.tex (\ninettsl): cmsltt10 is not standard, so use
cmsltt10 scaled 900.
 	Date: Mon, 15 Jun 1998 12:35:41 +0200 (MET DST)
 	From: Werner Struckmann <struck@ips.cs.tu-bs.de>.
1998-06-22 13:00:05 +00:00
Karl Berry
4f79de612b * texinfo.tex: @macro fixes from Zack Weinberg
<zack@rabi.phys.columbia.edu>.
 	- @ifblah did not work inside @macro
        - spaces in parameter lists in macro definitions caused errors
        - leading spaces in parameter lists in macro invocations were
	  preserved inappropriately.
1998-06-19 11:50:37 +00:00
Karl Berry
ea9504a609 * texinfo.tex (\smallformatx, \smalldisplayx): New macros.
(\smallbook): Arrange to use them.
	(\display, \flushleft, etc.): Rewrite to avoid duplication.
1998-06-12 19:10:27 +00:00
Karl Berry
511cb55530 * texinfo.tex (\pagesizes): Rename to \internalpagesizes.
(\custompaper): Rename to \pagesizes.
1998-06-08 21:37:20 +00:00
Karl Berry
65d7b12aeb * texinfo.tex: Rewrite paper size definitions, add @custompaper.
* texinfo.tex: Fix for macros in arguments to other commands.
  		From Zack.
1998-06-07 13:35:32 +00:00
Karl Berry
2968844002 * texinfo.tex: Better @macro implementation.
From: Zack Weinberg <zack@rabi.phys.columbia.edu>.
1998-06-05 20:10:04 +00:00
Karl Berry
a709205e81 * texinfo.tex (\imagexxx): Center image if it is not part of a
paragraph.
1998-05-27 21:04:33 +00:00
Karl Berry
9391fb8e4c Tue May 19 17:17:12 1998 Karl Berry <karl@cs.umb.edu>
* texinfo.tex: \linkstrue by default.
	Also, first implementation of @macro; can only handle some cases,
 		but that is better than nothing.
	From: Zack Weinberg <zack@rabi.phys.columbia.edu>

Thu May 14 17:32:47 1998  Karl Berry  <karl@cs.umb.edu>

	* texinfo.tex: New command @novalidate along the lines of makeinfo
		--no-validate.
	Date: Sun, 26 Oct 1997 18:54:47 -0500
	From: Zack Weinberg <zack@rabi.phys.columbia.edu>
1998-05-19 21:26:03 +00:00
Ulrich Drepper
4950159344 automatically generated from GPLed version 1998-05-19 07:09:32 +00:00
Karl Berry
91da8b09df * texinfo.tex (\valuexxx): Split up into expandable and
non-expandable parts.
	(\expandablevalue): New macro.
	(\indexdummies): \let\value = \expandable value.

	* texinfo.tex: Doc fixes.

	* texinfo.tex (\doind): Just call \dosubind with empty third arg.
	(\dosubind): Replace with \doind definition and suitable code to handle
	possible third arg.  And propagate glue past the whatsit from the
 	\write so index entries don't cause extra space between
 	@defuns (for example).

Wed May  6 12:51:27 1998  Karl Berry  <karl@cs.umb.edu>

	* texinfo.tex (\deftypemethparsebody): Handle the extra arg in
 	@deftypemethodx, too.
	(\deftypefunx): Error definition was misspelled as \deftypeunx.
1998-05-13 12:44:07 +00:00
Karl Berry
e3e88767f1 (\putwordon, \putwordMethodon): New macros.
* texinfo/texinfo.tex (\putwordon, \putwordMethodon): New macros.
  	Use in \def... commands.
	(\indexdummies): make `\ ' be just ` ' for sorting.
	(\deftypemethparsebody): New macro.
	(\defmethod): Call it.
	Various doc fixes.
	Repored by: KHMarbaise@p69.ks.fido.de (Karl Heinz Marbaise)
	Date: Wed, 07 Jan 1998 10:19:42 +0100
1998-05-02 14:14:31 +00:00
Ulrich Drepper
76ae1bc064 automatically generated from GPLed version 1998-04-27 23:45:12 +00:00
Ulrich Drepper
e24c9e161a automatically generated from GPLed version 1998-04-27 23:45:12 +00:00
Ulrich Drepper
f0a7421adc automatically generated from GPLed version 1998-04-13 23:54:17 +00:00
Ulrich Drepper
8204f56f2f automatically generated from GPLed version 1998-04-13 23:54:16 +00:00
Karl Berry
e97f8e6f57 @cartouche: Align right side correctly.
From: dale.smith@bellhow.com (Dale Smith)
Date: Fri, 06 Mar 1998 14:47:02 GMT
1998-04-10 20:54:46 +00:00
Karl Berry
20b68e968a (\dosetq): Use \normalturnoffactive instead of just \turnoffactive,
so \'s in node names are handled properly.
(\tie): Move definition to more rational position in the file.
(\@, \{, etc.): Use decimal numbers in all cases, to avoid use of '.
Paranoia only.
(\+): Turn off once and for all at the beginning, and define as
\tabalign in @tex.
1998-04-05 21:19:01 +00:00
Karl Berry
9d31f1e1f1 (\synindex, \syncodeindex): \closeout the redirected index.
From: Jakob Stoklund Olesen <stoklund@mi.aau.dk>
1998-04-01 00:36:53 +00:00
Karl Berry
2fcce1d3b0 (\doignore): Ignore everything after `c', so @end ifinfo and the like
can be commented out.
(\macrocsname): New macro.
Reported by: "James A. Lupo" <lupoja@feynman.ml.wpafb.af.mil>
1998-04-01 00:33:30 +00:00
Karl Berry
1290679bc3 (\doprintindex): Change catcode of @ before \read, in case of
\initial{@} being the line that is read.
Reported by: Drew Csillag <drew_csillag@geocities.com>
1998-02-25 22:54:34 +00:00
Karl Berry
dc70a3bc0b (\dotable): Don't inherit \rightskip from
surrounding environment.  Add \leftskip to \hsize in the first
column.  Set \item to \crcr to avoid empty first row.  Prepend
\parskip glue before table.  Set \everycr locally outside of
alignment, don't reset it explicitly in \Emultitable.
From Andreas Schwab.

Also, work on leading commentary in file a bit.
1998-02-25 20:48:50 +00:00
Karl Berry
aa9ec7c2c7 \!: Save and restore this for @tex.
From: Jean-Pierre Moreau <jpmoreau@ciframedical.com>
Date: Fri, 22 Aug 1997 16:47:36 -0400
1998-02-24 23:05:08 +00:00
Karl Berry
04c488df1c (\angleleft, \angleright): New macros.
(\refx, \email, \key): Use them.
From: Stephen Gildea <gildea@intouchsys.com>
Date: Fri, 26 Dec 1997 11:43:32 EST
1998-02-24 22:48:24 +00:00
Karl Berry
8de0e41662 1997-08-28 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* doc/texinfo.tex (xrdef): Read the second argument with \ as an
	escape character.
1998-02-23 22:34:20 +00:00
Karl Berry
e94d73997a (\tocentry): Don't \turnoffactive before
typesetting the arguments, it causes special characters to be
printed incorrectly.
1998-01-26 20:40:21 +00:00
Karl Berry
7585dedefc (\dots, \enddots): Use current font instead of always using math italic. 1997-12-24 18:59:06 +00:00
Karl Berry
57ba55d08c Spurious xepsf.tex should be epsf.tex. 1997-12-23 16:33:04 +00:00
Ulrich Drepper
886748c02d automatically generated from GPLed version 1997-12-04 01:16:52 +00:00
Ulrich Drepper
d378e4204d automatically generated from GPLed version 1997-11-06 00:43:09 +00:00
Karl Heuer
e7e9b799c4 Mention YFLAGS and LFLAGS along with CFLAGS. 1997-10-27 03:47:03 +00:00
Karl Berry
a3a7581c1a (\titlefont): Explicitly set \rm. 1997-10-13 19:49:25 +00:00
Paul Smith
3e12cad198 Quick changes for make 3.76.1. 1997-09-19 19:47:55 +00:00
Paul Smith
e2ffc653aa Minor tweaks for 3.76. 1997-09-16 18:08:59 +00:00
Paul Smith
4e58a6ca4c Changes for GNU make 3.76 1997-09-16 14:19:43 +00:00
Paul Smith
41dcca8426 Changes for GNU make 3.76 1997-09-16 14:17:23 +00:00
Paul Eggert
161a026602 automatically generated from GPLed version 1997-09-11 18:13:19 +00:00
Ulrich Drepper
e244062995 automatically generated from GPLed version 1997-09-11 18:13:19 +00:00
Paul Eggert
24fec5cb53 automatically generated from GPLed version 1997-09-11 18:13:19 +00:00
Ulrich Drepper
b903988475 automatically generated from GPLed version 1997-09-11 18:13:19 +00:00
Paul Smith
6ea87be73b Changes for GNU make 3.75.93. 1997-09-05 21:01:49 +00:00
Paul Smith
f6490d62cf GNU make 3.75.92 1997-08-27 21:14:44 +00:00
Paul Smith
480ad62713 New glob.h to understand __const 1997-08-27 20:43:43 +00:00
Paul Smith
acd666ce50 Updated for GNU make 3.75.92. 1997-08-27 20:36:31 +00:00
Paul Smith
be3fb0ae6d Updates for GNU make 3.75.92. 1997-08-27 20:30:54 +00:00
Paul Smith
dd0c939e78 Last minute 3.75.91 changes. 1997-08-18 20:14:30 +00:00
Paul Smith
fff468765c e the global copy of this lib. 1997-08-18 19:31:49 +00:00
Paul Smith
63dff1e0bc Bug fixes and automake changes. 1997-08-18 18:11:04 +00:00
Paul Smith
e746a9c951 Removed files that are no longer needed now that we use automake. 1997-08-18 16:48:45 +00:00
Paul Smith
74d4418f1c Removed files that are no longer needed now that we use automake. 1997-08-18 15:19:04 +00:00
Miles Bader
062e5f6aae automatically generated from GPLed version 1997-08-14 02:25:35 +00:00
Paul Eggert
c495345f7c automatically generated from GPLed version 1997-08-14 02:16:15 +00:00
Paul Smith
f0239bb0af Final update for 3.75.1. 1997-08-01 06:31:21 +00:00
Karl Berry
2d29a55137 (\email): Let to \uref instead of \code, as a second optional argument
makes sense for this, too.
1997-07-26 19:12:35 +00:00
Richard M. Stallman
806c7aa46c Test __unix' along with unix'. 1997-07-22 21:35:43 +00:00
Jim Meyering
47daa6787e Add comment describing HAVE_PSTAT_GETDYNAMIC. 1997-07-15 13:21:56 +00:00
Karl Berry
eb4d510a74 (\indexdummies): Add \value. 1997-07-14 17:43:41 +00:00
Karl Berry
c86587fb9b (\authorrm): Must use \def instead of \let, as \secrm is not yet
defined.
1997-07-10 17:34:25 +00:00
Richard M. Stallman
fd688f6e9c (\titlefont): Define again, using \titlefonts. 1997-07-10 01:23:38 +00:00
Karl Berry
f96ef9a409 (\startcontents): Leave ^ catcode as other. 1997-07-09 20:45:27 +00:00
Richard M. Stallman
09616e5837 Declare how to hyphenate "whitespace". 1997-07-09 19:40:16 +00:00
Richard M. Stallman
cf9aa5b70b [OSF_ALPHA]: Include sys/mbuf.h, sys/socket.h, net/route.h. 1997-07-06 23:43:39 +00:00
Karl Berry
9033f1a656 (\titlefonts): New macro to set title font styles, so italic etc. work
in @title.
(\titlefont): No longer needed.
(\titlepage): Call \titlefonts instead of \titlefont.
(\chapsf, \ssecsy, \ssecttsl): Correct magstep values.
From: Stephen Gildea <gildea@intouchsys.com>.
1997-07-05 21:51:30 +00:00
Karl Berry
ccfe89b829 (\onepageout): Back up to 2\baselineskip per Stephen.
(\kbdinputstyle): New command.
1997-07-05 21:16:39 +00:00
Richard M. Stallman
35f1bbbe23 [__GNU__]: Test for not NeXT. 1997-07-04 04:45:19 +00:00
gnu
9f88582943 fix TeX overfills -len 1997-07-04 04:42:36 +00:00
Richard M. Stallman
b38d9d2ae9 (\kbdfont, \kbdexamplefont): New macros, parms that
tell @kbd what to do.
(\setkbdinputdistinct, \setkbdinputexample): New commands set them.
(\kbd): Use those parms.
1997-07-04 00:07:28 +00:00
Karl Berry
132e0eda6c (\onepageout): Leave only one line space above the footline, to be more
like plain.  Suggested by Stephen Gildea.
(\evenfootline): Left one too many line spaces here, so reduce by two.

(\ifnottex): Another ignore command.
(\ifnothtml,\ifnotinfo): New commands.
(\doignore): Ignore brace characters, so mismatched braces in ignored
text do not cause complaints.
1997-07-03 20:52:37 +00:00
Karl Berry
c297b2fbd5 (\image): New definition for new @image command. 1997-06-27 19:09:14 +00:00
Richard M. Stallman
ec08feae97 Update FSF address in second place. 1997-06-26 20:56:18 +00:00
Ulrich Drepper
8c7887ac02 update from main archive 970623 1997-06-23 22:48:40 +00:00
Ulrich Drepper
08cf536bfb automatically generated from GPLed version 1997-06-21 04:31:18 +00:00
Paul Eggert
b48b02c7f4 automatically generated from GPLed version 1997-06-21 04:31:18 +00:00
Ulrich Drepper
e7a0e14a43 automatically generated from GPLed version 1997-06-21 04:31:18 +00:00
Paul Eggert
6413a1d08e automatically generated from GPLed version 1997-06-21 04:31:18 +00:00
Miles Bader
8f34c48e3f automatically generated from GPLed version 1997-06-21 04:31:18 +00:00
Paul Eggert
818bb8940c automatically generated from GPLed version 1997-06-21 03:24:49 +00:00
Karl Berry
cc4d91d751 (\oddfootingxxx),
(\onepageout): Leave space for the footline if present.
(\everyfootingxxx, \everyheadingxxx): Call \oddfootingxxx and
\evenfootingxxx instead of repeating their code.
From: Stephen Gildea <gildea@intouchsys.com>.

(\setfilename): Read texinfo.cnf if present.

(\indexdummies, \indexnofonts): No-op additional commands @result @equiv
@expansion @print @error @point.
From: Dave Bodenstab <imdave@ais.net> (for texi2www doc).
1997-06-18 19:58:18 +00:00
Ulrich Drepper
36d804bd51 Undo last change. 1997-06-13 23:19:09 +00:00
Ulrich Drepper
f95d071efc update from main archive 970612 1997-06-12 23:56:51 +00:00
Karl Berry
c0deecf9ee (\setmultitablespacing): Restore bad typing mistake from yesterday. 1997-06-06 14:31:32 +00:00
Karl Berry
dd63648825 (\uref): Write real definition, taking one mandatory argument and one
optional one.
1997-06-05 22:04:25 +00:00
Karl Berry
229ba33d0e * texinfo.tex (\mainmagstep): Define this as a \count variable
instead of with \let, to make changing to \magstep1 more transparent.
 	From: HERBERT@boevm4.vnet.ibm.com.
	(\uref): New command a la \url.
1997-06-04 21:47:40 +00:00
Paul Eggert
ccbe33db90 automatically generated from GPLed version 1997-05-27 03:15:15 +00:00
Paul Eggert
32efbf8dc3 automatically generated from GPLed version 1997-05-27 03:15:15 +00:00
Paul Eggert
6e3b0629f1 automatically generated from GPLed version 1997-05-27 03:15:15 +00:00
Karl Berry
51659ed000 (\deftypemethod, \deftypemethodheader): New macros to implement
new commands @deftypemethod and @deftypemethodx.
Suggestion from: KHMarbaise@p69.ks.fido.de (Karl Heinz Marbaise).
1997-05-24 22:06:39 +00:00
Karl Berry
7827f1bde8 (\opnr, \clnr): Increment/decrement \parencount, for
* texinfo.tex (\opnr, \clnr): Increment/decrement \parencount, for
   	  @defun lines with nested parens.  From Bill Schelter
 	  <wfs@fireant.ma.utexas.edu>.
	(\itemizeitem): Correct \errmessage.
1997-05-23 17:02:00 +00:00
Karl Berry
922730c406 (\codeunder): Use \_ and \ifusingtt to avoid dotaccent from _ in roman
fonts, e.g., @deftypefn.
(\tex): Remove spurious spaces at the end of subdefinitions.
From: "John W. Eaton" <jwe@bevo.che.wisc.edu>.
(\url, \email): \let to \code; no quotes or angle brackets.
1997-05-19 21:34:38 +00:00
Richard M. Stallman
5e91041347 Explain which commands should use CFLAGS. 1997-05-17 19:07:42 +00:00
Karl Berry
9f7ba4a505 (\onepageout): \ifcropmarks, center the page body.
Lost this when merged \croppageout with \onepageout.
Found by Arnold.

(\doprintindex): Do not bother to go into double column mode unless
there actually is a non-empty index.

(\begindoublecolumns): Include any existing \partialpage in the new one,
lest we lose a whole page of output.
Found by M J Morley <mjm@scs.leeds.ac.uk>.

(\chapternofonts): Remove spurious spaces, both in the definitions that
get output to the aux file(s) and in this macro.

Fix comments and rationalize whitespace in various other places.
1997-05-05 21:06:33 +00:00
Karl Berry
2745ed943b Avoid expansion in node titles.
Merge cropmarks code into main output routine.
1997-04-27 19:40:44 +00:00
Paul Eggert
0cb72b4a51 automatically generated from GPLed version 1997-04-18 00:47:55 +00:00
Paul Smith
73fcfdbe24 Last-minute changed for 3.75.1 1997-04-07 18:02:17 +00:00
Paul Smith
0ada207e2d Changes for make 3.75.1 1997-04-07 07:21:16 +00:00
Paul Smith
7bb7ba7849 New file for DJGPP port. 1997-04-07 06:54:40 +00:00
Paul Smith
2a294c52d1 Renamed to config.h.W32 at RMS' request. 1997-04-02 06:03:37 +00:00
Paul Smith
71515366cd Renamed to README.W32 at RMS' request. 1997-04-02 05:59:56 +00:00
Roland McGrath
d78f2db327 Mon Mar 10 23:47:02 1997 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* job.c (construct_command_argv_internal): Don't discard an
	explicit empty argument at the end of the command line.  In the
	slow case return immediately if the command line was empty.
1997-03-12 21:17:08 +00:00
Miles Bader
30c9fcfec3 [__GNU__] (NeXT, host_self):
New macros, to make hurd systems use the NeXT code for getting load averages.
1997-02-23 03:38:49 +00:00
Paul Eggert
e2b79aacf7 automatically generated from GPLed version 1997-01-23 04:23:12 +00:00
Paul Eggert
e981c049f4 automatically generated from GPLed version 1997-01-22 05:25:31 +00:00
Jim Meyering
9012013552 [hpux && HAVE_PSTAT_GETDYNAMIC]: Use HPUX's pstat_getdynamic so
we don't need any special privileges to determine load averages.
Patch from Kaveh Ghazi, based on a sample implementation from
Richard J. Rauenzahn.
Indent cpp-directives to reflect nesting.
1997-01-16 03:33:02 +00:00
Karl Berry
cda4f25fd4 Oops, did inadvertent branch. 1997-01-04 19:24:13 +00:00
Ulrich Drepper
b32b9197ab update from main archive 961217 1996-12-18 03:22:53 +00:00
Paul Eggert
b66145d8bc Spelling fix. 1996-12-17 06:25:17 +00:00
David J. MacKenzie
d2fe84cab3 fix a couple of bugs 1996-12-11 00:49:47 +00:00
Karl Berry
c2ea8e2486 (\deftypevarheader, \deftypevrheader): Remove
* texinfo.tex (\deftypevarheader, \deftypevrheader): Remove
        anything after the first space in the name to be indexed, for the
	sake of tzname[2].
	(\dovarind): New macro.
	From: Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>.
1996-11-19 21:11:43 +00:00
Karl Berry
db2384b9ab \indexbreaks, \realunder, \multitable, \footnotezzz. 1996-11-17 00:12:46 +00:00
Karl Berry
9b0b3a6e70 (\value): Don't call \parsearg, @value takes a simple arg. 1996-11-16 00:20:09 +00:00
Karl Berry
a71d56b4cc (\parsetpheaderline): Don't go through \tptemp when
removing braces from #2, use the macro call directly.
	(\removeemptybraces): Expand to #1 instead of defining \tptemp.
	From: Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>.
	This makes @deftp {Data type} {struct termios} work again.
1996-11-16 00:19:07 +00:00
Karl Berry
10011ce289 (\set, \value): Allow - and _ in @set variable names. 1996-11-09 23:37:11 +00:00
David J. MacKenzie
84a9fd68b7 many bug fixes and a few additions, mostly derived from bug-gnu-utils 1996-11-09 22:19:34 +00:00
Karl Berry
262ca66cb7 (\readauxfile): Leave \catcode`\^ as other;
* texinfo.tex (\readauxfile): Leave \catcode`\^ as other;
 	otherwise, node names containing ^, such as in info/info.texi,
 	cause an error when run through TeX.
	(\setq): Do not call \auxhat.
	(\auxhat): Definition no longer needed.
	Reported by Howard Gayle <howard@hal.com>.
1996-11-09 18:44:09 +00:00
Richard M. Stallman
a1eb3e67cd Talk about which dir Info files, Bison output, etc. should go in.
Add some more utilities that can be used in make commands.
1996-11-07 22:30:30 +00:00
Karl Berry
78a4848b83 (see ChangeLog for Oct 29.) 1996-11-05 19:52:23 +00:00
Karl Berry
b16829dc46 Call \normalturnoffactive for the sake of \write's that include a \. 1996-11-05 19:51:16 +00:00
Jim Meyering
c71e4ac269 [__hpux]: Define hpux. From Eric Backus.
[__sun]: Define sun.  Reported by Kaveh Ghazi.
1996-10-10 03:29:50 +00:00
Karl Berry
82e6316607 Untabify. 1996-09-30 17:47:57 +00:00
Karl Berry
a8de4b93e3 Changes for Texinfo 3.8 release; see ChangeLog. 1996-09-30 17:39:54 +00:00
Karl Berry
6e7fa14c65 (\inforef): Move to more appropriate place.
* texinfo.tex (\inforef): Move to more appropriate place.
	(\pounds): Remove spurious extra $.
	(\email): Typeset argument in angle brackets.
	(\macro): Use \doignore for robustness, instead of just letting TeX
	parse the argument.
	(\unmacro): Define.
1996-09-18 12:15:20 +00:00
Richard M. Stallman
5206d3f2bc (getloadavg): Add new code for SUNOS_5 to use -lkstat. 1996-09-10 19:50:17 +00:00
Richard M. Stallman
e2da48ca55 Describe preinstall and postinstall commands. 1996-09-09 18:06:22 +00:00
Karl Berry
bc26243d90 Formatting change, define @pounds, etc. 1996-09-06 19:24:48 +00:00
Karl Berry
b4db97478e (\centerchfplain): Rewrite to use \chfplain, and to
actually center.
	(\unnchfplain): Just call \chfplain.
	(\chfplain): Rewrite to be generally callable.
	(\centerparametersmaybe): Hook, a no-op except with @centerchap.
1996-09-02 15:14:43 +00:00
Karl Berry
4e361d0f01 (\key): Do not uppercase the argument; key names
can be mixed case, e.g., `Control'.
1996-08-31 19:08:16 +00:00
Roland McGrath
d5d49d2e5a Regenerated for 3.75 1996-08-28 21:13:05 +00:00
Roland McGrath
191dc2b434 . 1996-08-28 18:15:23 +00:00
Roland McGrath
6fa74367b7 Tue Aug 27 01:06:34 1996 Roland McGrath <roland@baalperazim.frob.com>
* main.c (print_version): Print out bug-reporting address.
Mon Aug 26 19:55:47 1996  Roland McGrath  <roland@baalperazim.frob.com>

	* main.c (print_data_base): Don't declare ctime; headers do it for us
 	already.
1996-08-27 11:29:03 +00:00
Roland McGrath
4cee1500a4 Tue Aug 27 01:06:34 1996 Roland McGrath <roland@baalperazim.frob.com>
* version.c: Version 3.75 released.
1996-08-27 10:16:17 +00:00
Karl Berry
2602fb8e71 (\key): Typeset a lozenge around the argument (from
gildea@intouchsys.com).
1996-08-20 18:37:11 +00:00
Karl Berry
bfce132399 (\heading, \subheading, \subsubheading): Can no
* texinfo.tex (\heading, \subheading, \subsubheading): Can no
 	longer call the nonexistent \*secheadingi series. Instead, call
 	\plain*secheading.
	(\plainsubsecheading, \plainsubsubsecheading): New macros, by analogy
	with \plainsecheading.
	(\unnumberedsubseczzz, \unnumberedsubsubseczzz): Call them.
1996-08-05 18:01:12 +00:00
Karl Berry
30cf28ef63 (\HEADINGSdouble, \HEADINGSsingle,
HEADINGSdoubleafter, \HEADINGSsingleafter, \CHAPPAGoff,
\CHAPPAGon, \CHAPPAGodd): Set \contentsalignmacro, analogous to
\pagealignmacro.
(\startcontents): Call \contentsalignmacro instead of \pagealignmacro.
1996-08-03 18:59:17 +00:00
Karl Berry
a7f3831457 Restoring good RCS id. 1996-08-02 15:12:28 +00:00
Karl Berry
bcd11d854b (\indexfonts): Make leading be 12pt. Otherwise, it's too crammed.
(\smalllispx): Remove \setleading{10pt}. That was too small.
(\doprintindex): Do not call \tex ... \Etex.  Index files are Texinfo
source, not TeX source, except for using \ instead of @ as the
escape character (for now).
1996-07-29 19:08:10 +00:00
Roland McGrath
bb01a1a810 . 1996-07-29 05:46:07 +00:00
Roland McGrath
c622dd9bdf Sun Jul 28 15:37:09 1996 Rob Tulloh (tulloh@tivoli.com)
* w32/include/pathstuff.h: Added prototype for the new
	function convert_vpath_to_win32. Deleted macro for same.
1996-07-29 05:44:09 +00:00
Roland McGrath
7092951361 Sun Jul 28 15:37:09 1996 Rob Tulloh (tulloh@tivoli.com)
* w32/pathstuff.c: Turned convert_vpath_to_win32() into a
	real function. This was done so that VPATH could contain
	white space separated pathnames. Please note that directory
	paths (in VPATH/vpath context) containing white space are not
	supported (just as they are not under Unix). See README.WIN32
	for suggestions.
1996-07-29 05:44:06 +00:00
Roland McGrath
88d39b2a22 Sun Jul 28 15:37:09 1996 Rob Tulloh (tulloh@tivoli.com)
* w32/pathstuff.c: Turned convert_vpath_to_win32() into a
	real function. This was done so that VPATH could contain
	white space separated pathnames. Please note that directory
	paths (in VPATH/vpath context) containing white space are not
	supported (just as they are not under Unix). See README.WIN32
	for suggestions.
	* README.WIN32: Added some notes about why I chose not to try
	and support pathnames which contain white space and some
	workaround suggestions.
1996-07-29 05:44:03 +00:00
Karl Berry
3863dbeb03 (paragraphindent): Move to more reasonable place in the source file.
(chapfonts, secfonts, subsecfonts, indexfonts): Call \setleading.
(\chfplain, \secheading, \plainsecheading, \subsecheading,
 \subsubheading): Rewrite to properly \hangindent the title.
(\sectionheading): New generic macro to print section titles.
1996-07-28 20:57:40 +00:00
Karl Berry
cca242e6e3 Initial revision 1996-07-28 20:55:30 +00:00
Roland McGrath
7082394702 . 1996-07-26 02:33:47 +00:00
Roland McGrath
1f0bf7b4db Thu Jul 25 19:53:31 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* GNUmakefile (mkdep-nolib): Use -MM option unconditionally.
1996-07-26 02:33:35 +00:00
Roland McGrath
b18ce15130 Regenerated 1996-07-26 02:29:30 +00:00
Roland McGrath
c41efad63b Regenerated 1996-07-26 00:35:16 +00:00
Roland McGrath
683c716de3 autoconf 1996-07-26 00:35:09 +00:00
Roland McGrath
29253a9683 Regenerated for 3.74.7 1996-07-26 00:34:58 +00:00
Roland McGrath
9cc98648fd Updated from libc 1996-07-26 00:34:37 +00:00
Roland McGrath
d3c192e4a6 . 1996-07-26 00:33:49 +00:00
Roland McGrath
08905cdcbc Thu Jul 25 19:53:31 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* main.c (define_makeflags): Back up P to point at null terminator
	when killing final space and dash before setting MFLAGS.
1996-07-26 00:33:25 +00:00
Roland McGrath
4b72e38789 . 1996-07-26 00:06:10 +00:00
Roland McGrath
ce17fda12f Thu Jul 25 19:53:31 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* GNUmakefile (win32files): Add NMakefile.
1996-07-26 00:05:44 +00:00
Roland McGrath
2df6034eb6 Thu Jul 25 19:53:31 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
From Robert Hoehne <robert.hoehne@Mathematik.TU-Chemnitz.DE>:
	* dir.c [__MSDOS__] [DJGPP > 1]: Include <libc/dosio.h> and defin
	`__opendir_flags' initialized to 0.
	[__MSDOS__] (dosify) [DJGPP > 1]: Return name unchanged if _USE_LFN.
	(find_directory) [__MSDOS__ && DJGPP > 1]: If _USE_LGN, set
	__opendir_flags to __OPENDIR_PRESERVE_CASE.
1996-07-26 00:05:41 +00:00
Roland McGrath
dd0fe8f1ee Thu Jul 25 19:53:31 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* GNUmakefile (win32files): Add NMakefile.
	* NMakefile (LDFLAGS_debug): Value fixed by tulloh.
1996-07-26 00:05:37 +00:00
Roland McGrath
37fbc32ba4 Thu Jul 25 19:53:31 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* vmsfunctions.c (vms_stat): `sys$dassgn (DevChan);' added by kkaempf.
1996-07-26 00:05:34 +00:00
Roland McGrath
64bdaa521f . 1996-07-20 11:13:47 +00:00
Roland McGrath
37ce7efdca Sat Jul 20 12:32:10 1996 Klaus Kmpf (kkaempf@progis.de)
* remake.c (f_mtime) [VMS]: Add missing `if' conditional for future
	modtime check.
	* config.h-vms, makefile.vms, readme.vms, vmsify.c: Update address.
1996-07-20 11:13:04 +00:00
Roland McGrath
4b92c539d4 Sat Jul 20 05:29:43 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* configure.in: Require autoconf 2.10 or later.
1996-07-20 09:30:04 +00:00
Roland McGrath
a22f67aaf7 Regenerated for 3.74.6 1996-07-19 22:18:36 +00:00
Roland McGrath
9fc574683d Updated from libc 1996-07-19 22:18:33 +00:00
Roland McGrath
c8e016d07a 3.74.6 1996-07-19 21:43:36 +00:00
Roland McGrath
c396f06a21 . 1996-07-19 21:42:21 +00:00
Roland McGrath
fc47a2c83c updated w32 code by tulloh 1996-07-19 21:41:07 +00:00
Roland McGrath
561b384313 Fri Jul 19 16:57:27 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* GNUmakefile (win32files): New variable.
	(distfiles): Add it.
	* w32: Updated by Rob Tulloh.
1996-07-19 21:40:29 +00:00
Roland McGrath
88942403a6 Fri Jul 19 16:57:27 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* makefile.vms (LOADLIBES): Fix typo.
1996-07-19 21:40:25 +00:00
Roland McGrath
8733fbd646 . 1996-07-14 19:59:40 +00:00
Roland McGrath
cf2db2cf3c Sun Jul 14 12:59:27 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* job.c (construct_command_argv_internal): Fix up #else, #endifs.
1996-07-14 19:59:13 +00:00
Roland McGrath
f0cea20864 Sun Jul 14 12:59:27 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* remake.c (f_mtime): Don't compare MTIME to NOW if MTIME == -1.
1996-07-14 19:59:04 +00:00
Roland McGrath
fcb18b988b Sun Jul 14 12:59:27 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* configh.dos: Define HAVE_DIRENT_H instead of DIRENT.
1996-07-14 19:58:54 +00:00
Roland McGrath
8b24ec18b0 xref nonunix ports 1996-07-14 19:54:36 +00:00
Roland McGrath
df5ba0ef96 Regenerated for 3.74.5 1996-07-14 17:10:20 +00:00
Roland McGrath
74475bb939 Updated from libc 1996-07-14 17:09:51 +00:00
Roland McGrath
22ffba3660 . 1996-07-14 17:07:54 +00:00
Roland McGrath
9603eb13a0 . 1996-07-14 17:07:27 +00:00
Roland McGrath
fde68d03f3 Sun Jul 14 12:59:27 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* main.c (main): Exit with status 2 when update_goal_chain returns 2.
1996-07-14 17:07:13 +00:00
Mark Seaborn
56162c4968 formatting tweaks 1996-07-03 23:05:19 +00:00
Roland McGrath
f78bcc2e72 . 1996-06-22 22:00:43 +00:00
Roland McGrath
0c23819036 Sat Jun 22 14:56:05 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* configure.in: Don't check for _sys_siglist.
	* make.h [HAVE__SYS_SIGLIST]: Don't test this; just punt if there is
	no strsignal or sys_siglist.
1996-06-22 22:00:31 +00:00
Roland McGrath
91a7257252 . 1996-06-22 21:42:29 +00:00
Roland McGrath
d5f0b88095 Sat Jun 22 14:56:05 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* job.c (start_job_command): Call block_sigs.
	(block_sigs): New function, broken out of start_job_command.
	(reap_children): Block fatal signals around removing dead child from
	chain and adjusting job_slots_used.
	* job.h: Declare block_sigs.
1996-06-22 21:42:15 +00:00
Roland McGrath
3024918fcd Sat Jun 22 14:56:05 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* file.c (file_hash_enter): Allow renaming :: to : when latter is
	non-target, or : to :: when former is non-target.
1996-06-22 21:42:13 +00:00
Roland McGrath
bdc49369eb Sat Jun 22 14:56:05 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* job.c (reap_children): Don't call die if handling_fatal_signal.
	* job.c (start_job_command): Call block_sigs.
	(block_sigs): New function, broken out of start_job_command.
	(reap_children): Block fatal signals around removing dead child from
	chain and adjusting job_slots_used.
	* job.h: Declare block_sigs.
	* job.c (reap_children): Quiescent value of shell_function_pid is
	zero, not -1.
1996-06-22 21:42:10 +00:00
Roland McGrath
610526fee7 Sat Jun 22 14:56:05 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* remote-stub.c (remote_setup, remote_cleanup): New (empty) functions.
	* main.c (main): Call remote_setup.
	(die): Call remote_cleanup.
	* main.c (print_version): Add 96 to copyright years.
1996-06-22 21:42:06 +00:00
Roland McGrath
3f60c36245 Sat Jun 22 14:56:05 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* read.c (conditional_line): Strip ws in `ifeq (a , b)' so it is the
	same as `ifeq (a, b)'.
1996-06-22 21:42:02 +00:00
Roland McGrath
bd88059c38 (Wildcard Function): fix typo 1996-06-22 21:21:30 +00:00
Roland McGrath
63f3cf925b Updated from libc 1996-06-22 21:14:22 +00:00
Roland McGrath
8541e3345d . 1996-06-22 19:31:26 +00:00
Roland McGrath
d86e4a26c8 Sat Jun 22 14:56:05 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* remote-stub.c (remote_setup, remote_cleanup): New (empty) functions.
	* main.c (main): Call remote_setup.
	(die): Call remote_cleanup.
	* main.c (print_version): Add 96 to copyright years.
1996-06-22 19:31:12 +00:00
Roland McGrath
2c973c0b46 Sat Jun 22 14:56:05 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* remote-stub.c (remote_setup, remote_cleanup): New (empty) functions.
	* main.c (main): Call remote_setup.
	(die): Call remote_cleanup.
1996-06-22 19:31:06 +00:00
Roland McGrath
e0620ee179 Sat Jun 22 14:56:05 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* job.c (start_job_command): Call block_sigs.
	(block_sigs): New function, broken out of start_job_command.
	(reap_children): Block fatal signals around removing dead child from
	chain and adjusting job_slots_used.
	* job.c (reap_children): Quiescent value of shell_function_pid is
	zero, not -1.
1996-06-22 19:30:59 +00:00
Roland McGrath
dac23b2d0b Wed May 15 17:37:26 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* dir.c (print_dir_data_base): Use %ld dev and ino and cast them to
	long.
1996-06-22 19:30:04 +00:00
Roland McGrath
783e6680b2 Sat Jun 15 20:30:01 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* read.c (find_char_unquote): Avoid calling strlen on every call
	just to throw away the value most of the time.
1996-06-22 19:26:13 +00:00
Richard M. Stallman
2529deb2bf Describe lispdir variable. 1996-06-12 21:50:54 +00:00
Karl Heuer
3d3252b8de [SOLARIS2]: Define SUNOS_5. 1996-05-28 00:17:16 +00:00
Roland McGrath
b14b16769c Note win32 port 1996-05-27 00:58:20 +00:00
Roland McGrath
e7a525c5d5 Wed May 15 10:14:14 CDT 1996 Rob Tulloh <tulloh@tivoli.com>
* dir.c: WIN32 does not support inode. For now, fully qualified
	pathname along with st_mtime will be keys for files.
	Fixed problem where vpath can be confused when files
	are added to a directory after the directory has already been
	read in. The code now attempts to reread the directory if it
	discovers that the datestamp on the directory has changed since
	it was cached by make. This problem only seems to occur on WIN32
	right now so it is lumped under port #ifdef WIN32.

	* function.c: WIN32: call subproc library (CreateProcess()) instead of
	fork/exec.

	* job.c: WIN32: Added the code to do fork/exec/waitpid style processing
	on WIN32 systems via calls to subproc library.

	* main.c: WIN32: Several things added here. First, there is code
	for dealing with PATH and SHELL defaults. Make tries to figure
	out if the user has %PATH% set in the environment and sets it to
	%Path% if it is not set already. Make also looks to see if sh.exe
	is anywhere to be found. Code path through job.c will change
	based on existence of a working Bourne shell. The checking for
	default shell is done twice: once before makefiles are read in
	and again after. Fall back to MSDOS style execution mode if no sh.exe
	is found. Also added some debug support that allows user to pause make
	with -D switch and attach a debugger. This is especially useful for
	debugging recursive calls to make where problems appear only in the
	sub-make.

	* make.h: WIN32: A few macros and header files for WIN32 support.

	* misc.c: WIN32: Added a function end_of_token_w32() to assist
	in parsing code in read.c.

	* read.c: WIN32: Fixes similar to MSDOS which allow colon to
	appear in filenames. Use of colon in filenames would otherwise
	confuse make.

	* remake.c: WIN32: Added include of io.h to eliminate compiler
	warnings. Added some code to default LIBDIR if it is not set
	on WIN32.

	* variable.c: WIN32: Added support for detecting Path/PATH
	and converting them to semicolon separated lists for make's
	internal use. New function sync_Path_environment()
	which is called in job.c and function.c before creating a new
	process. Caller must set Path in environment since we don't
	have fork() to do this for us.

	* vpath.c: WIN32: Added detection for filenames containing
	forward or backward slashes.

	* NMakefile: WIN32: Visual C compatible makefile for use with nmake.
	Use this to build GNU make the first time on Windows NT or Windows 95.

	* README.WIN32: WIN32: Contains some helpful notes.

	* build_w32.bat: WIN32: If you don't like nmake, use this the first
	time you build GNU make on Windows NT or Windows 95.

	* config.h.WIN32: WIN32 version of config.h

	* subproc.bat: WIN32: A bat file used to build the
	subproc library from the top-level NMakefile. Needed because
	WIndows 95 (nmake) doesn't allow you to cd in a make rule.

	* w32/include/dirent.h
	* w32/compat/dirent.c: WIN32: opendir, readdir, closedir, etc.

	* w32/include/pathstuff.h: WIN32: used by files needed functions
	defined in pathstuff.c (prototypes).

	* w32/include/sub_proc.h: WIN32: prototypes for subproc.lib functions.

	* w32/include/w32err.h: WIN32: prototypes for w32err.c.

	* w32/pathstuff.c: WIN32: File and Path/Path conversion functions.

	* w32/subproc/build.bat: WIN32: build script for subproc library
	if you don't wish to use nmake.

	* w32/subproc/NMakefile: WIN32: Visual C compatible makefile for use
	with nmake. Used to build subproc library.

	* w32/subproc/misc.c: WIN32: subproc library support code
	* w32/subproc/proc.h: WIN32: subproc library support code
	* w32/subproc/sub_proc.c: WIN32: subproc library source code
	* w32/subproc/w32err.c: WIN32: subproc library support code
1996-05-22 21:51:45 +00:00
Roland McGrath
d369e0531a [WIN32]: No-op as for [MSDOS]. 1996-05-22 21:47:37 +00:00
Roland McGrath
6701f24bbb . 1996-05-22 21:25:55 +00:00
Roland McGrath
e76076e334 Wed May 22 17:24:51 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* makefile.vms: Set LOADLIBES.
	* makefile.com (link_using_library): Fix typo.
1996-05-22 21:25:45 +00:00
Roland McGrath
673e04af3a Mon May 13 14:37:42 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* GNUmakefile (vmsfiles): Fix typo.
1996-05-13 23:22:17 +00:00
Roland McGrath
bc8ac28654 . 1996-05-13 23:21:36 +00:00
Roland McGrath
95744a1491 Regenerated for 3.74.4 1996-05-13 23:16:46 +00:00
Roland McGrath
78f280d541 Updated from libc 1996-05-13 23:16:23 +00:00
Roland McGrath
44811ac351 . 1996-05-13 23:14:45 +00:00
Roland McGrath
6cf0e549f7 Updated from libc 1996-05-13 20:30:33 +00:00
Roland McGrath
25d9818333 . 1996-05-13 20:22:24 +00:00
Roland McGrath
2a905c5e5a Sun May 12 19:19:43 1996 Aaron Digulla <digulla@fh-konstanz.de>
* dir.c: New function: amigafy() to fold filenames
	Changes HASH() to HASHI() to fold filenames on Amiga.
	Stringcompares use strieq() instead of streq()
	The current directory on Amiga is "" instead of "."
	* file.c: Likewise.
1996-05-13 20:22:05 +00:00
Roland McGrath
0ddf0df13c Sun May 12 19:19:43 1996 Aaron Digulla <digulla@fh-konstanz.de>
* main.c: (main), variable.c Changed handling of ENV-vars. Make
	stores now the names of the variables only and reads their contents
	when they are accessed to reflect that these variables are really
	global (ie. they CAN change WHILE make runs !) This handling is
	made in lookup_variable()
	* variable.c: Handling of ENV variable happens inside lookup_variable()
1996-05-13 18:40:28 +00:00
Roland McGrath
b4dcc6f6bd Sun May 12 19:19:43 1996 Aaron Digulla <digulla@fh-konstanz.de>
* job.h: No envp on Amiga
1996-05-13 18:40:22 +00:00
Roland McGrath
c8484a6170 Sun May 12 19:19:43 1996 Aaron Digulla <digulla@fh-konstanz.de>
* main.c: (main), variable.c Changed handling of ENV-vars. Make
	stores now the names of the variables only and reads their contents
	when they are accessed to reflect that these variables are really
	global (ie. they CAN change WHILE make runs !) This handling is
	made in lookup_variable()
1996-05-13 18:40:11 +00:00
Roland McGrath
7431536bed Mon May 13 14:37:42 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* GNUmakefile (amigafiles): Add amiga.h.
Sun May 12 19:19:43 1996  Aaron Digulla   <digulla@fh-konstanz.de>

	* amiga.h: New file. Prototypes for amiga.c
1996-05-13 18:39:59 +00:00
Roland McGrath
678b14fb7e Sun May 12 19:19:43 1996 Aaron Digulla <digulla@fh-konstanz.de>
* function.c: Use special function wildcard_expansion() for
	$(wildcard ) to allow Amiga wildcards
	The current directory on Amiga is "" instead of "."
1996-05-13 18:39:52 +00:00
Roland McGrath
efbe1b6411 Sun May 12 19:19:43 1996 Aaron Digulla <digulla@fh-konstanz.de>
* README.Amiga: updated feature list
1996-05-13 18:39:46 +00:00
Roland McGrath
5fb14db85f Sun May 12 19:19:43 1996 Aaron Digulla <digulla@fh-konstanz.de>
* Makefile.ami: renamed file.h to filedep.h
	Updated dependencies
1996-05-13 18:39:40 +00:00
Roland McGrath
df99d7af1f Mon May 13 14:37:42 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* GNUmakefile (amigafiles): Add amiga.h.
1996-05-13 18:39:33 +00:00
Roland McGrath
db561cfc3e Sun May 12 19:19:43 1996 Aaron Digulla <digulla@fh-konstanz.de>
* read.c: "find_semicolon" is declared as static but never defined.
	No difference between Makefile and makefile on Amiga; added
	SMakefile to *default_makefiles[].
	(read_makefile) SAS/C want's two_colon and pattern_percent be set
	before use.
	The current directory on Amiga is "" instead of "."
	Strange #endif moved.
1996-05-13 18:39:02 +00:00
Roland McGrath
0feb1dd25f Sun May 12 19:19:43 1996 Aaron Digulla <digulla@fh-konstanz.de>
* make.h: Added HASHI(). This is the same as HASH() but converts
	it's second parameter to lowercase on Amiga to fold filenames.
1996-05-13 18:38:38 +00:00
Roland McGrath
e2d8bf4aa4 Sun May 12 19:19:43 1996 Aaron Digulla <digulla@fh-konstanz.de>
* job.c: No Pipes on Amiga, too
	(load_too_high) Neither on Amiga
	ENV variable on Amiga are in a special directory and are not
	passed as third argument to main().
1996-05-13 18:38:29 +00:00
Roland McGrath
dc27ebc311 Sun May 12 19:19:43 1996 Aaron Digulla <digulla@fh-konstanz.de>
* dir.c: New function: amigafy() to fold filenames
	Changes HASH() to HASHI() to fold filenames on Amiga.
	Stringcompares use strieq() instead of streq()
	The current directory on Amiga is "" instead of "."
1996-05-13 18:38:20 +00:00
Roland McGrath
989d9ecaae Sun May 12 19:19:43 1996 Aaron Digulla <digulla@fh-konstanz.de>
* amiga.c: New function wildcard_expansion(). Allows to use
	Amiga wildcards with $(wildcard )
	* amiga.h: New file. Prototypes for amiga.c
1996-05-13 18:38:15 +00:00
Roland McGrath
b0098dfd6a Sun May 12 19:19:43 1996 Aaron Digulla <digulla@fh-konstanz.de>
* read.c: "find_semicolon" is declared as static but never defined.
	No difference between Makefile and makefile on Amiga; added
	SMakefile to *default_makefiles[].
	(read_makefile) SAS/C want's two_colon and pattern_percent be set
	before use.
	The current directory on Amiga is "" instead of "."
	Strange #endif moved.
	* SMakefile: Updated dependencies
1996-05-13 18:38:10 +00:00
Roland McGrath
40a08e8a62 . 1996-05-09 20:07:56 +00:00
Roland McGrath
5e728dfa57 Thu May 9 13:54:49 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* commands.c (fatal_error_signal) [SIGQUIT]: Make SIGQUIT check
	conditional.
1996-05-09 20:07:14 +00:00
Roland McGrath
085eac4c74 Mention amiga port 1996-05-09 18:40:55 +00:00
Roland McGrath
085caaa900 Updated from libc 1996-05-09 18:29:30 +00:00
Roland McGrath
cc28a52f40 . 1996-05-09 18:28:25 +00:00
Roland McGrath
1e38c11f3c Thu May 9 13:54:49 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* function.c (expand_function) [_AMIGA]: Fix some typos.
	(patsubst_expand): Make len vars unsigned.
1996-05-09 18:28:15 +00:00
Roland McGrath
58af8d9dd1 Thu May 9 13:54:49 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* read.c (parse_file_seq): Use `int' for char arg to avoid widening
	conflict issues.
	* dep.h: Fix prototype.
1996-05-09 18:28:09 +00:00
Roland McGrath
abe5f64440 Thu May 9 13:54:49 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* main.c (main): Use unsigned for fread return.
1996-05-09 18:28:03 +00:00
Roland McGrath
68b9650616 Updated from libc 1996-05-09 18:16:24 +00:00
Roland McGrath
5dfa403ec8 (libc-srcdir): Use ../libc. 1996-05-09 18:10:49 +00:00
Roland McGrath
f7ecda9a35 Updated from libc 1996-05-09 18:06:45 +00:00
Roland McGrath
e99a3aca7e Thu May 9 13:54:49 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* GNUmakefile (globfiles): Add AmigaDOS support files.
	(distfiles): Add $(amigafiles).
	(amigafiles): New variable.

Thu Nov  7 10:18:16 1995  Aaron Digulla   <digulla@fh-konstanz.de>

	* Added Amiga support in commands.c, dir.c, function.c,
	job.c, main.c, make.h, read.c, remake.c
	* commands.c: Amiga has neither SIGHUP nor SIGQUIT
	* dir.c: Amiga has filenames with Upper- and Lowercase,
	but "FileName" is the same as "filename". Added strieq()
	which is use to compare filenames. This is like streq()
	on all other systems. Also there is no such thing as
	"." under AmigaDOS.
	* function.c: On Amiga, the environment is not passed as envp,
	there are no pipes and Amiga can't fork. Use my own function
	to create a new child.
	* job.c: default_shell is "" (The system automatically chooses
	a shell for me). Have to use the same workaround as MSDOS for
	running batch commands. Added HAVE_SYS_PARAM_H. NOFILE isn't
	known on Amiga. Cloned code to run children from MSDOS. Own
	version of sh_chars[] and sh_cmds[]. No dup2() or dup() on Amiga.
	* main.c: Force stack to 20000 bytes. Read environment from ENV:
	device. On Amiga, exec_command() does return, so I exit()
	afterwards.
	* make.h: Added strieq() to compare filenames.
	* read.c: Amiga needs special extension to have passwd. Only
	one include-dir. "Makefile" and "makefile" are the same.
	Added "SMakefile".  Added special code to handle device names (xxx:)
	and "./" in rules.
	* remake.c: Only one lib-dir. Amiga link-libs are named "%s.lib"
	instead of "lib%s.a".
	* main.c, rule.c, variable.c: Avoid floats at all costs.
	* vpath.c: Get rid of as many alloca()s as possible.
1996-05-09 18:02:06 +00:00
Roland McGrath
73c52a3b12 Thu May 9 13:20:43 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* read.c (read_makefile): Grok `sinclude' as alias for `-include'.
1996-05-09 17:28:47 +00:00
Roland McGrath
4679c702de Document "sinclude". 1996-05-09 17:25:54 +00:00
Roland McGrath
59cb26b58b Note "sinclude". 1996-05-09 17:24:04 +00:00
Roland McGrath
386e27b622 Update date to 20 March 96 1996-05-09 17:07:56 +00:00
Richard M. Stallman
68db062e1e Avoid symlinks if possible. 1996-05-06 03:45:23 +00:00
Roland McGrath
a67e842fb1 . 1996-03-20 15:01:50 +00:00
Roland McGrath
712c43dde1 [HAVE_STRING_H]: Include string.h. 1996-03-20 14:59:27 +00:00
Roland McGrath
c0e8c1012d moved to filedef.h 1996-03-20 14:58:34 +00:00
Roland McGrath
c97502625c Wed Mar 20 09:52:27 1996 Roland McGrath <roland@charlie-brown.gnu.ai.mit.edu>
* GNUmakefile (vmsfiles): New variable.
	(distfiles): Include $(vmsfiles).
1996-03-20 14:58:18 +00:00
Roland McGrath
9e443adaf6 Tue Mar 19 20:21:34 1996 Roland McGrath <roland@charlie-brown.gnu.ai.mit.edu>
Merged VMS port from Klaus Kaempf <kkaempf@didymus.rmi.de>.
	* make.h (PARAMS): New macro.
	* config.h-vms: New file.
	* makefile.com: New file.
	* makefile.vms: New file.
	* readme.vms: New file.
	* vmsdir.h: New file.
	* vmsfunctions.c: New file.
	* vmsify.c: New file.
	* file.h: Renamed to filedef.h to avoid conflict with VMS system hdr.
	* ar.c: Added prototypes and changes for VMS.
	* commands.c: Likewise.
	* commands.h: Likewise.
	* default.c: Likewise.
	* dep.h: Likewise.
	* dir.c: Likewise.
	* expand.c: Likewise.
	* file.c: Likewise.
	* function.c: Likewise.
	* implicit.c: Likewise.
	* job.c: Likewise.
	* job.h: Likewise.
	* main.c: Likewise.
	* make.h: Likewise.
	* misc.c: Likewise.
	* read.c: Likewise.
	* remake.c: Likewise.
	* remote-stub.c: Likewise.
	* rule.c: Likewise.
	* rule.h: Likewise.
	* variable.c: Likewise.
	* variable.h: Likewise.
	* vpath.c: Likewise.
	* compatMakefile (srcs): Rename file.h to filedef.h.
1996-03-20 14:57:41 +00:00
Roland McGrath
dfefc77263 Regenerated 1996-03-20 14:55:13 +00:00
Roland McGrath
ee7af57e3c Updated from libc 1996-03-20 03:12:54 +00:00
Roland McGrath
46a1497b8e (NULL): Define only if not already defined. 1996-03-20 01:08:11 +00:00
Roland McGrath
4603f9f8c6 [HAVE_STRING_H]: Include string.h.
[HAVE_STDLIB_H]: Include stdlib.h.
1996-03-20 01:07:36 +00:00
Roland McGrath
b2a22df721 RMS documented his .SECONDARY feature. 1996-03-20 00:58:43 +00:00
Roland McGrath
89785948f6 . 1996-03-20 00:57:43 +00:00
Roland McGrath
8b2aca5930 Sun Jul 30 00:49:53 1995 Richard Stallman <rms@mole.gnu.ai.mit.edu>
* file.h (struct file): New field `secondary'.
	* file.c (snap_deps): Check for .INTERMEDIATE and .SECONDARY.
	(remove_intermediates): Don't delete .SECONDARY files.
1996-03-20 00:56:52 +00:00
Roland McGrath
b8ea37e31c Sat Aug 19 23:11:00 1995 Richard Stallman <rms@mole.gnu.ai.mit.edu>
* remake.c (check_dep): For a secondary file, try implicit and
	default rules if appropriate.
Wed Aug  2 04:29:42 1995  Richard Stallman  <rms@mole.gnu.ai.mit.edu>

	* remake.c (check_dep): If an intermediate file exists,
	do consider its actual date.
1996-03-20 00:56:45 +00:00
Roland McGrath
e044fe76f6 Add '96 to copyright years. 1996-03-04 17:59:44 +00:00
Roland McGrath
557392f016 Minor tweaks to fix overfull & underfull hboxes in fmting make man. 1996-03-04 17:57:41 +00:00
Roland McGrath
eaecc11501 . 1996-03-02 21:27:49 +00:00
Roland McGrath
b25f811f51 Sat Mar 2 16:26:52 1996 Roland McGrath <roland@charlie-brown.gnu.ai.mit.edu>
* compatMakefile (srcs): Add getopt.h; prepend $(srcdir)/ to getopt*.
1996-03-02 21:27:40 +00:00
Roland McGrath
34b0c6b3b4 (Standard Targets): Use @smallexample. 1996-03-01 21:47:33 +00:00
Roland McGrath
2de9513b20 . 1996-03-01 19:19:37 +00:00
Roland McGrath
8eb20e9d92 Fri Mar 1 12:04:47 1996 Roland McGrath <roland@charlie-brown.gnu.ai.mit.edu>
* remake.c (f_mtime): Move future modtime check before FILE is
	clobbered by :: loop.
1996-03-01 19:14:35 +00:00
Roland McGrath
32979e8122 . 1996-03-01 17:45:50 +00:00
Roland McGrath
490f35dda4 Fri Mar 1 12:04:47 1996 Roland McGrath <roland@charlie-brown.gnu.ai.mit.edu>
* dir.c: Use canonical code from autoconf manual for dirent include.
	[_D_NAMLEN]: Redefine NAMLEN using this.
	(dir_contents_file_exists_p): Use NAMLEN macro.
	(read_dirstream) [_DIRENT_HAVE_D_NAMLEN]: Only set d_namlen #if this.
1996-03-01 17:45:37 +00:00
Roland McGrath
a579af186b Fri Mar 1 12:04:47 1996 Roland McGrath <roland@charlie-brown.gnu.ai.mit.edu>
* compatMakefile (objs): Add missing backslash.
1996-03-01 17:45:34 +00:00
Roland McGrath
01d08292bc Updated from libc 1996-03-01 17:43:47 +00:00
Roland McGrath
f9c4aae3bf (libc-srcdir) New var.
(stamp-glob): Use $(libc-srcdir).
1996-03-01 17:19:01 +00:00
Roland McGrath
74e456e107 autoheader 1996-03-01 17:07:48 +00:00
Roland McGrath
f8b096b9fd Regenerated 1996-03-01 17:07:36 +00:00
Roland McGrath
527201342c Regenerated for 3.74.3 1996-03-01 17:07:14 +00:00
Roland McGrath
5f1e98e59b Updated from libc 1996-03-01 17:07:10 +00:00
Roland McGrath
f4020bfba8 . 1996-03-01 17:05:11 +00:00
Roland McGrath
4792e6f5c0 Fixed sed cmd in auto dep section.
Fixed bogus MAKEFLAGS override example.
1996-03-01 17:02:26 +00:00
Roland McGrath
514eda2bda Mention future modtime detection. 1996-03-01 17:00:57 +00:00
Richard M. Stallman
310f677b84 Say it is ok to use true and false.
Make recommendations about install-info accurate.
1996-02-29 04:22:34 +00:00
Roland McGrath
f323abd6b3 . 1996-02-29 00:27:34 +00:00
Roland McGrath
b07e961db1 Wed Feb 28 03:56:20 1996 Roland McGrath <roland@charlie-brown.gnu.ai.mit.edu>
* remake.c (f_mtime): Check for future timestamps; give error and mark
	file as "failed to update".
1996-02-29 00:27:25 +00:00
Roland McGrath
5958f28900 Wed Feb 28 03:56:20 1996 Roland McGrath <roland@charlie-brown.gnu.ai.mit.edu>
* default.c (default_terminal_rules): Remove + prefix from RCS cmds.
	(default_variables): Put + prefix in $(CHECKOUT,v) value instead.
1996-02-29 00:27:22 +00:00
Roland McGrath
fd504b4d84 . 1996-02-28 07:40:34 +00:00
Richard M. Stallman
1bb24cbbbb Replace strip' target with install-strip'. 1996-02-27 07:36:22 +00:00
Richard M. Stallman
b255a75bab Describe `strip' target. 1996-02-10 06:28:45 +00:00
Karl Heuer
0569ceb303 Update FSF address in comment. 1996-02-01 18:44:05 +00:00
arnold
8021c41954 Reordering of sections for better reading linearly and to go with
reorg'ed standards.texi. use Makefile with a capital 'M' everywhere.
Add description of Autoconf versions of standard directories.
1996-01-19 00:18:58 +00:00
Richard M. Stallman
edd7981e49 Minor change about parallel make. 1996-01-17 22:29:34 +00:00
Roland McGrath
715363eb49 Don't declare unblock_sigs; job.h already does. 1996-01-12 23:09:23 +00:00
Karl Heuer
c36430699e (alloca): If malloc fails, just abort. 1996-01-07 07:00:56 +00:00
Roland McGrath
5f99dee5b5 . 1996-01-06 21:26:02 +00:00
Roland McGrath
9521ecc573 (HAVE_SYSCONF_OPEN_MAX): #undef removed. 1996-01-06 21:25:28 +00:00
Roland McGrath
cb69b06199 (NGROUPS_MAX): Don't try to define this macro. 1996-01-06 21:24:34 +00:00
Richard M. Stallman
21fed1fbcc (getloadavg) [MSDOS]: Return 0 load instead of failing the call. 1995-12-28 23:28:35 +00:00
Roland McGrath
17aef36902 . 1995-12-22 23:45:03 +00:00
Roland McGrath
98f8d6286e (GETOPT, GETOPT_SRC, GLOB): Variables removed.
(objs, srcs): Include their values here instead of references.
1995-12-22 23:44:31 +00:00
Roland McGrath
d96d52d27d autoconf 1995-12-14 11:25:51 +00:00
Roland McGrath
625b9f6ba2 . 1995-12-14 11:25:36 +00:00
Roland McGrath
8756e81616 Regenerated for 3.74.2 1995-12-14 11:25:13 +00:00
Roland McGrath
3e141c8277 . 1995-12-14 11:23:23 +00:00
Roland McGrath
aaed50ac3f (reap_children): Call unblock_sigs after start_job_command. 1995-12-14 11:21:20 +00:00
Roland McGrath
a89eb21084 Updated from libc 1995-12-14 11:14:36 +00:00
Roland McGrath
4356ddddbc . 1995-12-14 11:00:34 +00:00
Roland McGrath
b8db661c24 (dir_setup_glob): Don't use lstat; glob never calls it anyway.
Avoid & before function names to silence bogus sunos4 compiler.
1995-12-14 07:22:03 +00:00
Roland McGrath
a54c552d39 Remove check for `sysconf (_SC_OPEN_MAX)'. 1995-12-14 07:18:09 +00:00
Roland McGrath
25d48503eb . 1995-12-12 05:49:35 +00:00
Roland McGrath
5df0d41985 (read_dirstream): Fix braino: fill in the buffer when not reallocating it! 1995-12-12 05:48:31 +00:00
Roland McGrath
737e056a89 (CPPFLAGS): Add -Iglob. 1995-12-12 05:47:27 +00:00
Roland McGrath
8c13a20895 Fix typo. 1995-12-12 04:55:06 +00:00
Roland McGrath
2a0707e1b8 Mention delayed -w msgs. 1995-12-12 04:54:41 +00:00
Roland McGrath
d116acac75 autoheader 1995-12-12 04:36:32 +00:00
Roland McGrath
6ab25d18b2 Regenerated 1995-12-12 04:35:35 +00:00
Roland McGrath
4061695ef6 autoconf 1995-12-12 04:34:14 +00:00
Roland McGrath
e3200b9303 Regenerated for 3.74.1 1995-12-12 04:33:36 +00:00
Roland McGrath
18a7013e55 Updated from libc 1995-12-12 04:33:02 +00:00
Roland McGrath
624552badd . 1995-12-12 04:32:10 +00:00
Roland McGrath
76d037cb95 (collapse_continuations): Fix skipping of trailing \s so it can never
dereference before the beginning of the array.
1995-12-12 04:24:17 +00:00
Roland McGrath
dfdf1bec21 . 1995-12-12 03:48:29 +00:00
Roland McGrath
caa2fe5d39 [HAVE_D_NAMLEN]: Define this for __GNU_LIBRARY__ > 1.
(D_NAMLEN): Macro removed.
(FAKE_DIR_ENTRY): New macro.
(dir_contents_file_exists_p): Test HAVE_D_NAMLEN instead of using D_NAMLEN.
(read_dirstream): Return a struct dirent * for new glob interface.
(init_dir): Function removed.
(dir_setup_glob): New function.
1995-12-12 03:37:15 +00:00
Roland McGrath
2f506a6d52 Remove all [M_XENIX] code. 1995-12-12 03:33:25 +00:00
Roland McGrath
856d83462f (main): Don't call init_dir. 1995-12-12 03:32:46 +00:00
Roland McGrath
e9fcf7ea88 Use plain stat instead of safe_stat.
(find_semicolon): Function removed.
(read_makefile): Don't use find_semicolon or remove_comments for rule lines.
Use find_char_unquote directly and handle quoted comments properly.
(multi_glob): Call dir_setup_glob on our glob_t and use GLOB_ALTDIRFUNC flag.
1995-12-12 03:31:40 +00:00
Roland McGrath
bfa6ab6a0c (safe_stat): Function removed. 1995-12-12 03:27:28 +00:00
Roland McGrath
4e6de57b8f Use plain stat instead of safe_stat. 1995-12-12 03:26:08 +00:00
Roland McGrath
41e6704efd Updated from libc 1995-12-12 02:50:12 +00:00
Roland McGrath
ffea662953 Updated from libc 1995-12-12 02:42:43 +00:00
Roland McGrath
db5cc03f75 Updated from libc 1995-12-07 21:05:46 +00:00
Roland McGrath
cd851988e7 Updated from libc 1995-12-07 20:32:37 +00:00
Roland McGrath
fb39f49937 . 1995-11-26 01:43:28 +00:00
Roland McGrath
dccc12dbee [HAVE_UNION_WAIT]: Include sys/wait.h.
(start_job_command): Pass new arg to `message'; fix inverted test in that
call.
1995-11-26 01:42:27 +00:00
Roland McGrath
1305447ace . 1995-11-26 01:40:35 +00:00
Roland McGrath
5ed1a6399a (log_working_directory): Declare it. 1995-11-26 01:39:38 +00:00
Roland McGrath
3f614c58ed Pass new arg in `message' calls. 1995-11-26 01:38:10 +00:00
Roland McGrath
37cf6fdc18 (log_working_directory): Made global.
Print entering msg only once.
1995-11-26 01:37:07 +00:00
Roland McGrath
808f1c1cd2 (message): Take new arg PREFIX. Print "make: " only if nonzero. 1995-11-26 01:35:05 +00:00
Roland McGrath
06021f945f (touch_file): Removing newline from message string. 1995-11-22 00:16:14 +00:00
Roland McGrath
ad61285598 (start_job_command): Pass null instead of "" to message; don't add newline. 1995-11-22 00:14:59 +00:00
Roland McGrath
10d6808977 (start_job_command): Use `message' to print the command, and call it with
an empty string if the command is silent.
1995-11-22 00:06:28 +00:00
Roland McGrath
21fbad8602 (touch_file): Use message instead of printf. 1995-11-21 23:58:54 +00:00
Roland McGrath
fa6d6f9150 . 1995-11-17 20:03:48 +00:00
Roland McGrath
ed02723506 . 1995-10-10 20:22:47 +00:00
Roland McGrath
692858922f (How Make Works): Clearify that default goal is only first target. 1995-10-10 20:18:24 +00:00
Roland McGrath
9da3bccd89 . 1995-10-10 20:12:44 +00:00
Roland McGrath
16a5d4cf48 . 1995-10-10 20:07:10 +00:00
Roland McGrath
b1e6353edd (enter_command_line_file): Barf if NAME is "". 1995-10-10 18:59:08 +00:00
Roland McGrath
e1c593016b Add note wrt broken system makes--use build.sh. 1995-10-04 18:15:35 +00:00
Roland McGrath
10124ce95b . 1995-09-11 18:14:14 +00:00
Roland McGrath
6e19c6febb Updated from libc 1995-09-11 18:04:00 +00:00
Roland McGrath
4314e2f987 . 1995-09-09 10:45:06 +00:00
Roland McGrath
0eab889a28 (delete_target): Ignore unlink failure if it is ENOENT. 1995-09-09 10:32:56 +00:00
hag
c51dd24814 Updated ISBN and foundation address 1995-08-22 18:45:01 +00:00
hag
41ea0f1556 Updated address of foundation 1995-08-22 18:43:05 +00:00
Roland McGrath
ee6b27b728 Don't check for getdtablesize. 1995-08-17 19:09:57 +00:00
Roland McGrath
af72fc38fe (getdtablesize): Remove decls and macros. 1995-08-17 19:08:36 +00:00
Roland McGrath
294c429f93 (Standard Targets): rewrote some paragraphs to avoid overfull hboxes. 1995-08-15 00:12:12 +00:00
Roland McGrath
9409f5c54a Don't suggest sending questions to bug-gnu-utils.
Use @smallexample instead of @example to avoid overfull hbox.
1995-08-15 00:03:06 +00:00
Roland McGrath
78ac5bd9c7 (define_makeflags): Omit command line variable definitions from MFLAGS
value.
1995-08-10 23:58:12 +00:00
Roland McGrath
030d31ba93 Updated from libc 1995-08-10 23:29:54 +00:00
Roland McGrath
70465ffcfb (ar_scan) [AIAMAG]: Check for zero MEMBER_OFFSET, indicating a valid, but
empty, archive.
1995-08-10 23:09:46 +00:00
Roland McGrath
ee2b67af6d [ps2]: Use nlist instead of knlist #ifdef _AIX. 1995-08-07 20:48:08 +00:00
Roland McGrath
0afe62e255 (file_impossible_p): Correctly reset FILENAME to name within directory
before hash search.
1995-08-07 20:42:51 +00:00
Roland McGrath
ee14af651f (child_error): Do nothing if IGNORED under -s. 1995-08-07 20:37:15 +00:00
Roland McGrath
9fd3c2453b (exec_command): Correctly use ARGV[0] for script name when running shell
directly.
1995-08-07 19:39:37 +00:00
Roland McGrath
a4e66c61c0 (CFLAGS): Add some warnings. 1995-08-01 18:48:58 +00:00
Roland McGrath
8cfdca3e72 . 1995-08-01 18:48:11 +00:00
Roland McGrath
2c27d8dbdc (child_execute_job): Close STDIN_FD and STDOUT_FD after dup'ing from them.
Don't try to close all excess descriptors; getdtablesize might return
a huge value.  Any open descriptors in the parent should have FD_CLOEXEC
set.
1995-08-01 18:46:37 +00:00
Roland McGrath
d02b26a4b8 (start_job_command): Set FD_CLOEXEC flag on BAD_STDIN descriptor. 1995-08-01 18:38:49 +00:00
Roland McGrath
8b3f13f6ec (getloadavg): Set FD_CLOEXEC flag on /dev/kmem file descriptor. 1995-08-01 18:29:36 +00:00
David J. MacKenzie
e74b6ae5c2 Define mandir the way everyone actually uses it. 1995-06-27 18:28:56 +00:00
David J. MacKenzie
f21ec15ffa . 1995-06-23 02:57:42 +00:00
Roland McGrath
3f49392b9c [convex] (LOAD_AVE_TYPE, LDAV_CVT): Define to double, no conversion. 1995-06-20 07:50:41 +00:00
Roland McGrath
f9a914c035 (read_all_makefiles): Properly append default makefiles to the end of the
`read_makefiles' chain.
1995-06-20 07:47:01 +00:00
Roland McGrath
b2fc502c55 Regenerated for 3.74 1995-05-19 20:40:12 +00:00
Roland McGrath
d091a08961 . 1995-05-19 20:37:02 +00:00
Roland McGrath
eb3b7904f0 Regenerated 1995-05-10 21:59:24 +00:00
Roland McGrath
bbfb270092 Regenerated for 3.73.3 1995-05-10 21:58:53 +00:00
Roland McGrath
c18253b59b Updated from libc 1995-05-10 21:57:56 +00:00
Roland McGrath
41177916df . 1995-05-10 21:46:30 +00:00
Roland McGrath
7acd99c5e6 AIX support from Tim Bell <tbel@afsmail.cern.ch>:
[_AIX] (LOAD_AVE_TYPE, FSCALE, NLIST_STRUCT): Define these for AIX.
(getloadavg) [_AIX]: Use `knlist' instead of `nlist'.
1995-05-10 15:03:48 +00:00
Roland McGrath
d6c62b351f . 1995-05-09 22:51:11 +00:00
Roland McGrath
c9c43b0871 ($(infodir)/make.info): Make sure $$dir is set in install-info cmd. 1995-05-09 21:14:48 +00:00
Roland McGrath
13e8568f03 (print_file): Grok update_status of 1 for -q. 1995-05-03 19:53:19 +00:00
Roland McGrath
cebdba9dfa Move include of config.h before all others. 1995-04-29 19:47:58 +00:00
Roland McGrath
4ea152e71b Regenerated 1995-04-27 16:57:09 +00:00
Roland McGrath
443f39f4f7 Regenerated for 3.73.2 1995-04-27 16:56:40 +00:00
Roland McGrath
675981bc4f Updated from libc 1995-04-27 16:43:27 +00:00
Roland McGrath
11af972f87 . 1995-04-27 16:41:39 +00:00
Roland McGrath
d9c126da40 . 1995-04-27 16:41:12 +00:00
Roland McGrath
7170467928 . 1995-04-27 16:37:56 +00:00
Roland McGrath
81699266d3 (remove_intermediates): Fix inverted test to bail under -n for signal case.
Bail under -q or -t.
Skip files with update_status==-1.
1995-04-26 21:27:19 +00:00
Roland McGrath
cbdb3653da [HAVE_UNISTD_H]: Include unistd.h so it can declare sys_siglist. 1995-04-26 21:19:26 +00:00
Roland McGrath
5d82479d89 (job_next_command): Skip empty lines.
(new_job): Don't test the return of job_next_command.
Just let start_waiting_job handle the case of empty commands.
1995-04-26 21:15:25 +00:00
Roland McGrath
ed0d607279 . 1995-04-19 22:20:52 +00:00
Roland McGrath
855bd6896d [__MSDOS__]: Include <fcntl.h>. From DJ Delorie. 1995-04-19 18:09:30 +00:00
Roland McGrath
179ef370e8 Regenerated for 3.73.1 1995-04-19 07:29:56 +00:00
Roland McGrath
01dc9a22f9 Updated from libc 1995-04-19 07:28:27 +00:00
Roland McGrath
bc15ada5ed . 1995-04-19 07:26:32 +00:00
Roland McGrath
fce5e4a9b9 . 1995-04-08 18:54:00 +00:00
Roland McGrath
07a45cd0af (notice_finished_file): Set FILE->update_status to zero if it's -1. 1995-04-08 18:52:42 +00:00
Roland McGrath
226a132e31 (CPPFLAGS): Use $(defines) too. 1995-04-05 04:53:56 +00:00
Roland McGrath
b59f5f30b9 Regenerated for 3.73 1995-04-05 04:41:14 +00:00
Roland McGrath
acdd73ea34 . 1995-04-05 04:21:27 +00:00
Roland McGrath
38b5b27eb5 Add '95 to copyright years. 1995-04-05 03:32:21 +00:00
Roland McGrath
e8325b9be2 (Options/Recursion): Correction: -I is indeed passed in MAKEFLAGS. 1995-04-05 03:29:01 +00:00
Roland McGrath
f8eb0fc41b . 1995-03-30 10:02:35 +00:00
Roland McGrath
ea38e1fe78 (main): Fixed braino in assert. 1995-03-28 18:59:57 +00:00
Roland McGrath
ed276c008d Regenerated for 3.72.13 1995-03-28 18:28:18 +00:00
Roland McGrath
910d25619e (CPPFLAGS): Use $(CPPFLAGS) instead of $(defines). 1995-03-28 18:24:20 +00:00
Roland McGrath
2ae5430550 Remade with Autoconf 2.3 1995-03-28 18:04:30 +00:00
Roland McGrath
e53ac8a6fc . 1995-03-27 10:55:57 +00:00
Roland McGrath
cb51d55ab2 Avoid string in assert expression. Some systems are broken. 1995-03-27 10:28:35 +00:00
Roland McGrath
0b4723a689 . 1995-03-27 10:02:36 +00:00
Roland McGrath
3f9ce84b4a Include <assert.h>. 1995-03-24 23:39:24 +00:00
Roland McGrath
bdbe8501c6 (main): Handle 1 and 2 returns from update_goal_chain makefile run
properly.
1995-03-24 23:27:05 +00:00
Roland McGrath
3a12be3a73 autoheader 1995-03-24 07:30:46 +00:00
Roland McGrath
2346f99368 Regenerated for 3.72.12 1995-03-24 07:28:53 +00:00
Roland McGrath
d855846472 . 1995-03-24 07:27:44 +00:00
Roland McGrath
b9f7d21e42 Regenerated 1995-03-24 06:37:24 +00:00
Roland McGrath
db089ad3e3 . 1995-03-24 05:58:13 +00:00
Roland McGrath
1331cca1fa (handle_non_switch_argument): New function, broken out of decode_switches.
(decode_switches): Set optind to 0 to reinitialize getopt, not to 1.  When
getopt_long returns EOF, break the loop and handle remaining args with a
simple second loop.
1995-03-24 05:56:41 +00:00
Roland McGrath
fe05aaf7f2 (update_file_1): Handle FILE->update_status == 2 in -d printout. 1995-03-24 05:40:22 +00:00
Roland McGrath
cc35ff7381 (remake_file): Set update_status to 2 instead of 1 for no rule to make.
Mention parent (dependent) in error message.
1995-03-24 05:33:31 +00:00
Roland McGrath
a146085382 (start_job_command, reap_children): Set update_status to 2 instead of 1
for failed commands.
1995-03-24 05:32:12 +00:00
Roland McGrath
79fcb77ad1 (signame_init): Define SIGINFO. 1995-03-21 21:44:32 +00:00
Roland McGrath
3608635ec6 (search_path): Function removed (was already #if 0'd out). 1995-03-21 21:24:36 +00:00
Roland McGrath
ca53696814 Remove AC_TYPE_GETGROUPS; nothing needs it any more. 1995-03-21 21:23:26 +00:00
Roland McGrath
61dac07200 Updated from libc 1995-03-17 21:17:43 +00:00
Roland McGrath
9e42026e08 . 1995-03-17 21:16:34 +00:00
Roland McGrath
b52ea79ee6 Write @CPPFLAGS@ translation. 1995-03-17 20:57:17 +00:00
Roland McGrath
e483431569 . 1995-03-13 05:51:54 +00:00
Roland McGrath
28b622b8a1 (stamp-glob): Remove $(globfiles), not the whole glob directory. 1995-03-13 05:51:44 +00:00
Roland McGrath
cbfc50cb51 (parse_file_seq): Rearranged l(a b)' -> l(a) l(b)' loop to not
skip the elt immediately preceding `l(...'.
1995-03-13 05:45:44 +00:00
Roland McGrath
deb7cced6e Regenerated for 3.72.11 1995-03-10 20:36:06 +00:00
Roland McGrath
f9af56ac67 . 1995-03-10 20:36:06 +00:00
Roland McGrath
3ba2e947ac Changed find_char_unquote callers here too. 1995-03-10 20:34:41 +00:00
Roland McGrath
13d0eeb8e5 (find_char_unquote): Make second arg a string of stop chars instead of a
single stop char.  Stop when any char in the string is hit.
All callers changed.
(find_semicolon): Pass stop chars "#;" to one find_char_unquote call,
instead of using two calls.  If the match is not a ; but a #, return zero.
1995-03-10 20:33:40 +00:00
Roland McGrath
d9f063656b . 1995-03-10 19:08:28 +00:00
Roland McGrath
aceefb74da (read_makefile, parse_file_seq): Fix typo __MS_DOS__ -> __MSDOS__. 1995-03-10 19:07:26 +00:00
Roland McGrath
f38d98e988 Regenerated for 3.72.10 1995-03-10 19:00:29 +00:00
Roland McGrath
ff8ff73e65 . 1995-03-10 18:58:47 +00:00
Roland McGrath
8478b0c10a (globfiles): Add glob/configure.bat.
(distfiles): Add configh.dos, configure.bat.
1995-03-10 18:56:38 +00:00
Roland McGrath
1adf3a07dc (read_makefile, parse_file_seq) [__MS_DOS__]: Don't see : as separator in
"C:\...".
1995-03-09 01:42:12 +00:00
Roland McGrath
a5a27a893d (STDC_HEADERS): Define only if undefined.
(HAVE_SYS_PARAM_H): Don't define this.
(HAVE_STRERROR): Define this.
1995-03-09 01:13:02 +00:00
Roland McGrath
595f7598ae (construct_command_argv_internal) [__MSDOS__]: Fix typos. 1995-03-09 01:08:14 +00:00
Roland McGrath
8bc1a424e2 . 1995-03-08 18:21:45 +00:00
Roland McGrath
5e69859273 Regenerated 1995-03-08 18:18:03 +00:00
Roland McGrath
3a0f9ce0cb (decode_switches): Reset optind to 1 instead of 0. 1995-03-08 18:10:43 +00:00
Roland McGrath
3aabdf96a1 . 1995-03-08 18:09:30 +00:00
Roland McGrath
55b99d4151 Undo last change. Bad juju. 1995-03-08 18:08:00 +00:00
Roland McGrath
f3699ad75f (configure, config.h.in): Depend on aclocal.m4. Commit files to CVS. 1995-03-08 18:06:59 +00:00
Roland McGrath
0af0c8dba0 . 1995-03-08 00:13:28 +00:00
Roland McGrath
1280ee49bb (configure, config.h.in): Uncomment these rules.
Commit the files to CVS if there is a CVS directory.
1995-03-08 00:11:27 +00:00
Roland McGrath
8fc1187283 Do CVS magic, not RCS magic. 1995-03-08 00:10:10 +00:00
Roland McGrath
e8dcf11ae0 . 1995-03-07 23:49:08 +00:00
Roland McGrath
ce40d6af9f . 1995-03-07 23:44:43 +00:00
Roland McGrath
636435e5c2 (decode_switches): If non-option arg is "-", ignore it. 1995-03-07 22:31:01 +00:00
Roland McGrath
0733d6947d (strsignal): Cast sys_siglist elt to char *. 1995-03-07 06:41:05 +00:00
Roland McGrath
b91d62feb3 [! __STDC__]: Don't use prototype for strsignal decl. 1995-02-23 23:42:12 +00:00
Roland McGrath
f6d5cdba19 (main): Pass missing arg to tmpnam. 1995-02-22 03:19:53 +00:00
Roland McGrath
fcb29e5e96 Check for strsignal. 1995-02-22 03:18:18 +00:00
Roland McGrath
d7a043b46c (child_error): Use strsignal. 1995-02-22 03:17:54 +00:00
Roland McGrath
d85ab5953a (main): Don't call signame_init #ifdef HAVE_STRSIGNAL. 1995-02-22 03:17:22 +00:00
Roland McGrath
93dd485ab6 (strsignal): Declare it. 1995-02-22 03:15:51 +00:00
Roland McGrath
5c350f4fd5 [! HAVE_STRSIGNAL] (strsignal): New function. 1995-02-22 03:13:12 +00:00
Roland McGrath
514c4bac33 (strerror): Fix swapped args in sprintf. 1995-02-22 03:10:16 +00:00
Roland McGrath
8f24715a10 (CFLAGS, LDFLAGS): Don't set these variables. 1995-02-13 16:50:03 +00:00
Roland McGrath
4c7f18cd09 (print_version): Add 95 to copyright years. 1995-02-11 01:39:58 +00:00
Roland McGrath
c5af4810ff (start_job_command): Remember to call notice_finsihed_file under -n when
not recursing.  To do this, consolidate that code under the empty command
case and goto there for the -n case.
1995-02-10 23:44:03 +00:00
Richard M. Stallman
551c4322cb real-clean renamed to maintainer-clean.
Description changed too.
1995-02-07 23:45:48 +00:00
Roland McGrath
e33c50b1e2 [! STDC_HEADERS]: Don't declare qsort. Sun headers declare it int. 1995-02-07 18:36:00 +00:00
Roland McGrath
bc1e6b66f1 (read_makefile): For bogus line starting with tab, ignore it if blank after
removing comments.
1995-02-06 22:58:07 +00:00
Roland McGrath
bbd5e695f5 Cast results of alloca' to char *'. 1995-02-06 22:37:36 +00:00
Roland McGrath
f3cfccf0b8 Cast results of alloca' to char *' in two places. 1995-02-06 22:36:43 +00:00
Roland McGrath
016e1beef5 Check for mktemp. 1995-02-05 23:50:12 +00:00
Roland McGrath
21a8ec0d72 (main) [! HAVE_MKTEMP]: Use tmpnam instead of mktemp. 1995-02-05 23:49:40 +00:00
Roland McGrath
fecd9e661a (make_cv_sysconf_open_max): New check for `sysconf (_SC_OPEN_MAX)'. 1995-02-05 23:45:49 +00:00
Roland McGrath
2914c705e5 Added #undef HAVE_SYSCONF_OPEN_MAX. 1995-02-05 23:36:04 +00:00
Roland McGrath
3f506aaf90 [HAVE_SYSCONF_OPEN_MAX] (getdtablesize): Define as macro using sysconf. 1995-02-05 23:35:39 +00:00
Roland McGrath
75ea6c3ce2 (update_file_1): When !MUST_MAKE, don't set FILE->update_status to zero
before calling notice_finished_file.
(notice_finished_file): Touch only when FILE->update_status is zero.
(remake_file): Set FILE->update_status to zero after not calling
execute_file_command and deciding to touch instead.
1995-01-27 09:42:00 +00:00
Roland McGrath
3fb9ebf83f (debug_signal_handler): New function; toggles debug_flag.
(main): Handle SIGUSR1 with that.
1995-01-26 06:29:18 +00:00
Roland McGrath
b4890bdb1c (realclean): Remove Info files. 1995-01-16 20:46:50 +00:00
Roland McGrath
2cbfa1024a (variable_expand): Fix braino in last change. 1995-01-15 16:33:35 +00:00
Roland McGrath
258dad0f9a Fix nits in last change. 1995-01-15 16:32:10 +00:00
Roland McGrath
37358a9a82 (start_job_command): Save and restore environ around vfork call.
(search_path): Function #if 0'd out.
(exec_command): Use execvp instead of search_path.
1995-01-15 15:57:48 +00:00
Roland McGrath
e167e0a3c2 (variable_expand): Rewrote computed variable name and substitution
reference handling to be simpler.  First expand the entire text between the
parens if it contains any $s, then examine the result of that for
subtitution references and do no further expansion while parsing them.
1995-01-15 15:32:37 +00:00
Roland McGrath
7879457545 (construct_command_argv_internal): Handle " quoting too, when no
backslash, $ or ` characters appear inside the quotes.
1995-01-15 13:43:48 +00:00
Roland McGrath
d525f4dd72 (union wait check): If WEXITSTATUS and WTERMSIG are defined, just use int. 1995-01-15 13:23:03 +00:00
Roland McGrath
bd19554ea7 (Foreach Function): Correccion de gramatica espanola. 1995-01-13 06:30:39 +00:00
Roland McGrath
fffc384bfc (default_variables) [__hpux]: Remove special definition of ARFLAGS.
Existence of the `f' flag is not consistent across HPUX versions;
and one might be using GNU ar anyway.
1995-01-11 00:14:53 +00:00
Roland McGrath
afd1d69e7d (clean): Don't remove Info files. 1995-01-10 11:30:56 +00:00
Roland McGrath
c1305a1a18 ($(bindir)/make): Fix typo in echo. 1995-01-10 11:29:08 +00:00
Roland McGrath
43d5fbfc88 Fix typo in comment. 1995-01-10 11:28:12 +00:00
Roland McGrath
a4642a6a57 (check): Remove gratuitous target declaration. 1995-01-10 11:27:24 +00:00
Roland McGrath
11ca7f1ead (ETAGS, CTAGS): Don't use -t. 1995-01-07 16:59:15 +00:00
Roland McGrath
4aa992616f Include config.h first. 1995-01-07 16:57:36 +00:00
Roland McGrath
ab0fb2fa6f (ar_name_equal) [cray]: Subtract 1 like [__hpux]. 1995-01-07 16:55:30 +00:00
Roland McGrath
e1dd3bfa4a (decode_switches): For --help, print usage to stdout. 1995-01-07 16:38:08 +00:00
Richard M. Stallman
86238ec9d3 install, uninstall, installdirs should not alter the build dir. 1995-01-04 19:37:36 +00:00
Roland McGrath
2e9779fdb4 (update_file_1): Do set_command_state (FILE, cs_not_started) only if old
state was deps_running.
1994-12-05 17:42:13 +00:00
Roland McGrath
b61a13463d (start_waiting_job): Use set_command_state. 1994-11-29 01:10:47 +00:00
Roland McGrath
d3b9c35c8f (CPPFLAGS): New variable.
(prefix, exec_prefix): Set from @...@.
(compilation loop): Pass $CPPFLAGS to compiler.
1994-11-28 23:06:28 +00:00
Roland McGrath
c50b75b439 (build.sh.in): Make it executable. 1994-11-28 23:02:42 +00:00
Roland McGrath
7376280c33 (globfiles): Add configure.in, configure. 1994-11-28 22:02:23 +00:00
Roland McGrath
3c767901f6 (make-$(version).tar): Rename install.sh to install-sh. 1994-11-28 20:54:38 +00:00
Roland McGrath
c6dfff5f1b (prefix, exec_prefix): Set.
(CPPFLAGS): Filter out @...@.
($(ARCH)/glob/libglob.a): Don't pass down variables.
1994-11-28 20:51:40 +00:00
Roland McGrath
74540a1e91 Abbreviate copyright years. 1994-11-28 20:50:45 +00:00
Roland McGrath
5159db0aa4 (AC_OUTPUT): Don't write glob/Makefile. 1994-11-28 20:48:43 +00:00
Roland McGrath
e495d2380d (AC_CHECK_SYMBOL): Use AC_DEFINE_UNQUOTED. 1994-11-28 20:28:26 +00:00
Roland McGrath
1ed34a0118 Don't check for ranlib. 1994-11-28 20:20:43 +00:00
Roland McGrath
e8f64b2c88 (notice_finished_file): Only mark also_make's as updated if really ran
cmds.
1994-11-23 03:42:34 +00:00
Roland McGrath
4867409da2 Put dnls before random whitespace. 1994-11-15 11:32:39 +00:00
Roland McGrath
f801fc3521 (CPPFLAGS): New variable, set from @CPPFLAGS@.
(RANLIB): Variable removed.
(prefix, exec_prefix): Set these from @...@.
(.c.o): Use $(CPPFLAGS).
(glob/libglob.a): Don't pass down variables to sub-make.
glob/Makefile should be configured properly by configure.
(distclean): Remove config.log and config.cache (autoconf stuff).
1994-11-13 10:02:19 +00:00
David J. MacKenzie
b2c0446e71 Explain reason for new filesystem layout. 1994-11-11 04:33:24 +00:00
Roland McGrath
8f98ceb724 Add #undef HAVE_UNION_WAIT. 1994-11-08 02:09:49 +00:00
Roland McGrath
dea9990bc8 Converted to Autoconf v2. 1994-11-08 02:08:24 +00:00
Roland McGrath
e4c43aab3e Test HAVE_DIRENT_H, HAVE_SYS_DIR_H, HAVE_NDIR_H instead of DIRENT, SYSDIR,
NDIR.
1994-11-08 00:14:50 +00:00
Roland McGrath
e55ed78080 (prefix, exec_prefix): Set these from @...@.
(CPPFLAGS): New variable, set from @CPPFLAGS@.
(compiling loop): Pass $CPPFLAGS before $CFLAGS.
1994-11-07 23:42:58 +00:00
Roland McGrath
ca54a0b991 Initial revision 1994-11-07 23:40:44 +00:00
Roland McGrath
e25e2fb7f5 (define_makeflags): When no flags, set WORDS to zero. 1994-11-07 18:57:56 +00:00
Roland McGrath
1a886b6359 (define_makeflags): Terminate properly when FLAGSTRING is empty. 1994-11-06 23:33:55 +00:00
Roland McGrath
b511712f25 (rcs-mark-{alpha,beta}): Let make do the globbing instead of sh. 1994-11-04 21:08:52 +00:00
Roland McGrath
30fcca501f Remove `DRAFT' from edition. 1994-11-04 20:23:23 +00:00
Roland McGrath
806dc4f7c4 (Variables/Recursion): Fix typo. 1994-11-01 08:40:19 +00:00
Roland McGrath
c0163410d2 (start_job_command): When ARGV is nil, only set update_state and call
notice_finished_file if job_next_command returns zero.
1994-11-01 08:34:10 +00:00
Roland McGrath
eac1e9ee66 Doc .DELETE_ON_ERROR.
Doc new MAKEFLAGS/MAKEOVERRIDES.
Doc .IGNORE/.SILENT with deps.
1994-11-01 08:29:31 +00:00
Roland McGrath
8ad5af7c28 (start_job_command): Call notice_finished_file for empty command line. 1994-11-01 06:18:07 +00:00
Roland McGrath
857d7ad256 (snap_deps): Set COMMANDS_SILENT for .SILENT, not COMMANDS_NOERROR. 1994-10-27 06:02:43 +00:00
Roland McGrath
612a29e0dd [alliant && i860] (FSCALE): Move defn before #ifndef FSCALE. 1994-10-27 00:34:56 +00:00
Roland McGrath
462304918c (snap_deps): Set command_flags bits in all :: entries. 1994-10-26 02:49:21 +00:00
Roland McGrath
9d36c92adb (snap_deps): Fix last change. 1994-10-24 23:44:16 +00:00
Roland McGrath
640c4ecd99 (posix_pedantic): Declare it. 1994-10-24 23:11:57 +00:00
Roland McGrath
07f09cfd88 (main): Move checks .IGNORE, .SILENT, .POSIX to snap_deps. 1994-10-24 22:57:07 +00:00
Roland McGrath
d37c9ba18a (snap_deps): Check .IGNORE, .SILENT, .POSIX here instead of in main.
If .IGNORE has deps, OR COMMANDS_NOERROR into their command_flags and
don't set -i.  Likewise .SILENT.
1994-10-24 22:56:27 +00:00
Roland McGrath
cc8d6cf343 (start_job_command): In FLAGS initialization, OR in
CHILD->file->command_flags.
1994-10-24 22:50:01 +00:00
Roland McGrath
4b17f0982b (struct file): New member `command_flags'. 1994-10-24 22:47:43 +00:00
Roland McGrath
dc576b2051 (Automatic Dependencies): Improve recommended sed command.
Mention -MM flag to gcc.
1994-10-24 05:05:43 +00:00
Roland McGrath
a543a2ae9f (Commands): Add warning about "blank" line starting with a tab. 1994-10-17 00:02:27 +00:00
Roland McGrath
0e352e4bf7 (switches): Bump flag values for --no-print-directory and
--warn-undefined-variables, so neither is 1 (which indicates a nonoption
argument).
1994-10-16 05:01:46 +00:00
Roland McGrath
3f8bde0f25 (main): Add missing code in .IGNORE test. 1994-10-16 03:39:35 +00:00
Roland McGrath
4308542cb1 Document $+ and $(+D), $(+F). 1994-10-10 08:10:13 +00:00
Roland McGrath
e622fcf22e (define_automatic_variables): Define +D and +F. 1994-10-10 08:08:58 +00:00
Roland McGrath
1766b7fa59 (main): Define hidden automatic variable with command vars, and
MAKEOVERRIDES to a reference to that.
(define_makeflags): If posix_pedantic, write a reference to that instead.
1994-10-01 08:07:35 +00:00
Roland McGrath
fa999783d7 (posix_pedantic): New variable.
(main): Set posix_pedantic if .POSIX is a target.
Fix .IGNORE and .SILENT hecks to require is_target.
1994-09-30 01:04:54 +00:00
Roland McGrath
e97d6632b5 Comment fix. 1994-09-29 19:52:49 +00:00
Roland McGrath
e3d013a79a (set_file_variables): Define new automatic variable $+, like $^ but before
calling uniquize_deps.
1994-09-29 08:23:25 +00:00
Roland McGrath
9807a2869f (reap_children): Call delete_child_targets for non-signal error if
.DELETE_ON_ERROR is a target.
1994-09-29 04:14:20 +00:00
Roland McGrath
e9521d3447 [alliant && i860] (LOAD_AVE_TYPE, FSCALE, NLIST_STRUCT): Define. 1994-09-28 21:00:06 +00:00
Roland McGrath
c62ca42327 (reap_children): Don't change C->file->command_state when dying.
Test it only after calling start_job_command for a new command line.
When no more cmds, just set C->file->update_status.
(start_job_command): When the last line is empty or under -n, set
C->file->update_status.
(start_waiting_job): Grok cs_not_started after start_job_command as success.
(new_job): Set C->file->update_status when there are no cmds.
(job_next_command): When out of lines, don't set CHILD->file->update_status or
CHILD->file->command_state.
1994-09-26 23:02:40 +00:00
Roland McGrath
2feb36f620 (quote_as_word): Actually test DOUBLE_DOLLARS, instead of always doubling. 1994-09-26 22:45:08 +00:00
Roland McGrath
f40918e005 (quote_as_word): Renamed from shell_quote.
Take new arg; if nonzero, also double $s.
(main): Define MAKEOVERRIDES from command_variables here.
(define_makeflags): Don't use command_variables here; instead write a
reference $(MAKEOVERRIDES) in MAKEFLAGS.  Make vars recursive.
1994-09-26 22:37:10 +00:00
Roland McGrath
b13a443fa7 [__MSDOS__]: Fixed typo. 1994-09-26 22:20:56 +00:00
Roland McGrath
e938a511be (selective_vpath_search): Reset EXISTS when stat fails. 1994-09-26 22:16:51 +00:00
David J. MacKenzie
a96d572aa6 remove CONFIG_BROKETS 1994-09-26 21:57:54 +00:00
David J. MacKenzie
990c39d973 REMOVE CONFIG_BROKETS 1994-09-26 21:56:21 +00:00
David J. MacKenzie
24d37fb493 remove CONFIG_BROKETS 1994-09-26 21:52:40 +00:00
Richard M. Stallman
c1e20276cb (getloadavg): Add OSF_ALPHA support. 1994-09-17 00:16:57 +00:00
Roland McGrath
9f71eaf6b5 Include <assert.h> and use assert instead of printfs and abort. 1994-09-10 15:04:57 +00:00
Roland McGrath
03cd08cca2 (decode_switches): Loop until optind hits ARGC, not just until getopt_long
returns EOF.  Initialize C to zero before loop; in loop if C is EOF, set
optarg from ARGV[optind++], else call getopt_long.
(decode_env_switches): Use variable_expand instead of
allocated_variable_expand.  Allocate a fresh buffer to copy split words
into; scan characters by hand to break words and debackslashify.
(shell_quote): New function.
(define_makeflags): Allocate doubled space for switch args, and command
variable names and values; use shell_quote to quote those things.
1994-09-10 07:01:10 +00:00
Roland McGrath
dc44a79020 Add HAVE_SYS_SIGLIST and HAVE__SYS_SIGLIST. 1994-09-09 07:16:54 +00:00
Roland McGrath
8ed6e13cfe (Archive Suffix Rules): Remove Next pointer. 1994-09-09 06:59:08 +00:00
Roland McGrath
b321e0f535 (decode_switches): The non-option return from getopt is 1, not 0.
(command_variables): New type and variable.
(decode_switches, decode_env_switches): After making a variable definition,
record the struct variable pointer in the command_variables chain.
(define_makeflags): If ALL, write variable definitions for
command_variables.
1994-09-09 06:45:51 +00:00
Roland McGrath
c1433e9495 (other_args): Variable removed.
(goals, lastgoal): New static variables (moved from auto in main).
(main): Don't process OTHER_ARGS at all.
Don't set variable MAKEOVERRIDES at all; define MAKE to just $(MAKE_COMMAND).
(init_switches): Prepend a - (return in order) instead of a + (require order).
(decode_switches): Don't set OTHER_ARGS at all.
Grok '\0' return from getopt_long as non-option argument; try variable
definition and (if !ENV) enter goal targets here.
(decode_env_switches): Use allocated_variable_expand to store value.
Use find_next_token to simplify word-splitting loop.
Don't prepend a dash to uninterpreted value.
Instead, if split into only one word, try variable definition and failing
that prepend a dash to the word and pass it to decode_switches as a single arg.
1994-09-09 05:37:40 +00:00
Roland McGrath
e4a94e0210 (notice_finished_file): Only recheck modtimes if FILE->command_state was
cs_running on entry (meaning the commands actually just ran).
(update_file_1): Whenever we set FILE->update_status, call
notice_finished_file instead of just set_command_state.
1994-09-07 07:06:46 +00:00
Roland McGrath
9e97330bcb (start_job_command): Whenever we set CHILD->file->update_status, call
notice_finished_file instead of just set_command_state.
1994-09-07 07:02:23 +00:00
Roland McGrath
4969b416b8 (set_command_state): Actually set FILE->command_state. 1994-09-07 00:31:13 +00:00
Roland McGrath
0bd0301ae3 (set_command_state): Fix typo. 1994-09-07 00:24:10 +00:00
Roland McGrath
ff6efbadf5 (set_command_state): Declare D. 1994-09-07 00:17:57 +00:00
Roland McGrath
0b3317d2e1 Add missing ". 1994-09-07 00:15:23 +00:00
Roland McGrath
ca5a872280 Changed all assignments of command_state members to calls to
set_command_state.
1994-09-07 00:04:49 +00:00
Roland McGrath
4244f182f2 (set_command_state): New function. 1994-09-07 00:02:25 +00:00
Roland McGrath
be6e6d74bb Declare set_command_state. 1994-09-06 23:48:36 +00:00
Roland McGrath
4c0fef3dd7 (init_switches): Put a + first in options. 1994-09-06 23:13:43 +00:00
Richard M. Stallman
d3b65c3cb7 entered into RCS 1994-08-21 17:29:57 +00:00
gnu
bc48185f8e Formerly make-stds.texi.~29~ 1994-08-10 05:41:00 +00:00
Roland McGrath
6fcf219fa7 Initial revision 1994-07-25 23:47:05 +00:00
Roland McGrath
d2e23eefd2 Added trailing CRs. 1994-07-25 23:46:16 +00:00
Roland McGrath
55162a6730 Changed all uses of ':' to PATH_SEPARATOR_CHAR. 1994-07-25 23:34:32 +00:00
Roland McGrath
021ea7e61c (directory_before_chdir): New variable, moved out of main (was local).
(main) [__MSDOS__]: Look for \ or : to delimit last component of PROGRAM.
Don't frob ARGV[0] before setting MAKE_COMMAND variable.
(die): Change back to `directory_before_chdir' before dying.

Part of MSDOS/GO32 port from DJ Delorie <dj@ctron.com>.
1994-07-25 23:33:26 +00:00
Roland McGrath
f663464925 (PATH_SEPARATOR_CHAR): Macro removed (now in make.h). 1994-07-25 23:28:08 +00:00
Roland McGrath
5d435e0859 (PATH_SEPARATOR_CHAR): New macro; differing defns for [__MSDOS__] and not. 1994-07-25 23:27:48 +00:00
Roland McGrath
a2ab31ba62 [__MSDOS__]: Include <process.h>.
(PATH_SEPARATOR_CHAR): New macro; differing defns for [__MSDOS__] and not.
[__MSDOS__] (dos_pid, dos_status, dos_bname, dos_bename, dos_batch_file):
New variables.
(reap_children) [__MSDOS__]: Don't call wait; just examine those vars.
(unblock_sigs) [__MSDOS__]: Do nothing.
(start_job_command) [__MSDOS__]: Use spawnvpe instead of vfork and exec.
(load_too_high) [__MSDOS__]: Always return true.
(search_path) [__MSDOS__]: Check for : or / in FILE to punt.
Use PATH_SEPARATOR_CHAR instead of ':'.
(construct_command_argv_internal) [__MSDOS__]: Wholly different values for
sh_chars and sh_cmds.  Wholly new code to handle shell scripts.

Part of MSDOS/GO32 port from DJ Delorie <dj@ctron.com>.
1994-07-25 23:23:03 +00:00
Roland McGrath
da2ea1ea7f (expand_function: `shell') [__MSDOS__]: Wholly new implementation. 1994-07-25 23:06:00 +00:00
Roland McGrath
21a1b3b255 [__MSDOS__] (dosify): New function.
(dir_contents_file_exists_p) [__MSDOS__]: Call it on FILENAME and process
the result instead of FILENAME itself.
(file_impossible_p) [__MSDOS__]: Likewise.
Part of MSDOS/GO32 port from DJ Delorie <dj@ctron.com>.
1994-07-25 23:01:19 +00:00
Roland McGrath
c8e76a708e [__MSDOS__]: Define GCC_IS_NATIVE.
(default_suffix_rules) [__MSDOS__]: Use `y_tab.c' instead of `y.tab.c'.
(default_variables) [GCC_IS_NATIVE]: Set CC and CXX to `gcc', YACC to
`bison -y', and LEX to `flex'.
Part of MSDOS/GO32 port from DJ Delorie <dj@ctron.com>.
1994-07-25 22:54:09 +00:00
Roland McGrath
461cffc4e9 Initial revision 1994-07-25 22:48:06 +00:00
Roland McGrath
cdd25d1fb3 (fatal_error_signal) [__MSDOS__]: Just remove intermediates and exit.
Part of MSDOS/GO32 port from DJ Delorie <dj@ctron.com>.
1994-07-25 22:47:14 +00:00
Roland McGrath
9a3666d550 (set_file_variables): Add parens in length computation in .SUFFIXES dep
loop to quiet compiler warning.  From Jim Meyering.
1994-07-25 22:09:25 +00:00
Roland McGrath
90dffad2cc (read_makefile): Free FILENAME if we allocated it. From Jim Meyering. 1994-07-25 22:07:41 +00:00
Roland McGrath
c1f2ef6d09 Update ISBN number to 1-882114-50-7 for edition 0.46.
Use new macro ISBN set at top of file.
1994-07-20 12:30:52 +00:00
Roland McGrath
51250a676d Split a shell command line in @example to avoid overfull hbox. 1994-07-08 18:33:15 +00:00
Roland McGrath
d2461a2409 (Goals): Say that only first target in first rule is default goal.
(Archive Pitfalls): New node.
1994-07-05 21:27:09 +00:00
Roland McGrath
fdea69c5fa (selective_vpath_search): Use safe_stat in place of stat. 1994-07-04 21:56:24 +00:00
Roland McGrath
7c7552336d (construct_include_path): Use safe_stat in place of stat. 1994-07-04 21:55:13 +00:00
Roland McGrath
535dcf6a22 (search_path): Use safe_stat in place of stat. 1994-07-04 21:54:18 +00:00
Roland McGrath
84091971f9 (find_directory): Use safe_stat in place of stat. 1994-07-04 21:53:25 +00:00
Roland McGrath
61da194af9 (delete_target): Use safe_stat in place of stat. 1994-07-04 21:52:28 +00:00
Roland McGrath
30c1465265 (ar_member_touch) [EINTR]: Do EINTR looping around fstat. 1994-07-04 21:51:49 +00:00
Roland McGrath
b574b8ea5a (name_mtime): Use safe_stat in place of stat.
(touch_file) [EINTR]: Do EINTR looping around fstat.
1994-07-04 21:50:03 +00:00
Roland McGrath
710e8e6f6f (safe_stat): New function, EINTR-safe wrapper around stat. 1994-07-04 21:46:58 +00:00
Roland McGrath
4a8a7637f3 (read_makefile): Check for a shell command first, and then strip leading
tabs before further checking if it's not a shell command line.
1994-06-24 10:34:03 +00:00
Roland McGrath
6348923799 Fix typo in last change. 1994-06-24 10:22:37 +00:00
Roland McGrath
660a23d649 [__arm]: Undefine POSIX.
[!__GNU_LIBRARY__ && !POSIX && !_POSIX_VERSION]: Don't declare system
functions that return int.
1994-06-24 09:45:35 +00:00
Roland McGrath
5bd9836fba (construct_command_argv_internal): After swallowing a backslash-newline
combination, if INSTRING is set goto string_char (new label) for normal
INSTRING handling code.
1994-06-24 09:40:13 +00:00
Roland McGrath
0cb47363e1 Put #include of errno.h and decl of errno before #ifndef HAVE_GETLOADAVG. 1994-06-04 05:24:48 +00:00
Roland McGrath
fff5a9ece0 Don't check for sys_siglist and _sys_siglist with AC_HAVE_FUNCS.
Instead use two AC_COMPILE_CHECKs.
1994-06-04 05:11:12 +00:00
Richard M. Stallman
e3a24fc596 [emacs]: Block input around the garbage reclamation.
Include blockinput.h.
1994-06-02 17:45:40 +00:00
Roland McGrath
bb38b0c253 [!__GNU_LIBRARY__ && !POSIX]: Also test #ifndef _POSIX_VERSION for these
declarations.
1994-05-23 22:25:30 +00:00
Roland McGrath
d2ed03e72a [GETLOADAVG_PRIVILEGED] [POSIX]: Remove bogus #ifndefs around #undefs of
HAVE_SETREUID and HAVE_SETREGID.
1994-05-23 22:20:30 +00:00
Roland McGrath
e72213687f [GETLOADAVG_PRIVILEGED] [POSIX]: Don't test [HAVE_SETUID] and [HAVE_SETGID].
Every system has those, and configure doesn't check for them.
1994-05-21 20:28:10 +00:00
Roland McGrath
491d66a916 [_POSIX_VERSION]: Don't #define POSIX #ifdef ultrix. 1994-05-21 20:27:18 +00:00
Roland McGrath
f4fb1be3d8 (loadavg): Depend on and use loadavg.c instead of getloadavg.c.
(loadavg.c): Link or copy it from getloadavg.c.
(distclean): Remove loadavg.c.
1994-05-21 20:26:33 +00:00
Roland McGrath
10abeb4a08 (AC_MACRODIR): Don't define it.
[AC_MACRODIR]: Protect deps using it with ifdef.
1994-05-19 00:35:53 +00:00
Roland McGrath
a369402d11 Correct update date updated in last change. 1994-05-17 03:50:09 +00:00
Roland McGrath
fe3962cf54 Update update date for last change. 1994-05-17 03:46:27 +00:00
Roland McGrath
cf76b42f2b [GETLOADAVG_PRIVILEGED] [! POSIX]: Undefine HAVE_SETEUID and HAVE_SETEGID. 1994-05-17 03:09:02 +00:00
Roland McGrath
fb088e4526 (SCCS_GET_MINUS_G check): Put -G flag before file name. 1994-05-17 02:59:57 +00:00
Roland McGrath
f2804372bd (default_terminal_rules): In SCCS rules, put $(SCCS_OUTPUT_OPTION) before
$<.  On some systems -G is grokked only before the file name.
1994-05-17 02:58:49 +00:00
Roland McGrath
c25db14264 (Overriding Makefiles): Don't suggest using .DEFAULT; that loses if the
target file exists.  Instead recommend the combination of a match-anything
rule and a force target.
1994-05-11 01:42:43 +00:00
Roland McGrath
e83c7d40cd (construct_command_argv_internal): Swallow backslash-newline combinations
inside '' strings too.
1994-05-10 20:27:17 +00:00
Roland McGrath
65d0cd98a9 (do_define): Call collapse_continuations on each line before all else. 1994-05-05 08:15:00 +00:00
Roland McGrath
ec505152e0 (AC_MACRODIR): Change default back. 1994-05-02 23:45:18 +00:00
Roland McGrath
0d2488a804 Note that dirs in VPATH, vpath can be separated by blanks as well as
colons.
1994-05-02 23:00:39 +00:00
Roland McGrath
bc5f054132 (config.h.in): Use $(AC_MACRODIR) in dep. 1994-05-02 22:32:54 +00:00
Roland McGrath
e812d40f9f (AC_MACRODIR): Define if undefined.
(ACFLAGS, configure, config.h.in): Use that value.
1994-05-02 22:29:56 +00:00
Roland McGrath
b12c639bb2 (ARCH==hp300): Disabled customs. 1994-04-25 23:37:12 +00:00
Roland McGrath
dd841ded6f (construct_command_argv_internal): Notice newline inside '' string when
RESTP is non-null.
1994-04-25 23:31:55 +00:00
Roland McGrath
3c9e8b266a (update_goal_chain): Reset FILE to G->file after the double-colon loop so
it is never null for following code.
1994-04-22 21:58:26 +00:00
Roland McGrath
e6bce5ef88 (read_makefile): Fix `override define' parsing to skip whitespace after
`define' properly.
1994-04-22 21:57:47 +00:00
Roland McGrath
bdff21b09a (srcdir): Define as @srcdir@; don't reference $(VPATH).
(glob/Makefile): New target.
1994-04-22 21:33:25 +00:00
Roland McGrath
408e868fd2 (Using Variables): Fixed @xref node to `Automatic'. 1994-04-21 22:39:51 +00:00
Roland McGrath
cf63c0c966 (dist): Depend on rcs-mark first.
(rcs-mark): New target.
(rcs-mark-alpha, rcs-mark-beta): Use $(version-); append : to name for -N.
(version-): New variable, removes dots (RCS doesn't like) from $(version).
1994-04-21 22:35:15 +00:00
Roland McGrath
d2e496cc01 (Using Variables): Fix menu item to `Automatic'. 1994-04-21 22:23:37 +00:00
Roland McGrath
ac336f7a9c Undo last change; reverted to revision 1.22. 1994-04-21 22:14:01 +00:00
Roland McGrath
8f581d3bc0 (parse_file_seq): Fix typo in last change. Remove unused variable. 1994-04-21 21:28:59 +00:00
Roland McGrath
b2522ec319 (chop_commands): Fix braino in last change (failed to initialize IDX for
loop).
1994-04-21 21:28:02 +00:00
Roland McGrath
117d4e0f36 (remove_comments): Use find_char_unquote. 1994-04-21 21:18:04 +00:00
Roland McGrath
9b0a99a051 (find_char_unquote): Declare it. 1994-04-21 20:37:39 +00:00
Roland McGrath
5c807f5457 (find_char_unquote): New function, generalized from find_percent.
(find_percent, find_semicolon, parse_file_seq): Use that.
1994-04-21 20:36:47 +00:00
Roland McGrath
7eeab2fbe1 (chop_commands): Use find_char_unquote to find newlines. 1994-04-21 20:16:42 +00:00
Roland McGrath
f6716d5e74 (pattern_search): Always allocate new storage for FILE->stem.
It is not safe to store STEM's address because it might be auto storage.
1994-04-21 03:48:00 +00:00
Roland McGrath
be451f6d29 Check for seteuid and setegid. 1994-04-21 02:41:56 +00:00
Roland McGrath
eb0dbf1993 [HAVE_SETEUID]: Declare seteuid.
[HAVE_SETEGID]: Declare setegid.
(make_access, user_access) [HAVE_SETEUID]: Use seteuid.
[HAVE_SETEGID]: Use setegid.
1994-04-21 02:41:36 +00:00
Roland McGrath
5ebd380d7a Clarify -q exit status.
(Running): Enumerate possible exit status values (0, 1, 2).
1994-04-21 02:33:10 +00:00
Roland McGrath
cbfe6d75f6 (update_goal_chain): Set STATUS to FILE->update_status, to preserve whether
it's 2 for error or 1 for -q trigger.  When STATUS gets nonzero and -q is
set, always stop immediately.
1994-04-21 02:15:37 +00:00
Roland McGrath
716e804b5b (main, decode_switches): Die with 2 for errors.
(main): Accept 2 return from update_goal_chain and die with that.
1994-04-21 02:08:28 +00:00
Roland McGrath
4848c19870 (fatal, makefile_fatal): Die with 2; 1 is reserved for -q answer. 1994-04-21 02:01:24 +00:00
Roland McGrath
bca4e882ba (reap_children): Die with 2 for error.
(start_job_command): Set update_status to 2 for error.  Set it to 1 when we
would run a command and question_flag is set.
1994-04-21 02:00:20 +00:00
Roland McGrath
eb08818828 (read_makefile): Don't mark makefiles as precious. Just like other
targets, they can be left inconsistent and in need of remaking by aborted
commands.
1994-04-21 01:39:36 +00:00
Roland McGrath
b86e35d2a6 (Automatic Dependencies): Mention here that deps preclude intermediate files. 1994-04-21 01:35:11 +00:00
Roland McGrath
f5b14eee67 (Wildcard Pitfall): Fixed typo. 1994-04-21 01:21:39 +00:00
Roland McGrath
118439508b (Bugs): Take my bloody e-mail address out of the manual and tell them to
send misc. questions to the bug address.
1994-04-21 00:59:00 +00:00
Roland McGrath
f875c95115 (Archive Members): Don't say archive file must exist. Instead, in ar cmds
example, use `c' flag and mention it is needed if archive doesn't exist.
(Archive Update): Fix typo: foo.o -> file.o.
1994-04-21 00:55:18 +00:00
Roland McGrath
f2c10dedf0 (read_makefile): Write no error msg for -include file. 1994-04-20 22:42:32 +00:00
Roland McGrath
37c95f6d39 (dist-flavor): New variable, default to alpha.
(dist): Depend on rcs-mark-$(dist-flavor).
(rcs-mark-beta): New target.
1994-04-20 22:25:09 +00:00
Roland McGrath
22846c7022 (Using Variables): Add paragraph that xrefs to Automatic Variables.
Add Automatic Variables item to the menu.
1994-04-20 22:21:51 +00:00
Roland McGrath
fd025b9089 (fatal_error_signal): Don't unblock signals. 1994-04-06 01:17:43 +00:00
Roland McGrath
6dc8e442f2 (update_goal_chain): Do inner loop on double-colon entries.
(update_file): Use FILE->double_colon pointer to find all entries.
(f_mtime): Likewise.
(notice_finished_file): Propagate mtime change to all entries.
1994-04-05 10:37:12 +00:00
Roland McGrath
4e4b1ed670 (main): When disqualifying makefiles for updating, use double_colon pointer
to find all entries for a file.
1994-04-05 10:20:03 +00:00
Roland McGrath
3580cdedd8 (enter_file): If there is already a double-colon entry for the file, set
NEW->double_colon to that pointer.
(file_hash_enter): Use FILE->double_colon to find all entries to set name.
1994-04-05 10:17:01 +00:00
Roland McGrath
108cca9aa5 (record_files): Set double_colon pointer instead of flag. 1994-04-05 10:14:49 +00:00
Roland McGrath
98104e4d2e (try_variable_definition): Return after abort. 1994-04-05 10:09:28 +00:00
Roland McGrath
dc8983dc8b (struct file): Change member double_colon' from flag to struct file *'. 1994-04-05 09:22:13 +00:00
Roland McGrath
0513e29593 (read_makefile): Remove unused variable.
(parse_file_seq): When removing an elt that is just `)', properly fix up
the previous elt's next pointer.
1994-04-01 23:44:10 +00:00
Roland McGrath
087ef58502 Put $Id$ inside [] in AC_REVISION, since expansion contains a comma. 1994-03-29 00:23:41 +00:00
Roland McGrath
298a8363ff (rcs-mark-alpha): New target.
(dist): Depend on that.
1994-03-29 00:18:03 +00:00
Roland McGrath
ebe1ed2e49 (Makefile.in): Edit MAKE assignment into @SET_MAKE@. 1994-03-29 00:13:58 +00:00
Roland McGrath
6a7b0d623b Do AC_SET_MAKE. 1994-03-28 23:31:37 +00:00
Roland McGrath
f0c1a986db Added rcsid. 1994-03-28 22:58:08 +00:00
Roland McGrath
e7defc873b entered into RCS 1994-03-23 14:53:21 +00:00
Roland McGrath
4b4d5bcd0a Added rcs id. 1994-03-23 14:43:56 +00:00
Roland McGrath
d3fbc4f345 entered into RCS 1994-03-23 14:12:55 +00:00
Roland McGrath
227cffec2b entered into RCS 1994-03-04 05:36:26 +00:00
Roland McGrath
5d3189c952 Formerly read.c.~75~ 1994-03-04 05:10:22 +00:00
Roland McGrath
c71c43c0b5 Formerly misc.c.~31~ 1994-03-04 05:10:20 +00:00
Roland McGrath
1944def8db entered into RCS 1994-02-16 23:58:49 +00:00
Roland McGrath
4b7d940657 Formerly read.c.~74~ 1994-02-16 22:55:31 +00:00
Roland McGrath
d68bb0895b entered into RCS 1994-02-16 21:32:01 +00:00
Roland McGrath
29b051dc0c Formerly misc.c.~30~ 1994-02-16 21:25:32 +00:00
Roland McGrath
8e1432e250 Formerly main.c.~105~ 1994-02-16 21:13:16 +00:00
Roland McGrath
015d472119 entered into RCS 1994-02-16 21:09:47 +00:00
Roland McGrath
7aca4a343d entered into RCS 1994-02-12 00:16:20 +00:00
Roland McGrath
92c245ab98 entered into RCS 1994-02-11 02:45:27 +00:00
Roland McGrath
3bb79f5823 Formerly make.h.~82~ 1994-02-04 21:28:53 +00:00
Roland McGrath
554f67bc64 Formerly misc.c.~29~ 1994-02-03 07:21:18 +00:00
Roland McGrath
5ee9dc7472 Formerly variable.c.~27~ 1994-02-01 00:11:47 +00:00
Roland McGrath
bb55335906 Formerly read.c.~73~ 1994-02-01 00:07:17 +00:00
Roland McGrath
b5665419ba Formerly variable.c.~26~ 1994-01-26 00:48:30 +00:00
Roland McGrath
7f534ea595 Formerly make.texinfo.~127~ 1994-01-26 00:47:07 +00:00
Roland McGrath
23e64a0b13 Formerly commands.c.~20~ 1994-01-25 21:51:25 +00:00
Roland McGrath
1c0df127f8 Formerly make.texinfo.~126~ 1994-01-19 23:04:36 +00:00
Roland McGrath
68a5f2a17a Formerly make.texinfo.~125~ 1994-01-17 22:06:11 +00:00
Roland McGrath
50bb35c3e3 Formerly default.c.~32~ 1994-01-17 22:05:22 +00:00
Roland McGrath
fc99c2260b Formerly GNUmakefile.~116~ 1994-01-12 00:30:18 +00:00
Roland McGrath
f178779347 Formerly GNUmakefile.~115~ 1994-01-07 21:28:25 +00:00
Roland McGrath
90829c3577 entered into RCS 1994-01-07 21:27:29 +00:00
Roland McGrath
7c1f91ced2 Formerly main.c.~104~ 1994-01-06 23:12:09 +00:00
Roland McGrath
b4ccaac8da Formerly compatMakefile.~87~ 1994-01-06 23:11:22 +00:00
Roland McGrath
2932fb1bca Formerly read.c.~72~ 1993-12-23 22:56:05 +00:00
Roland McGrath
db98fe95a4 Formerly GNUmakefile.~113~ 1993-12-23 20:41:21 +00:00
Roland McGrath
66784463c0 Formerly configure.in.~32~ 1993-12-23 19:46:50 +00:00
Roland McGrath
fe450df425 Formerly vpath.c.~15~ 1993-12-23 04:42:29 +00:00
Roland McGrath
c9f149173f Formerly GNUmakefile.~112~ 1993-12-22 22:18:14 +00:00
Roland McGrath
9ee5e4d17d Formerly configure.in.~31~ 1993-12-22 22:00:41 +00:00
Roland McGrath
96d67bce90 Formerly configure.in.~30~ 1993-12-17 20:31:32 +00:00
Roland McGrath
a0ab37fcd6 Formerly arscan.c.~32~ 1993-12-16 23:24:39 +00:00
Roland McGrath
65b8056203 Formerly main.c.~103~ 1993-12-16 20:10:36 +00:00
Roland McGrath
4f752036ac Formerly main.c.~102~ 1993-12-15 22:49:45 +00:00
Roland McGrath
b8c55666a7 Formerly make.texinfo.~124~ 1993-12-15 00:33:30 +00:00
Roland McGrath
08e7a4fcdd Formerly configure.in.~29~ 1993-12-14 23:06:56 +00:00
Roland McGrath
386d0a7ffc Formerly make.texinfo.~123~ 1993-12-14 22:16:38 +00:00
Roland McGrath
c33908dea5 Formerly default.c.~31~ 1993-12-14 21:59:57 +00:00
Roland McGrath
1bc63e8cc7 Formerly configure.in.~28~ 1993-12-14 21:56:50 +00:00
Roland McGrath
ad87633b72 entered into RCS 1993-12-14 21:50:51 +00:00
Roland McGrath
21eecea26d Formerly ar.c.~6~ 1993-12-14 21:06:33 +00:00
Roland McGrath
d519e2c19b Formerly read.c.~71~ 1993-12-14 20:09:51 +00:00
Roland McGrath
cf9bc4ae2f Formerly file.c.~27~ 1993-12-14 19:36:43 +00:00
Roland McGrath
2a19159394 Formerly vpath.c.~14~ 1993-12-14 19:28:59 +00:00
Roland McGrath
8e73c0981b Formerly configure.in.~27~ 1993-12-03 21:40:28 +00:00
Roland McGrath
f935610ca9 Formerly read.c.~70~ 1993-12-02 20:44:03 +00:00
Roland McGrath
12113c5925 Formerly misc.c.~28~ 1993-12-02 20:37:46 +00:00
Roland McGrath
63160928cd Formerly GNUmakefile.~111~ 1993-11-11 16:51:19 +00:00
Roland McGrath
48fe766053 Formerly default.c.~30~ 1993-11-11 16:47:27 +00:00
Roland McGrath
acd7330a5f Formerly read.c.~69~ 1993-11-10 11:06:04 +00:00
Roland McGrath
78454538f9 entered into RCS 1993-11-03 13:06:04 +00:00
Roland McGrath
a7bafcee76 Formerly make.texinfo.~122~ 1993-11-03 12:21:47 +00:00
Roland McGrath
4394c7a32d entered into RCS 1993-11-03 11:56:26 +00:00
Roland McGrath
38abf5e6c4 Formerly function.c.~31~ 1993-10-29 21:50:48 +00:00
Roland McGrath
58c146fa50 Formerly compatMakefile.~86~ 1993-10-29 20:47:10 +00:00
Roland McGrath
e612cccef3 Formerly make.h.~81~ 1993-10-28 00:09:14 +00:00
Roland McGrath
960650331a Formerly file.h.~6~ 1993-10-27 22:23:18 +00:00
Roland McGrath
462e175970 Formerly main.c.~101~ 1993-10-27 22:14:41 +00:00
Roland McGrath
a1749c85c8 Formerly remake.c.~52~ 1993-10-27 22:14:26 +00:00
Roland McGrath
c727af1bcc Formerly main.c.~100~ 1993-10-26 23:55:04 +00:00
Roland McGrath
8cb881fa9e Formerly remake.c.~51~ 1993-10-26 23:45:32 +00:00
Roland McGrath
3aeb946943 Formerly read.c.~68~ 1993-10-25 19:25:17 +00:00
Roland McGrath
9012e6a254 Formerly GNUmakefile.~110~ 1993-10-25 19:11:46 +00:00
Roland McGrath
251b0fc75f Formerly main.c.~99~ 1993-10-25 18:52:25 +00:00
Roland McGrath
f7a6c58f5b Formerly configure.in.~26~ 1993-10-22 06:56:46 +00:00
Roland McGrath
0ddf761563 entered into RCS 1993-10-21 20:48:08 +00:00
Roland McGrath
58d81fe699 Formerly make.texinfo.~121~ 1993-10-21 20:02:11 +00:00
Roland McGrath
4daf275edd Formerly make.texinfo.~120~ 1993-10-20 05:46:21 +00:00
Roland McGrath
d27b2c3de5 Formerly configure.in.~25~ 1993-10-18 11:15:08 +00:00
Roland McGrath
7c456a7368 Formerly rule.c.~16~ 1993-10-18 11:04:04 +00:00
Roland McGrath
a8c24526e3 Formerly file.c.~26~ 1993-10-18 11:01:37 +00:00
Roland McGrath
9e7e303ac8 Formerly make.h.~80~ 1993-10-14 22:29:26 +00:00
Roland McGrath
a3d7dfa85c Formerly default.c.~29~ 1993-10-14 22:25:17 +00:00
Roland McGrath
88054f8ad3 Formerly main.c.~98~ 1993-10-14 22:23:39 +00:00
Roland McGrath
f5e7fb8ea0 Formerly job.h.~6~ 1993-10-14 21:27:29 +00:00
Roland McGrath
7cb595fc60 Formerly compatMakefile.~85~ 1993-10-14 21:04:51 +00:00
Roland McGrath
4cbe738cfb Formerly make.h.~79~ 1993-10-14 19:08:38 +00:00
Roland McGrath
0f83ab90e3 entered into RCS 1993-10-14 19:08:36 +00:00
Roland McGrath
0e15559bbf Formerly GNUmakefile.~109~ 1993-10-11 23:47:29 +00:00
Jim Meyering
eaba9405d7 entered into RCS 1993-10-08 00:11:55 +00:00
Roland McGrath
492f92b9ec *** empty log message *** 1993-10-03 19:33:04 +00:00
Roland McGrath
cc5be7c0cd Formerly default.c.~28~ 1993-10-03 19:15:29 +00:00
Roland McGrath
f8300f1e1c Formerly main.c.~97~ 1993-09-28 18:20:17 +00:00
Roland McGrath
7f71af7974 Formerly job.c.~110~ 1993-09-28 18:18:15 +00:00
Roland McGrath
065ac461c5 Formerly job.c.~109~ 1993-09-20 22:33:18 +00:00
Roland McGrath
f8c3e52b0f Formerly main.c.~96~ 1993-09-20 22:05:19 +00:00
Richard M. Stallman
1775c102ad entered into RCS 1993-09-20 20:03:30 +00:00
Roland McGrath
2a53aecb26 entered into RCS 1993-09-20 20:03:20 +00:00
Roland McGrath
3087dcdb2e *** empty log message *** 1993-09-20 20:02:01 +00:00
Roland McGrath
5174a5e5a1 Formerly make.texinfo.~119~ 1993-09-17 07:33:03 +00:00
Roland McGrath
b018db955c Formerly remake.c.~50~ 1993-09-17 04:51:21 +00:00
Roland McGrath
0da218acc1 Formerly make.h.~78~ 1993-09-17 04:49:17 +00:00
Roland McGrath
9fc36f7358 Formerly commands.c.~19~ 1993-09-17 04:46:36 +00:00
Roland McGrath
ec2751c045 Formerly job.c.~108~ 1993-09-17 04:37:54 +00:00
Roland McGrath
7b91e889b6 *** empty log message *** 1993-09-10 04:22:01 +00:00
Roland McGrath
16667d15e0 Formerly main.c.~95~ 1993-09-09 00:14:18 +00:00
Roland McGrath
b9337d3143 Formerly make.texinfo.~118~ 1993-09-06 23:34:51 +00:00
Roland McGrath
2bf7e9bcda Formerly make.texinfo.~117~ 1993-08-30 16:36:35 +00:00
Roland McGrath
b24a026b02 entered into RCS 1993-08-30 16:31:47 +00:00
Roland McGrath
0ef3708713 *** empty log message *** 1993-08-25 21:46:19 +00:00
Roland McGrath
2012e2877c Formerly make.texinfo.~116~ 1993-08-19 21:03:38 +00:00
Roland McGrath
ba45b6e5fa Formerly make.h.~77~ 1993-08-19 20:36:09 +00:00
Roland McGrath
308e6149e6 Formerly main.c.~94~ 1993-08-19 20:36:08 +00:00
Roland McGrath
cbbf3ee5ef Formerly variable.c.~25~ 1993-08-19 20:36:05 +00:00
Roland McGrath
8171a9ba6e Formerly read.c.~67~ 1993-08-18 19:01:46 +00:00
Roland McGrath
8788690192 Formerly GNUmakefile.~108~ 1993-08-16 21:40:16 +00:00
Roland McGrath
769061023a Formerly compatMakefile.~84~ 1993-08-16 21:39:37 +00:00
Roland McGrath
ba2c317cb7 Formerly configure.in.~24~ 1993-08-16 21:34:26 +00:00
Roland McGrath
aea1502a78 *** empty log message *** 1993-08-16 19:10:25 +00:00
Roland McGrath
9dcfb711c1 *** empty log message *** 1993-08-12 22:17:13 +00:00
Roland McGrath
4d8fff0ec0 Formerly make.h.~76~ 1993-08-12 21:19:12 +00:00
Roland McGrath
3c954a048b Formerly job.c.~107~ 1993-08-11 20:16:45 +00:00
Roland McGrath
2f8d1abe7c Formerly main.c.~93~ 1993-08-11 20:04:39 +00:00
Roland McGrath
d2654362c5 Formerly variable.c.~24~ 1993-08-11 20:04:34 +00:00
Roland McGrath
1bafe5ed81 Formerly job.c.~106~ 1993-08-11 19:32:02 +00:00
Roland McGrath
869ec1b877 *** empty log message *** 1993-08-11 07:27:10 +00:00
Roland McGrath
3cc0c7306a Formerly main.c.~92~ 1993-08-11 06:59:04 +00:00
Roland McGrath
c52575a837 Formerly main.c.~91~ 1993-08-11 06:54:23 +00:00
Roland McGrath
6d00f337e5 Formerly function.c.~30~ 1993-08-11 06:35:19 +00:00
Richard M. Stallman
b6e638af6d *** empty log message *** 1993-08-10 21:27:23 +00:00
Roland McGrath
5fc2539281 Formerly job.c.~105~ 1993-08-09 22:25:00 +00:00
Roland McGrath
0bab40c121 Formerly remote-stub.c.~3~ 1993-08-09 22:21:56 +00:00
Roland McGrath
8980e49036 Formerly function.c.~29~ 1993-08-09 22:11:17 +00:00
Roland McGrath
84b4d9cce4 Formerly compatMakefile.~83~ 1993-08-03 23:18:21 +00:00
Roland McGrath
92a67d1895 Formerly dep.h.~6~ 1993-08-03 04:18:56 +00:00
Roland McGrath
22cd0cd4e3 Formerly compatMakefile.~82~ 1993-08-02 20:49:11 +00:00
Roland McGrath
e75d998e50 *** empty log message *** 1993-08-02 20:48:12 +00:00
Roland McGrath
ae087fbb2f *** empty log message *** 1993-08-01 23:03:26 +00:00
Roland McGrath
714aeaf857 Formerly make.texinfo.~115~ 1993-08-01 22:32:20 +00:00
Roland McGrath
cbeeeafde9 *** empty log message *** 1993-08-01 20:39:38 +00:00
Roland McGrath
572856fa8f entered into RCS 1993-08-01 20:28:14 +00:00
Roland McGrath
1d9b68aef5 Formerly compatMakefile.~81~ 1993-08-01 20:17:31 +00:00
Roland McGrath
e813da324d Formerly misc.c.~27~ 1993-08-01 20:03:45 +00:00
Roland McGrath
b018243a45 Formerly compatMakefile.~80~ 1993-07-30 20:55:50 +00:00
Roland McGrath
9326e8fec5 Formerly compatMakefile.~79~ 1993-07-30 05:29:32 +00:00
Roland McGrath
5cf5f261d9 Formerly configure.in.~23~ 1993-07-30 03:37:40 +00:00
Roland McGrath
e22a936ca5 *** empty log message *** 1993-07-30 03:20:49 +00:00
Roland McGrath
9f33e6cdcb *** empty log message *** 1993-07-27 00:37:13 +00:00
Roland McGrath
16777bbe0f entered into RCS 1993-07-26 20:20:46 +00:00
Roland McGrath
e851ef2303 Initial revision 1993-07-26 20:20:42 +00:00
Roland McGrath
1681a1f29a Formerly make.texinfo.~114~ 1993-07-26 19:10:51 +00:00
melissa
acb8140655 Formerly make.texinfo.~113~ 1993-07-26 18:27:27 +00:00
Roland McGrath
245d0b3772 *** empty log message *** 1993-07-26 17:37:11 +00:00
Roland McGrath
96fb58e401 Formerly compatMakefile.~78~ 1993-07-26 02:23:47 +00:00
Roland McGrath
02d19fe9c1 Formerly GNUmakefile.~107~ 1993-07-26 02:12:47 +00:00
Roland McGrath
32b80e7367 Formerly make.texinfo.~112~ 1993-07-25 21:08:39 +00:00
Roland McGrath
7c30adcd57 Formerly make.texinfo.~111~ 1993-07-23 22:07:42 +00:00
Roland McGrath
8153755c17 Formerly make.h.~75~ 1993-07-23 20:04:37 +00:00
Roland McGrath
2a983b8ead Formerly configure.in.~22~ 1993-07-23 20:04:35 +00:00
Roland McGrath
bd395b5c02 Formerly make.texinfo.~110~ 1993-07-22 21:35:45 +00:00
Roland McGrath
d24f1f2330 Formerly make.texinfo.~109~ 1993-07-16 22:14:09 +00:00
Roland McGrath
cace096aba Formerly make.texinfo.~108~ 1993-07-15 02:31:03 +00:00
Roland McGrath
f0929a13c3 Formerly read.c.~66~ 1993-07-15 02:25:00 +00:00
Roland McGrath
7a031cd4b2 Formerly variable.c.~23~ 1993-07-15 01:59:03 +00:00
Roland McGrath
fc8fa16253 Formerly variable.c.~22~ 1993-07-15 00:22:56 +00:00
Roland McGrath
ca3b88c66a Formerly function.c.~28~ 1993-07-15 00:22:55 +00:00
Roland McGrath
f7f63b75b5 Formerly make.texinfo.~107~ 1993-07-14 23:54:44 +00:00
Roland McGrath
250e638f44 Formerly read.c.~65~ 1993-07-14 23:04:39 +00:00
Roland McGrath
0a0130dcf2 Formerly dep.h.~5~ 1993-07-14 22:56:42 +00:00
Roland McGrath
aef2a1ccd0 Formerly main.c.~90~ 1993-07-14 22:56:38 +00:00
Jim Meyering
2ef2fbe7a4 *** empty log message *** 1993-07-13 16:37:01 +00:00
Roland McGrath
c3b30f576d Formerly make.h.~74~ 1993-07-13 02:42:59 +00:00
David J. MacKenzie
c2cc8e33fb *** empty log message *** 1993-07-12 22:13:12 +00:00
Roland McGrath
af7ef68647 Formerly make.texinfo.~106~ 1993-07-09 18:02:38 +00:00
Roland McGrath
9a6b8d1015 Formerly vpath.c.~13~ 1993-07-09 01:30:13 +00:00
Roland McGrath
3296fa1dff Formerly rule.c.~15~ 1993-07-09 01:22:33 +00:00
Roland McGrath
5a4a5d3160 Formerly make.h.~73~ 1993-07-08 23:51:22 +00:00
David J. MacKenzie
3a511f5874 *** empty log message *** 1993-07-06 23:07:30 +00:00
Roland McGrath
2b8f817cfb Formerly GNUmakefile.~106~ 1993-07-01 03:36:40 +00:00
Roland McGrath
7789ea8a3c Formerly implicit.c.~14~ 1993-06-30 23:04:21 +00:00
Roland McGrath
5003c9b26b Formerly rule.h.~5~ 1993-06-30 22:42:37 +00:00
Roland McGrath
d92b741fce Formerly rule.c.~14~ 1993-06-30 22:40:50 +00:00
Roland McGrath
aa68ee5ce2 Formerly file.c.~25~ 1993-06-30 22:11:36 +00:00
Roland McGrath
26c6ec1893 Formerly make.texinfo.~103~ 1993-06-30 20:07:02 +00:00
Roland McGrath
86d4d7425b Formerly job.c.~104~ 1993-06-25 20:03:56 +00:00
Roland McGrath
f84518396b Formerly read.c.~64~ 1993-06-25 20:03:54 +00:00
Roland McGrath
2e0e3d22ec Formerly vpath.c.~12~ 1993-06-25 20:03:51 +00:00
Roland McGrath
d3fc910b29 Formerly make.texinfo.~102~ 1993-06-25 19:47:50 +00:00
Roland McGrath
9c32a4c3cd Formerly main.c.~89~ 1993-06-25 19:47:20 +00:00
Roland McGrath
54462c9590 Formerly make.h.~72~ 1993-06-25 19:20:49 +00:00
Roland McGrath
ae112a5cb5 Formerly expand.c.~9~ 1993-06-25 19:20:36 +00:00
Roland McGrath
4ac6d66244 Formerly default.c.~27~ 1993-06-25 18:59:05 +00:00
melissa
08c71a7dbf Formerly make.texinfo.~101~ 1993-06-24 21:21:03 +00:00
Roland McGrath
5b5415bf87 Formerly make.texinfo.~100~ 1993-06-22 06:02:26 +00:00
Roland McGrath
f64cd37b29 Formerly default.c.~26~ 1993-06-21 21:56:36 +00:00
Roland McGrath
8bd226777e Formerly compatMakefile.~77~ 1993-06-11 18:42:04 +00:00
Roland McGrath
e176cf73a5 Formerly read.c.~63~ 1993-06-10 22:20:53 +00:00
Roland McGrath
d66f4e3407 Formerly ar.c.~5~ 1993-06-10 22:13:54 +00:00
Roland McGrath
4abb5e433f Formerly make.texinfo.~99~ 1993-06-10 21:56:37 +00:00
Roland McGrath
46a5b5adcc Formerly make.texinfo.~98~ 1993-06-10 01:52:27 +00:00
Roland McGrath
4694e31659 Formerly ar.c.~4~ 1993-06-10 01:43:06 +00:00
Roland McGrath
3d6b586776 Formerly read.c.~62~ 1993-06-10 01:31:02 +00:00
Roland McGrath
c4cc2ec376 Formerly dep.h.~4~ 1993-06-10 00:18:21 +00:00
Roland McGrath
4a94240844 Formerly rule.c.~13~ 1993-06-09 23:16:30 +00:00
Roland McGrath
6fc0ab541e Formerly default.c.~25~ 1993-06-09 23:16:28 +00:00
Roland McGrath
5b4a918d26 Formerly function.c.~27~ 1993-06-09 23:16:25 +00:00
Roland McGrath
bd3309f09b Formerly GNUmakefile.~105~ 1993-06-09 22:06:20 +00:00
Roland McGrath
122c9699fa *** empty log message *** 1993-06-09 20:28:35 +00:00
Roland McGrath
e2f08f5dbf Formerly make.texinfo.~97~ 1993-06-09 17:45:57 +00:00
Jim Blandy
7089c07d4e *** empty log message *** 1993-06-09 09:23:12 +00:00
Roland McGrath
f363e41c27 Formerly read.c.~61~ 1993-06-08 00:36:13 +00:00
Roland McGrath
24cd5ede9e Formerly compatMakefile.~76~ 1993-06-08 00:24:19 +00:00
Roland McGrath
f4fac65746 Formerly main.c.~88~ 1993-06-08 00:08:45 +00:00
Roland McGrath
f6b549870a Formerly dep.h.~3~ 1993-06-07 23:28:51 +00:00
Roland McGrath
074d147ef7 Formerly main.c.~87~ 1993-06-04 19:53:32 +00:00
Roland McGrath
55f5d979ae Formerly main.c.~86~ 1993-06-04 00:27:28 +00:00
Roland McGrath
00dc97cb8a Formerly implicit.c.~13~ 1993-06-04 00:15:12 +00:00
Roland McGrath
9766fe1775 Formerly main.c.~85~ 1993-06-03 20:56:33 +00:00
Roland McGrath
b5fb6b260e Formerly GNUmakefile.~104~ 1993-06-03 20:47:55 +00:00
Roland McGrath
6382676838 Formerly read.c.~60~ 1993-06-02 21:42:39 +00:00
Roland McGrath
14f2b39dff Formerly GNUmakefile.~103~ 1993-06-02 21:09:00 +00:00
Roland McGrath
9697738544 entered into RCS 1993-06-02 20:56:37 +00:00
Roland McGrath
4a9fdcd65f Formerly file.c.~24~ 1993-06-02 20:51:35 +00:00
Roland McGrath
80091295df Formerly main.c.~84~ 1993-06-02 20:51:28 +00:00
Roland McGrath
3c11aba3cd Formerly compatMakefile.~75~ 1993-05-31 22:48:16 +00:00
Roland McGrath
54fb272967 Formerly implicit.c.~12~ 1993-05-27 21:34:50 +00:00
Roland McGrath
e12d722d99 Formerly make.texinfo.~96~ 1993-05-26 21:21:42 +00:00
Roland McGrath
8a5a2b9b8d Formerly make.texinfo.~95~ 1993-05-26 18:41:58 +00:00
Roland McGrath
0246a6dc63 Formerly main.c.~83~ 1993-05-26 18:33:12 +00:00
Richard M. Stallman
60c868c193 *** empty log message *** 1993-05-25 00:43:37 +00:00
Roland McGrath
1e71bdd085 Formerly make.texinfo.~94~ 1993-05-25 00:00:35 +00:00
Roland McGrath
b0a9db44b6 Formerly rule.c.~12~ 1993-05-24 23:02:13 +00:00
Roland McGrath
f846c07d43 *** empty log message *** 1993-05-24 21:41:18 +00:00
Roland McGrath
dfc8da6e0e Formerly compatMakefile.~74~ 1993-05-24 20:17:29 +00:00
Jim Blandy
8960f971ca *** empty log message *** 1993-05-24 15:57:15 +00:00
Roland McGrath
ff71fe9277 Formerly file.c.~23~ 1993-05-22 20:24:37 +00:00
Roland McGrath
fe92d8e656 Formerly main.c.~82~ 1993-05-22 20:20:16 +00:00
Jim Blandy
f0080188b7 *** empty log message *** 1993-05-21 23:39:17 +00:00
Roland McGrath
5a55f43ddc Formerly compatMakefile.~73~ 1993-05-21 22:15:48 +00:00
Roland McGrath
63b6de85b5 Formerly GNUmakefile.~102~ 1993-05-21 17:36:32 +00:00
Roland McGrath
29acbbea8d Initial revision 1993-05-20 20:22:34 +00:00
Roland McGrath
e66d29867e Formerly compatMakefile.~72~ 1993-05-20 01:30:41 +00:00
Roland McGrath
0bcabeb134 Formerly read.c.~59~ 1993-05-19 21:15:51 +00:00
Roland McGrath
e90a315ebe entered into RCS 1993-05-19 17:56:38 +00:00
Roland McGrath
b06b92566c Formerly make.texinfo.~93~ 1993-05-17 00:24:00 +00:00
Roland McGrath
8aa529e55e Formerly vpath.c.~11~ 1993-05-14 23:09:34 +00:00
Roland McGrath
03acd42408 Formerly dir.c.~12~ 1993-05-14 22:41:07 +00:00
Roland McGrath
bc0276c3cb Formerly read.c.~58~ 1993-05-14 22:25:11 +00:00
Roland McGrath
3d952e5879 Formerly main.c.~81~ 1993-05-14 21:50:11 +00:00
Roland McGrath
3f15ef960a Formerly make.texinfo.~92~ 1993-05-14 21:50:07 +00:00
Roland McGrath
fa67064dc6 Formerly make.h.~71~ 1993-05-14 20:40:38 +00:00
Roland McGrath
5340230f6b Formerly README.template.~5~ 1993-05-12 21:22:14 +00:00
Roland McGrath
7162378126 Formerly arscan.c.~31~ 1993-05-12 21:05:03 +00:00
Roland McGrath
534926ac7a Formerly function.c.~26~ 1993-05-12 19:44:41 +00:00
Roland McGrath
5580266222 Formerly configure.in.~21~ 1993-05-12 19:24:14 +00:00
Roland McGrath
6c6f210456 Formerly job.c.~103~ 1993-05-12 19:20:45 +00:00
Jim Meyering
c5c92b71ce Initial revision 1993-05-11 23:23:34 +00:00
Roland McGrath
369bb2a609 Formerly function.c.~25~ 1993-05-07 22:34:49 +00:00
Roland McGrath
5c82e72caa Formerly commands.c.~18~ 1993-05-06 21:30:42 +00:00
Roland McGrath
ca5b7c487d Formerly make.h.~70~ 1993-05-06 21:30:40 +00:00
Roland McGrath
9596950898 Formerly job.c.~102~ 1993-05-06 21:30:10 +00:00
Roland McGrath
29de1a7e5a Formerly expand.c.~8~ 1993-05-06 21:14:33 +00:00
Roland McGrath
f1daf67200 Formerly read.c.~57~ 1993-05-03 21:14:22 +00:00
Roland McGrath
e8c11d4e32 Formerly arscan.c.~30~ 1993-05-03 21:03:37 +00:00
Roland McGrath
481e0e7d22 Formerly arscan.c.~29~ 1993-04-30 01:08:30 +00:00
Roland McGrath
2b81718876 Formerly ar.c.~3~ 1993-04-29 23:57:58 +00:00
Roland McGrath
6ee7823efe Formerly job.c.~101~ 1993-04-29 01:20:37 +00:00
Roland McGrath
683e4a5de9 Formerly arscan.c.~28~ 1993-04-26 20:43:32 +00:00
Roland McGrath
548b4c9bf1 Formerly make.h.~69~ 1993-04-26 20:07:49 +00:00
Roland McGrath
fba3960a6a Formerly main.c.~80~ 1993-04-26 20:05:02 +00:00
Roland McGrath
0986bb2c43 Formerly GNUmakefile.~100~ 1993-04-22 22:42:00 +00:00
Roland McGrath
5532d1d11d Formerly make.texinfo.~91~ 1993-04-19 19:42:09 +00:00
Roland McGrath
dab0d4214e Formerly compatMakefile.~71~ 1993-04-16 20:11:42 +00:00
Roland McGrath
088a491f10 Formerly GNUmakefile.~99~ 1993-04-16 18:41:16 +00:00
Roland McGrath
681f7a3067 Formerly make.texinfo.~90~ 1993-04-16 18:26:18 +00:00
Roland McGrath
ada4528484 Formerly configure.in.~20~ 1993-04-16 00:54:50 +00:00
Roland McGrath
1386d961a9 Formerly default.c.~24~ 1993-04-16 00:54:40 +00:00
Roland McGrath
828b45420a Initial revision 1993-04-16 00:51:27 +00:00
Roland McGrath
e9f008dc04 Formerly misc.c.~26~ 1993-04-15 22:42:20 +00:00
Roland McGrath
44ecfc2f36 Formerly read.c.~56~ 1993-04-15 22:30:01 +00:00
Roland McGrath
e28495225d Formerly rule.c.~11~ 1993-04-15 22:29:57 +00:00
Roland McGrath
c190a98796 Formerly function.c.~24~ 1993-04-15 22:29:47 +00:00
Roland McGrath
a03f503fb7 Formerly misc.c.~25~ 1993-04-14 20:43:53 +00:00
Roland McGrath
04789f11cd Formerly make.texinfo.~89~ 1993-04-14 19:44:21 +00:00
Roland McGrath
f02ced5786 Formerly main.c.~79~ 1993-04-14 18:20:33 +00:00
Roland McGrath
2fae4442e2 Formerly make.h.~68~ 1993-04-14 17:34:15 +00:00
Roland McGrath
f138f0eeff Formerly job.c.~100~ 1993-04-14 17:22:35 +00:00
Roland McGrath
ea1e49e5a8 Formerly default.c.~23~ 1993-04-14 15:32:26 +00:00
Roland McGrath
9bd8004ded Formerly make.texinfo.~88~ 1993-04-12 21:11:48 +00:00
Roland McGrath
596d50cb1c Formerly arscan.c.~27~ 1993-04-12 20:52:46 +00:00
Roland McGrath
48f4ce2825 Formerly remake.c.~49~ 1993-04-12 20:52:45 +00:00
Roland McGrath
d8b7640a81 Formerly dir.c.~11~ 1993-04-12 20:51:44 +00:00
Roland McGrath
8c01d0459a Formerly main.c.~78~ 1993-04-12 20:51:42 +00:00
Roland McGrath
e4dce6fa11 Formerly configure.in.~19~ 1993-04-12 20:51:39 +00:00
Roland McGrath
7831181410 Formerly make.h.~67~ 1993-04-12 20:51:32 +00:00
Roland McGrath
2cc84f7c97 Formerly variable.c.~21~ 1993-04-12 20:02:24 +00:00
Roland McGrath
5136f317d2 Formerly default.c.~22~ 1993-04-12 19:58:26 +00:00
Roland McGrath
ae7b53245a Formerly make.texinfo.~87~ 1993-04-11 22:26:07 +00:00
Roland McGrath
542a0f8112 Formerly main.c.~77~ 1993-04-08 22:14:23 +00:00
Roland McGrath
2ed0333f3c Formerly job.c.~99~ 1993-04-08 22:08:11 +00:00
Roland McGrath
791928d60b Formerly job.c.~98~ 1993-04-07 21:10:12 +00:00
Roland McGrath
de21395cad Formerly make.texinfo.~86~ 1993-04-07 20:44:43 +00:00
Roland McGrath
5973c4e97a Formerly main.c.~76~ 1993-04-07 20:40:35 +00:00
Roland McGrath
6dbdf2caa8 Formerly compatMakefile.~70~ 1993-04-07 19:31:50 +00:00
Roland McGrath
6ed99f4d40 Formerly configure.in.~18~ 1993-04-06 00:58:10 +00:00
Roland McGrath
3f0a207eaf Formerly job.c.~97~ 1993-04-06 00:21:23 +00:00
Roland McGrath
07c6b685b7 Formerly main.c.~75~ 1993-04-02 22:16:47 +00:00
Roland McGrath
0c1c2ff3d0 Formerly GNUmakefile.~98~ 1993-03-29 19:30:33 +00:00
Roland McGrath
d1a988ce9f Formerly GNUmakefile.~97~ 1993-03-28 22:36:05 +00:00
Roland McGrath
ae1278315f Formerly compatMakefile.~69~ 1993-03-28 22:06:13 +00:00
Roland McGrath
164dcdad22 Formerly vpath.c.~10~ 1993-03-24 20:13:56 +00:00
Roland McGrath
f3bd744187 Formerly make.texinfo.~85~ 1993-03-24 19:29:31 +00:00
Roland McGrath
722018bdbe Formerly variable.c.~20~ 1993-03-24 19:27:11 +00:00
Roland McGrath
bfe005e8a0 Formerly GNUmakefile.~96~ 1993-03-18 01:34:17 +00:00
Roland McGrath
f9b50f6436 Formerly main.c.~74~ 1993-03-18 01:02:20 +00:00
Roland McGrath
28c125b725 Formerly compatMakefile.~68~ 1993-03-12 20:54:25 +00:00
Roland McGrath
ab9034ef4e Formerly compatMakefile.~67~ 1993-03-11 19:25:31 +00:00
Roland McGrath
19c3ead040 Formerly configure.in.~17~ 1993-03-11 19:25:28 +00:00
Roland McGrath
63b17f1d63 Formerly GNUmakefile.~95~ 1993-03-11 19:25:25 +00:00
Roland McGrath
3e9cf581d1 entered into RCS 1993-03-11 19:25:21 +00:00
Roland McGrath
e7b737dc5e Formerly GNUmakefile.~94~ 1993-03-10 22:56:43 +00:00
Roland McGrath
1a56335cbf Formerly implicit.c.~11~ 1993-03-10 20:41:03 +00:00
Roland McGrath
4b30933904 Formerly file.c.~22~ 1993-03-10 20:24:57 +00:00
Roland McGrath
094f89cee5 Formerly make.texinfo.~84~ 1993-03-08 21:54:29 +00:00
Roland McGrath
36a66b6bec Formerly remake.c.~48~ 1993-03-08 20:04:20 +00:00
Roland McGrath
69105addb4 Formerly compatMakefile.~66~ 1993-03-08 19:50:11 +00:00
Roland McGrath
e4c66e2f88 Formerly read.c.~55~ 1993-03-08 18:50:09 +00:00
Roland McGrath
d5ef06dee5 Formerly main.c.~73~ 1993-03-08 18:49:51 +00:00
Roland McGrath
7c675f86e6 Formerly make.man.~4~ 1993-03-08 18:38:35 +00:00
Roland McGrath
60a76e0d39 Formerly compatMakefile.~65~ 1993-02-22 19:19:33 +00:00
Roland McGrath
c88072ca74 Formerly implicit.c.~10~ 1993-02-21 22:03:38 +00:00
Roland McGrath
a609f1f9c2 Formerly rule.c.~10~ 1993-02-21 21:58:43 +00:00
Roland McGrath
2413679845 Formerly rule.h.~4~ 1993-02-21 21:56:09 +00:00
Roland McGrath
b50f2fc0a6 Formerly commands.c.~17~ 1993-02-21 20:05:54 +00:00
Roland McGrath
4034f2bdfb Formerly compatMakefile.~64~ 1993-02-21 19:49:42 +00:00
Roland McGrath
b2361b3591 Formerly misc.c.~24~ 1993-02-21 19:48:46 +00:00
Roland McGrath
ed70d6422c Formerly main.c.~72~ 1993-02-21 19:28:33 +00:00
Roland McGrath
17bc902648 Formerly variable.c.~19~ 1993-02-21 19:28:30 +00:00
Roland McGrath
db6a102206 Formerly read.c.~54~ 1993-02-21 19:28:27 +00:00
Roland McGrath
ded09420ad Formerly remake.c.~47~ 1993-02-08 22:56:09 +00:00
Roland McGrath
078cc29e60 Formerly implicit.c.~9~ 1993-02-08 22:50:02 +00:00
Roland McGrath
bede66b709 Formerly vpath.c.~9~ 1993-02-08 22:50:00 +00:00
Roland McGrath
cc1433e808 Formerly compatMakefile.~63~ 1993-02-08 22:12:47 +00:00
Roland McGrath
4f1320fba2 Formerly compatMakefile.~62~ 1993-02-05 22:48:57 +00:00
Roland McGrath
b8a4e2bb0e Formerly commands.c.~16~ 1993-02-05 22:34:51 +00:00
Roland McGrath
720b21097c Formerly commands.h.~2~ 1993-02-05 22:31:57 +00:00
Roland McGrath
162269418e Formerly remake.c.~46~ 1993-02-05 22:31:31 +00:00
Roland McGrath
580e2a7391 Formerly job.c.~96~ 1993-02-05 22:31:29 +00:00
Roland McGrath
d870f4df8c Formerly configure.in.~16~ 1993-02-05 20:24:00 +00:00
Roland McGrath
309a65a790 Formerly remote-cstms.c.~8~ 1993-02-04 18:31:53 +00:00
Roland McGrath
963f33c909 Formerly make.h.~66~ 1993-02-04 18:23:27 +00:00
Roland McGrath
af73694245 Formerly main.c.~71~ 1993-02-04 18:23:19 +00:00
Roland McGrath
a4f557cb63 Formerly make.texinfo.~83~ 1993-02-04 18:06:47 +00:00
Roland McGrath
d47d6051a3 Formerly compatMakefile.~61~ 1993-02-04 18:01:50 +00:00
Roland McGrath
87bb5a6259 Formerly make.texinfo.~82~ 1993-02-04 01:45:16 +00:00
Roland McGrath
708c7c90a3 Formerly compatMakefile.~60~ 1993-02-04 01:16:36 +00:00
Roland McGrath
573ddaf6da Formerly job.c.~95~ 1993-02-04 00:58:10 +00:00
Roland McGrath
db545dffcc Formerly read.c.~53~ 1993-02-04 00:01:08 +00:00
Roland McGrath
f7ee7d26a5 Formerly GNUmakefile.~93~ 1993-02-03 23:12:43 +00:00
Roland McGrath
15d4ec2322 Formerly expand.c.~7~ 1993-02-03 20:59:22 +00:00
Roland McGrath
88ae51cb2e Formerly compatMakefile.~59~ 1993-02-02 01:49:11 +00:00
Roland McGrath
657338f0c9 Formerly remote-cstms.c.~7~ 1993-02-01 23:58:39 +00:00
Roland McGrath
fe356384aa Formerly GNUmakefile.~92~ 1993-02-01 23:22:42 +00:00
Roland McGrath
69e442ec90 Formerly job.h.~5~ 1993-02-01 21:03:32 +00:00
Roland McGrath
8b738924b0 Formerly job.c.~94~ 1993-02-01 21:02:40 +00:00
Roland McGrath
afa97833cc Formerly read.c.~52~ 1993-02-01 00:24:58 +00:00
Roland McGrath
3c516ccd35 Formerly compatMakefile.~58~ 1993-02-01 00:11:27 +00:00
Roland McGrath
dfaa02a8d5 Formerly job.c.~93~ 1993-01-31 22:54:06 +00:00
mycroft
50d1798203 Formerly make.texinfo.~81~ 1993-01-29 02:57:54 +00:00
Roland McGrath
85da8b0b54 Formerly commands.c.~15~ 1993-01-28 23:01:09 +00:00
Roland McGrath
ddd3143498 Formerly variable.c.~18~ 1993-01-28 23:01:01 +00:00
Roland McGrath
cd493b3d8f Formerly configure.in.~15~ 1993-01-28 21:41:44 +00:00
Roland McGrath
6a44c4b672 Formerly make.texinfo.~78~ 1993-01-28 19:47:54 +00:00
Roland McGrath
2603a60526 Formerly configure.in.~14~ 1993-01-26 02:24:51 +00:00
Roland McGrath
9a1a8d0dc6 Formerly vpath.c.~8~ 1993-01-26 01:51:23 +00:00
Roland McGrath
7444af63fc Formerly compatMakefile.~57~ 1993-01-26 01:16:01 +00:00
Roland McGrath
ae0045f50e Formerly remake.c.~45~ 1993-01-26 00:41:38 +00:00
Roland McGrath
2c132055ef Formerly remake.c.~44~ 1993-01-25 23:30:19 +00:00
Roland McGrath
09e4a320e6 Formerly make.h.~65~ 1993-01-25 23:30:16 +00:00
Roland McGrath
c1e3141433 Formerly file.h.~5~ 1993-01-25 22:45:49 +00:00
Roland McGrath
c316ab7609 Formerly main.c.~70~ 1993-01-25 22:16:33 +00:00
Roland McGrath
cf197b7550 Formerly variable.c.~17~ 1993-01-25 21:42:31 +00:00
Roland McGrath
c653200459 Formerly variable.c.~16~ 1993-01-23 01:54:04 +00:00
Roland McGrath
0b396e2587 Formerly GNUmakefile.~91~ 1993-01-23 00:35:32 +00:00
Roland McGrath
6090eb3125 Formerly job.c.~92~ 1993-01-22 22:31:27 +00:00
Roland McGrath
21c1a55665 Formerly configure.in.~13~ 1993-01-22 22:16:40 +00:00
Roland McGrath
c50958dd46 Formerly remake.c.~43~ 1993-01-22 22:02:48 +00:00
Roland McGrath
d56535498b Formerly misc.c.~23~ 1993-01-22 21:32:00 +00:00
Roland McGrath
81e8efbcdf Formerly dir.c.~10~ 1993-01-22 19:46:10 +00:00
Roland McGrath
c308b3a5f3 Formerly configure.in.~12~ 1993-01-21 23:50:44 +00:00
Roland McGrath
f48fcf5f45 Formerly compatMakefile.~56~ 1993-01-21 23:50:44 +00:00
Roland McGrath
4d36cfe6a3 Formerly build.template.~4~ 1993-01-21 23:50:43 +00:00
Roland McGrath
2370f79846 Formerly job.c.~91~ 1993-01-21 23:27:00 +00:00
Roland McGrath
b758dc3f8b Formerly GNUmakefile.~90~ 1993-01-21 23:24:19 +00:00
Roland McGrath
e8a9cedc6a Formerly remake.c.~42~ 1993-01-21 22:24:55 +00:00
Roland McGrath
44078a3441 Formerly job.c.~90~ 1993-01-19 00:32:39 +00:00
Roland McGrath
ce25808caa Formerly configure.in.~11~ 1993-01-19 00:19:54 +00:00
Roland McGrath
c2b69b5d9d Formerly read.c.~51~ 1993-01-19 00:14:29 +00:00
Roland McGrath
6925f7153a Formerly compatMakefile.~55~ 1993-01-18 19:54:17 +00:00
Roland McGrath
5460cd5a00 Formerly make.texinfo.~77~ 1993-01-15 19:56:31 +00:00
Roland McGrath
2861ad6208 Formerly main.c.~69~ 1993-01-15 18:18:29 +00:00
Roland McGrath
37d9554e31 Formerly remake.c.~41~ 1993-01-15 18:06:22 +00:00
Roland McGrath
633efa004c Formerly make.h.~64~ 1993-01-15 18:05:49 +00:00
melissa
800a9e957d Formerly make.texinfo.~76~ 1993-01-15 02:46:25 +00:00
Robert J. Chassell
8ea8c0372a Formerly make.texinfo.~75~ 1993-01-14 22:55:03 +00:00
Roland McGrath
4dd2ed0ad1 entered into RCS 1993-01-14 22:25:02 +00:00
Roland McGrath
bbf2720b4d Formerly make.texinfo.~74~ 1993-01-14 20:23:10 +00:00
Roland McGrath
5893545370 Formerly read.c.~50~ 1993-01-14 19:26:47 +00:00
Roland McGrath
6ef5854e47 Formerly compatMakefile.~54~ 1993-01-14 18:53:17 +00:00
Roland McGrath
5c44db1b5f Formerly misc.c.~22~ 1993-01-13 21:23:01 +00:00
Roland McGrath
f0c68224d6 Formerly arscan.c.~26~ 1993-01-13 21:18:56 +00:00
Roland McGrath
bb90ac7aef Formerly variable.c.~15~ 1993-01-13 21:09:20 +00:00
Roland McGrath
4694e3fe2e Formerly GNUmakefile.~89~ 1993-01-13 21:05:06 +00:00
Roland McGrath
fae8065d7f Formerly build.template.~3~ 1993-01-13 21:05:03 +00:00
Roland McGrath
099b4d5643 Formerly build.template.~2~ 1993-01-12 23:00:41 +00:00
Roland McGrath
5e83d8b10a Formerly GNUmakefile.~88~ 1993-01-12 22:51:00 +00:00
Roland McGrath
4c84e13064 Formerly configure.in.~10~ 1993-01-12 21:11:23 +00:00
Roland McGrath
ef028aa4c6 Formerly README.template.~4~ 1993-01-12 21:02:13 +00:00
Roland McGrath
2bff7aa420 Formerly main.c.~68~ 1993-01-12 19:42:13 +00:00
Roland McGrath
e07db8077c Formerly make.h.~63~ 1993-01-12 19:36:16 +00:00
Roland McGrath
35ffa6973a Initial revision 1993-01-12 19:30:31 +00:00
Roland McGrath
402b400e52 Formerly compatMakefile.~53~ 1993-01-12 17:31:40 +00:00
Roland McGrath
6b6a4f1de2 Formerly GNUmakefile.~87~ 1993-01-11 23:02:32 +00:00
Roland McGrath
ab6a618dac Formerly make.texinfo.~73~ 1993-01-11 22:51:16 +00:00
Roland McGrath
45572fa600 Formerly vpath.c.~7~ 1993-01-11 22:46:31 +00:00
Richard M. Stallman
36a6a9eb7d Formerly make-stds.texi.~2~ 1993-01-11 22:29:30 +00:00
Roland McGrath
7c91702697 Formerly misc.c.~21~ 1993-01-11 19:45:54 +00:00
Roland McGrath
71fceb51e3 Formerly compatMakefile.~52~ 1993-01-11 19:45:52 +00:00
Richard M. Stallman
9705781777 Initial revision 1993-01-11 17:41:09 +00:00
Roland McGrath
76ae16dee3 Formerly job.c.~89~ 1993-01-08 22:40:24 +00:00
Roland McGrath
035157a2fd Formerly vpath.c.~6~ 1993-01-08 22:07:33 +00:00
Roland McGrath
50a643208f Formerly GNUmakefile.~86~ 1993-01-08 21:49:21 +00:00
Roland McGrath
92cd154b95 Formerly main.c.~67~ 1993-01-08 21:48:11 +00:00
Roland McGrath
d07b95da6f Formerly misc.c.~20~ 1993-01-08 20:32:36 +00:00
Roland McGrath
2f22bfeaaa Formerly make.texinfo.~72~ 1993-01-08 20:01:42 +00:00
Roland McGrath
fcedb448bb Formerly make.texinfo.~71~ 1993-01-07 22:47:51 +00:00
Roland McGrath
5a4ab813f0 Formerly job.c.~88~ 1993-01-07 01:46:47 +00:00
Robert J. Chassell
99369403b7 Formerly make.texinfo.~70~ 1993-01-07 01:40:19 +00:00
Roland McGrath
adde98d27b Formerly main.c.~66~ 1993-01-07 00:34:28 +00:00
Roland McGrath
e2622b0fea Formerly make.h.~62~ 1993-01-06 23:28:54 +00:00
Roland McGrath
99afb91aca Formerly function.c.~23~ 1993-01-06 22:57:35 +00:00
Roland McGrath
1632e7feb3 Formerly implicit.c.~8~ 1993-01-06 22:57:30 +00:00
Roland McGrath
9403ef9942 Formerly commands.c.~14~ 1993-01-06 22:57:24 +00:00
Roland McGrath
c8d4d2305d Formerly read.c.~49~ 1993-01-06 22:57:21 +00:00
Roland McGrath
f341a61976 Formerly job.h.~4~ 1993-01-06 22:57:14 +00:00
Roland McGrath
5778d6cdb9 Formerly compatMakefile.~51~ 1993-01-06 22:39:31 +00:00
Roland McGrath
f2bc0a0c93 Formerly dir.c.~9~ 1993-01-06 20:07:35 +00:00
Roland McGrath
d8817e2c39 Formerly GNUmakefile.~85~ 1993-01-06 00:30:46 +00:00
Roland McGrath
5b45a568c0 Formerly job.c.~87~ 1993-01-05 23:41:29 +00:00
Roland McGrath
d19c2ef049 Formerly misc.c.~19~ 1993-01-05 23:02:42 +00:00
Roland McGrath
c0c67164d5 Formerly configure.in.~9~ 1993-01-05 22:40:32 +00:00
Roland McGrath
93385de9ff Formerly compatMakefile.~50~ 1993-01-05 19:54:03 +00:00
Roland McGrath
9edb745a71 Formerly GNUmakefile.~84~ 1993-01-05 19:53:58 +00:00
Roland McGrath
d315acf15e Formerly main.c.~65~ 1993-01-04 21:59:56 +00:00
Roland McGrath
aa8a3b306d Formerly make.texinfo.~69~ 1993-01-04 20:42:16 +00:00
melissa
89b66be8b3 Formerly make.texinfo.~68~ 1992-12-31 20:56:47 +00:00
Roland McGrath
b313929074 Formerly make.h.~61~ 1992-12-31 17:26:10 +00:00
Robert J. Chassell
8c6ef34e56 Formerly make.texinfo.~67~ 1992-12-30 23:57:35 +00:00
Roland McGrath
f4f6b2b97e Formerly compatMakefile.~49~ 1992-12-29 18:59:17 +00:00
Roland McGrath
c2dbc39224 Formerly GNUmakefile.~83~ 1992-12-29 02:36:27 +00:00
Roland McGrath
2d89aa53df Formerly read.c.~48~ 1992-12-29 00:20:25 +00:00
Roland McGrath
52930ae3a9 Formerly compatMakefile.~48~ 1992-12-28 23:25:58 +00:00
Roland McGrath
ede645439a Formerly read.c.~47~ 1992-12-23 21:14:20 +00:00
Roland McGrath
95614c2e7c Formerly compatMakefile.~47~ 1992-12-23 18:18:27 +00:00
Roland McGrath
37fb62e217 Formerly variable.h.~9~ 1992-12-22 23:44:09 +00:00
Roland McGrath
555a705aaa Formerly expand.c.~6~ 1992-12-22 23:44:03 +00:00
Roland McGrath
123f70c521 Formerly compatMakefile.~46~ 1992-12-22 23:31:46 +00:00
Roland McGrath
02caa22338 Formerly default.c.~21~ 1992-12-22 22:31:16 +00:00
Roland McGrath
38f78c7be1 Formerly file.c.~21~ 1992-12-22 22:31:13 +00:00
Roland McGrath
fd5c585cab Formerly implicit.c.~7~ 1992-12-22 22:31:10 +00:00
Roland McGrath
0aa6e8609e Formerly read.c.~46~ 1992-12-22 22:31:08 +00:00
Roland McGrath
40463f4410 Formerly commands.c.~13~ 1992-12-22 22:31:07 +00:00
Roland McGrath
01e07f8ae2 Formerly variable.c.~14~ 1992-12-22 22:16:14 +00:00
Robert J. Chassell
f75288402e Formerly make.texinfo.~66~ 1992-12-22 21:42:45 +00:00
Roland McGrath
63fec5f467 Formerly remake.c.~40~ 1992-12-22 21:22:05 +00:00
Roland McGrath
b0a8c63bf2 Formerly make.texinfo.~65~ 1992-12-22 20:14:36 +00:00
Roland McGrath
2d038ae579 Formerly GNUmakefile.~82~ 1992-12-21 21:53:24 +00:00
Roland McGrath
50f2c1fbd9 Formerly configure.in.~7~ 1992-12-20 23:08:11 +00:00
Roland McGrath
40507f313a Formerly GNUmakefile.~81~ 1992-12-20 22:59:52 +00:00
Roland McGrath
11404035d1 Formerly compatMakefile.~45~ 1992-12-20 22:58:53 +00:00
Roland McGrath
3cc78a1a0f Formerly make.h.~60~ 1992-12-20 22:57:06 +00:00
Roland McGrath
501241725a Formerly compatMakefile.~44~ 1992-12-17 21:16:40 +00:00
Roland McGrath
501732ca84 Formerly configure.in.~6~ 1992-12-16 21:25:21 +00:00
Roland McGrath
17d92fd05b Formerly make.texinfo.~64~ 1992-12-16 00:08:34 +00:00
Roland McGrath
d0d141ea5b Formerly make.texinfo.~63~ 1992-12-15 19:35:51 +00:00
Roland McGrath
97f458f27e Formerly make.texinfo.~62~ 1992-12-11 01:10:17 +00:00
Roland McGrath
da96d5b5bb Formerly make.texinfo.~61~ 1992-12-10 20:04:37 +00:00
Roland McGrath
68aec7ab65 Formerly make.texinfo.~60~ 1992-12-10 18:48:19 +00:00
Noah Friedman
c1d26a2bde Formerly make.texinfo.~59~ 1992-12-09 23:32:39 +00:00
Roland McGrath
dfdedfe97a Formerly make.texinfo.~58~ 1992-12-09 23:28:14 +00:00
Roland McGrath
8c4eb82fb8 Formerly main.c.~64~ 1992-12-09 22:10:14 +00:00
Roland McGrath
2b42e280e8 Formerly default.c.~20~ 1992-12-09 22:09:42 +00:00
Roland McGrath
289417e089 Formerly read.c.~45~ 1992-12-09 21:02:53 +00:00
Roland McGrath
1faf31158c Formerly remake.c.~39~ 1992-12-09 20:34:36 +00:00
Roland McGrath
0a7da8a929 Formerly make.texinfo.~57~ 1992-12-09 19:35:34 +00:00
Roland McGrath
a3254ad7b3 Formerly variable.c.~13~ 1992-11-23 20:53:24 +00:00
Roland McGrath
b8b8ba69d4 Formerly default.c.~19~ 1992-11-23 20:48:49 +00:00
Roland McGrath
081275c58e Formerly make.h.~59~ 1992-11-23 20:41:02 +00:00
Roland McGrath
968e9fce6c Formerly job.c.~86~ 1992-11-23 20:04:25 +00:00
Roland McGrath
b81f248c35 Formerly main.c.~63~ 1992-11-23 20:04:19 +00:00
Roland McGrath
fa0cf27f72 Formerly read.c.~44~ 1992-11-18 19:54:01 +00:00
Roland McGrath
4cbb8e0d70 Formerly make.texinfo.~56~ 1992-11-17 23:43:09 +00:00
Roland McGrath
4a970dc04e Formerly make.texinfo.~55~ 1992-11-17 01:08:21 +00:00
Roland McGrath
4125f8f08e Formerly main.c.~62~ 1992-11-16 23:59:17 +00:00
Roland McGrath
45649948db Formerly vpath.c.~5~ 1992-11-16 22:49:14 +00:00
Roland McGrath
7d8fafa4b7 Formerly make.texinfo.~54~ 1992-11-13 23:19:57 +00:00
Roland McGrath
9e258d2369 Formerly rule.c.~9~ 1992-11-13 23:14:36 +00:00
Roland McGrath
1ab478ef48 Formerly make.texinfo.~53~ 1992-11-13 22:19:43 +00:00
Roland McGrath
ecc3b33299 Formerly job.c.~85~ 1992-11-12 20:45:29 +00:00
Roland McGrath
424bcccf98 Formerly read.c.~43~ 1992-11-10 21:41:55 +00:00
Roland McGrath
d13ecbbb67 Formerly dir.c.~8~ 1992-11-10 20:43:35 +00:00
Roland McGrath
09fe55be99 Formerly rule.c.~8~ 1992-11-10 20:36:44 +00:00
Roland McGrath
1efb91cda6 Formerly default.c.~18~ 1992-11-10 20:36:42 +00:00
Roland McGrath
3d72bcb583 Formerly function.c.~22~ 1992-11-10 20:36:39 +00:00
Roland McGrath
2fbb3407dd Formerly vpath.c.~4~ 1992-11-10 20:29:48 +00:00
Roland McGrath
9d58debbcc Formerly remake.c.~38~ 1992-11-09 22:52:52 +00:00
Roland McGrath
07a309961b Formerly make.h.~58~ 1992-11-09 22:52:50 +00:00
Roland McGrath
eae9bb14a2 Formerly job.c.~84~ 1992-11-09 22:52:13 +00:00
Roland McGrath
a401a5e46a Formerly read.c.~42~ 1992-11-05 23:33:11 +00:00
Roland McGrath
019a25fa84 Formerly vpath.c.~3~ 1992-11-05 23:33:08 +00:00
Roland McGrath
a8993377f7 Formerly compatMakefile.~43~ 1992-11-04 02:00:19 +00:00
Roland McGrath
8c9b95d07e Formerly file.c.~20~ 1992-11-04 01:44:30 +00:00
Roland McGrath
db8c8b2ad8 Formerly read.c.~41~ 1992-10-29 21:49:15 +00:00
Roland McGrath
55b9f37c35 Formerly make.texinfo.~52~ 1992-10-29 20:32:03 +00:00
Roland McGrath
815ee70d7d Formerly remake.c.~37~ 1992-10-25 06:16:09 +00:00
Roland McGrath
04b7426dfa Formerly commands.c.~12~ 1992-10-25 06:13:10 +00:00
Roland McGrath
0e4062c177 Formerly remake.c.~36~ 1992-10-25 05:49:07 +00:00
Roland McGrath
cff0af8d6d Formerly read.c.~40~ 1992-10-25 03:24:24 +00:00
Roland McGrath
8b591a8b90 Formerly expand.c.~5~ 1992-10-25 03:01:07 +00:00
Roland McGrath
deefc22d2f Formerly GNUmakefile.~80~ 1992-10-25 02:43:22 +00:00
Roland McGrath
a485ade084 Formerly variable.c.~12~ 1992-10-23 19:57:55 +00:00
Roland McGrath
b45d1ae3c2 Formerly default.c.~17~ 1992-10-15 23:11:06 +00:00
Roland McGrath
7db4dd0dbd Formerly dir.c.~7~ 1992-10-15 23:11:04 +00:00
Roland McGrath
348caf1627 Formerly compatMakefile.~42~ 1992-10-15 23:11:02 +00:00
Roland McGrath
6683a1c8db Formerly make.h.~57~ 1992-10-15 23:01:36 +00:00
Roland McGrath
d3543bc097 Formerly misc.c.~18~ 1992-10-15 23:01:34 +00:00
Roland McGrath
6247727678 Formerly job.c.~83~ 1992-10-12 21:58:54 +00:00
Roland McGrath
67516d5331 Formerly make.h.~56~ 1992-10-12 21:58:52 +00:00
Roland McGrath
e7f3e4a031 Formerly compatMakefile.~41~ 1992-10-12 20:32:29 +00:00
Roland McGrath
b0a49baf2f Formerly GNUmakefile.~79~ 1992-10-12 18:16:07 +00:00
Roland McGrath
d9ffca6d79 Formerly dir.c.~6~ 1992-10-12 18:05:41 +00:00
Roland McGrath
dba6ec5d0c Formerly file.c.~19~ 1992-10-12 18:04:07 +00:00
Roland McGrath
953f1c7df0 Formerly compatMakefile.~40~ 1992-10-12 17:46:23 +00:00
Roland McGrath
81acf8675a Formerly read.c.~39~ 1992-10-12 17:35:43 +00:00
Roland McGrath
f31ff1c1c4 Formerly main.c.~61~ 1992-10-11 21:26:57 +00:00
Roland McGrath
8140043344 Formerly dir.c.~5~ 1992-10-11 21:25:04 +00:00
Roland McGrath
29002aca14 Formerly compatMakefile.~39~ 1992-10-11 21:01:06 +00:00
Roland McGrath
a39f01fb1d Formerly configure.in.~4~ 1992-10-11 21:01:04 +00:00
Roland McGrath
b13de88757 Formerly read.c.~38~ 1992-10-09 18:00:37 +00:00
Roland McGrath
b3747a6bdb Formerly commands.c.~11~ 1992-10-09 17:50:59 +00:00
Roland McGrath
112dd3508d Formerly variable.c.~11~ 1992-10-09 17:50:55 +00:00
Roland McGrath
46ccc784fe Formerly dir.c.~4~ 1992-10-09 17:35:07 +00:00
Roland McGrath
9603279fb8 Formerly vpath.c.~2~ 1992-10-09 17:35:03 +00:00
Roland McGrath
e567c8d914 Formerly configure.in.~3~ 1992-10-09 16:12:29 +00:00
Roland McGrath
21d566bf51 Formerly make.h.~55~ 1992-10-02 23:42:13 +00:00
Roland McGrath
313e5ec45d Formerly main.c.~60~ 1992-09-30 23:21:22 +00:00
Roland McGrath
b0cafff1bf Formerly main.c.~59~ 1992-09-30 01:26:59 +00:00
Roland McGrath
f683e78f53 Formerly make.texinfo.~51~ 1992-09-30 00:47:33 +00:00
Roland McGrath
be0d85ba3e Formerly make.texinfo.~50~ 1992-09-25 19:37:40 +00:00
Robert J. Chassell
6a0cfeb0f2 Formerly make.texinfo.~49~ 1992-09-25 18:05:31 +00:00
Roland McGrath
1f534482de Formerly read.c.~37~ 1992-09-16 20:15:19 +00:00
Roland McGrath
144b6ecba5 Formerly main.c.~58~ 1992-09-15 20:10:46 +00:00
Roland McGrath
53f7c27956 Formerly read.c.~36~ 1992-09-15 19:14:03 +00:00
Roland McGrath
44251cbc0c Formerly remake.c.~35~ 1992-09-09 20:46:57 +00:00
Roland McGrath
a1849dfc5f Formerly job.c.~82~ 1992-09-09 20:32:56 +00:00
Roland McGrath
e7930bea3a Formerly commands.c.~10~ 1992-09-09 20:20:37 +00:00
Roland McGrath
d8f06cf21f Formerly default.c.~16~ 1992-09-09 19:50:38 +00:00
Roland McGrath
44653ac71b Formerly compatMakefile.~38~ 1992-09-02 22:03:40 +00:00
Roland McGrath
7f0fe7f44d Formerly make.h.~54~ 1992-09-02 21:53:59 +00:00
Roland McGrath
47839c882d Formerly make.texinfo.~48~ 1992-08-29 00:51:40 +00:00
Robert J. Chassell
e547c81b9a Formerly make.texinfo.~47~ 1992-08-28 18:27:35 +00:00
Roland McGrath
b52b376cf1 Formerly read.c.~35~ 1992-08-28 00:14:48 +00:00
Roland McGrath
e80a2e9424 Formerly compatMakefile.~37~ 1992-08-28 00:14:44 +00:00
Roland McGrath
e30c4023e1 Formerly read.c.~34~ 1992-08-27 23:53:17 +00:00
Roland McGrath
5aa595c99b Formerly remake.c.~34~ 1992-08-27 23:29:25 +00:00
Roland McGrath
a301f9327a Formerly GNUmakefile.~78~ 1992-08-27 23:25:59 +00:00
Roland McGrath
602d1e18af Formerly file.c.~18~ 1992-08-27 22:06:44 +00:00
Roland McGrath
178a758738 Formerly compatMakefile.~36~ 1992-08-27 21:51:23 +00:00
Roland McGrath
381a6bbfb4 Formerly configure.in.~2~ 1992-08-27 19:30:57 +00:00
Roland McGrath
f4a089447d Formerly make.texinfo.~46~ 1992-08-26 22:33:53 +00:00
Roland McGrath
d080dd0182 Formerly main.c.~57~ 1992-08-26 21:47:38 +00:00
Roland McGrath
37bfd879df Formerly remake.c.~33~ 1992-08-26 21:18:03 +00:00
Roland McGrath
4d345bdee3 Formerly GNUmakefile.~77~ 1992-08-26 21:00:12 +00:00
Roland McGrath
e222f10616 Formerly make.texinfo.~45~ 1992-08-20 23:27:46 +00:00
Robert J. Chassell
9869db36e9 Formerly make.texinfo.~44~ 1992-08-20 21:29:58 +00:00
Roland McGrath
2ebdf6de85 Formerly job.c.~81~ 1992-08-20 18:20:20 +00:00
Roland McGrath
db7633eac4 Formerly remake.c.~32~ 1992-08-20 18:10:20 +00:00
Roland McGrath
8fbb772041 Formerly make.texinfo.~43~ 1992-08-19 22:16:47 +00:00
Roland McGrath
3c660b4d55 Formerly function.c.~21~ 1992-08-19 22:16:15 +00:00
Roland McGrath
0fad0bd5c5 Formerly compatMakefile.~35~ 1992-08-19 20:24:03 +00:00
Roland McGrath
1fa7491d02 Initial revision 1992-08-18 21:25:14 +00:00
Roland McGrath
1292aa1e4b Formerly make.texinfo.~42~ 1992-08-18 18:59:26 +00:00
Roland McGrath
0c61dffcb5 Formerly make.texinfo.~41~ 1992-08-14 18:47:05 +00:00
Robert J. Chassell
30016eef42 Formerly make.texinfo.~40~ 1992-08-14 18:39:14 +00:00
Roland McGrath
781ce7f4a8 Formerly arscan.c.~25~ 1992-08-14 16:37:50 +00:00
Roland McGrath
c76d6785de Formerly GNUmakefile.~76~ 1992-08-13 22:09:36 +00:00
Roland McGrath
81731a29d1 Formerly main.c.~56~ 1992-08-13 21:50:48 +00:00
Roland McGrath
ad93a01fa6 Formerly make.texinfo.~39~ 1992-08-11 21:03:44 +00:00
Roland McGrath
423783c913 Formerly implicit.c.~6~ 1992-08-10 22:08:41 +00:00
Roland McGrath
ccff1cc0d2 Formerly function.c.~20~ 1992-08-10 22:03:03 +00:00
Roland McGrath
47707f76cb Formerly compatMakefile.~34~ 1992-08-10 21:05:08 +00:00
Roland McGrath
3241a91312 Formerly file.c.~17~ 1992-08-02 11:28:04 +00:00
Roland McGrath
b732b99c0b Formerly variable.c.~10~ 1992-08-02 11:28:03 +00:00
Roland McGrath
b001b6a55a Formerly file.h.~4~ 1992-08-02 11:28:01 +00:00
Roland McGrath
24c9aabe16 Formerly make.h.~53~ 1992-08-02 11:28:00 +00:00
Roland McGrath
92df7dd504 Formerly variable.h.~8~ 1992-08-02 11:27:59 +00:00
Roland McGrath
fba924717c Formerly GNUmakefile.~75~ 1992-08-02 10:36:52 +00:00
Roland McGrath
e07d203a2f Formerly file.c.~16~ 1992-08-02 10:16:54 +00:00
Roland McGrath
92546f9ff9 Formerly rule.h.~3~ 1992-08-02 10:11:29 +00:00
Roland McGrath
849b2101e6 Formerly rule.c.~7~ 1992-08-02 10:11:25 +00:00
Roland McGrath
09a534168f Formerly file.h.~3~ 1992-08-02 09:51:40 +00:00
Roland McGrath
a98a648754 Formerly make.h.~52~ 1992-08-02 09:10:08 +00:00
Roland McGrath
f4c3f77b96 Formerly variable.h.~7~ 1992-08-02 09:10:05 +00:00
Roland McGrath
b95e47d401 Formerly variable.c.~9~ 1992-08-02 09:10:03 +00:00
Roland McGrath
8aff0091fc Formerly dep.h.~2~ 1992-08-02 05:42:58 +00:00
Roland McGrath
bc8c4949b7 Formerly GNUmakefile.~74~ 1992-07-30 20:32:16 +00:00
Roland McGrath
f44c1d9366 Formerly main.c.~55~ 1992-07-30 20:31:50 +00:00
Roland McGrath
5329b592b7 Formerly default.c.~15~ 1992-07-30 19:53:39 +00:00
Roland McGrath
39e2dbb7b3 Formerly make.h.~51~ 1992-07-30 19:41:18 +00:00
Roland McGrath
47db5afe4f Formerly make.h.~50~ 1992-07-26 22:30:45 +00:00
Roland McGrath
19142fcfd4 Formerly job.c.~80~ 1992-07-26 20:57:13 +00:00
Roland McGrath
2283b32986 Formerly variable.c.~8~ 1992-07-24 06:16:47 +00:00
Roland McGrath
2e5f56539d Formerly main.c.~54~ 1992-07-24 06:02:26 +00:00
Roland McGrath
a63f4e1f9c Formerly make.texinfo.~38~ 1992-07-24 02:23:53 +00:00
Roland McGrath
1d2e7e6142 Formerly make.texinfo.~37~ 1992-07-24 02:03:20 +00:00
Robert J. Chassell
099b302768 Formerly make.texinfo.~36~ 1992-07-24 00:25:51 +00:00
Robert J. Chassell
c29174d96b Formerly make.texinfo.~35~ 1992-07-17 17:05:55 +00:00
Robert J. Chassell
cda455684c Formerly make.texinfo.~34~ 1992-07-16 22:42:17 +00:00
Roland McGrath
0858bbcfb5 Formerly GNUmakefile.~73~ 1992-07-16 19:17:12 +00:00
Roland McGrath
f23e838c15 Formerly README.template.~3~ 1992-07-16 18:35:19 +00:00
Roland McGrath
5814d65428 Formerly GNUmakefile.~72~ 1992-07-16 18:34:43 +00:00
Roland McGrath
f8197823a4 Formerly main.c.~53~ 1992-07-16 18:31:50 +00:00
Roland McGrath
b408ee65f6 Formerly remake.c.~31~ 1992-07-15 02:15:54 +00:00
Roland McGrath
0f045633a7 Formerly main.c.~52~ 1992-07-15 02:15:53 +00:00
Roland McGrath
62e8630bdc Formerly rule.c.~6~ 1992-07-14 23:08:36 +00:00
Roland McGrath
eb7484abc4 Formerly GNUmakefile.~71~ 1992-07-13 22:17:50 +00:00
Roland McGrath
8ef3af8bed Formerly commands.c.~9~ 1992-07-13 21:51:47 +00:00
Roland McGrath
4eb52d9a45 Formerly make.texinfo.~33~ 1992-07-10 05:18:22 +00:00
Roland McGrath
7817332cc1 Formerly variable.h.~6~ 1992-07-10 04:06:24 +00:00
Roland McGrath
e3fbb5828f Formerly variable.c.~7~ 1992-07-10 04:06:22 +00:00
Roland McGrath
45cf6ce658 Formerly compatMakefile.~33~ 1992-07-10 01:40:44 +00:00
Roland McGrath
69222204e6 Formerly compatMakefile.~32~ 1992-07-07 23:55:43 +00:00
Roland McGrath
dc2a270b71 Formerly job.c.~79~ 1992-07-07 23:12:46 +00:00
Roland McGrath
9c7598db10 Formerly make.texinfo.~32~ 1992-07-07 01:04:06 +00:00
Roland McGrath
00fb56c2b9 Formerly GNUmakefile.~70~ 1992-07-05 01:55:13 +00:00
Roland McGrath
e37b0392be Formerly commands.c.~8~ 1992-07-05 00:52:52 +00:00
Roland McGrath
7dba11957a Formerly job.c.~78~ 1992-07-05 00:52:50 +00:00
Roland McGrath
517a17b6d9 Formerly main.c.~51~ 1992-07-05 00:52:48 +00:00
Roland McGrath
9d3d0c6b79 Formerly make.h.~49~ 1992-07-05 00:52:46 +00:00
Roland McGrath
bc1770c035 Formerly remote-cstms.c.~6~ 1992-07-05 00:52:45 +00:00
Roland McGrath
50cd0d5a12 Formerly main.c.~50~ 1992-07-02 22:48:17 +00:00
Roland McGrath
8d6f98b83d Formerly GNUmakefile.~69~ 1992-07-01 22:37:12 +00:00
Roland McGrath
8809c8ec38 Formerly job.c.~77~ 1992-07-01 00:52:45 +00:00
Roland McGrath
6feabe12a7 Formerly file.c.~15~ 1992-07-01 00:52:43 +00:00
Roland McGrath
41d94fb0e3 Formerly function.c.~19~ 1992-07-01 00:52:41 +00:00
Roland McGrath
d425bd20a2 Formerly make.h.~48~ 1992-07-01 00:52:39 +00:00
Roland McGrath
e7e9d84a54 Formerly arscan.c.~24~ 1992-07-01 00:52:37 +00:00
Roland McGrath
c84a275871 Formerly make.texinfo.~31~ 1992-06-26 00:58:23 +00:00
Roland McGrath
8d1f6733a9 Formerly GNUmakefile.~68~ 1992-06-26 00:54:04 +00:00
Roland McGrath
c355295fe0 Formerly README.template.~2~ 1992-06-26 00:52:43 +00:00
Roland McGrath
9ef264a343 Formerly remake.c.~30~ 1992-06-26 00:46:53 +00:00
Roland McGrath
fec3694512 Formerly job.c.~76~ 1992-06-26 00:33:00 +00:00
Roland McGrath
eaa2a12a44 Formerly main.c.~49~ 1992-06-25 21:45:52 +00:00
Roland McGrath
1b3fc99e0f Formerly compatMakefile.~31~ 1992-06-25 21:10:49 +00:00
Roland McGrath
e293b96610 Formerly dir.c.~3~ 1992-06-25 01:05:20 +00:00
Roland McGrath
f2c51355ed Formerly make.h.~47~ 1992-06-25 00:28:36 +00:00
Roland McGrath
7ab1580762 Formerly job.c.~75~ 1992-06-25 00:13:20 +00:00
Roland McGrath
a819615113 Formerly make.texinfo.~30~ 1992-06-24 23:40:28 +00:00
Roland McGrath
f519275024 Formerly file.c.~14~ 1992-06-23 22:42:43 +00:00
Roland McGrath
7a9130401f Formerly compatMakefile.~30~ 1992-06-22 20:34:09 +00:00
Roland McGrath
bfb4dddc2e Formerly GNUmakefile.~67~ 1992-06-22 20:34:05 +00:00
Roland McGrath
6f322b59da Formerly arscan.c.~23~ 1992-06-19 20:21:54 +00:00
Roland McGrath
320a119913 Formerly make.texinfo.~29~ 1992-06-18 23:25:43 +00:00
Robert J. Chassell
fcd3964082 Formerly make.texinfo.~28~ 1992-06-18 23:17:48 +00:00
Roland McGrath
eeb9b7065d Formerly default.c.~14~ 1992-06-17 21:59:54 +00:00
Roland McGrath
2aed822bd7 Formerly compatMakefile.~29~ 1992-06-17 02:07:35 +00:00
Roland McGrath
add4780bf7 Formerly commands.c.~7~ 1992-06-16 23:43:37 +00:00
Roland McGrath
df884f9d9a Formerly file.c.~13~ 1992-06-16 23:43:35 +00:00
Roland McGrath
498f1b50f7 Formerly make.h.~46~ 1992-06-16 23:43:31 +00:00
Roland McGrath
29380252a8 Formerly expand.c.~4~ 1992-06-16 23:43:29 +00:00
Roland McGrath
ade465512f Formerly arscan.c.~22~ 1992-06-16 23:43:25 +00:00
Roland McGrath
37fbe2a271 Formerly compatMakefile.~28~ 1992-06-16 01:30:57 +00:00
Roland McGrath
15614defd8 Formerly GNUmakefile.~66~ 1992-06-16 01:25:32 +00:00
Roland McGrath
b5ee5f8539 Formerly variable.c.~6~ 1992-06-15 22:41:38 +00:00
Roland McGrath
febf5d0944 Formerly make.h.~45~ 1992-06-15 22:41:21 +00:00
Roland McGrath
9e37e514d2 Formerly arscan.c.~21~ 1992-06-15 22:38:32 +00:00
Roland McGrath
5c2f4a7d88 Formerly job.c.~74~ 1992-06-15 22:10:36 +00:00
Roland McGrath
db8eb71a9c Formerly compatMakefile.~27~ 1992-06-15 21:53:41 +00:00
Roland McGrath
5780852aee Formerly job.c.~73~ 1992-06-15 21:47:25 +00:00
Roland McGrath
6619d7d8ac Formerly remake.c.~29~ 1992-06-15 21:47:19 +00:00
Roland McGrath
82f7d51bde Formerly file.c.~12~ 1992-06-15 16:39:11 +00:00
Roland McGrath
8407664cf6 Formerly job.c.~72~ 1992-06-12 23:41:40 +00:00
Roland McGrath
b5b32c8f9a Formerly file.h.~2~ 1992-06-12 23:17:24 +00:00
Roland McGrath
3dbe309fce Formerly make.texinfo.~27~ 1992-06-12 23:12:20 +00:00
Robert J. Chassell
87c5a97b91 Formerly make.texinfo.~26~ 1992-06-12 22:52:31 +00:00
Robert J. Chassell
83bb8c72a7 Formerly make.texinfo.~25~ 1992-06-12 20:59:52 +00:00
Robert J. Chassell
2172dfa41f Formerly make.texinfo.~24~ 1992-06-12 03:51:46 +00:00
Roland McGrath
ef46822708 Formerly variable.h.~5~ 1992-06-12 00:29:24 +00:00
Roland McGrath
78e7551083 Formerly expand.c.~3~ 1992-06-12 00:29:21 +00:00
Roland McGrath
d298fecfda Formerly GNUmakefile.~65~ 1992-06-12 00:29:17 +00:00
Roland McGrath
d3ea420650 Formerly job.c.~71~ 1992-06-12 00:21:48 +00:00
Roland McGrath
067777e77d Formerly arscan.c.~20~ 1992-06-11 22:30:17 +00:00
Roland McGrath
5ccd482b90 Formerly compatMakefile.~26~ 1992-06-11 20:08:55 +00:00
Roland McGrath
3893d9217c Formerly main.c.~48~ 1992-06-11 20:05:40 +00:00
Roland McGrath
efc335d4a1 Formerly GNUmakefile.~64~ 1992-06-11 05:33:52 +00:00
Roland McGrath
b9f64130af Formerly make.h.~44~ 1992-06-11 05:30:34 +00:00
Roland McGrath
0a4502e116 Formerly compatMakefile.~25~ 1992-06-11 05:30:32 +00:00
Roland McGrath
b6364d9ae4 Formerly job.c.~70~ 1992-06-11 05:25:28 +00:00
Roland McGrath
59caea5674 Formerly read.c.~33~ 1992-06-11 05:16:34 +00:00
Roland McGrath
2f5b18ba2f Formerly commands.c.~6~ 1992-06-11 05:12:44 +00:00
Roland McGrath
5631243fdd Formerly remake.c.~28~ 1992-06-11 05:05:49 +00:00
Roland McGrath
a61fc8acd1 Formerly dir.c.~2~ 1992-06-11 04:58:32 +00:00
Roland McGrath
b87ff76b7e Formerly remote-cstms.c.~5~ 1992-06-11 04:58:23 +00:00
Roland McGrath
1c9e851fe0 Formerly main.c.~47~ 1992-06-11 04:58:20 +00:00
Roland McGrath
5382f6d197 Formerly misc.c.~17~ 1992-06-11 04:58:15 +00:00
Roland McGrath
8ca2f785e2 Formerly arscan.c.~19~ 1992-06-11 04:58:10 +00:00
Roland McGrath
459c8137c0 Formerly ar.c.~2~ 1992-06-11 04:58:08 +00:00
Roland McGrath
9165d8e5d1 Formerly variable.h.~4~ 1992-06-11 02:28:31 +00:00
Roland McGrath
fcc5c80298 Formerly variable.c.~5~ 1992-06-11 02:27:16 +00:00
Roland McGrath
e309bb2f76 Formerly expand.c.~2~ 1992-06-11 02:27:09 +00:00
Roland McGrath
92dc493189 Formerly read.c.~32~ 1992-06-11 02:07:33 +00:00
Roland McGrath
39f1bf9ce8 Formerly job.c.~69~ 1992-06-05 01:04:26 +00:00
Roland McGrath
fe8bcf44ef Formerly main.c.~46~ 1992-06-05 01:04:07 +00:00
Roland McGrath
56ccbcff9a Formerly file.c.~11~ 1992-06-04 03:52:53 +00:00
Roland McGrath
72b7cf376b Formerly GNUmakefile.~63~ 1992-06-03 03:24:11 +00:00
Roland McGrath
374e8d510a Formerly commands.c.~5~ 1992-06-03 01:45:11 +00:00
Roland McGrath
343ac48a2d Formerly commands.c.~4~ 1992-06-03 01:17:16 +00:00
Roland McGrath
85bab9477b Formerly default.c.~13~ 1992-06-03 01:13:51 +00:00
Roland McGrath
835c266436 Formerly make.h.~43~ 1992-06-03 01:13:30 +00:00
Roland McGrath
6b0a5fd941 Formerly arscan.c.~18~ 1992-06-03 01:07:39 +00:00
Roland McGrath
1e9a5d4b8e Formerly GNUmakefile.~62~ 1992-05-28 05:03:09 +00:00
Roland McGrath
b238874895 Formerly GNUmakefile.~61~ 1992-05-26 10:26:59 +00:00
Roland McGrath
fc1ec6ab56 Formerly rule.c.~5~ 1992-05-26 05:26:26 +00:00
Roland McGrath
b4f6efcf69 Formerly main.c.~45~ 1992-05-25 23:02:13 +00:00
Roland McGrath
b3cc9ddd66 Formerly make.texinfo.~23~ 1992-05-21 20:34:22 +00:00
Roland McGrath
3a34103bb6 Formerly compatMakefile.~24~ 1992-05-20 00:51:39 +00:00
Roland McGrath
6268af4ceb Formerly main.c.~44~ 1992-05-20 00:49:58 +00:00
Roland McGrath
ecfe56b932 Formerly job.c.~68~ 1992-05-14 20:42:25 +00:00
Roland McGrath
16d81de018 Formerly GNUmakefile.~60~ 1992-05-14 20:05:17 +00:00
Roland McGrath
a5a036c101 Formerly job.c.~67~ 1992-05-13 22:28:01 +00:00
Roland McGrath
792819609a Formerly job.c.~66~ 1992-05-12 21:32:24 +00:00
Roland McGrath
3b69c7a484 Formerly main.c.~43~ 1992-05-12 17:29:57 +00:00
Roland McGrath
8ed1c7446e Formerly make.texinfo.~22~ 1992-05-12 04:43:56 +00:00
Roland McGrath
8486a30c74 Formerly variable.c.~4~ 1992-05-12 04:42:11 +00:00
Roland McGrath
8696be1950 Formerly GNUmakefile.~59~ 1992-05-11 19:21:28 +00:00
Roland McGrath
b43df925f8 Formerly compatMakefile.~23~ 1992-05-11 19:20:28 +00:00
Roland McGrath
cfe0c54e8c Formerly main.c.~42~ 1992-05-11 18:11:40 +00:00
Roland McGrath
81db471695 Formerly make.texinfo.~21~ 1992-05-11 05:31:18 +00:00
Roland McGrath
eb5d80d39a Formerly main.c.~41~ 1992-05-11 05:28:52 +00:00
Roland McGrath
ea3d4b3712 Formerly main.c.~40~ 1992-05-09 04:28:28 +00:00
Roland McGrath
cf561391a1 Formerly GNUmakefile.~58~ 1992-05-09 04:06:58 +00:00
Roland McGrath
276016fba7 Formerly compatMakefile.~22~ 1992-05-09 04:02:30 +00:00
Roland McGrath
d9dedc8f27 Formerly job.c.~65~ 1992-05-09 02:26:35 +00:00
Roland McGrath
569cdeac4e Formerly read.c.~31~ 1992-05-07 02:02:33 +00:00
Roland McGrath
48cabc8f9f Formerly job.c.~64~ 1992-05-05 22:04:08 +00:00
Roland McGrath
69e9db54be Formerly GNUmakefile.~57~ 1992-05-04 22:54:21 +00:00
Roland McGrath
1be71be2a2 Formerly make.texinfo.~20~ 1992-05-04 22:47:45 +00:00
Roland McGrath
2ebaa9f881 Formerly variable.c.~3~ 1992-05-04 22:37:22 +00:00
Roland McGrath
207db3747f Formerly read.c.~30~ 1992-05-04 22:37:19 +00:00
Roland McGrath
a3bd6fa73f Formerly variable.h.~3~ 1992-05-04 22:33:57 +00:00
Roland McGrath
883239f29a Formerly GNUmakefile.~56~ 1992-05-03 22:24:16 +00:00
Roland McGrath
e74b5d4fbf Formerly make.texinfo.~19~ 1992-05-03 22:21:18 +00:00
Roland McGrath
7a7b9644aa Formerly variable.h.~2~ 1992-05-03 22:09:16 +00:00
Roland McGrath
a2032ba51f Formerly read.c.~29~ 1992-05-03 22:03:26 +00:00
Roland McGrath
b8d48ad379 Formerly variable.c.~2~ 1992-05-03 22:02:26 +00:00
Roland McGrath
fec655d5e9 Formerly main.c.~39~ 1992-05-01 15:39:36 +00:00
Roland McGrath
9edeb3ad8e Formerly main.c.~38~ 1992-04-30 22:17:12 +00:00
Roland McGrath
56f17eb659 Formerly job.c.~63~ 1992-04-30 21:50:23 +00:00
Roland McGrath
d052fb99ee Formerly misc.c.~16~ 1992-04-29 21:23:10 +00:00
Roland McGrath
be3ab15f71 Formerly remake.c.~27~ 1992-04-29 21:22:58 +00:00
Roland McGrath
6a325039e2 Formerly main.c.~37~ 1992-04-29 21:15:52 +00:00
Roland McGrath
08ab2b7f94 Formerly job.c.~62~ 1992-04-29 21:11:44 +00:00
Roland McGrath
d724ba1739 Formerly job.c.~61~ 1992-04-29 01:10:14 +00:00
Roland McGrath
687844b2fe Formerly rule.c.~4~ 1992-04-29 00:44:29 +00:00
Roland McGrath
8b8764b427 Formerly rule.c.~3~ 1992-04-26 19:19:06 +00:00
Roland McGrath
f959c6b5b5 Formerly job.c.~60~ 1992-04-22 01:52:14 +00:00
Roland McGrath
7d375209b9 Formerly GNUmakefile.~55~ 1992-04-21 08:01:27 +00:00
Roland McGrath
75448c19f4 Formerly job.c.~59~ 1992-04-21 07:59:32 +00:00
Roland McGrath
a80e32c0fe Formerly main.c.~36~ 1992-04-21 07:56:07 +00:00
Roland McGrath
02b78d7ed0 Formerly commands.c.~3~ 1992-04-21 07:50:13 +00:00
Roland McGrath
3fcefefce5 Formerly function.c.~17~ 1992-04-21 07:50:09 +00:00
Roland McGrath
00da07ebd1 Formerly job.h.~3~ 1992-04-21 07:50:08 +00:00
Roland McGrath
79a2237ed2 Formerly remake.c.~26~ 1992-04-21 07:44:18 +00:00
Roland McGrath
fb37865802 Formerly job.h.~2~ 1992-04-21 07:16:26 +00:00
Roland McGrath
4ee750d034 Formerly job.c.~58~ 1992-04-15 06:02:36 +00:00
Roland McGrath
a31b168049 Formerly GNUmakefile.~54~ 1992-04-14 23:35:25 +00:00
Roland McGrath
22fda945cc Formerly implicit.c.~5~ 1992-04-14 22:39:01 +00:00
Roland McGrath
c5f7787f37 Formerly make.h.~42~ 1992-04-14 22:37:04 +00:00
Roland McGrath
7c92d87313 Formerly read.c.~28~ 1992-04-14 22:31:19 +00:00
Roland McGrath
491a9d9cb4 Formerly GNUmakefile.~53~ 1992-04-14 02:30:18 +00:00
Roland McGrath
71956239ac Formerly remake.c.~25~ 1992-04-14 02:12:51 +00:00
Roland McGrath
123c2494c3 Formerly remake.c.~24~ 1992-04-01 10:06:27 +00:00
Roland McGrath
d8742e9b3e Formerly file.c.~10~ 1992-04-01 09:58:26 +00:00
Roland McGrath
a7ec3f0576 Formerly read.c.~27~ 1992-04-01 09:42:11 +00:00
Roland McGrath
008dab1b25 Formerly commands.c.~2~ 1992-03-31 00:24:58 +00:00
Roland McGrath
d922934cf8 Formerly rule.c.~2~ 1992-03-24 09:50:46 +00:00
Roland McGrath
39d4bb0c7a Formerly remake.c.~23~ 1992-03-11 19:59:26 +00:00
Roland McGrath
feb8a001e1 Formerly make.texinfo.~18~ 1992-03-11 19:56:18 +00:00
melissa
9573cef0a8 Formerly make.texinfo.~17~ 1992-03-11 03:20:05 +00:00
melissa
bc8dd5d3f0 Formerly make.texinfo.~15~ 1992-03-10 23:51:10 +00:00
Roland McGrath
a4bfdb8264 Formerly remote-stub.c.~2~ 1992-03-10 22:15:46 +00:00
Roland McGrath
ee200385e4 Formerly remote-cstms.c.~4~ 1992-03-10 22:15:39 +00:00
Roland McGrath
c7ba588030 Formerly compatMakefile.~21~ 1992-03-10 22:15:32 +00:00
Roland McGrath
8da2a78834 Formerly job.c.~57~ 1992-03-10 22:15:30 +00:00
Roland McGrath
1fc97863a0 Formerly file.c.~9~ 1992-03-09 23:17:21 +00:00
Roland McGrath
46677a6769 Initial revision 1992-03-09 23:06:05 +00:00
Roland McGrath
4f811a3de9 Formerly compatMakefile.~20~ 1992-03-09 23:00:07 +00:00
Roland McGrath
13f4412f2c Formerly function.c.~16~ 1992-03-01 20:48:57 +00:00
Roland McGrath
edbca2344d Formerly make.texinfo.~14~ 1992-02-26 04:34:35 +00:00
Roland McGrath
794fb5ac89 Formerly GNUmakefile.~52~ 1992-02-16 07:20:51 +00:00
Roland McGrath
f5c49a3f5c Initial revision 1992-02-15 22:12:14 +00:00
Roland McGrath
5adf3025db Formerly read.c.~26~ 1992-02-14 11:30:14 +00:00
Roland McGrath
24e5b78f36 Initial revision 1992-02-14 10:52:22 +00:00
Roland McGrath
ba251262db Formerly main.c.~35~ 1992-02-14 05:15:30 +00:00
Roland McGrath
0642eea2ab Formerly make.texinfo.~13~ 1992-02-12 17:07:34 +00:00
Roland McGrath
6858598bee Formerly GNUmakefile.~51~ 1992-02-06 22:12:06 +00:00
Roland McGrath
87178cb5a4 Formerly job.c.~56~ 1992-02-05 01:04:23 +00:00
Roland McGrath
3e08b8c56a Formerly make.h.~41~ 1992-01-29 23:54:37 +00:00
Roland McGrath
ba26d609a1 Initial revision 1992-01-29 23:54:36 +00:00
Robert J. Chassell
7eda2f8293 Formerly make.texinfo.~12~ 1992-01-23 22:25:20 +00:00
Roland McGrath
cb14b4eb1e Initial revision 1992-01-20 19:14:46 +00:00
Roland McGrath
d2e5ab8c57 Initial revision 1992-01-20 18:49:36 +00:00
Roland McGrath
3798621e0b Initial revision 1992-01-18 02:09:28 +00:00
Roland McGrath
94527665c2 Initial revision 1992-01-17 08:30:31 +00:00
Roland McGrath
77497793e0 Formerly misc.c.~15~ 1992-01-17 08:30:27 +00:00
Roland McGrath
6a2935d67b Formerly default.c.~12~ 1992-01-14 02:12:09 +00:00
Roland McGrath
ee02d42916 Formerly make.texinfo.~11~ 1992-01-14 00:15:26 +00:00
Roland McGrath
b859320606 Initial revision 1992-01-11 11:37:36 +00:00
Roland McGrath
1eadb68598 Initial revision 1992-01-11 11:09:59 +00:00
Roland McGrath
8ac061de69 Formerly make.texinfo.~10~ 1992-01-11 07:20:24 +00:00
Roland McGrath
45fa41ff5c Formerly make.texinfo.~9~ 1991-12-30 18:11:55 +00:00
Roland McGrath
bdb62b6fe9 Formerly make.texinfo.~8~ 1991-11-15 02:22:08 +00:00
Roland McGrath
12220aa8fd Formerly arscan.c.~17~ 1991-10-23 01:30:25 +00:00
Roland McGrath
da136cba6f Initial revision 1991-10-18 19:26:24 +00:00
Roland McGrath
a4a1d4a78d Initial revision 1991-10-08 20:20:29 +00:00
Roland McGrath
6af05c6197 Initial revision 1991-10-08 20:04:17 +00:00
Roland McGrath
42289c5f18 Formerly implicit.c.~4~ 1991-10-08 20:04:11 +00:00
Roland McGrath
fb0ffcddc8 Formerly arscan.c.~16~ 1991-10-07 22:05:49 +00:00
Roland McGrath
97d38d0817 Initial revision 1991-10-07 22:04:20 +00:00
Roland McGrath
bd3a693fd4 Initial revision 1991-09-24 04:03:40 +00:00
Roland McGrath
4575aeb1e7 Formerly make.man.~3~ 1991-09-24 03:33:24 +00:00
Roland McGrath
c6fec241bc Formerly make.texinfo.~7~ 1991-09-18 19:07:51 +00:00
Roland McGrath
b9c983dee3 Initial revision 1991-09-15 21:20:45 +00:00
Roland McGrath
1a51e308e5 Initial revision 1991-09-13 23:39:37 +00:00
Roland McGrath
462a5eabb4 Formerly rule.h.~2~ 1991-06-03 20:37:28 +00:00
Roland McGrath
59fdb0d242 Initial revision 1991-06-03 20:37:27 +00:00
Roland McGrath
19ca125ae7 Initial revision 1991-03-23 14:10:48 +00:00
Roland McGrath
47a8cea564 Formerly make.man.~2~ 1990-09-17 20:01:40 +00:00
Roland McGrath
a7e692dc7a Initial revision 1990-01-25 05:31:33 +00:00
Roland McGrath
cd20a6a67f Initial revision 1989-08-13 07:28:15 +00:00
Roland McGrath
38892f2959 Initial revision 1989-06-11 21:44:40 +00:00
Roland McGrath
83fcf12d25 Initial revision 1989-05-10 22:57:31 +00:00
Roland McGrath
db3c60d235 Minor editorial changes. 1988-07-10 17:52:55 +00:00
Roland McGrath
2153102725 Changed `Features' chapter, giving credit to some
people who may have invented some things.
1988-07-10 00:51:51 +00:00
Roland McGrath
bf81164407 Gave credit for VPATH to System V (where it was invented, but
is undocumented) as well as 4.3 BSD (where it was taken from
System V and documented).
Added the replacement of filenames found via VPATH search inside
commands to `Missing' list.  Maybe implement this soon?
1988-07-04 13:41:43 +00:00
Roland McGrath
3206072ac3 * Misc cleanup from RMS.
* Documented `word' and `words' functions.
* Bumped revision number to match make.c
1988-07-03 20:59:14 +00:00
Roland McGrath
c9be6b239c Added some more stuff about recursive references. 1988-07-03 13:07:42 +00:00
Roland McGrath
78079dd062 Misc cleanup. Fixed `Features' list slightly. 1988-07-02 17:49:14 +00:00
Roland McGrath
da1fb0f2e9 Added copying conditions. 1988-07-02 12:14:48 +00:00
Roland McGrath
b85736329a * Fixed a minor grammaticaly error.
* Second release.
1988-06-28 21:58:42 +00:00
Roland McGrath
b8342bbfa8 Added recursive variable references. 1988-06-19 16:15:50 +00:00
Roland McGrath
0bc8f78d4b Fixed yet another Texinfo error. (Sigh) 1988-06-18 01:16:59 +00:00
Roland McGrath
03e57530fa Fixed some more Texinfo errors. 1988-06-18 00:26:10 +00:00
Roland McGrath
6e427e1209 * Documented that -k will continue if it doesn't know how to make a file.
* Fixed a Texinfo error.
* Bumped revision number to match the source.
1988-06-18 00:19:49 +00:00
Roland McGrath
0bc6cc3735 * Removed Bourne shell $(a-b), etc. variable references.
* Fixed foreach documentation slightly.
* Added chapter listing features tersely.
1988-06-18 00:13:50 +00:00
Roland McGrath
6b7b5698e9 Misc cleanup by RMS.
Removed RCS log.
1988-06-14 21:38:42 +00:00
Roland McGrath
edacffc68d Added more stuff about `foreach'. 1988-06-10 11:43:00 +00:00
Roland McGrath
8d8b42b086 * Fixed a typo in the `Missing' section.
* Added an example of how to replace the System V $$@ feature
  using static pattern rules.
1988-06-03 00:07:30 +00:00
Roland McGrath
4f7ffc8c0f Added foreach' and sort' functions. 1988-05-30 21:39:16 +00:00
Roland McGrath
15c5b63713 * Removed built-in .? -> .s suffix rules.
* Misc cleanup, etc.
1988-05-26 17:55:55 +00:00
206 changed files with 70939 additions and 4301 deletions

32
.cvsignore Normal file
View File

@@ -0,0 +1,32 @@
*.gz *.Z *.tar *.tgz
=*
TODO COPYING* ABOUT-NLS
make-3* make-test*
*.info *.info-*
stamp-*
makebook*
.*gdbinit
*.dep *.dvi *.toc *.aux *.log
*.cp *.cps *.fn *.fns *.vr *.vrs *.tp *.tps *.ky *.kys *.pg *.pgs
README README.DOS README.W32
aclocal.m4 autom4te.cache
config.h.in config.h config.status config.cache configure
Makefile.in Makefile
build.sh.in build.sh
SMakefile NMakefile Makefile.DOS
config.ami configh.dos config.h.W32 config.h-vms
loadavg loadavg.c make
.deps .dep_segment
_*
sun4 i386 i386-netbsd hp300-netbsd hp300 rs6000 sun3 news800 amiga
hp700 hp834 mips sol2 i486-linux
customs
install-sh mkinstalldirs

12
.purify Normal file
View File

@@ -0,0 +1,12 @@
# Solaris (2.5.1) has a couple if issues.
#
suppress plk malloc; setvbuf "libc*"; main "main.c"
suppress umr kstat_read; kstat_chain_update; kstat_open; getloadavg
suppress umr kstat_chain_update; kstat_open; getloadavg
# The command line options stuff leaks a little bit. No big deal.
#
suppress mlk malloc; xmalloc "misc.c"; decode_env_switches "main.c"
suppress plk malloc; xmalloc "misc.c"; decode_env_switches "main.c"
suppress mlk malloc; xmalloc "misc.c"; concat "misc.c"; decode_env_switches "main.c"
suppress plk malloc; xmalloc "misc.c"; concat "misc.c"; decode_env_switches "main.c"

57
AUTHORS Normal file
View File

@@ -0,0 +1,57 @@
-----------------------------------
GNU make development up to version 3.75 by:
Roland McGrath <roland@gnu.org>
Development starting with GNU make 3.76 by:
Paul D. Smith <psmith@gnu.org>
GNU Make User's Manual
Written by:
Richard M. Stallman <rms@gnu.org>
Edited by:
Roland McGrath <roland@gnu.org>
Bob Chassell <bob@gnu.org>
Melissa Weisshaus <melissa@gnu.org>
Paul D. Smith <psmith@gnu.org>
-----------------------------------
GNU make porting efforts:
Port to VMS by:
Klaus Kaempf <kkaempf@progis.de>
Archive support/Bug fixes by:
John W. Eaton <jwe@bevo.che.wisc.edu>
Martin Zinser <zinser@decus.decus.de>
Port to Amiga by:
Aaron Digulla <digulla@fh-konstanz.de>
Port to MS-DOS (DJGPP) and MS-Windows 95/NT by:
DJ Delorie <dj@delorie.com>
Rob Tulloh <rob_tulloh@tivoli.com>
Eli Zaretskii <eliz@is.elta.co.il>
-----------------------------------
Other contributors:
Janet Carson <janet_carson@tivoli.com>
Howard Chu <hyc@highlandsun.com>
Paul Eggert <eggert@twinsun.com>
Klaus Heinz <kamar@ease.rhein-main.de>
Michael Joosten
Jim Kelton <jim_kelton@tivoli.com>
David Lubbren <uhay@rz.uni-karlsruhe.de>
Tim Magill <tim.magill@telops.gte.com>
Greg McGary <greg@mcgary.org>
Han-Wen Nienhuys <hanwen@cs.uu.nl>
Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
Carl Staelin (Princeton University)
Ian Stewartson (Data Logic Limited)
With suggestions/comments/bug reports from a cast of ... well ...
hundreds, anyway :)

340
COPYING Normal file
View File

@@ -0,0 +1,340 @@
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
59 Temple Place - Suite 330, Boston, MA
02111-1307, USA.
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users. This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it. (Some other Free Software Foundation software is covered by
the GNU Library General Public License instead.) You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have. You must make sure that they, too, receive or can get the
source code. And you must show them these terms so they know their
rights.
We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.
Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software. If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.
Finally, any free program is threatened constantly by software
patents. We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary. To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and
modification follow.
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License. The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language. (Hereinafter, translation is included without limitation in
the term "modification".) Each licensee is addressed as "you".
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.
1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.
You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.
2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) You must cause the modified files to carry prominent notices
stating that you changed the files and the date of any change.
b) You must cause any work that you distribute or publish, that in
whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no charge to all third
parties under the terms of this License.
c) If the modified program normally reads commands interactively
when run, you must cause it, when started running for such
interactive use in the most ordinary way, to print or display an
announcement including an appropriate copyright notice and a
notice that there is no warranty (or else, saying that you provide
a warranty) and that users may redistribute the program under
these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not required to print an announcement.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.
In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:
a) Accompany it with the complete corresponding machine-readable
source code, which must be distributed under the terms of Sections
1 and 2 above on a medium customarily used for software interchange; or,
b) Accompany it with a written offer, valid for at least three
years, to give any third party, for a charge no more than your
cost of physically performing source distribution, a complete
machine-readable copy of the corresponding source code, to be
distributed under the terms of Sections 1 and 2 above on a medium
customarily used for software interchange; or,
c) Accompany it with the information you received as to the offer
to distribute corresponding source code. (This alternative is
allowed only for noncommercial distribution and only if you
received the program in object code or executable form with such
an offer, in accord with Subsection b above.)
The source code for a work means the preferred form of the work for
making modifications to it. For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable. However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.
If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.
4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.
5. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Program or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.
6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.
7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all. For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation. If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.
10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission. For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.
NO WARRANTY
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
END OF TERMS AND CONDITIONS
Appendix: How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) 19yy <name of author>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
Also add information on how to contact you by electronic and paper mail.
If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:
Gnomovision version 69, Copyright (C) 19yy name of author
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, the commands you use may
be called something other than `show w' and `show c'; they could even be
mouse-clicks or menu items--whatever suits your program.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
`Gnomovision' (which makes passes at compilers) written by James Hacker.
<signature of Ty Coon>, 1 April 1989
Ty Coon, President of Vice
This General Public License does not permit incorporating your program into
proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library. If this is what you want to do, use the GNU Library General
Public License instead of this License.

857
ChangeLog Normal file
View File

@@ -0,0 +1,857 @@
2002-10-03 Paul D. Smith <psmith@gnu.org>
Version 3.80 released.
* dir.c: Change hash functions to use K&R function definition style.
* function.c: Ditto.
* read.c: Ditto.
* variable.c: Ditto.
Update to automake 1.7.
* Makefile.am (AUTOMAKE_OPTIONS): Update to require 1.7.
(pdf): Remove this target as automake now provides one.
* configure.in: Change AM_CONFIG_HEADER to AC_CONFIG_HEADERS.
2002-09-30 Martin P.J. Zinser <zinser@decus.de>
* makefile.com: Updates for GNU make 3.80.
* makefile.vms: Ditto.
2002-09-23 Paul D. Smith <psmith@gnu.org>
* read.c (enum make_word_type): Remove w_comment.
(get_next_mword): Don't treat comment characters as special; where
this function is used we will never see a comment (it's stripped
before we get here) and treating comments specially means that
targets like "foo\#bar" aren't handled properly.
2002-09-18 Paul D. Smith <psmith@gnu.org>
* doc/make.texi (Bugs): Update with some info on Savannah, etc.
* read.c (eval): Expansion of arguments to export/unexport was
ignoring all arguments after the first one. Change the algorithm
to expand the whole line once, then parse the results.
2002-09-17 Paul D. Smith <psmith@gnu.org>
Fix Bug #940 (plus another bug I found while looking at this):
* read.c (record_target_var): enter_file() will add a new entry if
it's a double-colon target: we don't want to do that in this
situation. Invoke lookup_file() and only enter_file() if it does
not already exist. If the file we get back is a double-colon then
add this variable to the "root" double-colon target.
* variable.c (initialize_file_variables): If this file is a
double-colon target but is not the "root" target, then initialize
the root and make the root's variable list the parent of our
variable list.
2002-09-13 Paul D. Smith <psmith@gnu.org>
* doc/make.texi (MAKE Variable): Add some indexing for "+".
* hash.c (round_up_2): Get rid of a warning.
2002-09-12 Paul D. Smith <psmith@gnu.org>
* Makefile.am (loadavg_SOURCES, loadavg.c): Tiptoe around automake
so it doesn't complain about getloadavg.c.
* commands.c (set_file_variables): Make sure we always alloca() at
least 1 character for the value of $? (for '\0').
2002-09-11 Paul D. Smith <psmith@gnu.org>
* hash.h (STRING_COMPARE, ISTRING_COMPARE, STRING_N_COMPARE): Fix
macro to use RESULT instead of the incorrect _RESULT_.
* make.h (HAVE_BROKEN_RESTART): Add prototypes for atomic_stat()
and atomic_readdir(). We need to #include dirent.h to get this to
work.
* misc.c (atomic_readdir): Fix typos.
2002-09-10 Paul D. Smith <psmith@gnu.org>
* read.c (eval): Expand variable lists given to export and
unexport, so that "export $(LIST_OF_VARIABLES)" (etc.) works.
(conditional_line): Ditto for "ifdef". Fixes bug #103.
* doc/make.texi (Variables/Recursion): Document this.
(Conditional Syntax): And here.
2002-09-09 Paul D. Smith <psmith@gnu.org>
* configure.in: Check for memmove().
2002-09-07 Paul D. Smith <psmith@gnu.org>
* configure.in (HAVE_BROKEN_RESTART): Define this on PTX systems;
Michael Sterrett <msterret@coat.com> reports that while it has
SA_RESTART, it does not work properly.
* misc.c (atomic_stat): If HAVE_BROKEN_RESTART, create a function
that invokes stat() and loops to do it again if it returns EINTR.
(atomic_readdir): Ditto, with readdir().
* make.h (stat, readdir): If HAVE_BROKEN_RESTART, alias stat()
and readdir() to atomic_stat() and atomic_readdir().
2002-09-04 Paul D. Smith <psmith@gnu.org>
* implicit.c (pattern_search): Daniel <barkalow@reputation.com>
reports that GNU make sometimes doesn't recognize that targets can
be made, when directories can be created as prerequisites. He
reports that changing the order of predicates in the DEP->changed
flag test so that lookup_file() is always performed, solves this
problem.
2002-08-08 Paul D. Smith <psmith@gnu.org>
* configure.in: Require a newer version of gettext.
* misc.c (perror_with_name): Translate the format string (for
right-to-left language support).
(pfatal_with_name): Ditto.
* main.c: Create a static array of strings to store the usage
text. This is done to facilitate translations.
(struct command_switch): Remove argdesc and description fields.
(switches): Remove values for obsolete fields.
(print_usage): Print each element of the usage array.
* hash.c: Change function definitions to be K&R style.
2002-08-02 Paul D. Smith <psmith@gnu.org>
* NEWS: Remove the mention of .TARGETS; we aren't going to publish
this one because it's too hard to get right. We'll look at it for
a future release.
* main.c (main): Don't create the .TARGETS variable.
* variable.c (handle_special_var): Don't handle .TARGETS.
2002-08-01 Paul D. Smith <psmith@gnu.org>
* main.c (switches): Add a new option, -B (--always-make). If
specified, make will rebuild all targets that it encounters even
if they don't appear to be out of date.
(always_make_flag): New flag.
* make.h: Extern always_make_flag.
* remake.c (update_file_1): Check always_make_flag; if it's set we
will always rebuild any target we can, even if none of its
prerequisites are newer.
* NEWS: Mention it.
* doc/make.texi (Shell Function): Make it clear that make
variables marked as "export" are not passed to instances of the
shell function.
Add new introspection variable .VARIABLES and .TARGETS.
* variable.c (handle_special_var): New function. If the variable
reference passed in is "special" (.VARIABLES or .TARGETS),
calculate the new value if necessary. .VARIABLES is handled here:
walk through the hash of defined variables and construct a value
which is a list of the names. .TARGETS is handled by
build_target_list().
(lookup_variable): Invoke handle_special_var().
* file.c (build_target_list): Walk through the hask of known files
and construct a list of the names of all the ones marked as
targets.
* main.c (main): Initialize them to empty (and as simple variables).
* doc/make.texi (Special Variables): Document them.
* NEWS: Mention them.
* variable.h (struct variable): Add a new flag "exportable" which
is true if the variable name is valid for export.
* variable.c (define_variable_in_set): Set "exportable" when a new
variable is defined.
(target_environment): Use the "exportable" flag instead of
re-checking the name here... an efficiency improvement.
2002-07-31 Paul D. Smith <psmith@gnu.org>
* config.h-vms.template: Updates to build on VMS. Thanks to
Brian_Benning@aksteel.com for helping verify the build.
* makefile.com: Build the new hash.c file.
* hash.h: Use strcpmi(), not stricmp(), in the
HAVE_CASE_INSENSITIVE_FS case.
2002-07-30 Paul D. Smith <psmith@gnu.org>
* hash.h (ISTRING_COMPARE, return_ISTRING_COMPARE): Add missing
backslashes to the HAVE_CASE_INSENSITIVE_FS case.
Reported by <Brian_Benning@aksteel.com>.
2002-07-10 Paul D. Smith <psmith@gnu.org>
* variable.c (pop_variable_scope): Remove variable made unused by
new hash infrastructure.
* read.c (dep_hash_cmp): Rewrite this to handle ignore_mtime
comparisons as well as name comparisons.
* variable.h: Add a prototype for new hash_init_function_table().
* file.c (lookup_file): Remove variables made unused by new hash
infrastructure.
* dir.c (directory_contents_hash_2): Missing return of hash value.
(dir_contents_file_exists_p): Remove variables made unused by new
hash infrastructure.
Installed Greg McGary's integration of the hash functions from the
GNU id-utils package:
2002-07-10 Greg McGary <greg@mcgary.org>
* scripts/functions/filter-out: Add literals to to the
pattern space in order to add complexity, and trigger
use of an internal hash table. Fix documentation strings.
* scripts/targets/INTERMEDIATE: Reverse order of files
passed to expected `rm' command.
2002-07-10 Greg McGary <greg@mcgary.org>
* Makefile.am (SRCS): Add hash.c (noinst_HEADERS): Add hash.h
* hash.c: New file, taken from id-utils.
* hash.h: New file, taken from id-utils.
* make.h (HASH, HASHI): Remove macros.
(find_char_unquote): Change arglist in decl.
(hash_init_directories): New function decl.
* variable.h (hash.h): New #include.
(MAKELEVEL_NAME, MAKELEVEL_LENGTH): New constants.
* filedef.h (hash.h): New #include.
(struct file) [next]: Remove member.
(file_hash_enter): Remove function decl.
(init_hash_files): New function decl.
* ar.c (ar_name): Delay call to strlen until needed.
* main.c (initialize_global_hash_tables): New function.
(main): Call it. Use MAKELEVEL_NAME & MAKELEVEL_LENGTH.
* misc.c (remove_comments): Pass char constants to find_char_unquote.
* remake.c (notice_finished_file): Update last_mtime on `prev' chain.
* dir.c (hash.h): New #include.
(struct directory_contents) [next, files]: Remove members.
[ctime]: Add member for VMS. [dirfiles]: Add hash-table member.
(directory_contents_hash_1, directory_contents_hash_2,
directory_contents_hash_cmp): New functions.
(directories_contents): Change type to `struct hash_table'.
(struct directory) [next]: Remove member.
(directory_hash_1, directory_hash_2, directory_hash_cmp): New funcs.
(directory): Change type to `struct hash_table'.
(struct dirfile) [next]: Remove member.
[length]: Add member. [impossible]: widen type to fill alignment gap.
(dirfile_hash_1, dirfile_hash_2, dirfile_hash_cmp): New functions.
(find_directory): Use new hash table package.
(dir_contents_file_exists_p): Likewise.
(file_impossible): Likewise.
(file_impossible_p): Likewise.
(print_dir_data_base): Likewise.
(open_dirstream): Likewise.
(read_dirstream): Likewise.
(hash_init_directories): New function.
* file.c (hash.h): New #include.
(file_hash_1, file_hash_2, file_hash_cmp): New functions.
(files): Change type to `struct hash_table'.
(lookup_file): Use new hash table package.
(enter_file): Likewise.
(remove_intermediates): Likewise.
(snap_deps): Likewise.
(print_file_data_base): Likewise.
* function.c
(function_table_entry_hash_1, function_table_entry_hash_2,
function_table_entry_hash_cmp): New functions.
(lookup_function): Remove `table' argument.
Use new hash table package.
(struct a_word) [chain, length]: New members.
(a_word_hash_1, a_word_hash_2, a_word_hash_cmp): New functions.
(struct a_pattern): New struct.
(func_filter_filterout): Pass through patterns noting boundaries
and '%', if present. Note a_word length. Use a hash table if
arglists are large enough to justify cost.
(function_table_init): Renamed from function_table.
(function_table): Declare as `struct hash_table'.
(FUNCTION_TABLE_ENTRIES): New constant.
(hash_init_function_table): New function.
* read.c (hash.h): New #include.
(read_makefile): Pass char constants to find_char_unquote.
(dep_hash_1, dep_hash_2, dep_hash_cmp): New functions.
(uniquize_deps): Use hash table to efficiently identify duplicates.
(find_char_unquote): Accept two char-constant stop chars, rather
than a string constant, avoiding zillions of calls to strchr.
Tighten inner search loops to test only for desired delimiters.
* variable.c (variable_hash_1, variable_hash_2,
variable_hash_cmp): New functions.
(variable_table): Declare as `struct hash_table'.
(global_variable_set): Remove initialization.
(init_hash_global_variable_set): New function.
(define_variable_in_set): Use new hash table package.
(lookup_variable): Likewise.
(lookup_variable_in_set): Likewise.
(initialize_file_variables): Likewise.
(pop_variable_scope): Likewise.
(create_new_variable_set): Likewise.
(merge_variable_sets): Likewise.
(define_automatic_variables): Likewise.
(target_environment): Likewise.
(print_variable_set): Likewise.
2002-07-10 Paul D. Smith <psmith@gnu.org>
Implement the SysV make syntax $$@, $$(@D), and $$(@F) in the
prerequisite list. A real SysV make will expand the entire
prerequisites list _twice_: we don't do that as it's a big
backward-compatibility problem. We only replace those specific
variables.
* read.c (record_files): Replace any $@, $(@D), and $(@F) variable
references left in the list of prerequisites. Check for .POSIX as
we record targets, so we can disable non-POSIX behavior while
reading makefiles as well as running them.
(eval): Check the prerequisite list to see if we have anything
that looks like a SysV prerequisite variable reference.
2002-07-09 Paul D. Smith <psmith@gnu.org>
* doc/make.texi (Prerequisite Types): Add a new section describing
order-only prerequisites.
* read.c (uniquize_deps): If we have the same file as both a
normal and order-only prereq, get rid of the order-only prereq,
since the normal one supersedes it.
2002-07-08 Paul D. Smith <psmith@gnu.org>
* AUTHORS: Added Greg McGary to the AUTHORS file.
* NEWS: Blurbed order-only prerequisites.
* file.c (print_file): Show order-only deps properly when printing
the database.
* maintMakefile: Add "update" targets for wget'ing the latest
versions of various external files. Taken from Makefile.maint in
autoconf, etc.
* dosbuild.bat: Somehow we got _double_ ^M's. Remove them.
Reported by Eli Zaretskii <eliz@is.elta.co.il>.
2002-07-07 Paul D. Smith <psmith@gnu.org>
* po/*.po: Remove. We'll use wget to retrieve them at release
time.
* variable.c (do_variable_definition) [W32]: On W32 using cmd
rather than a shell you get an exception. Make sure we look up
the variable. Patch provided by Eli Zaretskii <eliz@is.elta.co.il>.
* remake.c (notice_finished_file): Fix handling of -t flag.
Patch provided by Henning Makholm <henning@makholm.net>.
* implicit.c (pattern_search): Some systems apparently run short
of stack space, and using alloca() in this function caused an
overrun. I modified it to use xmalloc() on the two variables
which seemed like they might get large. Fixes Bug #476.
* main.c (print_version): Update copyright notice to conform with
GNU standards.
(print_usage): Update help output.
* function.c (func_eval): Create a new make function, $(eval
...). Expand the arguments, put them into a buffer, then invoke
eval_buffer() on the resulting string.
(func_quote): Create a new function, $(quote VARNAME). Inserts
the value of the variable VARNAME without expanding it any
further.
* read.c (struct ebuffer): Change the linebuffer structure to an
"eval buffer", which can be either a file or a buffer.
(eval_makefile): Move the code in the old read_makefile() which
located a makefile into here: create a struct ebuffer with that
information. Have it invoke the new function eval() with that
ebuffer.
(eval_buffer): Create a new function that creates a struct ebuffer
that holds a string buffer instead of a file. Have it invoke
eval() with that ebuffer.
(eval): New function that contains the guts of the old
read_makefile() function: this function parses makefiles. Obtains
data to parse from the provided ebuffer. Some modifications to
make the flow of the function cleaner and clearer. Still could
use some work here...
(do_define): Takes a struct ebuffer instead of a FILE*. Read the
contents of the define/endef variable from the ebuffer.
(readstring): Read the next line from a string-style ebuffer.
(readline): Read the next line from an ebuffer. If it's a string
ebuffer, invoke readstring(). If it's a FILE* ebuffer, read it
from the file.
* dep.h (eval_buffer): Prototype eval_buffer();
* variable.c (do_variable_definition): Make sure that all
non-target-specific variables are registered in the global set.
If we're invoked from an $(eval ...) we might be inside a $(call
...) or other function which has pushed a variable scope; we still
want to define our variables from evaluated makefile code in the
global scope.
2002-07-03 Greg McGary <greg@mcgary.org>
* dep.h (struct dep) [ignore_mtime]: New member.
[changed]: convert to a bitfield.
* implicit.c (pattern_search): Zero ignore_mtime.
* main.c (main, handle_non_switch_argument): Likewise.
* rule.c (convert_suffix_rule): Likewise.
* read.c (read_all_makefiles, read_makefile, multi_glob): Likewise.
(read_makefile): Parse '|' in prerequisite list.
(uniquize_deps): Consider ignore_mtime when comparing deps.
* remake.c (update_file_1, check_dep): Don't force remake for
dependencies that have d->ignore_mtime.
* commands.c (FILE_LIST_SEPARATOR): New constant.
(set_file_variables): Don't include a
prerequisite in $+, $^ or $? if d->ignore_mtime.
Define $|.
2002-06-18 Paul D. Smith <psmith@gnu.org>
* make.texinfo: Updates for next revision. New date/rev/etc.
Recreate all Info menus. Change license on the manual to the GNU
Free Documentation License. A number of typos.
(Variables Simplify): Don't use "-" before it's defined.
(Automatic Prerequisites): Rewrite the target example to work
properly if the compile fails. Remove incorrect comments about
how "set -e" behaves.
(Text Functions): Move the "word", "wordlist", "words", and
"firstword" functions here, from "File Name Functions".
* make-stds.texi: Update from latest GNU version.
* fdl.texi: (created) Import the latest GNU version.
2002-06-06 Paul D. Smith <psmith@gnu.org>
* variable.c (do_variable_definition): New function: extract the
part of try_variable_definition() that actually sets the value
into a separate function.
(try_variable_definition): Call do_variable_definition() after
parsing the variable definition string.
(define_variable_in_set): Make the name argument const.
* variable.h (enum variable_flavor): Make public.
(do_variable_definition): Create prototype.
* read.c (read_all_makefiles): Create a new built-in variable,
MAKEFILE_LIST.
(read_makefile): Add each makefile read in to this variable value.
2002-05-18 Eli Zaretskii <eliz@is.elta.co.il>
* Makefile.DOS.template: Tweak according to changes in the
distribution. Add back the dependencies of *.o files.
* configh.dos.template: Synchronize with config.h.in.
2002-05-09 Paul D. Smith <psmith@gnu.org>
* file.c (file_timestamp_now): Use K&R function declaration.
* getloadavg.c (getloadavg): Merge setlocale() fix from sh-utils
getloadavg.c. Autoconf thinks QNX is SVR4-like, but it isn't, so
#undef it. Remove predefined setup of NLIST_STRUCT. Decide
whether to include nlist.h based on HAVE_NLIST_H. Change obsolete
NLIST_NAME_UNION to new HAVE_STRUCT_NLIST_N_UN_N_NAME.
* configure.in (NLIST_STRUCT): Define this if we have nlist.h and
nlist.n_name is a pointer rather than an array.
* acinclude.m4 (make_FUNC_SETVBUF_REVERSED): Grab the latest
version of AC_FUNC_SETVBUF_REVERSED from autoconf CVS.
* configure.in: Use it instead of the old version.
* main.c (main): Prefer setvbuf() to setlinebuf().
2002-05-08 Paul D. Smith <psmith@gnu.org>
* Makefile.am (make_LDADD): Add GETLOADAVG_LIBS.
(loadavg_LDADD): Ditto.
2002-04-29 Paul D. Smith <psmith@gnu.org>
* expand.c (recursively_expand_for_file): Rename
recursively_expand() to recursively_expand_for_file() and provide
an extra argument, struct file. If the argument is provided, set
the variable scope to that of the file before expanding.
* variable.h (recursively_expand): Make this a macro that invokes
recursively_expand_for_file() with a NULL file pointer.
* variable.c (target_environment): Call the renamed function and
provide the current file context.
Fixes Debian bug #144306.
2002-04-28 Paul D. Smith <psmith@gnu.org>
Allow $(call ...) user-defined variables to be self-referencing
without throwing an error. Allows implementation of transitive
closures, among other possibly useful things.
Requested by: Philip Guenther <guenther@sendmail.com>
* variable.h (struct variable): Add a new field: exp_count, and
new macros to hold its size and maximum value.
(warn_undefined): Make this a macro.
* variable.c (define_variable_in_set): Initialize it.
* expand.c (recursively_expand): If we detect recursive expansion
of a variable, check the exp_count field. If it's greater than 0
allow the recursion and decrement the count.
(warn_undefined): Remove this (now a macro in variable.h).
* function.c (func_call): Before we expand the user-defined
function, modify its exp_count field to contain the maximum
number of recursive calls we'll allow. After the call, reset it
to 0.
2002-04-21 Paul D. Smith <psmith@gnu.org>
Modified to use latest autoconf (2.53), automake (1.6.1), and
gettext (0.11.1). We're using gettext's new "external" support,
to avoid including libintl source with GNU make.
* README.cvs: New file. Explain how to build GNU make from CVS.
* configure.in: Modify checking for the system glob library.
Use AC_EGREP_CPP instead of AC_TRY_CPP. Remove the setting of
GLOBDIR (we will always put "glob" in SUBDIRS, so automake
etc. will manage it correctly). Set an automake conditional
USE_LOCAL_GLOB to decide whether to compile the glob library.
* getloadavg.c (main): Include make.h in the "TEST" program to
avoid warnings.
* Makefile.am: Remove special rules for loadavg. Replace them
with Automake capabilities for building extra programs.
* signame.c: This file does nothing if the system provide
strsignal(). If not, it implements strsignal(). If the system
doesn't define sys_siglist, then we make our own; otherwise we use
the system version.
* signame.h: Removed.
* main.c (main): No need to invoke signame_init(). Update copyright.
* ABOUT-NLS: Removed.
* gettext.c: Removed.
* gettext.h: Get a simplified copy from the gettext package.
* po/*: Created.
* i18n/*.po: Moved to po/.
* i18n/: Removed.
* config/*: Created. Contains package configuration helper files.
* config.guess, config.sub: Moved to config directory.
* configure.in (AC_CONFIG_FILES): Add po/Makefile.in, config/Makefile.
Rework to use new-style autoconf features. Use the "external"
mode for gettext. Make the build.sh config file conditional on
whether build.sh.in exists, to avoid autoconf errors.
* acinclude.m4: Removed almost all macros as being obsolete.
Rewrote remaining macros to use AC_DEFINE.
* acconfig.h: Removed.
* Makefile.am (EXTRA_DIST): Add config/config.rpath. Use a
conditional to handle customs support. Remove special handling
for i18n features.
2002-04-20 Paul D. Smith <psmith@gnu.org>
* function.c (func_call): Don't mark the argument variables $1,
etc. as recursive. They've already been fully expanded so
there's no need to do it again, and doing so strips escaped $'s.
Reported by Sebastian Glita <glseba@yahoo.com>.
* remake.c (notice_finished_file): Walk through double-colon
entries via the prev field, not the next field!
Reported by Greg McGary <greg@mcgary.org>.
* main.c (main): If the user specifies -q and asks for a specific
target which is a makefile, we got an assert. In that case it
turns out we should continue normally instead.
* i18n/de.po, i18n/fr.po: Installed an updated translation.
* i18n/he.po: Installed a new translation.
2002-01-07 Paul D. Smith <psmith@gnu.org>
* i18n/es.po, i18n/ru.po: Installed an updated translation.
2001-12-04 Paul D. Smith <psmith@gnu.org>
* i18n/ja.po: Installed an updated translation.
2001-09-04 Paul D. Smith <psmith@gnu.org>
* i18n/da.po: Installed an updated translation.
2001-08-03 Paul D. Smith <psmith@gnu.org>
* i18n/fr.po: Installed an updated translation.
Resolves Debian bug #106720.
2001-06-13 Paul D. Smith <psmith@gnu.org>
* i18n/da.po, configure.in (ALL_LINGUAS): Installed a new
translation.
2001-06-11 Paul D. Smith <psmith@gnu.org>
* i18n/ko.po: Installed a new translation.
2001-05-06 Paul D. Smith <psmith@gnu.org>
Modify the EINTR handling.
* job.c (new_job): Reorganize the jobserver algorithm. Reorder
the way in which we manage the file descriptor/signal handler race
trap to be more efficient.
2001-05-06 Paul Eggert <eggert@twinsun.com>
Restart almost all system calls that are interrupted, instead
of worrying about EINTR. The lone exception is the read() for
job tokens.
* configure.in (HAVE_SA_RESTART): New macro.
(MAKE_JOBSERVER): Define to 1 only if HAVE_SA_RESTART.
* main.c (main): Use SA_RESTART instead of the old,
nonstandard SA_INTERRUPT.
* configure.in (AC_CHECK_FUNCS): Add bsd_signal.
* main.c (bsd_signal): New function or macro,
if the implementation doesn't supply it.
(The bsd_signal function will be in POSIX 1003.1-200x.)
(HANDLESIG): Remove.
(main, FATAL_SIG): Use bsd_signal instead of signal or HANDLESIG.
* make.h (EINTR_SET): Remove.
(SA_RESTART): New macro.
* arscan.c (ar_member_touch): Don't worry about EINTR.
* function.c (func_shell): Likewise.
* job.c (reap_children, free_child, new_job): Likewise.
* main.c (main): Likewise.
* remake.c (touch_file, name_mtime): Likewise.
* arscan.c (ar_member_touch): Fix bug uncovered by EINTR removal;
if fstat failed with errno!=EINTR, the error was ignored.
* job.c (set_child_handler_action_flags): New function.
(new_job): Use it to temporarily clear the SIGCHLD action flags
while reading the token.
2001-05-02 Paul D. Smith <psmith@gnu.org>
* job.c (start_job_command): Don't add define/endef per-line flags
to the top-level flags setting.
2001-04-03 Paul D. Smith <psmith@gnu.org>
* arscan.c (VMS_get_member_info,ar_scan) [VMS]: VMS sets the low
bit on error, so check for odd return values, not non-0 return
values.
(VMS_get_member_info): Calculate the timezone differences correctly.
Reported by John Fowler <jfowler@nyx.net>.
2001-03-14 Paul D. Smith <psmith@gnu.org>
* variable.c (lookup_variable) [VMS]: Null-terminate the variable
value before invoking define_variable().
Reported by John Fowler <jfowler@nyx.net>.
2001-02-07 Paul D. Smith <psmith@gnu.org>
* read.c (record_target_var): If we reset the variable due to a
command-line variable setting overriding it, turn off the "append"
flag.
2001-01-17 Paul D. Smith <psmith@gnu.org>
* variable.c (lookup_variable) [VMS]: When getting values from the
environment, allocate enough space for the _value_ plus escapes,
not enough space for the name plus escapes :-/.
Reported by John Fowler <jfowler@nyx.net>.
* remake.c (f_mtime): Removed the "***" prefix from the mod time
warnings that make generates, so it doesn't look like an error.
Reported by Karl Berry <karl@gnu.org>.
Fix for PR/2020: Rework appended target-specific variables. I'm
fairly confident this algorithm is finally correct.
* expand.c (allocated_variable_append): Rewrite. Instead of
expanding each appended variable then adding all the expanded
strings together, we append all the unexpanded values going up
through the variable set contexts, then expand the final result.
This behaves just like non-target-specific appended variable
values, while the old way didn't in various corner cases.
(variable_append): New function: recursively append the unexpanded
value of a variable, walking from the outermost variable scope to
the innermost.
* variable.c (lookup_variable): Remove the code that looked up the
variable set list if the found variable was "append". We don't
need this anymore.
(lookup_variable_in_set): Make this non-static so we can use it
elsewhere.
(try_variable_definition): Use lookup_variable_in_set() rather
than faking out current_variable_set_list by hand (cleanup).
* variable.h: Add a prototype for the now non-static
lookup_variable_in_set().
2000-11-17 Paul D. Smith <psmith@gnu.org>
* remake.c (f_mtime) [WINDOWS32]: On various advice, I changed the
WINDOWS32 port to assume timestamps can be up to 3 seconds away
before throwing a fit.
2000-11-17 Paul D. Smith <psmith@gnu.org>
* read.c (readline): CRLF calculations had a hole, if you hit the
buffer grow scenario just right. Reworked the algorithm to avoid
the need for len or lastlen at all. Problem description with
sample code chages provided by Chris Faylor <cgf@redhat.com>.
2000-10-24 Paul D. Smith <psmith@gnu.org>
* gettext.c (SWAP): Declare this with the prototype, otherwise
some systems don't work (non-32-bit? Reported for Cray T3E).
Reported by Thorstein Thorsteinsson <thor@signe.teokem.lu.se>.
2000-10-05 Paul D. Smith <psmith@gnu.org>
* acinclude.m4 (AM_LC_MESSAGES): Remove undefined macro
AM_LC_MESSAGES; it doesn't seem to do anything anyway??
* i18n/gl.po, configure.in (ALL_LINGUAS): New Galician translation.
2000-09-22 Paul D. Smith <psmith@gnu.org>
* gettext.c: Don't #define _GETTEXT_H here; we only include some
parts of the real gettext.h here, and we expect to really include
the real gettext.h later. If we keep this #define, it's ignored.
2000-09-21 Paul D. Smith <psmith@gnu.org>
* main.c (log_working_directory): Rework the text to use complete
sentences, to make life simpler for the translators.
2000-08-29 Paul D. Smith <psmith@gnu.org>
* file.c (remove_intermediates): Print a debug message before we
remove intermediate files, so the user (if she uses -d) knows
what's going on.
2000-08-21 Paul D. Smith <psmith@gnu.org>
* variable.c (try_variable_definition): Change how we handle
target-specific append variable defns: instead of just setting the
value, expand it as an append _but_ only within the current
target's context. Otherwise we lose all but the last value if the
variable is appended more than once within the current target
context. Fixes PR/1831.
2000-08-16 Paul D. Smith <psmith@gnu.org>
* function.c (func_shell): Nul-terminate the buffer before
printing an exec error message (just in case it's not!).
Fixes PR/1860, reported by Joey Hess <joey@valinux.com>.
2000-07-25 Paul D. Smith <psmith@gnu.org>
* job.c (construct_command_argv_internal): Add "~" to the list of
sh_chars[] which disallow optimizing out the shell call.
2000-07-23 Paul Eggert <eggert@twinsun.com>
* NEWS, make.texinfo: Document .LOW_RESOLUTION_TIME, which
supersedes --disable-nsec-timestamps.
* make.texinfo: Consistently use "time stamp" instead of "timestamp".
* README: Remove --disable-nsec-timestamps.
* filedef.h (struct file.low_resolution_time): New member.
* file.c (snap_deps): Add support for .LOW_RESOLUTION_TIME.
* remake.c (update_file_1):
Avoid spurious rebuilds due to low resolution time stamps,
generalizing the earlier code that applied only to archive members.
(f_mtime): Archive members always have low resolution time stamps.
* configure.in: Remove --disable-nsec-timestamps, as this has
been superseded by .LOW_RESOLUTION_TIME.
2000-07-23 Paul Eggert <eggert@twinsun.com>
* configure.in (enable_nsec_timestamps): Renamed from
make_cv_nsec_timestamps, since enable/disable options
shouldn't be cached.
2000-07-23 Bruno Haible <haible@clisp.cons.org>
and Paul Eggert <eggert@twinsun.com>
* file.c (file_timestamp_now):
Use preprocessor-time check for FILE_TIMESTAMP_HI_RES
so that clock_gettime is not linked unless needed.
* filedef.h (FILE_TIMESTAMP_HI_RES):
Remove definition; "configure" now does this.
* configure.in (jm_AC_TYPE_UINTMAX_T): Move up,
to before high resolution file timestamp check,
since that check now uses uintmax_t.
(FILE_TIMESTAMP_HI_RES): Define to nonzero if the code should use
high resolution file timestamps.
(HAVE_CLOCK_GETTIME): Do not define if !FILE_TIMESTAMP_HI_RES,
so that we don't link in clock_gettime unnecessarily.
2000-07-17 Paul D. Smith <psmith@gnu.org>
* i18n/ja.po: New version of the translation file.
2000-07-07 Paul D. Smith <psmith@gnu.org>
* remake.c (f_mtime): If NO_FLOAT is defined, don't bother with
the offset calculation.
(name_mtime): Replace EINTR test with EINTR_SET macro.
2000-07-07 Paul Eggert <eggert@twinsun.com>
Fix for PR/1811:
* remake.c (update_file_1):
Avoid spurious rebuilds of archive members due to their
timestamp resolution being only one second.
(f_mtime): Avoid spurious warnings of timestamps in the future due to
the clock's resolution being lower than file timestamps'.
When warning about future timestamps, report only the discrepancy,
not the absolute value of the timestamp and the current time.
* file.c (file_timestamp_now): New arg RESOLUTION.
* filedef.h (file_timestamp_now): Likewise.
(FILE_TIMESTAMP_NS): Now returns int. All uses changed.
2000-07-05 Paul D. Smith <psmith@gnu.org>
* variable.c (lookup_variable) [VMS]: Remove vestigial references
to listp. Fixes PR/1793.
2000-06-26 Paul Eggert <eggert@twinsun.com>
* Makefile.am (MAINTAINERCLEANFILES): New macro, with stamp-pot in it.
* dir.c (vms_hash): Ensure ctype macro args are nonnegative.
* remake.c (f_mtime): Remove unused var memtime.
2000-06-25 Martin Buchholz <martin@xemacs.org>
* make.texinfo, NEWS, TODO.private: Minor spelling corrections.
Ran spell-check on make.texinfo.
See ChangeLog.2 for earlier changes.

4980
ChangeLog.1 Normal file

File diff suppressed because it is too large Load Diff

6648
ChangeLog.2 Normal file

File diff suppressed because it is too large Load Diff

187
INSTALL Normal file
View File

@@ -0,0 +1,187 @@
Basic Installation
==================
The `configure' shell script attempts to guess correct values for
various system-dependent variables used during compilation. It uses
those values to create a `Makefile' in each directory of the package.
It may also create one or more `.h' files containing system-dependent
definitions. Finally, it creates a shell script `config.status' that
you can run in the future to recreate the current configuration, a file
`config.cache' that saves the results of its tests to speed up
reconfiguring, and a file `config.log' containing compiler output
(useful mainly for debugging `configure').
If you need to do unusual things to compile the package, please try
to figure out how `configure' could check whether to do them, and mail
diffs or instructions to the address given in the `README' so they can
be considered for the next release. If at some point `config.cache'
contains results you don't want to keep, you may remove or edit it.
The file `configure.in' is used to create `configure' by a program
called `autoconf'. You only need `configure.in' if you want to change
it or regenerate `configure' using a newer version of `autoconf'.
The simplest way to compile this package is:
1. `cd' to the directory containing the package's source code and type
`./configure' to configure the package for your system. If you're
using `csh' on an old version of System V, you might need to type
`sh ./configure' instead to prevent `csh' from trying to execute
`configure' itself.
Running `configure' takes awhile. While running, it prints some
messages telling which features it is checking for.
2. Type `make' to compile the package.
If you're building GNU make on a system which does not already have
a `make', you can use the build.sh shell script to compile. Run
`sh ./build.sh'. This should compile the program in the current
directory. Then you will have a Make program that you can use for
`make install', or whatever else.
3. Optionally, type `./make check' to run any self-tests that come with
the package.
4. Type `make install' to install the programs and any data files and
documentation.
5. You can remove the program binaries and object files from the
source code directory by typing `make clean'. To also remove the
files that `configure' created (so you can compile the package for
a different kind of computer), type `make distclean'. There is
also a `make maintainer-clean' target, but that is intended mainly
for the package's developers. If you use it, you may have to get
all sorts of other programs in order to regenerate files that came
with the distribution.
Compilers and Options
=====================
Some systems require unusual options for compilation or linking that
the `configure' script does not know about. You can give `configure'
initial values for variables by setting them in the environment. Using
a Bourne-compatible shell, you can do that on the command line like
this:
CC=c89 CFLAGS=-O2 LIBS=-lposix ./configure
Or on systems that have the `env' program, you can do it like this:
env CPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure
Compiling For Multiple Architectures
====================================
You can compile the package for more than one kind of computer at the
same time, by placing the object files for each architecture in their
own directory. To do this, you must use a version of `make' that
supports the `VPATH' variable, such as GNU `make'. `cd' to the
directory where you want the object files and executables to go and run
the `configure' script. `configure' automatically checks for the
source code in the directory that `configure' is in and in `..'.
If you have to use a `make' that does not supports the `VPATH'
variable, you have to compile the package for one architecture at a time
in the source code directory. After you have installed the package for
one architecture, use `make distclean' before reconfiguring for another
architecture.
Installation Names
==================
By default, `make install' will install the package's files in
`/usr/local/bin', `/usr/local/man', etc. You can specify an
installation prefix other than `/usr/local' by giving `configure' the
option `--prefix=PATH'.
You can specify separate installation prefixes for
architecture-specific files and architecture-independent files. If you
give `configure' the option `--exec-prefix=PATH', the package will use
PATH as the prefix for installing programs and libraries.
Documentation and other data files will still use the regular prefix.
In addition, if you use an unusual directory layout you can give
options like `--bindir=PATH' to specify different values for particular
kinds of files. Run `configure --help' for a list of the directories
you can set and what kinds of files go in them.
If the package supports it, you can cause programs to be installed
with an extra prefix or suffix on their names by giving `configure' the
option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
Optional Features
=================
Some packages pay attention to `--enable-FEATURE' options to
`configure', where FEATURE indicates an optional part of the package.
They may also pay attention to `--with-PACKAGE' options, where PACKAGE
is something like `gnu-as' or `x' (for the X Window System). The
`README' should mention any `--enable-' and `--with-' options that the
package recognizes.
For packages that use the X Window System, `configure' can usually
find the X include and library files automatically, but if it doesn't,
you can use the `configure' options `--x-includes=DIR' and
`--x-libraries=DIR' to specify their locations.
Specifying the System Type
==========================
There may be some features `configure' can not figure out
automatically, but needs to determine by the type of host the package
will run on. Usually `configure' can figure that out, but if it prints
a message saying it can not guess the host type, give it the
`--host=TYPE' option. TYPE can either be a short name for the system
type, such as `sun4', or a canonical name with three fields:
CPU-COMPANY-SYSTEM
See the file `config.sub' for the possible values of each field. If
`config.sub' isn't included in this package, then this package doesn't
need to know the host type.
If you are building compiler tools for cross-compiling, you can also
use the `--target=TYPE' option to select the type of system they will
produce code for and the `--build=TYPE' option to select the type of
system on which you are compiling the package.
Sharing Defaults
================
If you want to set default values for `configure' scripts to share,
you can create a site shell script called `config.site' that gives
default values for variables like `CC', `cache_file', and `prefix'.
`configure' looks for `PREFIX/share/config.site' if it exists, then
`PREFIX/etc/config.site' if it exists. Or, you can set the
`CONFIG_SITE' environment variable to the location of the site script.
A warning: not all `configure' scripts look for a site script.
Operation Controls
==================
`configure' recognizes the following options to control how it
operates.
`--cache-file=FILE'
Use and save the results of the tests in FILE instead of
`./config.cache'. Set FILE to `/dev/null' to disable caching, for
debugging `configure'.
`--help'
Print a summary of the options to `configure', and exit.
`--quiet'
`--silent'
`-q'
Do not print messages saying which checks are being made. To
suppress all normal output, redirect it to `/dev/null' (any error
messages will still be shown).
`--srcdir=DIR'
Look for the package's source code in directory DIR. Usually
`configure' can determine that directory automatically.
`--version'
Print the version of Autoconf used to generate the `configure'
script, and exit.
`configure' also accepts some other, not widely useful, options.

568
Makefile.DOS.template Normal file
View File

@@ -0,0 +1,568 @@
# -*-Makefile-*- template for DJGPP
# Makefile.in generated automatically by automake 1.2 from Makefile.am
# Copyright (C) 1994, 1995-1998, 1999, 2002 Free Software Foundation, Inc.
# This Makefile.DOS is free software; the Free Software Foundation
# gives unlimited permission to copy, distribute and modify it.
SHELL = /bin/sh
srcdir = .
VPATH = $(srcdir)
# $DJDIR is defined automatically by DJGPP to point
# to the root of the DJGPP installation tree.
prefix = /dev/env/DJDIR
exec_prefix = ${prefix}
bindir = /bin
datadir = /share
libdir = /lib
infodir = /info
mandir = /man
includedir = /include
oldincludedir = c:/djgpp/include
DESTDIR = /dev/env/DJDIR
pkgdatadir = $(datadir)/make
pkglibdir = $(libdir)/make
pkgincludedir = $(includedir)/make
localedir = $(datadir)/locale
INSTALL = ${exec_prefix}/bin/ginstall -c
INSTALL_PROGRAM = ${exec_prefix}/bin/ginstall -c
INSTALL_DATA = ${exec_prefix}/bin/ginstall -c -m 644
INSTALL_SCRIPT = ${exec_prefix}/bin/ginstall -c
transform = s,x,x,
# This will fail even if they don't have a Unix-like shell (stock DOS
# shell doesn't know about `false'). The only difference is that they
# get "Error -1" instead of "Error 1".
EXIT_FAIL = false
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
EXEEXT = .exe
OBJEXT = o
AR = ar
AWK = gawk
CC = gcc
CPP = gcc -E
LIBOBJS =
MAKEINFO = ${exec_prefix}/bin/makeinfo
PACKAGE = make
PERL = perl
RANLIB = ranlib
REMOTE = stub
VERSION = %VERSION%
AUTOMAKE_OPTIONS = 1.2
bin_PROGRAMS = %PROGRAMS%$(EXEEXT)
make_SOURCES = %SOURCES%
# This should include the glob/ prefix
libglob_a_SOURCES = %GLOB_SOURCES%
make_LDADD = glob/libglob.a
info_TEXINFOS = make.texinfo
man_MANS = make.1
INCLUDES = -I$(srcdir)/glob -DLIBDIR=\"c:/djgpp/lib\" -DINCLUDEDIR=\"c:/djgpp/include\" -DLOCALEDIR=\"$(localedir)\"
BUILT_SOURCES = README build.sh-in
EXTRA_DIST = $(BUILT_SOURCES) $(man_MANS) README.customs remote-cstms.c make-stds.texi texinfo.tex SCOPTIONS SMakefile Makefile.ami README.Amiga config.ami amiga.c amiga.h NMakefile README.DOS configh.dos configure.bat makefile.com README.W32 build_w32.bat config.h-W32 subproc.bat make.lnk config.h-vms makefile.vms readme.vms vmsdir.h vmsfunctions.c vmsify.c
SUBDIRS = glob
mkinstalldirs = ${exec_prefix}/bin/gmkdir -p
CONFIG_HEADER = config.h
CONFIG_CLEAN_FILES = build.sh
PROGRAMS = $(bin_PROGRAMS)
MAKE_HOST = i386-pc-msdosdjgpp
DEFS = -I. -I$(srcdir) -I.
CPPFLAGS = -DHAVE_CONFIG_H
LDFLAGS =
LIBS =
make_OBJECTS = %OBJECTS%
make_DEPENDENCIES = glob/libglob.a
make_LDFLAGS =
libglob_a_LIBADD =
libglob_a_OBJECTS = %GLOB_OBJECTS%
noinst_LIBRARIES = glob/libglob.a
CFLAGS = -O2 -g
COMPILE = $(CC) $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS)
LINK = $(CC) $(CFLAGS) $(LDFLAGS) -o $@
TEXI2DVI = texi2dvi
TEXINFO_TEX = $(srcdir)/config/texinfo.tex
INFO_DEPS = make.info
DVIS = make.dvi
TEXINFOS = make.texinfo
man1dir = $(mandir)/man1
MANS = $(man_MANS)
NROFF = nroff
DIST_COMMON = README ABOUT-NLS AUTHORS COPYING ChangeLog INSTALL Makefile.am Makefile.in NEWS acconfig.h aclocal.m4 alloca.c build.sh-in config.h-in configure configure.in getloadavg.c
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
TAR = gtar
GZIP = --best
SOURCES = $(make_SOURCES)
OBJECTS = $(make_OBJECTS)
HEADERS = $(wildcard $(srcdir)/*.h)
default: all
.SUFFIXES:
.SUFFIXES: .c .dvi .info .o .obj .ps .texinfo .tex
mostlyclean-hdr:
clean-hdr:
distclean-hdr:
-rm -f config.h
maintainer-clean-hdr:
mostlyclean-binPROGRAMS:
clean-binPROGRAMS:
-test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS)
distclean-binPROGRAMS:
maintainer-clean-binPROGRAMS:
install-binPROGRAMS: $(bin_PROGRAMS)
@$(NORMAL_INSTALL)
$(mkinstalldirs) $(DESTDIR)$(bindir)
@list='$(bin_PROGRAMS)'; for p in $$list; do if test -f $$p; then echo " $(INSTALL_PROGRAM) $$p $(DESTDIR)$(bindir)/`echo $$p | sed '$(transform)'`"; $(INSTALL_PROGRAM) $$p $(DESTDIR)$(bindir)/`echo $$p | sed '$(transform)'`; else :; fi; done
uninstall-binPROGRAMS:
$(NORMAL_UNINSTALL)
list='$(bin_PROGRAMS)'; for p in $$list; do rm -f $(DESTDIR)$(bindir)/`echo $$p|sed '$(transform)'`.exe; done
.c.o:
$(COMPILE) -c $<
clean-noinstLIBRARIES:
-test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES)
mostlyclean-compile:
-rm -f *.$(OBJEXT) *$(EXEEXT) make.new core
clean-compile:
distclean-compile:
-rm -f *.tab.c *_tab.c
maintainer-clean-compile:
make$(EXEEXT): $(make_OBJECTS) $(make_DEPENDENCIES)
@command.com /c if exist make del make
@command.com /c if exist make.exe del make.exe
$(LINK) $(make_LDFLAGS) $(make_OBJECTS) $(make_LDADD) $(LIBS)
make.info: make.texinfo
make.dvi: make.texinfo
DVIPS = dvips
.texinfo.info:
@command.com /c if exist make.info* del make.info*
@command.com /c if exist make.i* del make.i*
$(MAKEINFO) -I$(srcdir) $< -o ./$@
.texinfo:
@command.com /c if exist make.info* del make.info*
@command.com /c if exist make.i* del make.i*
$(MAKEINFO) -I$(srcdir) $< -o ./$@
.texinfo.dvi:
TEXINPUTS="$(srcdir);$$TEXINPUTS" MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2DVI) $<
.dvi.ps:
$(DVIPS) $< -o $@
install-info-am: $(INFO_DEPS)
@$(NORMAL_INSTALL)
$(mkinstalldirs) $(DESTDIR)$(infodir)
@for file in $(INFO_DEPS) make.i; do d=$(srcdir); for ifile in `cd $$d && echo $$file $$file-[0-9] $$file-[0-9][0-9] $$file[0-9] $$file[0-9][0-9]`; do if test -f $$d/$$ifile; then echo " $(INSTALL_DATA) $$d/$$ifile $(DESTDIR)$(infodir)/$$ifile"; $(INSTALL_DATA) $$d/$$ifile $(DESTDIR)$(infodir)/$$ifile; else : ; fi; done; done
@$(POST_INSTALL)
@if $(SHELL) -c 'install-info --version | sed 1q | fgrep -s -v -i debian' >/dev/null 2>&1; then for file in $(INFO_DEPS); do echo " install-info --info-dir=$(DESTDIR)$(infodir) $(DESTDIR)$(infodir)/$$file"; install-info --info-dir=$(DESTDIR)$(infodir) $(DESTDIR)$(infodir)/$$file || :; done; else : ; fi
uninstall-info:
$(PRE_UNINSTALL)
@if $(SHELL) -c 'install-info --version | sed 1q | fgrep -s -v -i debian' >/dev/null 2>&1; then ii=yes; else ii=; fi; for file in $(INFO_DEPS); do test -z $ii || install-info --info-dir=$(DESTDIR)$(infodir) --remove $$file; done
$(NORMAL_UNINSTALL)
for file in $(INFO_DEPS) make.i; do (cd $(DESTDIR)$(infodir) && rm -f $$file $$file-[0-9] $$file-[0-9][0-9] $$file[0-9] $$file[0-9][0-9]); done
dist-info: $(INFO_DEPS)
for base in $(INFO_DEPS); do d=$(srcdir); for file in `cd $$d && eval echo $$base*`; do test -f $(distdir)/$$file || ln $$d/$$file $(distdir)/$$file 2> /dev/null || cp -p $$d/$$file $(distdir)/$$file; done; done
mostlyclean-aminfo:
-rm -f make.aux make.cp make.cps make.dvi make.fn make.fns make.ky \
make.kys make.ps make.log make.pg make.toc make.tp make.tps \
make.vr make.vrs make.op make.tr make.cv make.cn
clean-aminfo:
distclean-aminfo:
maintainer-clean-aminfo:
for i in $(INFO_DEPS) make.i; do rm -f `eval echo $$i*`; done
install-man1:
$(mkinstalldirs) $(DESTDIR)$(man1dir)
@list='$(man1_MANS)'; \
l2='$(man_MANS)'; for i in $$l2; do \
case "$$i" in \
*.1*) list="$$list $$i" ;; \
esac; \
done; \
for i in $$list; do \
if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \
else file=$$i; fi; \
ext=`echo $$i | sed -e 's/^.*\\.//'`; \
inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \
inst=`echo $$inst | sed '$(transform)'`.$$ext; \
echo " $(INSTALL_DATA) $$file $(DESTDIR)$(man1dir)/$$inst"; \
$(INSTALL_DATA) $$file $(DESTDIR)$(man1dir)/$$inst; \
done
uninstall-man1:
@list='$(man1_MANS)'; \
l2='$(man_MANS)'; for i in $$l2; do \
case "$$i" in \
*.1*) list="$$list $$i" ;; \
esac; \
done; \
for i in $$list; do \
ext=`echo $$i | sed -e 's/^.*\\.//'`; \
inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \
inst=`echo $$inst | sed '$(transform)'`.$$ext; \
echo " rm -f $(DESTDIR)$(man1dir)/$$inst"; \
rm -f $(DESTDIR)$(man1dir)/$$inst; \
done
install-man: $(MANS)
@$(NORMAL_INSTALL)
$(MAKE) install-man1
uninstall-man:
@$(NORMAL_UNINSTALL)
$(MAKE) uninstall-man1
# Assume that the only thing to do in glob is to build libglob.a,
# but do a sanity check: if $SUBDIRS will ever have more than
# a single directory, yell bloody murder.
all-recursive:
ifeq ($(words $(SUBDIRS)), 1)
@command.com /c if not exist glob\\nul md glob
@echo Making all in $(SUBDIRS)
$(MAKE) -C $(SUBDIRS) -f ../Makefile INCLUDES='-I$(srcdir) -I$(srcdir)/glob' DEFS='-I.. -I$(srcdir)' VPATH=$(srcdir)/glob libglob.a
else
@echo FATAL: There is more than one directory in "($(SUBDIRS))"
@$(EXIT_FAIL)
endif
$(SUBDIRS):
command.com /c md $@
libglob.a: $(libglob_a_OBJECTS)
command.com /c if exist libglob.a del libglob.a
$(AR) cru libglob.a $(libglob_a_OBJECTS) $(libglob_a_LIBADD)
$(RANLIB) libglob.a
mostlyclean-recursive clean-recursive distclean-recursive \
maintainer-clean-recursive check-recursive:
ifeq ($(words $(SUBDIRS)), 1)
@echo Making $(shell echo $@ | sed s/-recursive//) in $(SUBDIRS)
$(MAKE) -C $(SUBDIRS) -f ../Makefile $(shell echo $@ | sed s/-recursive//)-am
else
@echo FATAL: There is more than one directory in "($(SUBDIRS))"
@$(EXIT_FAIL)
endif
tags-in-glob: $(libglob_a_SOURCES)
etags $(addprefix $(srcdir)/,$^) -o ./glob/TAGS
tags-recursive:
ifeq ($(words $(SUBDIRS)), 1)
$(MAKE) tags-in-glob
else
@echo FATAL: There is more than one directory in "($(SUBDIRS))"
@$(EXIT_FAIL)
endif
tags: TAGS
ID: $(HEADERS) $(SOURCES)
mkid $(srcdir)/$(SOURCES) $(srcdir)/$(libglob_a_SOURCES) ./config.h $(HEADERS)
TAGS: tags-recursive $(HEADERS) $(srcdir)/$(SOURCES) config.h $(TAGS_DEPENDENCIES)
etags -i ./glob/TAGS $(ETAGS_ARGS) $(srcdir)/$(SOURCES) ./config.h $(HEADERS)
mostlyclean-tags:
clean-tags:
distclean-tags:
-rm -f TAGS ID
maintainer-clean-tags:
distdir = $(PACKAGE)-$(VERSION)
top_distdir = $(distdir)
# This target untars the dist file and tries a VPATH configuration. Then
# it guarantees that the distribution is self-contained by making another
# tarfile.
distcheck: dist
rm -rf $(distdir)
GZIP=$(GZIP) $(TAR) zxf $(distdir).tar.gz
mkdir $(distdir)/=build
mkdir $(distdir)/=inst
dc_install_base=`cd $(distdir)/=inst && pwd`; cd $(distdir)/=build && ../configure --srcdir=.. --prefix=$$dc_install_base && $(MAKE) && $(MAKE) dvi && $(MAKE) check && $(MAKE) install && $(MAKE) installcheck && $(MAKE) dist
rm -rf $(distdir)
@echo "========================"; echo "$(distdir).tar.gz is ready for distribution"; echo "========================"
dist: distdir
-chmod -R a+r $(distdir)
GZIP=$(GZIP) $(TAR) chozf $(distdir).tar.gz $(distdir)
rm -rf $(distdir)
dist-all: distdir
-chmod -R a+r $(distdir)
GZIP=$(GZIP) $(TAR) chozf $(distdir).tar.gz $(distdir)
rm -rf $(distdir)
distdir: $(DISTFILES)
rm -rf $(distdir)
mkdir $(distdir)
-chmod 777 $(distdir)
@for file in $(DISTFILES); do d=$(srcdir); test -f $(distdir)/$$file || ln $$d/$$file $(distdir)/$$file 2> /dev/null || cp -p $$d/$$file $(distdir)/$$file; done; for subdir in $(SUBDIRS); do test -d $(distdir)/$$subdir || mkdir $(distdir)/$$subdir || exit 1; chmod 777 $(distdir)/$$subdir; (cd $$subdir && $(MAKE) top_distdir=../$(top_distdir)/$$subdir distdir=../$(distdir)/$$subdir distdir) || exit 1; done
$(MAKE) top_distdir="$(top_distdir)" distdir="$(distdir)" dist-info
$(MAKE) top_distdir="$(top_distdir)" distdir="$(distdir)" dist-hook
info: $(INFO_DEPS) info-recursive
dvi: $(DVIS) dvi-recursive
check: all-am check-recursive check-local
@:
installcheck: installcheck-recursive
all-recursive-am: config.h
$(MAKE) all-recursive
all-am: Makefile $(INFO_DEPS) $(PROGRAMS) config.h
install-exec-am: install-binPROGRAMS
install-data-am: install-info-am
uninstall-am: uninstall-binPROGRAMS uninstall-info
install-exec: install-exec-recursive install-exec-am
@$(NORMAL_INSTALL)
install-data: install-data-recursive install-data-am
@$(NORMAL_INSTALL)
install-recursive uninstall-recursive:
@:
install: install-recursive install-exec-am install-data-am
@:
uninstall: uninstall-recursive uninstall-am
all: all-recursive-am all-am
install-strip:
$(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' INSTALL_SCRIPT='$(INSTALL_PROGRAM)' install
installdirs: installdirs-recursive
$(mkinstalldirs) $(bindir) $(infodir)
mostlyclean-generic:
-test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
clean-generic:
-test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
distclean-generic:
-rm -f Makefile $(DISTCLEANFILES)
-rm -f config.cache config.log stamp-h stamp-h[0-9]*
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
maintainer-clean-generic:
-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
-test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
mostlyclean-am: mostlyclean-hdr mostlyclean-binPROGRAMS mostlyclean-compile mostlyclean-aminfo mostlyclean-tags mostlyclean-generic
clean-am: clean-hdr clean-binPROGRAMS clean-compile clean-aminfo clean-tags clean-generic mostlyclean-am
distclean-am: distclean-hdr distclean-binPROGRAMS distclean-compile distclean-aminfo distclean-tags distclean-generic clean-am
maintainer-clean-am: maintainer-clean-hdr maintainer-clean-binPROGRAMS maintainer-clean-compile maintainer-clean-aminfo maintainer-clean-tags maintainer-clean-generic distclean-am
mostlyclean: mostlyclean-recursive mostlyclean-am
clean: clean-noinstLIBRARIES clean-recursive clean-am
distclean: distclean-recursive distclean-am
rm -f config.status
maintainer-clean: maintainer-clean-recursive maintainer-clean-am
@echo "This command is intended for maintainers to use;"
@echo "it deletes files that may require special tools to rebuild."
rm -f config.status
.PHONY: default mostlyclean-hdr distclean-hdr clean-hdr \
maintainer-clean-hdr mostlyclean-binPROGRAMS distclean-binPROGRAMS \
clean-binPROGRAMS maintainer-clean-binPROGRAMS uninstall-binPROGRAMS \
install-binPROGRAMS mostlyclean-compile distclean-compile clean-compile \
maintainer-clean-compile install-info-am uninstall-info \
mostlyclean-aminfo distclean-aminfo clean-aminfo \
maintainer-clean-aminfo install-data-recursive uninstall-data-recursive \
install-exec-recursive uninstall-exec-recursive installdirs-recursive \
uninstalldirs-recursive all-recursive check-recursive check-am \
installcheck-recursive info-recursive dvi-recursive \
mostlyclean-recursive distclean-recursive clean-recursive \
maintainer-clean-recursive tags tags-recursive mostlyclean-tags \
distclean-tags clean-tags maintainer-clean-tags distdir \
mostlyclean-depend distclean-depend clean-depend \
maintainer-clean-depend info dvi check-local installcheck \
all-recursive-am all-am install-exec-am install-data-am uninstall-am \
install-exec install-data install uninstall all installdirs \
mostlyclean-generic distclean-generic clean-generic \
maintainer-clean-generic clean mostlyclean distclean maintainer-clean
# --------------- Local DIST Section
# Install the w32 subdirectory
#
dist-hook:
(cd $(srcdir); \
w32=`find w32 -follow \( -name CVS -prune \) -o -type f -print`; \
tar chf - $$w32) \
| (cd $(distdir); tar xfBp -)
# --------------- Local CHECK Section
# Note: check-loadavg is NOT a prerequisite of check-local, since
# there's no uptime utility, and the test it does doesn't make sense
# on MSDOS anyway.
check-local: check-shell check-regression
@banner=" Regression PASSED: GNU Make $(VERSION) ($(MAKE_HOST)) built with $(CC) "; \
dashes=`echo "$$banner" | sed s/./=/g`; \
echo; \
echo "$$dashes"; \
echo "$$banner"; \
echo "$$dashes"; \
echo
.PHONY: check-loadavg check-shell check-regression
# > check-shell
#
# check-shell is designed to fail if they don't have a Unixy shell
# installed. The test suite requires such a shell.
check-shell:
@echo If Make says Error -1, you do not have Unix-style shell installed
@foo=bar.exe :
# > check-loadavg
#
loadavg: loadavg.c config.h
@rm -f loadavg
$(LINK) -DTEST $(make_LDFLAGS) loadavg.c $(LIBS)
# We copy getloadavg.c into a different file rather than compiling it
# directly because some compilers clobber getloadavg.o in the process.
loadavg.c: getloadavg.c
ln $(srcdir)/getloadavg.c loadavg.c || \
cp $(srcdir)/getloadavg.c loadavg.c
check-loadavg: loadavg
@echo The system uptime program believes the load average to be:
-uptime
@echo The GNU load average checking code believes:
-./loadavg
# > check-regression
#
# Look for the make test suite, and run it if found. Look in MAKE_TEST if
# specified, or else in the srcdir or the distdir, their parents, and _their_
# parents.
#
check-regression:
@if test -f "$(srcdir)/tests/run_make_tests"; then \
if $(PERL) -v >/dev/null 2>&1; then \
case `cd $(srcdir); pwd` in `pwd`) : ;; \
*) test -d tests || mkdir tests; \
for f in run_make_tests run_make_tests.pl test_driver.pl scripts; do \
rm -rf tests/$$f; cp -pr $(srcdir)/tests/$$f tests; \
done ;; \
esac; \
echo "cd tests && $(PERL) ./run_make_tests.pl -make ../make.exe $(MAKETESTFLAGS)"; \
cd tests && $(PERL) ./run_make_tests.pl -make ../make.exe $(MAKETESTFLAGS); \
else \
echo "Can't find a working Perl ($(PERL)); the test suite requires Perl."; \
fi; \
else \
echo "Can't find the GNU Make test suite ($(srcdir)/tests)."; \
fi
# --------------- Maintainer's Section
# Note this requires GNU make. Not to worry, since it will only be included
# in the Makefile if we're in the maintainer's environment.
#include $(srcdir)/maintMakefile
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
# --------------- DEPENDENCIES
ar.o: ar.c make.h config.h gettext.h filedef.h dep.h glob/fnmatch.h
arscan.o: arscan.c make.h config.h gettext.h
commands.o: commands.c make.h config.h gettext.h dep.h filedef.h \
variable.h job.h commands.h
default.o: default.c make.h config.h gettext.h rule.h dep.h filedef.h \
job.h commands.h variable.h
dir.o: dir.c make.h config.h gettext.h glob/glob.h
expand.o: expand.c make.h config.h gettext.h filedef.h job.h commands.h \
variable.h rule.h
file.o: file.c make.h config.h gettext.h dep.h filedef.h job.h \
commands.h variable.h debug.h
function.o: function.c make.h config.h gettext.h filedef.h variable.h \
dep.h job.h commands.h debug.h
getopt.o: getopt.c config.h gettext.h getopt.h
getopt1.o: getopt1.c config.h getopt.h
implicit.o: implicit.c make.h config.h gettext.h rule.h dep.h filedef.h \
debug.h
job.o: job.c make.h config.h gettext.h job.h debug.h filedef.h \
commands.h variable.h
main.o: main.c make.h config.h gettext.h dep.h filedef.h variable.h \
job.h commands.h rule.h debug.h getopt.h
misc.o: misc.c make.h config.h gettext.h dep.h debug.h
read.o: read.c make.h config.h gettext.h glob/glob.h dep.h filedef.h \
job.h commands.h variable.h rule.h debug.h
remake.o: remake.c make.h config.h gettext.h filedef.h job.h commands.h \
dep.h variable.h debug.h
remote-stub.o: remote-stub.c make.h config.h gettext.h filedef.h job.h \
commands.h
rule.o: rule.c make.h config.h gettext.h dep.h filedef.h job.h \
commands.h variable.h rule.h
signame.o: signame.c make.h config.h gettext.h
variable.o: variable.c make.h config.h gettext.h dep.h filedef.h job.h \
commands.h variable.h rule.h
version.o: version.c config.h
vpath.o: vpath.c make.h config.h gettext.h filedef.h variable.h

162
Makefile.am Normal file
View File

@@ -0,0 +1,162 @@
# This is a -*-Makefile-*-, or close enough
AUTOMAKE_OPTIONS = 1.7 dist-bzip2 check-news
ACLOCAL_AMFLAGS = -I config
SUBDIRS = glob config po doc
bin_PROGRAMS = make
if USE_CUSTOMS
remote = remote-cstms.c
else
remote = remote-stub.c
endif
make_SOURCES = ar.c arscan.c commands.c default.c dir.c expand.c file.c \
function.c getopt.c getopt1.c implicit.c job.c main.c \
misc.c read.c remake.c $(remote) rule.c signame.c \
variable.c version.c vpath.c hash.c
EXTRA_make_SOURCES = remote-stub.c remote-cstms.c
noinst_HEADERS = commands.h dep.h filedef.h job.h make.h rule.h variable.h \
debug.h getopt.h gettext.h hash.h
make_LDADD = @LIBOBJS@ @ALLOCA@ $(GLOBLIB) @GETLOADAVG_LIBS@ @LIBINTL@
man_MANS = make.1
DEFS = -DLOCALEDIR=\"$(localedir)\" -DLIBDIR=\"$(libdir)\" -DINCLUDEDIR=\"$(includedir)\" @DEFS@
AM_CPPFLAGS = $(GLOBINC)
# Extra stuff to include in the distribution.
# Note we need all the glob stuff here, rather than in glob/Makefile.am,
# because often that directory isn't built on the systems used by the
# maintainers.
EXTRA_DIST = README build.sh.in $(man_MANS)\
README.customs\
SCOPTIONS SMakefile\
README.Amiga Makefile.ami config.ami make.lnk amiga.c amiga.h\
README.DOS Makefile.DOS configure.bat dosbuild.bat configh.dos\
README.W32 NMakefile config.h.W32 build_w32.bat subproc.bat\
readme.vms makefile.vms makefile.com config.h-vms \
vmsdir.h vmsfunctions.c vmsify.c
MAKE_HOST = @MAKE_HOST@
# Forward targets
html:
cd doc && $(MAKE) $(AM_MAKEFLAGS) $@
.PHONY: html
# --------------- Internationalization Section
localedir = $(datadir)/locale
# --------------- Local INSTALL Section
# If necessary, change the gid of the app and turn on the setgid flag.
#
# Whether or not make needs to be installed setgid.
# The value should be either `true' or `false'.
# On many systems, the getloadavg function (used to implement the `-l'
# switch) will not work unless make is installed setgid kmem.
#
inst_setgid = @NEED_SETGID@
# Install make setgid to this group so it can get the load average.
#
inst_group = @KMEM_GROUP@
install-exec-local:
@if $(inst_setgid); then \
app=$(DESTDIR)$(bindir)/`echo $(bin_PROGRAMS)|sed '$(transform)'`; \
if chgrp $(inst_group) $$app && chmod g+s $$app; then \
echo "chgrp $(inst_group) $$app && chmod g+s $$app"; \
else \
echo "$$app needs to be owned by group $(inst_group) and setgid;"; \
echo "otherwise the \`-l' option will probably not work."; \
echo "You may need special privileges to complete the installation"; \
echo "of $$app."; \
fi; \
else true; fi
# --------------- Local DIST Section
# Install the w32 and tests subdirectories
#
dist-hook:
(cd $(srcdir); \
sub=`find w32 tests -follow \( -name CVS -prune -o -name .cvsignore -o -name work -prune \) -o \( -name \*.orig -o -name \*.rej -o -name \*~ -prune \) -o -type f -print`; \
tar chf - $$sub) \
| (cd $(distdir); tar xfBp -)
# --------------- Local CHECK Section
check-local: check-regression check-loadavg
@banner=" Regression PASSED: GNU Make $(VERSION) ($(MAKE_HOST)) built with $(CC) "; \
dashes=`echo "$$banner" | sed s/./=/g`; \
echo; \
echo "$$dashes"; \
echo "$$banner"; \
echo "$$dashes"; \
echo
.PHONY: check-loadavg check-regression
check-loadavg: loadavg
@echo The system uptime program believes the load average to be:
-uptime
@echo The GNU load average checking code thinks:
-./loadavg
# The loadavg function is invoked during "make check" to test getloadavg.
noinst_PROGRAMS = loadavg
loadavg_SOURCES = loadavg.c
loadavg_CFLAGS = -DTEST
loadavg_LDADD = @GETLOADAVG_LIBS@
loadavg.c: $(srcdir)/getloadavg.c
cp $(srcdir)/getloadavg.c loadavg.c
# > check-regression
#
# Look for the make test suite, and run it if found and we can find perl.
# If we're building outside the tree, we use symlinks to make a local copy of
# the test suite. Unfortunately the test suite itself isn't localizable yet.
#
MAKETESTFLAGS =
check-regression:
@if test -f "$(srcdir)/tests/run_make_tests"; then \
if $(PERL) -v >/dev/null 2>&1; then \
case `cd $(srcdir); pwd` in `pwd`) : ;; \
*) test -d tests || mkdir tests; \
rm -f srctests; \
if ln -s "$(srcdir)/tests" srctests; then \
for f in run_make_tests run_make_tests.pl test_driver.pl scripts; do \
rm -f tests/$$f; ln -s ../srctests/$$f tests; \
done; fi ;; \
esac; \
echo "cd tests && $(PERL) ./run_make_tests.pl -make ../make $(MAKETESTFLAGS)"; \
cd tests && $(PERL) ./run_make_tests.pl -make ../make $(MAKETESTFLAGS); \
else \
echo "Can't find a working Perl ($(PERL)); the test suite requires Perl."; \
fi; \
else \
echo "Can't find the GNU Make test suite ($(srcdir)/tests)."; \
fi
# --------------- Maintainer's Section
@MAINT_MAKEFILE@

305
Makefile.ami Normal file
View File

@@ -0,0 +1,305 @@
# NOTE: If you have no `make' program at all to process this makefile, run
# `build.sh' instead.
#
# Copyright (C) 1988, 89, 91, 92, 93, 94, 1995 Free Software Foundation, Inc.
# This file is part of GNU Make.
#
# GNU Make is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# GNU Make is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GNU Make; see the file COPYING. If not, write to
# the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
# Boston, MA 02111-1307, USA.
#
# Makefile for GNU Make
#
CC = sc
RM = delete
CFLAGS =
CPPFLAGS =
LDFLAGS =
# Define these for your system as follows:
# -DNO_ARCHIVES To disable `ar' archive support.
# -DNO_FLOAT To avoid using floating-point numbers.
# -DENUM_BITFIELDS If the compiler isn't GCC but groks enum foo:2.
# Some compilers apparently accept this
# without complaint but produce losing code,
# so beware.
# NeXT 1.0a uses an old version of GCC, which required -D__inline=inline.
# See also `config.h'.
defines =
# Which flavor of remote job execution support to use.
# The code is found in `remote-$(REMOTE).c'.
REMOTE = stub
# If you are using the GNU C library, or have the GNU getopt functions in
# your C library, you can comment these out.
GETOPT = getopt.o getopt1.o
GETOPT_SRC = $(srcdir)getopt.c $(srcdir)getopt1.c $(srcdir)getopt.h
# If you are using the GNU C library, or have the GNU glob functions in
# your C library, you can comment this out. GNU make uses special hooks
# into the glob functions to be more efficient (by using make's directory
# cache for globbing), so you must use the GNU functions even if your
# system's C library has the 1003.2 glob functions already. Also, the glob
# functions in the AIX and HPUX C libraries are said to be buggy.
GLOB = glob/glob.lib
# If your system doesn't have alloca, or the one provided is bad, define this.
ALLOCA = alloca.o
ALLOCA_SRC = $(srcdir)alloca.c
# If your system needs extra libraries loaded in, define them here.
# System V probably need -lPW for alloca. HP-UX 7.0's alloca in
# libPW.a is broken on HP9000s300 and HP9000s400 machines. Use
# alloca.c instead on those machines.
LOADLIBES =
# Any extra object files your system needs.
extras = amiga.o
# Common prefix for machine-independent installed files.
prefix =
# Common prefix for machine-dependent installed files.
exec_prefix =
# Directory to install `make' in.
bindir = sc:c
# Directory to find libraries in for `-lXXX'.
libdir = lib:
# Directory to search by default for included makefiles.
includedir = include:
# Directory to install the Info files in.
infodir = doc:
# Directory to install the man page in.
mandir = t:
# Number to put on the man page filename.
manext = 1
# Prefix to put on installed `make' binary file name.
binprefix =
# Prefix to put on installed `make' man page file name.
manprefix = $(binprefix)
# Whether or not make needs to be installed setgid.
# The value should be either `true' or `false'.
# On many systems, the getloadavg function (used to implement the `-l'
# switch) will not work unless make is installed setgid kmem.
install_setgid = false
# Install make setgid to this group so it can read /dev/kmem.
group = sys
# Program to install `make'.
INSTALL_PROGRAM = copy
# Program to install the man page.
INSTALL_DATA = copy
# Generic install program.
INSTALL = copy
# Program to format Texinfo source into Info files.
MAKEINFO = makeinfo
# Program to format Texinfo source into DVI files.
TEXI2DVI = texi2dvi
# Programs to make tags files.
ETAGS = etags -w
CTAGS = ctags -w
objs = commands.o job.o dir.o file.o misc.o main.o read.o remake.o \
rule.o implicit.o default.o variable.o expand.o function.o \
vpath.o version.o ar.o arscan.o signame.o remote-$(REMOTE).o \
$(GETOPT) $(ALLOCA) $(extras)
srcs = $(srcdir)commands.c $(srcdir)job.c $(srcdir)dir.c \
$(srcdir)file.c $(srcdir)getloadavg.c $(srcdir)misc.c \
$(srcdir)main.c $(srcdir)read.c $(srcdir)remake.c \
$(srcdir)rule.c $(srcdir)implicit.c $(srcdir)default.c \
$(srcdir)variable.c $(srcdir)expand.c $(srcdir)function.c \
$(srcdir)vpath.c $(srcdir)version.c \
$(srcdir)remote-$(REMOTE).c \
$(srcdir)ar.c $(srcdir)arscan.c \
$(srcdir)signame.c $(srcdir)signame.h $(GETOPT_SRC) \
$(srcdir)commands.h $(srcdir)dep.h $(srcdir)filedep.h \
$(srcdir)job.h $(srcdir)make.h $(srcdir)rule.h \
$(srcdir)variable.h $(ALLOCA_SRC) $(srcdir)config.h.in
.SUFFIXES:
.SUFFIXES: .o .c .h .ps .dvi .info .texinfo
all: make
info: make.info
dvi: make.dvi
# Some makes apparently use .PHONY as the default goal if it is before `all'.
.PHONY: all check info dvi
make.info: make.texinfo
$(MAKEINFO) -I$(srcdir) $(srcdir)make.texinfo -o make.info
make.dvi: make.texinfo
$(TEXI2DVI) $(srcdir)make.texinfo
make.ps: make.dvi
dvi2ps make.dvi > make.ps
make: $(objs) $(GLOB)
$(CC) Link $(LDFLAGS) $(objs) Lib $(GLOB) $(LOADLIBES) To make.new
-delete make
rename make.new make
TMPFILE = t:Make$$
$(GLOB):
cd glob @@\
$(MAKE) -$(MAKEFLAGS) -f Makefile
# -I. is needed to find config.h in the build directory.
OUTPUT_OPTION =
.c.o:
$(CC) $(defines) IDir "" IDir glob \
$(CPPFLAGS) $(CFLAGS) $< $(OUTPUT_OPTION)
# For some losing Unix makes.
SHELL = /bin/sh
#@SET_MAKE@
glob/libglob.a: FORCE config.h
cd glob; $(MAKE) libglob.a
FORCE:
tagsrcs = $(srcs) $(srcdir)remote-*.c
.PHONY: install installdirs
install: installdirs \
$(bindir)$(binprefix)make $(infodir)make.info \
$(mandir)$(manprefix)make.$(manext)
installdirs:
$(SHELL) ${srcdir}/mkinstalldirs $(bindir) $(infodir) $(mandir)
$(bindir)$(binprefix)make: make
$(INSTALL_PROGRAM) make $@.new
@if $(install_setgid); then \
if chgrp $(group) $@.new && chmod g+s $@.new; then \
echo "chgrp $(group) $@.new && chmod g+s $@.new"; \
else \
echo "$@ needs to be owned by group $(group) and setgid;"; \
echo "otherwise the \`-l' option will probably not work."; \
echo "You may need special privileges to install $@."; \
fi; \
else true; fi
# Some systems can't deal with renaming onto a running binary.
-$(RM) $@.old
-mv $@ $@.old
mv $@.new $@
$(infodir)make.info: make.info
if [ -r ./make.info ]; then dir=.; else dir=$(srcdir); fi; \
for file in $${dir}/make.info*; do \
name="`basename $$file`"; \
$(INSTALL_DATA) $$file \
`echo $@ | sed "s,make.info\$$,$$name,"`; \
done
# Run install-info only if it exists.
# Use `if' instead of just prepending `-' to the
# line so we notice real errors from install-info.
# We use `$(SHELL) -c' because some shells do not
# fail gracefully when there is an unknown command.
if $(SHELL) -c 'install-info --version' >/dev/null 2>&1; then \
if [ -r ./make.info ]; then dir=.; else dir=$(srcdir); fi; \
install-info --infodir=$(infodir) $$dir/make.info; \
else true; fi
$(mandir)$(manprefix)make.$(manext): make.man
$(INSTALL_DATA) $(srcdir)make.man $@
loadavg: loadavg.c config.h
$(CC) $(defines) -DTEST -I. -I$(srcdir) $(CFLAGS) $(LDFLAGS) \
loadavg.c $(LOADLIBES) -o $@
# We copy getloadavg.c into a different file rather than compiling it
# directly because some compilers clobber getloadavg.o in the process.
loadavg.c: getloadavg.c
ln $(srcdir)getloadavg.c loadavg.c || \
cp $(srcdir)getloadavg.c loadavg.c
check-loadavg: loadavg
@echo The system uptime program believes the load average to be:
-uptime
@echo The GNU load average checking code believes:
./loadavg
check: check-loadavg
.PHONY: clean realclean distclean mostlyclean
clean: glob-clean
-$(RM) make loadavg "#?.o" core make.dvi
distclean: clean glob-realclean
-$(RM) Makefile config.h config.status build.sh
-$(RM) config.log config.cache
-$(RM) TAGS tags
-$(RM) make.?? make.??s make.log make.toc make.*aux
-$(RM) loadavg.c
realclean: distclean
-$(RM) make.info*
mostlyclean: clean
.PHONY: glob-clean glob-realclean
glob-clean glob-realclean:
cd glob @@\
$(MAKE) $@
# This tells versions [3.59,3.63) of GNU make not to export all variables.
.NOEXPORT:
# The automatically generated dependencies below may omit config.h
# because it is included with ``#include <config.h>'' rather than
# ``#include "config.h"''. So we add the explicit dependency to make sure.
$(objs): config.h
# Automatically generated dependencies will be put at the end of the file.
# Automatically generated dependencies.
commands.o: commands.c make.h dep.h filedef.h variable.h job.h \
commands.h
job.o: job.c make.h job.h filedef.h commands.h variable.h
dir.o: dir.c make.h
file.o: file.c make.h dep.h filedef.h job.h commands.h variable.h
misc.o: misc.c make.h dep.h
main.o: main.c make.h dep.h filedef.h variable.h job.h commands.h \
getopt.h
read.o: read.c make.h dep.h filedef.h job.h commands.h variable.h \
glob/glob.h
remake.o: remake.c make.h filedef.h job.h commands.h dep.h
rule.o: rule.c make.h dep.h filedef.h job.h commands.h variable.h \
rule.h
implicit.o: implicit.c make.h rule.h dep.h filedef.h
default.o: default.c make.h rule.h dep.h filedef.h job.h commands.h \
variable.h
variable.o: variable.c make.h dep.h filedef.h job.h commands.h \
variable.h
expand.o: expand.c make.h filedef.h job.h commands.h variable.h
function.o: function.c make.h filedef.h variable.h dep.h job.h \
commands.h amiga.h
vpath.o: vpath.c make.h filedef.h variable.h
version.o: version.c
ar.o: ar.c make.h filedef.h dep.h
arscan.o: arscan.c make.h
signame.o: signame.c signame.h
remote-stub.o: remote-stub.c make.h filedef.h job.h commands.h
getopt.o: getopt.c
getopt1.o : getopt1.c getopt.h
getloadavg.o: getloadavg.c
amiga.o: amiga.c make.h variable.h amiga.h

859
NEWS Normal file
View File

@@ -0,0 +1,859 @@
GNU make NEWS -*-indented-text-*-
History of user-visible changes.
03 October 2002
Copyright (C) 2002 Free Software Foundation, Inc.
See the end for copying conditions.
All changes mentioned here are more fully described in the GNU make
manual, which is contained in this distribution as the file make.texinfo.
Please send GNU make bug reports to <bug-make@gnu.org>.
See the README file and the GNU make manual for details on sending bug
reports.
Version 3.80
* A new feature exists: order-only prerequisites. These prerequisites
affect the order in which targets are built, but they do not impact
the rebuild/no-rebuild decision of their dependents. That is to say,
they allow you to require target B be built before target A, without
requiring that target A will always be rebuilt if target B is updated.
Patch for this feature provided by Greg McGary <greg@mcgary.org>.
* For compatibility with SysV make, GNU make now supports the peculiar
syntax $$@, $$(@D), and $$(@F) in the prerequisites list of a rule.
This syntax is only valid within explicit and static pattern rules: it
cannot be used in implicit (suffix or pattern) rules. Edouard G. Parmelan
<egp@free.fr> provided a patch implementing this feature; however, I
decided to implement it in a different way.
* The argument to the "ifdef" conditional is now expanded before it's
tested, so it can be a constructed variable name.
Similarly, the arguments to "export" (when not used in a variable
definition context) and "unexport" are also now expanded.
* A new function is defined: $(value ...). The argument to this
function is the _name_ of a variable. The result of the function is
the value of the variable, without having been expanded.
* A new function is defined: $(eval ...). The arguments to this
function should expand to makefile commands, which will then be
evaluated as if they had appeared in the makefile. In combination
with define/endef multiline variable definitions this is an extremely
powerful capability. The $(value ...) function is also sometimes
useful here.
* A new built-in variable is defined, $(MAKEFILE_LIST). It contains a
list of each makefile GNU make has read, or started to read, in the
order in which they were encountered. So, the last filename in the
list when a makefile is just being read (before any includes) is the
name of the current makefile.
* A new built-in variable is defined: $(.VARIABLES). When it is
expanded it returns a complete list of variable names defined by all
makefiles at that moment.
* A new command-line option is defined, -B or --always-make. If
specified GNU make will consider all targets out-of-date even if they
would otherwise not be.
* The arguments to $(call ...) functions were being stored in $1, $2,
etc. as recursive variables, even though they are fully expanded
before assignment. This means that escaped dollar signs ($$ etc.)
were not behaving properly. Now the arguments are stored as simple
variables. This may mean that if you added extra escaping to your
$(call ...) function arguments you will need to undo it now.
* The variable invoked by $(call ...) can now be recursive: unlike other
variables it can reference itself and this will not produce an error
when it is used as the first argument to $(call ...) (but only then).
* New pseudo-target .LOW_RESOLUTION_TIME, superseding the configure
option --disable-nsec-timestamps. You might need this if your build
process depends on tools like "cp -p" preserving time stamps, since
"cp -p" (right now) doesn't preserve the subsecond portion of a time
stamp.
* Updated translations for French, Galician, German, Japanese, Korean,
and Russian. New translations for Croatian, Danish, Hebrew, and
Turkish.
* Updated internationalization support to Gettext 0.11.5.
GNU make now uses Gettext's "external" feature, and does not include
any internationalization code itself. Configure will search your
system for an existing implementation of GNU Gettext (only GNU Gettext
is acceptable) and use it if it exists. If not, NLS will be disabled.
See ABOUT-NLS for more information.
* Updated to autoconf 2.54 and automake 1.7. Users should not be impacted.
Version 3.79.1
* .SECONDARY with no prerequisites now prevents any target from being
removed because make thinks it's an intermediate file, not just those
listed in the makefile.
* New configure option --disable-nsec-timestamps, but this was
superseded in later versions by the .LOW_RESOLUTION_TIME pseudo-target.
Version 3.79
* GNU make optionally supports internationalization and locales via the
GNU gettext (or local gettext if suitable) package. See the ABOUT-NLS
file for more information on configuring GNU make for NLS.
* Previously, GNU make quoted variables such as MAKEFLAGS and
MAKEOVERRIDES for proper parsing by the shell. This allowed them to
be used within make build scripts. However, using them there is not
proper behavior: they are meant to be passed to subshells via the
environment. Unfortunately the values were not quoted properly to be
passed through the environment. This meant that make didn't properly
pass some types of command line values to submakes.
With this version we change that behavior: now these variables are
quoted properly for passing through the environment, which is the
correct way to do it. If you previously used these variables
explicitly within a make rule you may need to re-examine your use for
correctness given this change.
* A new pseudo-target .NOTPARALLEL is available. If defined, the
current makefile is run serially regardless of the value of -j.
However, submakes are still eligible for parallel execution.
* The --debug option has changed: it now allows optional flags
controlling the amount and type of debugging output. By default only
a minimal amount information is generated, displaying the names of
"normal" targets (not makefiles) that were deemed out of date and in
need of being rebuilt.
Note that the -d option behaves as before: it takes no arguments and
all debugging information is generated.
* The `-p' (print database) output now includes filename and linenumber
information for variable definitions, to aid debugging.
* The wordlist function no longer reverses its arguments if the "start"
value is greater than the "end" value. If that's true, nothing is
returned.
* Hartmut Becker provided many updates for the VMS port of GNU make.
See the readme.vms file for more details.
Version 3.78
* Two new functions, $(error ...) and $(warning ...) are available. The
former will cause make to fail and exit immediately upon expansion of
the function, with the text provided as the error message. The latter
causes the text provided to be printed as a warning message, but make
proceeds normally.
* A new function $(call ...) is available. This allows users to create
their own parameterized macros and invoke them later. Original
implementation of this function was provided by Han-Wen Nienhuys
<hanwen@cs.uu.nl>.
* A new function $(if ...) is available. It provides if-then-else
capabilities in a builtin function. Original implementation of this
function was provided by Han-Wen Nienhuys <hanwen@cs.uu.nl>.
* Make defines a new variable, .LIBPATTERNS. This variable controls how
library dependency expansion (dependencies like ``-lfoo'') is performed.
* Make accepts CRLF sequences as well as traditional LF, for
compatibility with makefiles created on other operating systems.
* Make accepts a new option: -R, or --no-builtin-variables. This option
disables the definition of the rule-specific builtin variables (CC,
LD, AR, etc.). Specifying this option forces -r (--no-builtin-rules)
as well.
* A "job server" feature, suggested by Howard Chu <hyc@highlandsun.com>.
On systems that support POSIX pipe(2) semantics, GNU make can now pass
-jN options to submakes rather than forcing them all to use -j1. The
top make and all its sub-make processes use a pipe to communicate with
each other to ensure that no more than N jobs are started across all
makes. To get the old behavior of -j back, you can configure make
with the --disable-job-server option.
* The confusing term "dependency" has been replaced by the more accurate
and standard term "prerequisite", both in the manual and in all GNU make
output.
* GNU make supports the "big archive" library format introduced in AIX 4.3.
* GNU make supports large files on AIX, HP-UX, and IRIX. These changes
were provided by Paul Eggert <eggert@twinsun.com>. (Large file
support for Solaris and Linux was introduced in 3.77, but the
configuration had issues: these have also been resolved).
* The Windows 95/98/NT (W32) version of GNU make now has native support
for the Cygnus Cygwin release B20.1 shell (bash).
* The GNU make regression test suite, long available separately "under
the table", has been integrated into the release. You can invoke it
by running "make check" in the distribution. Note that it requires
Perl (either Perl 4 or Perl 5) to run.
Version 3.77
* Implement BSD make's "?=" variable assignment operator. The variable
is assigned the specified value only if that variable is not already
defined.
* Make defines a new variable, "CURDIR", to contain the current working
directory (after the -C option, if any, has been processed).
Modifying this variable has no effect on the operation of make.
* Make defines a new default RCS rule, for new-style master file
storage: ``% :: RCS/%'' (note no ``,v'' suffix).
Make defines new default rules for DOS-style C++ file naming
conventions, with ``.cpp'' suffixes. All the same rules as for
``.cc'' and ``.C'' suffixes are provided, along with LINK.cpp and
COMPILE.cpp macros (which default to the same value as LINK.cc and
COMPILE.cc). Note CPPFLAGS is still C preprocessor flags! You should
use CXXFLAGS to change C++ compiler flags.
* A new feature, "target-specific variable values", has been added.
This is a large change so please see the appropriate sections of the
manual for full details. Briefly, syntax like this:
TARGET: VARIABLE = VALUE
defines VARIABLE as VALUE within the context of TARGET. This is
similar to SunOS make's "TARGET := VARIABLE = VALUE" feature. Note
that the assignment may be of any type, not just recursive, and that
the override keyword is available.
COMPATIBILITY: This new syntax means that if you have any rules where
the first or second dependency has an equal sign (=) in its name,
you'll have to escape them with a backslash: "foo : bar\=baz".
Further, if you have any dependencies which already contain "\=",
you'll have to escape both of them: "foo : bar\\\=baz".
* A new appendix listing the most common error and warning messages
generated by GNU make, with some explanation, has been added to the
GNU make User's Manual.
* Updates to the GNU make Customs library support (see README.customs).
* Updates to the Windows 95/NT port from Rob Tulloh (see README.W32),
and to the DOS port from Eli Zaretski (see README.DOS).
Version 3.76.1
* Small (but serious) bug fix. Quick rollout to get into the GNU source CD.
Version 3.76
* GNU make now uses automake to control Makefile.in generation. This
should make it more consistent with the GNU standards.
* VPATH functionality has been changed to incorporate the VPATH+ patch,
previously maintained by Paul Smith <psmith@baynetworks.com>. See the
manual.
* Make defines a new variable, `MAKECMDGOALS', to contain the goals that
were specified on the command line, if any. Modifying this variable
has no effect on the operation of make.
* A new function, `$(wordlist S,E,TEXT)', is available: it returns a
list of words from number S to number E (inclusive) of TEXT.
* Instead of an error, detection of future modification times gives a
warning and continues. The warning is repeated just before GNU make
exits, so it is less likely to be lost.
* Fix the $(basename) and $(suffix) functions so they only operate on
the last filename, not the entire string:
Command Old Result New Result
------- ---------- ----------
$(basename a.b) a a
$(basename a.b/c) a a.b/c
$(suffix a.b) b b
$(suffix a.b/c) b/c <empty>
* The $(strip) function now removes newlines as well as TABs and spaces.
* The $(shell) function now changes CRLF (\r\n) pairs to a space as well
as newlines (\n).
* Updates to the Windows 95/NT port from Rob Tulloh (see README.W32).
* Eli Zaretskii has updated the port to 32-bit protected mode on MSDOS
and MS-Windows, building with the DJGPP v2 port of GNU C/C++ compiler
and utilities. See README.DOS for details, and direct all questions
concerning this port to Eli Zaretskii <eliz@is.elta.co.il> or DJ
Delorie <dj@delorie.com>.
* John W. Eaton has updated the VMS port to support libraries and VPATH.
Version 3.75
* The directory messages printed by `-w' and implicitly in sub-makes,
are now omitted if Make runs no commands and has no other messages to print.
* Make now detects files that for whatever reason have modification times
in the future and gives an error. Files with such impossible timestamps
can result from unsynchronized clocks, or archived distributions
containing bogus timestamps; they confuse Make's dependency engine
thoroughly.
* The new directive `sinclude' is now recognized as another name for
`-include', for compatibility with some other Makes.
* Aaron Digulla has contributed a port to AmigaDOS. See README.Amiga for
details, and direct all Amiga-related questions to <digulla@fh-konstanz.de>.
* Rob Tulloh of Tivoli Systems has contributed a port to Windows NT or 95.
See README.W32 for details, and direct all Windows-related questions to
<rob_tulloh@tivoli.com>.
Version 3.73
* Converted to use Autoconf version 2, so `configure' has some new options.
See INSTALL for details.
* You can now send a SIGUSR1 signal to Make to toggle printing of debugging
output enabled by -d, at any time during the run.
Version 3.72
* DJ Delorie has ported Make to MS-DOS using the GO32 extender.
He is maintaining the DOS port, not the GNU Make maintainer;
please direct bugs and questions for DOS to <djgpp@sun.soe.clarkson.edu>.
MS-DOS binaries are available for FTP from ftp.simtel.net in
/pub/simtelnet/gnu/djgpp/.
* The `MAKEFLAGS' variable (in the environment or in a makefile) can now
contain variable definitions itself; these are treated just like
command-line variable definitions. Make will automatically insert any
variable definitions from the environment value of `MAKEFLAGS' or from
the command line, into the `MAKEFLAGS' value exported to children. The
`MAKEOVERRIDES' variable previously included in the value of `$(MAKE)'
for sub-makes is now included in `MAKEFLAGS' instead. As before, you can
reset `MAKEOVERRIDES' in your makefile to avoid putting all the variables
in the environment when its size is limited.
* If `.DELETE_ON_ERROR' appears as a target, Make will delete the target of
a rule if it has changed when its commands exit with a nonzero status,
just as when the commands get a signal.
* The automatic variable `$+' is new. It lists all the dependencies like
`$^', but preserves duplicates listed in the makefile. This is useful
for linking rules, where library files sometimes need to be listed twice
in the link order.
* You can now specify the `.IGNORE' and `.SILENT' special targets with
dependencies to limit their effects to those files. If a file appears as
a dependency of `.IGNORE', then errors will be ignored while running the
commands to update that file. Likewise if a file appears as a dependency
of `.SILENT', then the commands to update that file will not be printed
before they are run. (This change was made to conform to POSIX.2.)
Version 3.71
* The automatic variables `$(@D)', `$(%D)', `$(*D)', `$(<D)', `$(?D)', and
`$(^D)' now omit the trailing slash from the directory name. (This change
was made to comply with POSIX.2.)
* The source distribution now includes the Info files for the Make manual.
There is no longer a separate distribution containing Info and DVI files.
* You can now set the variables `binprefix' and/or `manprefix' in
Makefile.in (or on the command line when installing) to install GNU make
under a name other than `make' (i.e., ``make binprefix=g install''
installs GNU make as `gmake').
* The built-in Texinfo rules use the new variables `TEXI2DVI_FLAGS' for
flags to the `texi2dvi' script, and `MAKEINFO_FLAGS' for flags to the
Makeinfo program.
* The exit status of Make when it runs into errors is now 2 instead of 1.
The exit status is 1 only when using -q and some target is not up to date.
(This change was made to comply with POSIX.2.)
Version 3.70
* It is no longer a fatal error to have a NUL character in a makefile.
You should never put a NUL in a makefile because it can have strange
results, but otherwise empty lines full of NULs (such as produced by
the `xmkmf' program) will always work fine.
* The error messages for nonexistent included makefiles now refer to the
makefile name and line number where the `include' appeared, so Emacs's
C-x ` command takes you there (in case it's a typo you need to fix).
Version 3.69
* Implicit rule search for archive member references is now done in the
opposite order from previous versions: the whole target name `LIB(MEM)'
first, and just the member name and parentheses `(MEM)' second.
* Make now gives an error for an unterminated variable or function reference.
For example, `$(foo' with no matching `)' or `${bar' with no matching `}'.
* The new default variable `MAKE_VERSION' gives the version number of
Make, and a string describing the remote job support compiled in (if any).
Thus the value (in this release) is something like `3.69' or `3.69-Customs'.
* Commands in an invocation of the `shell' function are no longer run with
a modified environment like target commands are. As in versions before
3.68, they now run with the environment that `make' started with. We
have reversed the change made in version 3.68 because it turned out to
cause a paradoxical situation in cases like:
export variable = $(shell echo value)
When Make attempted to put this variable in the environment for a target
command, it would try expand the value by running the shell command
`echo value'. In version 3.68, because it constructed an environment
for that shell command in the same way, Make would begin to go into an
infinite loop and then get a fatal error when it detected the loop.
* The commands given for `.DEFAULT' are now used for phony targets with no
commands.
Version 3.68
* You can list several archive member names inside parenthesis:
`lib(mem1 mem2 mem3)' is equivalent to `lib(mem1) lib(mem2) lib(mem3)'.
* You can use wildcards inside archive member references. For example,
`lib(*.o)' expands to all existing members of `lib' whose names end in
`.o' (e.g. `lib(a.o) lib(b.o)'); `*.a(*.o)' expands to all such members
of all existing files whose names end in `.a' (e.g. `foo.a(a.o)
foo.a(b.o) bar.a(c.o) bar.a(d.o)'.
* A suffix rule `.X.a' now produces two pattern rules:
(%.o): %.X # Previous versions produced only this.
%.a: %.X # Now produces this as well, just like other suffixes.
* The new flag `--warn-undefined-variables' says to issue a warning message
whenever Make expands a reference to an undefined variable.
* The new `-include' directive is just like `include' except that there is
no error (not even a warning) for a nonexistent makefile.
* Commands in an invocation of the `shell' function are now run with a
modified environment like target commands are, so you can use `export' et
al to set up variables for them. They used to run with the environment
that `make' started with.
Version 3.66
* `make --version' (or `make -v') now exits immediately after printing
the version number.
Version 3.65
* Make now supports long-named members in `ar' archive files.
Version 3.64
* Make now supports the `+=' syntax for a variable definition which appends
to the variable's previous value. See the section `Appending More Text
to Variables' in the manual for full details.
* The new option `--no-print-directory' inhibits the `-w' or
`--print-directory' feature. Make turns on `--print-directory'
automatically if you use `-C' or `--directory', and in sub-makes; some
users have found this behavior undesirable.
* The built-in implicit rules now support the alternative extension
`.txinfo' for Texinfo files, just like `.texinfo' and `.texi'.
Version 3.63
* Make now uses a standard GNU `configure' script. See the new file
INSTALL for the new (and much simpler) installation procedure.
* There is now a shell script to build Make the first time, if you have no
other `make' program. `build.sh' is created by `configure'; see README.
* GNU Make now completely conforms to the POSIX.2 specification for `make'.
* Elements of the `$^' and `$?' automatic variables that are archive
member references now list only the member name, as in Unix and POSIX.2.
* You should no longer ever need to specify the `-w' switch, which prints
the current directory before and after Make runs. The `-C' switch to
change directory, and recursive use of Make, now set `-w' automatically.
* Multiple double-colon rules for the same target will no longer have their
commands run simultaneously under -j, as this could result in the two
commands trying to change the file at the same time and interfering with
one another.
* The `SHELL' variable is now never taken from the environment.
Each makefile that wants a shell other than the default (/bin/sh) must
set SHELL itself. SHELL is always exported to child processes.
This change was made for compatibility with POSIX.2.
* Make now accepts long options. There is now an informative usage message
that tells you what all the options are and what they do. Try `make --help'.
* There are two new directives: `export' and `unexport'. All variables are
no longer automatically put into the environments of the commands that
Make runs. Instead, only variables specified on the command line or in
the environment are exported by default. To export others, use:
export VARIABLE
or you can define variables with:
export VARIABLE = VALUE
or:
export VARIABLE := VALUE
You can use just:
export
or:
.EXPORT_ALL_VARIABLES:
to get the old behavior. See the node `Variables/Recursion' in the manual
for a full description.
* The commands from the `.DEFAULT' special target are only applied to
targets which have no rules at all, not all targets with no commands.
This change was made for compatibility with Unix make.
* All fatal error messages now contain `***', so they are easy to find in
compilation logs.
* Dependency file names like `-lNAME' are now replaced with the actual file
name found, as with files found by normal directory search (VPATH).
The library file `libNAME.a' may now be found in the current directory,
which is checked before VPATH; the standard set of directories (/lib,
/usr/lib, /usr/local/lib) is now checked last.
See the node `Libraries/Search' in the manual for full details.
* A single `include' directive can now specify more than one makefile to
include, like this:
include file1 file2
You can also use shell file name patterns in an `include' directive:
include *.mk
* The default directories to search for included makefiles, and for
libraries specified with `-lNAME', are now set by configuration.
* You can now use blanks as well as colons to separate the directories in a
search path for the `vpath' directive or the `VPATH' variable.
* You can now use variables and functions in the left hand side of a
variable assignment, as in "$(foo)bar = value".
* The `MAKE' variable is always defined as `$(MAKE_COMMAND) $(MAKEOVERRIDES)'.
The `MAKE_COMMAND' variable is now defined to the name with which make
was invoked.
* The built-in rules for C++ compilation now use the variables `$(CXX)' and
`$(CXXFLAGS)' instead of `$(C++)' and `$(C++FLAGS)'. The old names had
problems with shells that cannot have `+' in environment variable names.
* The value of a recursively expanded variable is now expanded when putting
it into the environment for child processes. This change was made for
compatibility with Unix make.
* A rule with no targets before the `:' is now accepted and ignored.
This change was made for compatibility with SunOS 4 make.
We do not recommend that you write your makefiles to take advantage of this.
* The `-I' switch can now be used in MAKEFLAGS, and are put there
automatically just like other switches.
Version 3.61
* Built-in rules for C++ source files with the `.C' suffix.
We still recommend that you use `.cc' instead.
* If commands are given too many times for a single target,
the last set given is used, and a warning message is printed.
* Error messages about makefiles are in standard GNU error format,
so C-x ` in Emacs works on them.
* Dependencies of pattern rules which contain no % need not actually exist
if they can be created (just like dependencies which do have a %).
Version 3.60
* A message is always printed when Make decides there is nothing to be done.
It used to be that no message was printed for top-level phony targets
(because "`phony' is up to date" isn't quite right). Now a different
message "Nothing to be done for `phony'" is printed in that case.
* Archives on AIX now supposedly work.
* When the commands specified for .DEFAULT are used to update a target,
the $< automatic variable is given the same value as $@ for that target.
This is how Unix make behaves, and this behavior is mandated by POSIX.2.
Version 3.59
* The -n, -q, and -t options are not put in the `MAKEFLAGS' and `MFLAG'
variables while remaking makefiles, so recursive makes done while remaking
makefiles will behave properly.
* If the special target `.NOEXPORT' is specified in a makefile,
only variables that came from the environment and variables
defined on the command line are exported.
Version 3.58
* Suffix rules may have dependencies (which are ignored).
Version 3.57
* Dependencies of the form `-lLIB' are searched for as /usr/local/lib/libLIB.a
as well as libLIB.a in /usr/lib, /lib, the current directory, and VPATH.
Version 3.55
* There is now a Unix man page for GNU Make. It is certainly not a replacement
for the Texinfo manual, but it documents the basic functionality and the
switches. For full documentation, you should still read the Texinfo manual.
Thanks to Dennis Morse of Stanford University for contributing the initial
version of this.
* Variables which are defined by default (e.g., `CC') will no longer be put
into the environment for child processes. (If these variables are reset by the
environment, makefiles, or the command line, they will still go into the
environment.)
* Makefiles which have commands but no dependencies (and thus are always
considered out of date and in need of remaking), will not be remade (if they
were being remade only because they were makefiles). This means that GNU
Make will no longer go into an infinite loop when fed the makefiles that
`imake' (necessary to build X Windows) produces.
* There is no longer a warning for using the `vpath' directive with an explicit
pathname (instead of a `%' pattern).
Version 3.51
* When removing intermediate files, only one `rm' command line is printed,
listing all file names.
* There are now automatic variables `$(^D)', `$(^F)', `$(?D)', and `$(?F)'.
These are the directory-only and file-only versions of `$^' and `$?'.
* Library dependencies given as `-lNAME' will use "libNAME.a" in the current
directory if it exists.
* The automatic variable `$($/)' is no longer defined.
* Leading `+' characters on a command line make that line be executed even
under -n, -t, or -q (as if the line contained `$(MAKE)').
* For command lines containing `$(MAKE)', `${MAKE}', or leading `+' characters,
only those lines are executed, not their entire rules.
(This is how Unix make behaves for lines containing `$(MAKE)' or `${MAKE}'.)
Version 3.50
* Filenames in rules will now have ~ and ~USER expanded.
* The `-p' output has been changed so it can be used as a makefile.
(All information that isn't specified by makefiles is prefaced with comment
characters.)
Version 3.49
* The % character can be quoted with backslash in implicit pattern rules,
static pattern rules, `vpath' directives, and `patsubst', `filter', and
`filter-out' functions. A warning is issued if a `vpath' directive's
pattern contains no %.
* The `wildcard' variable expansion function now expands ~ and ~USER.
* Messages indicating failed commands now contain the target name:
make: *** [target] Error 1
* The `-p' output format has been changed somewhat to look more like
makefile rules and to give all information that Make has about files.
Version 3.48
Version 3.47
* The `-l' switch with no argument removes any previous load-average limit.
* When the `-w' switch is in effect, and Make has updated makefiles,
it will write a `Leaving directory' messagfe before re-executing itself.
This makes the `directory change tracking' changes to Emacs's compilation
commands work properly.
Version 3.46
* The automatic variable `$*' is now defined for explicit rules,
as it is in Unix make.
Version 3.45
* The `-j' switch is now put in the MAKEFLAGS and MFLAGS variables when
specified without an argument (indicating infinite jobs).
The `-l' switch is not always put in the MAKEFLAGS and MFLAGS variables.
* Make no longer checks hashed directories after running commands.
The behavior implemented in 3.41 caused too much slowdown.
Version 3.44
* A dependency is NOT considered newer than its dependent if
they have the same modification time. The behavior implemented
in 3.43 conflicts with RCS.
Version 3.43
* Dependency loops are no longer fatal errors.
* A dependency is considered newer than its dependent if
they have the same modification time.
Version 3.42
* The variables F77 and F77FLAGS are now set by default to $(FC) and
$(FFLAGS). Makefiles designed for System V make may use these variables in
explicit rules and expect them to be set. Unfortunately, there is no way to
make setting these affect the Fortran implicit rules unless FC and FFLAGS
are not used (and these are used by BSD make).
Version 3.41
* Make now checks to see if its hashed directories are changed by commands.
Other makes that hash directories (Sun, 4.3 BSD) don't do this.
Version 3.39
* The `shell' function no longer captures standard error output.
Version 3.32
* A file beginning with a dot can be the default target if it also contains
a slash (e.g., `../bin/foo'). (Unix make allows this as well.)
Version 3.31
* Archive member names are truncated to 15 characters.
* Yet more USG stuff.
* Minimal support for Microport System V (a 16-bit machine and a
brain-damaged compiler). This has even lower priority than other USG
support, so if it gets beyond trivial, I will take it out completely.
* Revamped default implicit rules (not much visible change).
* The -d and -p options can come from the environment.
Version 3.30
* Improved support for USG and HPUX (hopefully).
* A variable reference like `$(foo:a=b)', if `a' contains a `%', is
equivalent to `$(patsubst a,b,$(foo))'.
* Defining .DEFAULT with no deps or commands clears its commands.
* New default implicit rules for .S (cpp, then as), and .sh (copy and make
executable). All default implicit rules that use cpp (even indirectly), use
$(CPPFLAGS).
Version 3.29
* Giving the -j option with no arguments gives you infinite jobs.
Version 3.28
* New option: "-l LOAD" says not to start any new jobs while others are
running if the load average is not below LOAD (a floating-point number).
* There is support in place for implementations of remote command execution
in Make. See the file remote.c.
Version 3.26
* No more than 10 directories will be kept open at once.
(This number can be changed by redefining MAX_OPEN_DIRECTORIES in dir.c.)
Version 3.25
* Archive files will have their modification times recorded before doing
anything that might change their modification times by updating an archive
member.
Version 3.20
* The `MAKELEVEL' variable is defined for use by makefiles.
Version 3.19
* The recursion level indications in error messages are much shorter than
they were in version 3.14.
Version 3.18
* Leading spaces before directives are ignored (as documented).
* Included makefiles can determine the default goal target.
(System V Make does it this way, so we are being compatible).
Version 3.14.
* Variables that are defaults built into Make will not be put in the
environment for children. This just saves some environment space and,
except under -e, will be transparent to sub-makes.
* Error messages from sub-makes will indicate the level of recursion.
* Hopefully some speed-up for large directories due to a change in the
directory hashing scheme.
* One child will always get a standard input that is usable.
* Default makefiles that don't exist will be remade and read in.
Version 3.13.
* Count parentheses inside expansion function calls so you can
have nested calls: `$(sort $(foreach x,a b,$(x)))'.
Version 3.12.
* Several bug fixes, including USG and Sun386i support.
* `shell' function to expand shell commands a la `
* If the `-d' flag is given, version information will be printed.
* The `-c' option has been renamed to `-C' for compatibility with tar.
* The `-p' option no longer inhibits other normal operation.
* Makefiles will be updated and re-read if necessary.
* Can now run several commands at once (parallelism), -j option.
* Error messages will contain the level of Make recursion, if any.
* The `MAKEFLAGS' and `MFLAGS' variables will be scanned for options after
makefiles are read.
* A double-colon rule with no dependencies will always have its commands run.
(This is how both the BSD and System V versions of Make do it.)
Version 3.05
(Changes from versions 1 through 3.05 were never recorded. Sorry.)
----------------------------------------------------------------------
Copyright information:
Permission is granted to anyone to make or distribute verbatim copies
of this document as received, in any medium, provided that the
copyright notice and this permission notice are preserved, thus
giving the recipient permission to redistribute in turn.
Permission is granted to distribute modified versions of this
document, or of portions of it, under the above conditions, provided
also that they carry prominent notices stating who last changed them.

123
NMakefile.template Normal file
View File

@@ -0,0 +1,123 @@
# NOTE: If you have no `make' program at all to process this makefile, run
# `build_w32.bat' instead.
#
# Copyright (C) 1988,89,91,92,93,94,95,96,97 Free Software Foundation, Inc.
# This file is part of GNU Make.
#
# GNU Make is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# GNU Make is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GNU Make; see the file COPYING. If not, write to
# the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
# Boston, MA 02111-1307, USA.
#
# NMakefile for GNU Make
#
LINK = link
CC = cl
OUTDIR=.
MAKEFILE=NMakefile
SUBPROC_MAKEFILE=NMakefile
CFLAGS_any = /nologo /MT /W3 /GX /Zi /YX /I . /I glob /I w32/include /D WIN32 /D WINDOWS32 /D _CONSOLE /D HAVE_CONFIG_H
CFLAGS_debug = $(CFLAGS_any) /Od /D DEBUG /D _DEBUG /FR.\WinDebug/ /Fp.\WinDebug/make.pch /Fo.\WinDebug/ /Fd.\WinDebug/make.pdb
CFLAGS_release = $(CFLAGS_any) /O2 /D NDEBUG /FR.\WinRel/ /Fp.\WinRel/make.pch /Fo.\WinRel/
LDFLAGS_debug = w32\subproc\WinDebug\subproc.lib /NOLOGO /SUBSYSTEM:console\
/INCREMENTAL:no /PDB:WinDebug/make.pdb /MACHINE:I386 \
/OUT:WinDebug/make.exe /DEBUG
LDFLAGS_release = w32\subproc\WinRel\subproc.lib /NOLOGO /SUBSYSTEM:console\
/INCREMENTAL:no /MACHINE:I386 /OUT:WinRel/make.exe
all: config.h subproc Release Debug
#
# Make sure we build the subproc library first. It has it's own
# makefile. To be portable to Windows 95, we put the instructions
# on how to build the library into a batch file. On NT, we could
# simply have done foo && bar && dog, but this doesn't port.
#
subproc: w32/subproc/WinDebug/subproc.lib w32/subproc/WinRel/subproc.lib
w32/subproc/WinDebug/subproc.lib w32/subproc/WinRel/subproc.lib: w32/subproc/misc.c w32/subproc/sub_proc.c w32/subproc/w32err.c
subproc.bat $(SUBPROC_MAKEFILE) $(MAKE)
if exist WinDebug\make.exe erase WinDebug\make.exe
if exist WinRel\make.exe erase WinRel\make.exe
config.h: config.h.W32
copy $? $@
Release:
$(MAKE) /f $(MAKEFILE) LDFLAGS="$(LDFLAGS_release)" CFLAGS="$(CFLAGS_release)" OUTDIR=WinRel WinRel/make.exe
Debug:
$(MAKE) /f $(MAKEFILE) LDFLAGS="$(LDFLAGS_debug)" CFLAGS="$(CFLAGS_debug)" OUTDIR=WinDebug WinDebug/make.exe
clean:
if exist WinDebug\nul rmdir /s /q WinDebug
if exist WinRel\nul rmdir /s /q WinRel
if exist w32\subproc\WinDebug\nul rmdir /s /q w32\subproc\WinDebug
if exist w32\subproc\WinRel\nul rmdir /s /q w32\subproc\WinRel
if exist config.h erase config.h
erase *.pdb
$(OUTDIR):
if not exist .\$@\nul mkdir .\$@
LIBS = kernel32.lib user32.lib advapi32.lib
OBJS = \
$(OUTDIR)/ar.obj \
$(OUTDIR)/arscan.obj \
$(OUTDIR)/commands.obj \
$(OUTDIR)/default.obj \
$(OUTDIR)/dir.obj \
$(OUTDIR)/expand.obj \
$(OUTDIR)/file.obj \
$(OUTDIR)/function.obj \
$(OUTDIR)/getloadavg.obj \
$(OUTDIR)/getopt.obj \
$(OUTDIR)/getopt1.obj \
$(OUTDIR)/implicit.obj \
$(OUTDIR)/job.obj \
$(OUTDIR)/main.obj \
$(OUTDIR)/misc.obj \
$(OUTDIR)/read.obj \
$(OUTDIR)/remake.obj \
$(OUTDIR)/remote-stub.obj \
$(OUTDIR)/rule.obj \
$(OUTDIR)/signame.obj \
$(OUTDIR)/variable.obj \
$(OUTDIR)/version.obj \
$(OUTDIR)/vpath.obj \
$(OUTDIR)/glob.obj \
$(OUTDIR)/fnmatch.obj \
$(OUTDIR)/dirent.obj \
$(OUTDIR)/pathstuff.obj
$(OUTDIR)/make.exe: $(OUTDIR) $(OBJS)
$(LINK) @<<
$(LDFLAGS) $(LIBS) $(OBJS)
<<
.c{$(OUTDIR)}.obj:
$(CC) $(CFLAGS) /c $<
$(OUTDIR)/glob.obj : glob/glob.c
$(CC) $(CFLAGS) /c $?
$(OUTDIR)/fnmatch.obj : glob/fnmatch.c
$(CC) $(CFLAGS) /c $?
$(OUTDIR)/dirent.obj : w32/compat/dirent.c
$(CC) $(CFLAGS) /c $?
$(OUTDIR)/pathstuff.obj : w32/pathstuff.c
$(CC) $(CFLAGS) /c $?

61
README.Amiga Normal file
View File

@@ -0,0 +1,61 @@
Short: Port of GNU make with SAS/C (no ixemul.library required)
Author: GNU, Amiga port by Aaron "Optimizer" Digulla
Uploader: Aaron "Optimizer" Digulla (digulla@fh-konstanz.de)
Type: dev/c
This is a pure Amiga port of GNU make. It needs no extra libraries or
anything. It has the following features (in addition to any features of
GNU make):
- Runs Amiga-Commands with SystemTags() (Execute)
- Can run multi-line statements
- Allows to use Device-Names in targets:
c:make : make.o
is ok. To distinguish between device-names and target : or ::, MAKE
looks for spaces. If there are any around :, it's taken as a target
delimiter, if there are none, it's taken as the name of a device. Note
that "make:make.o" tries to create "make.o" on the device "make:".
- Replaces @@ by a newline in any command line:
if exists make @@\
delete make.bak quiet @@\
rename make make.bak @@\
endif @@\
$(CC) Link Make.o To make
works. Note that the @@ must stand alone (ie. "make@@\" is illegal).
Also be carefull that there is a space after the "\" (ie, at the
beginning of the next line).
- Can be made resident to save space and time
- Amiga specific wildcards can be used in $(wildcard ...)
BUGS:
- The line
dummy.h : src/*.c
tries to make dummy.h from "src/*.c" (ie. no wildcard-expansion takes
place). You have to use "$(wildcard src/*.c)" instead.
COMPILING FROM SCRATCH
----------------------
To recompile, you need SAS/C 6.51. make itself is not neccessary, there
is an smakefile.
1. Copy config.ami to config.h
2. If you use make to compie, copy Makefile.ami to Makefile and
glob/Makefile.ami to glob/Makefile. Copy make into the current
directory.
3. Run smake/make
INSTALLATION
Copy make somewhere in your search path (eg. sc:c or sc:bin).
If you plan to use recursive makes, install make resident:
Resident make Add

323
README.DOS.template Normal file
View File

@@ -0,0 +1,323 @@
Port of GNU Make to 32-bit protected mode on MSDOS and MS-Windows.
Builds with DJGPP v2 port of GNU C/C++ compiler and utilities.
New (since 3.74) DOS-specific features:
1. Supports long filenames when run from DOS box on Windows 9x.
2. Supports both stock DOS COMMAND.COM and Unix-style shells
(details in ``Notes'' below).
3. Supports DOS drive letters in dependencies and pattern rules.
4. Better support for DOS-style backslashes in pathnames (but see
``Notes'' below).
5. The $(shell) built-in can run arbitrary complex commands,
including pipes and redirection, even when COMMAND.COM is your
shell.
6. Can be built without floating-point code (see below).
7. Supports signals in child programs and restores the original
directory if the child was interrupted.
8. Can be built without (a previous version of) Make.
9. The build process requires only standard tools. (Optional
targets like "install:" and "clean:" still need additional
programs, though, see below.)
10. Beginning with v3.78, the test suite works in the DJGPP
environment (requires Perl and auxiliary tools; see below).
To install a binary distribution:
Simply unzip the makNNNb.zip file (where NNN is the version number)
preserving the directory structure (-d switch if you use PKUNZIP).
If you are installing Make on Windows 9X or Windows 2000, use an
unzip program that supports long filenames in zip files. After
unzipping, make sure the directory with make.exe is on your PATH,
and that's all you need to use Make.
To build from sources:
1. Unzip the archive, preserving the directory structure (-d switch
if you use PKUNZIP). If you build Make on Windows 9X or Windows
2000, use an unzip program that supports long filenames in zip
files.
If you are unpacking an official GNU source distribution, use
either DJTAR (which is part of the DJGPP development
environment), or the DJGPP port of GNU Tar.
2. Invoke the `configure.bat' batch file.
If you are building Make in-place, i.e. in the same directory
where its sources are kept, just type "configure.bat" and press
[Enter]. Otherwise, you need to supply the path to the source
directory as an argument to the batch file, like this:
c:\djgpp\gnu\make-%VERSION%\configure.bat c:/djgpp/gnu/make-%VERSION%
Note the forward slashes in the source path argument: you MUST
use them here.
3. If configure.bat doesn't find a working Make, it will suggest to
use the `dosbuild.bat' batch file to build Make. Either do as it
suggests or install another Make program (a pre-compiled binary
should be available from the usual DJGPP sites) and rerun
configure.bat.
4. If you will need to run Make on machines without an FPU, you
might consider building a version of Make which doesn't issue
floating-point instructions (they don't help much on MSDOS
anyway). To this end, edit the Makefile created by
configure.bat and add -DNO_FLOAT to the value of CPPFLAGS.
5. Invoke Make.
If you are building from outside of the source directory, you
need to tell Make where the sources are, like this:
make srcdir=c:/djgpp/gnu/make-%VERSION%
(configure.bat will tell you this when it finishes). You MUST
use a full, not relative, name of the source directory here, or
else Make might fail.
6. After Make finishes, if you have a Unix-style shell installed,
you can use the `install' target to install the package. You
will also need GNU Fileutils and GNU Sed for this (they should
be available from the DJGPP sites).
By default, GNU make will install into your DJGPP installation
area. If you wish to use a different directory, override the
DESTDIR variable when invoking "make install", like this:
make install DESTDIR=c:/other/dir
This causes the make executable to be placed in c:/other/dir/bin,
the man pages in c:/other/dir/man, etc.
Without a Unix-style shell, you will have to install programs
and the docs manually. Copy make.exe to a directory on your
PATH, make.i* info files to your Info directory, and update the
file `dir' in your Info directory by adding the following item
to the main menu:
* Make: (make.info). The GNU make utility.
If you have the `install-info' program (from the GNU Texinfo
package), it will do that for you if you invoke it like this:
install-info --info-dir=c:/djgpp/info c:/djgpp/info/make.info
(If your Info directory is other than C:\DJGPP\INFO, change this
command accordingly.)
7. The `clean' targets also require Unix-style shell, and GNU Sed
and `rm' programs (the latter from Fileutils).
8. To run the test suite, type "make check". This requires a Unix
shell (I used the DJGPP port of Bash 2.03), Perl, Sed, Fileutils
and Sh-utils.
Notes:
-----
1. The shell issue.
This is probably the most significant improvement, first
introduced in the port of GNU Make 3.75.
The original behavior of GNU Make is to invoke commands
directly, as long as they don't include characters special to
the shell or internal shell commands, because that is faster.
When shell features like redirection or filename wildcards are
involved, Make calls the shell.
This port supports both DOS shells (the stock COMMAND.COM and its
4DOS/NDOS replacements), and Unix-style shells (tested with the
venerable Stewartson's `ms_sh' 2.3 and the DJGPP port of `bash' by
Daisuke Aoyama <jack@st.rim.or.jp>).
When the $SHELL variable points to a Unix-style shell, Make
works just like you'd expect on Unix, calling the shell for any
command that involves characters special to the shell or
internal shell commands. The only difference is that, since
there is no standard way to pass command lines longer than the
infamous DOS 126-character limit, this port of Make writes the
command line to a temporary disk file and then invokes the shell
on that file.
If $SHELL points to a DOS-style shell, however, Make will not
call it automatically, as it does with Unix shells. Stock
COMMAND.COM is too dumb and would unnecessarily limit the
functionality of Make. For example, you would not be able to
use long command lines in commands that use redirection or
pipes. Therefore, when presented with a DOS shell, this port of
Make will emulate most of the shell functionality, like
redirection and pipes, and shall only call the shell when a
batch file or a command internal to the shell is invoked. (Even
when a command is an internal shell command, Make will first
search the $PATH for it, so that if a Makefile calls `mkdir',
you can install, say, a port of GNU `mkdir' and have it called
in that case.)
The key to all this is the extended functionality of `spawn' and
`system' functions from the DJGPP library; this port just calls
`system' where it would invoke the shell on Unix. The most
important aspect of these functions is that they use a special
mechanism to pass long (up to 16KB) command lines to DJGPP
programs. In addition, `system' emulates some internal
commands, like `cd' (so that you can now use forward slashes
with it, and can also change the drive if the directory is on
another drive). Another aspect worth mentioning is that you can
call Unix shell scripts directly, provided that the shell whose
name is mentioned on the first line of the script is installed
anywhere along the $PATH. It is impossible to tell here
everything about these functions; refer to the DJGPP library
reference for more details.
The $(shell) built-in is implemented in this port by calling
`popen'. Since `popen' calls `system', the above considerations
are valid for $(shell) as well. In particular, you can put
arbitrary complex commands, including pipes and redirection,
inside $(shell), which is in many cases a valid substitute for
the Unix-style command substitution (`command`) feature.
2. "SHELL=/bin/sh" -- or is it?
Many Unix Makefiles include a line which sets the SHELL, for
those versions of Make which don't have this as the default.
Since many DOS systems don't have `sh' installed (in fact, most
of them don't even have a `/bin' directory), this port takes
such directives with a grain of salt. It will only honor such a
directive if the basename of the shell name (like `sh' in the
above example) can indeed be found in the directory that is
mentioned in the SHELL= line (`/bin' in the above example), or
in the current working directory, or anywhere on the $PATH (in
that order). If the basename doesn't include a filename
extension, Make will look for any known extension that indicates
an executable file (.exe, .com, .bat, .btm, .sh, and even .sed
and .pl). If any such file is found, then $SHELL will be
defined to the exact pathname of that file, and that shell will
hence be used for the rest of processing. But if the named
shell is *not* found, the line which sets it will be effectively
ignored, leaving the value of $SHELL as it was before. Since a
lot of decisions that this port makes depend on the gender of
the shell, I feel it doesn't make any sense to tailor Make's
behavior to a shell which is nowhere to be found.
Note that the above special handling of "SHELL=" only happens
for Makefiles; if you set $SHELL in the environment or on the
Make command line, you are expected to give the complete
pathname of the shell, including the filename extension.
The default value of $SHELL is computed as on Unix (see the Make
manual for details), except that if $SHELL is not defined in the
environment, $COMSPEC is used. Also, if an environment variable
named $MAKESHELL is defined, it takes precedence over both
$COMSPEC and $SHELL. Note that, unlike Unix, $SHELL in the
environment *is* used to set the shell (since on MSDOS, it's
unlikely that the interactive shell will not be suitable for
Makefile processing).
The bottom line is that you can now write Makefiles where some
of the targets require a real (i.e. Unix-like) shell, which will
nevertheless work when such shell is not available (provided, of
course, that the commands which should always work, don't
require such a shell). More important, you can convert Unix
Makefiles to MSDOS and leave the line which sets the shell
intact, so that people who do have Unixy shell could use it for
targets which aren't converted to DOS (like `install' and
`uninstall', for example).
3. Default directories.
GNU Make knows about standard directories where it searches for
library and include files mentioned in the Makefile. Since
MSDOS machines don't have standard places for these, this port
will search ${DJDIR}/lib and ${DJDIR}/include respectively.
$DJDIR is defined automatically by the DJGPP startup code as the
root of the DJGPP installation tree (unless you've tampered with
the DJGPP.ENV file). This should provide reasonable default
values, unless you moved parts of DJGPP to other directories.
4. Letter-case in filenames.
If you run Make on Windows 9x, you should be aware of the
letter-case issue. Make is internally case-sensitive, but all
file operations are case-insensitive on Windows 9x, so
e.g. files `FAQ', `faq' and `Faq' all refer to the same file, as
far as Windows is concerned. The underlying DJGPP C library
functions honor the letter-case of the filenames they get from
the OS, except that by default, they down-case 8+3 DOS filenames
which are stored in upper case in the directory and would break
many Makefiles otherwise. (The details of which filenames are
converted to lower case are explained in the DJGPP libc docs,
under the `_preserve_fncase' and `_lfn_gen_short_fname'
functions, but as a thumb rule, any filename that is stored in
upper case in the directory, is a valid DOS 8+3 filename and
doesn't include characters invalid on MSDOS FAT filesystems,
will be automatically down-cased.) User reports that I have
indicate that this default behavior is generally what you'd
expect; however, your input is most welcome.
In any case, if you hit a situation where you must force Make to
get the 8+3 DOS filenames in upper case, set FNCASE=y in the
environment or in the Makefile.
5. DOS-style pathnames.
There are a lot of places throughout the program sources which
make implicit assumptions about the pathname syntax. In
particular, the directories are assumed to be separated by `/',
and any pathname which doesn't begin with a `/' is assumed to be
relative to the current directory. This port attempts to
support DOS-style pathnames which might include the drive letter
and use backslashes instead of forward slashes. However, this
support is not complete; I feel that pursuing this support too
far might break some more important features, particularly if
you use a Unix-style shell (where a backslash is a quote
character). I only consider support of backslashes desirable
because some Makefiles invoke non-DJGPP programs which don't
understand forward slashes. A notable example of such programs
is the standard programs which come with MSDOS. Otherwise, you
are advised to stay away from backslashes whenever possible. In
particular, filename globbing won't work on pathnames with
backslashes, because the GNU `glob' library doesn't support them
(backslash is special in filename wildcards, and I didn't want
to break that).
One feature which *does* work with backslashes is the filename-
related built-in functions such as $(dir), $(notdir), etc.
Drive letters in pathnames are also fully supported.
Bug reports:
-----------
Bugs that are clearly related to the MSDOS/DJGPP port should be
reported first on the comp.os.msdos.djgpp news group (if you cannot
post to Usenet groups, write to the DJGPP mailing list,
<djgpp@delorie.com>, which is an email gateway into the above news
group). For other bugs, please follow the procedure explained in
the "Bugs" chapter of the Info docs. If you don't have an Info
reader, look up that chapter in the `make.i1' file with any text
browser/editor.
Enjoy,
Eli Zaretskii <eliz@is.elta.co.il>

241
README.W32.template Normal file
View File

@@ -0,0 +1,241 @@
Port of GNU make to Windows NT and Windows 95
Builds natively with MSVC 2.x or MSVC 4.x compilers.
Should also build fine with MSVC 5.x and 6.x (though not confirmed).
This Windows 32-bit port of GNU make is maintained primarily by Rob
Tulloh, who is also the author of this README.
To build with nmake on Windows NT, Windows 95, or Windows 98:
1. Make sure cl.exe is in your %Path%. Example:
set Path=%Path%;c:/msdev/bin
2. Make sure %include% is set to msvc include directory. Example:
set include=c:/msdev/include
3. Make sure %lib% is set to msvc lib directory. Example:
set lib=c:/msdev/lib
4. nmake /f NMakefile
A short cut to steps 1, 2, and 3 is to run VCVARS32.bat before
invoking namke. For example:
c:
cd \msdev\bin
VCVARS32.bat
cd \path\to\make-%VERSION%
nmake /f NMakefile
There is a bat file (build_w32.bat) for folks who have fear of nmake.
Outputs:
WinDebug/make.exe
WinRel/make.exe
-- Notes/Caveats --
GNU make on Windows 32-bit platforms:
This version of make is ported natively to Windows32 platforms
(Windows NT 3.51, Windows NT 4.0, Windows 95, and Windows 98). It
does not rely on any 3rd party software or add-on packages for
building. The only thing needed is a version of Visual C++,
which is the predominant compiler used on Windows32 platforms.
Do not confuse this port of GNU make with other Windows32 projects
which provide a GNU make binary. These are separate projects
and are not connected to this port effort.
GNU make and sh.exe:
This port prefers you have a working sh.exe somewhere on your
system. If you don't have sh.exe, the port falls back to
MSDOS mode for launching programs (via a batch file).
The MSDOS mode style execution has not been tested that
carefully though (The author uses GNU bash as sh.exe).
There are very few true ports of Bourne shell for NT right now.
There is a version of GNU bash available from Cygnus "Cygwin"
porting effort (http://sourceware.cygnus.com/cygwin).
Other possibilities are the MKS version of sh.exe, or building
your own with a package like NutCracker (DataFocus) or Portage
(Consensys).
GNU make and brain-dead shells (BATCH_MODE_ONLY_SHELL):
Some versions of Bourne shell does not behave well when invoked
as 'sh -c' from CreateProcess(). The main problem is they seem
to have a hard time handling quoted strings correctly. This can
be circumvented by writing commands to be executed to a batch
file and then executing the command by calling 'sh file'.
To work around this difficulty, this version of make supports
a batch mode. When BATCH_MODE_ONLY_SHELL is defined at compile
time, make forces all command lines to be executed via script
files instead of by command line.
A native Windows32 system with no Bourne shell will also run
in batch mode. All command lines will be put into batch files
and executed via $(COMSPEC) (%COMSPEC%).
GNU make and Cygnus GNU Windows32 tools:
Good news! Make now has native support for Cygwin sh. To enable,
define the HAVE_CYGWIN_SHELL in config.h and rebuild make
from scratch. This version of make tested with B20.1 of Cygwin.
Do not define BATCH_MODE_ONLY_SHELL if you use HAVE_CYGWIN_SHELL.
GNU make and the MKS shell:
There is now semi-official support for the MKS shell. To turn this
support on, define HAVE_MKS_SHELL in the config.h.W32 before you
build make. Do not define BATCH_MODE_ONLY_SHELL if you turn
on HAVE_MKS_SHELL.
GNU make handling of drive letters in pathnames (PATH, vpath, VPATH):
There is a caveat that should be noted with respect to handling
single character pathnames on Windows systems. When colon is
used in PATH variables, make tries to be smart about knowing when
you are using colon as a separator versus colon as a drive
letter. Unfortunately, something as simple as the string 'x:/'
could be interpreted 2 ways: (x and /) or (x:/).
Make chooses to interpret a letter plus colon (e.g. x:/) as a
drive letter pathname. If it is necessary to use single
character directories in paths (VPATH, vpath, Path, PATH), the
user must do one of two things:
a. Use semicolon as the separator to disambiguate colon. For
example use 'x;/' if you want to say 'x' and '/' are
separate components.
b. Qualify the directory name so that there is more than
one character in the path(s) used. For example, none
of these settings are ambiguous:
./x:./y
/some/path/x:/some/path/y
x:/some/path/x:x:/some/path/y
Please note that you are free to mix colon and semi-colon in the
specification of paths. Make is able to figure out the intended
result and convert the paths internally to the format needed
when interacting with the operating system.
You are encouraged to use colon as the separator character.
This should ease the pain of deciding how to handle various path
problems which exist between platforms. If colon is used on
both Unix and Windows systems, then no ifdef'ing will be
necessary in the makefile source.
GNU make test suite:
I verified all functionality with a slightly modified version
of make-test-%VERSION% (modifications to get test suite to run
on Windows NT). All tests pass in an environment that includes
sh.exe. Tests were performed on both Windows NT and Windows 95.
Building GNU make on Windows NT and Windows 95/98 with Microsoft Visual C:
I did not provide a Visual C project file with this port as
the project file would not be considered freely distributable
(or so I think). It is easy enough to create one, though, if
you know how to use Visual C.
I build the program statically to avoid problems locating DLL's
on machines that may not have MSVC runtime installed. If you
prefer, you can change make to build with shared libraries by
changing /MT to /MD in the NMakefile (or in build_w32.bat).
The program has not been built for non-Intel architectures (yet).
I have not tried to build with any other compilers than MSVC. I
have heard that this is possible though so don't be afraid to
notify me of your successes!
Pathnames and white space:
Unlike Unix, Windows 95/NT systems encourage pathnames which
contain white space (e.g. C:\Program Files\). These sorts of pathnames
are legal under Unix too, but are never encouraged. There is
at least one place in make (VPATH/vpath handling) where paths
containing white space will simply not work. There may be others
too. I chose to not try and port make in such a way so that
these sorts of paths could be handled. I offer these suggestions
as workarounds:
1. Use 8.3 notation
2. Rename the directory so it does not contain white space.
If you are unhappy with this choice, this is free software
and you are free to take a crack at making this work. The code
in w32/pathstuff.c and vpath.c would be the places to start.
Pathnames and Case insensitivity:
Unlike Unix, Windows 95/NT systems are case insensitive but case
preserving. For example if you tell the file system to create a
file named "Target", it will preserve the case. Subsequent access to
the file with other case permutations will succeed (i.e. opening a
file named "target" or "TARGET" will open the file "Target").
By default, GNU make retains its case sensitivity when comparing
target names and existing files or directories. It can be
configured, however, into a case preserving and case insensitive
mode by adding a define for HAVE_CASE_INSENSITIVE_FS to
config.h.W32.
For example, the following makefile will create a file named
Target in the directory subdir which will subsequently be used
to satisfy the dependency of SUBDIR/DepTarget on SubDir/TARGET.
Without HAVE_CASE_INSENSITIVE_FS configured, the dependency link
will not be made:
subdir/Target:
touch $@
SUBDIR/DepTarget: SubDir/TARGET
cp $^ $@
Reliance on this behavior also eliminates the ability of GNU make
to use case in comparison of matching rules. For example, it is
not possible to set up a C++ rule using %.C that is different
than a C rule using %.c. GNU make will consider these to be the
same rule and will issue a warning.
SAMBA/NTFS/VFAT:
I have not had any success building the debug version of this
package using SAMBA as my file server. The reason seems to be
related to the way VC++ 4.0 changes the case name of the pdb
filename it is passed on the command line. It seems to change
the name always to to lower case. I contend that
the VC++ compiler should not change the casename of files that
are passed as arguments on the command line. I don't think this
was a problem in MSVC 2.x, but I know it is a problem in MSVC 4.x.
The package builds fine on VFAT and NTFS filesystems.
Most all of the development I have done to date has been using
NTFS and long file names. I have not done any considerable work
under VFAT. VFAT users may wish to be aware that this port
of make does respect case sensitivity.
FAT:
Version 3.76 added support for FAT filesystems. Make
works around some difficulties with stat'ing of
files and caching of filenames and directories internally.
Bug reports:
Please submit bugs via the normal bug reporting mechanism which
is described in the GNU make manual and the base README.

95
README.customs Normal file
View File

@@ -0,0 +1,95 @@
-*-indented-text-*-
GNU make can utilize the Customs library, distributed with Pmake, to
provide builds distributed across multiple hosts.
In order to utilize this capability, you must first download and build
the Customs library. It is contained in the Pmake distribution, which
can be obtained at:
ftp://ftp.icsi.berkeley.edu/pub/ai/stolcke/software/
This integration was tested (superficially) with Pmake 2.1.33.
BUILDING CUSTOMS
----------------
First, build pmake and Customs. You need to build pmake first, because
Customs require pmake to build. Unfortunately, this is not trivial;
please see the pmake and Customs documentation for details. The best
place to look for instructions is in the pmake-2.1.33/INSTALL file.
Note that the 2.1.33 Pmake distribution comes with a set of patches to
GNU make, distributed in the pmake-2.1.33/etc/gnumake/ directory. These
patches are based on GNU make 3.75 (there are patches for earlier
versions of GNU make, also). The parts of this patchfile which relate
directly to Customs support have already been incorporated into this
version of GNU make, so you should _NOT_ apply the patch file.
However, there are a few non-Customs specific (as far as I could tell)
changes here which are not incorporated (for example, the modification
to try expanding -lfoo to libfoo.so). If you rely on these changes
you'll need to re-apply them by hand.
Install the Customs library and header files according to the
documentation. You should also install the man pages (contrary to
comments in the documentation, they weren't installed automatically for
me; I had to cd to the ``pmake-2.1.33/doc'' directory and run ``pmake
install'' there directly).
BUILDING GNU MAKE
-----------------
Once you've installed Customs, you can build GNU make to use it. When
configuring GNU make, merely use the ``--with-customs=DIR'' option.
Provide the directory containing the ``lib'' and ``include/customs''
subdirectories as DIR. For example, if you installed the customs
library in /usr/local/lib and the headers in /usr/local/include/customs,
then you'd pass ``--with-customs=/usr/local'' as an option to configure.
Run make (or use build.sh) normally to build GNU make as described in
the INSTALL file.
See the documentation for Customs for information on starting and
configuring Customs.
INVOKING CUSTOMS-IZED GNU MAKE
-----------------------------
One thing you should be aware of is that the default build environment
for Customs requires root permissions. Practically, this means that GNU
make must be installed setuid root to use Customs.
If you don't want to do this, you can build Customs such that root
permissions are not necessary. Andreas Stolcke <stolcke@speech.sri.com>
writes:
> pmake, gnumake or any other customs client program is not required to
> be suid root if customs was compiled WITHOUT the USE_RESERVED_PORTS
> option in customs/config.h. Make sure the "customs" service in
> /etc/services is defined accordingly (port 8231 instead of 1001).
> Not using USE_RESERVED_PORTS means that a user with programming
> skills could impersonate another user by writing a fake customs
> client that pretends to be someone other than himself. See the
> discussion in etc/SECURITY.
PROBLEMS
--------
SunOS 4.1.x:
The customs/sprite.h header file #includes the <malloc.h> header
files; this conflicts with GNU make's configuration so you'll get a
compile error if you use GCC (or any other ANSI-capable C compiler).
I commented out the #include in sprite.h:107:
#if defined(sun) || defined(ultrix) || defined(hpux) || defined(sgi)
/* #include <malloc.h> */
#else
YMMV.

141
README.cvs Normal file
View File

@@ -0,0 +1,141 @@
-*-text-*-
Obtaining CVS Code
------------------
This seems redundant, since if you're reading this you most likely have
already performed this step; however, for completeness, you can obtain
the GNU make source code via anonymous CVS from the FSF's Savannah
project <http://savannah.gnu.org/projects/make/>:
$ cvs -d:pserver:anoncvs@subversions.gnu.org:/cvsroot/make co make
You might want to use the "-z3" option to get compression, and you most
certainly will want the -P option to avoid unneeded directories
cluttering up your source. Personally I add these (as well as -dP for
update) to my ~/.cvsrc file.
If you have an older version of CVS, you might have to login first.
There is no password; just hit the ENTER key if you are asked for one.
Building From CVS
-----------------
To build GNU make from CVS, you will need Autoconf 2.53 (or better),
Automake 1.6.3 (or better), and Gettext 0.11.5 (or better), and any
tools that those utilities require (GNU m4, Perl, etc.). You will also
need a copy of wget.
After checking out the code, you will need to perform these steps to get
to the point where you can run "make".
1) $ autopoint
This will instantiate various m4 macros files, etc. in the config
and po directories.
2) $ aclocal -I config
Generate the proper aclocal.m4 file.
3) $ autoheader
Generate a "config.h.in" file from the contents of configure.in,
etc.
4) $ automake --add-missing
Add (symlink) missing files into the distribution, and generate
Makefile.in's from Makefile.am's.
You will see these perhaps unexpected messages (among others which
you should be expecting :)); just ignore them--I know what I'm doing
:).
Makefile.am: required file `./README' not found
configure.in:xxx: required file `./build.sh.in' not found
Makefile.am:xxx: automatically discovered file `getloadavg.c' should not be explicitly mentioned
5) $ autoconf
Generate a "configure" script from configure.in and acinclude.m4.
6) $ ./configure
Generate a Makefile
7) $ make update
Use wget to retrieve various other files that GNU make relies on,
but does not keep in its own source tree.
At this point you have successfully brought your CVS copy of the GNU
make source directory up to the point where it can be treated
more-or-less like the official package you would get from ftp.gnu.org.
That is, you can just run:
$ make && make check && make install
to build and install GNU make.
Creating a Package
------------------
Once you have performed the above steps (including the configuration and
build) you can create a GNU make package. This is very simple, just
run:
$ make dist-gzip
and, if you like:
$ make dist-bzip2
Even better, you should run this:
$ make distcheck
Which will build both .gz and .bz2 package files, then unpack them into
a temporary location, try to build them, and repack them, verifying that
everything works, you get the same results, _and_ no extraneous files
are left over after the "distclean" rule--whew!! Now, _that_ is why
converting to Automake is worth the trouble! A big "huzzah!" to Tom
T. and the AutoToolers!
That's it, you're done!
Appendix A - For The Brave
--------------------------
For those of you who trust me implicitly, or are just brave (or
foolhardy), here is a canned sequence of commands to build a GNU make
distribution package from a virgin CVS source checkout (assuming all the
prerequisites are available of course).
This list is eminently suitable for a quick swipe o' the mouse and a
swift click o' mouse-2 into an xterm. Go for it!
autopoint
aclocal -I config
autoheader
automake --add-missing
autoconf
./configure
make update
make
make check
make distcheck

164
README.template Normal file
View File

@@ -0,0 +1,164 @@
This directory contains the %VERSION% release of GNU Make.
See the file NEWS for the user-visible changes from previous releases.
In addition, there have been bugs fixed.
Please check the system-specific notes below for any caveats related to
your operating system.
For general building and installation instructions, see the file INSTALL.
If you need to build GNU Make and have no other `make' program to use,
you can use the shell script `build.sh' instead. To do this, first run
`configure' as described in INSTALL. Then, instead of typing `make' to
build the program, type `sh build.sh'. This should compile the program
in the current directory. Then you will have a Make program that you can
use for `./make install', or whatever else.
Some systems' Make programs are broken and cannot process the Makefile for
GNU Make. If you get errors from your system's Make when building GNU
Make, try using `build.sh' instead.
GNU Make is free software. See the file COPYING for copying conditions.
Downloading
-----------
GNU Make can be obtained in many different ways. See a description here:
http://www.gnu.org/software/software.html
Documentation
-------------
GNU make is fully documented in the GNU Make manual, which is contained
in this distribution as the file make.texinfo. You can also find
on-line and preformatted (PostScript and DVI) versions at the FSF's web
site. There is information there about ordering hardcopy documentation.
http://www.gnu.org/
http://www.gnu.org/doc/doc.html
http://www.gnu.org/manual/manual.html
Development
-----------
GNU Make development is hosted by Savannah, the FSF's online development
management tool. Savannah is here:
http://savannah.gnu.org
And the GNU Make development page is here:
http://savannah.gnu.org/projects/make/
You can find most information concerning the development of GNU Make at
this site.
Bug Reporting
-------------
You can send GNU make bug reports to <bug-make@gnu.org>. Please see the
section of the GNU make manual entitled `Problems and Bugs' for
information on submitting useful and complete bug reports.
You can also use the online bug tracking system in the Savannah GNU Make
project to submit new problem reports or search for existing ones:
http://savannah.gnu.org/bugs/?group_id=71
If you need help using GNU make, try these forums:
help-make@gnu.org
help-utils@gnu.org
news:gnu.utils.help
news:gnu.utils.bug
http://savannah.gnu.org/support/?group_id=71
You may also find interesting patches to GNU Make available here:
http://savannah.gnu.org/patch/?group_id=71
Note these patches are provided by our users as a service and we make no
statements regarding their correctness. Please contact the authors
directly if you have a problem or suggestion for a patch available on
this page.
CVS Access
----------
The GNU make source repository is available via anonymous CVS from the
GNU Subversions CVS server; look here for details:
http://savannah.gnu.org/cvs/?group_id=71
Please note: you won't be able to build GNU make from CVS without
installing appropriate maintainer's tools, such as GNU m4, automake,
autoconf, Perl, GNU make, and GCC. See the README.cvs file for hints on
how to build GNU make once these tools are available. We make no
guarantees about the contents or quality of the latest code in the CVS
repository: it is not unheard of for code that is known to be broken to
be checked in. Use at your own risk.
System-specific Notes
---------------------
It has been reported that the XLC 1.2 compiler on AIX 3.2 is buggy such
that if you compile make with `cc -O' on AIX 3.2, it will not work correctly.
It is said that using `cc' without `-O' does work.
One area that is often a problem in configuration and porting is the code
to check the system's current load average. To make it easier to test and
debug this code, you can do `make check-loadavg' to see if it works
properly on your system. (You must run `configure' beforehand, but you
need not build Make itself to run this test.)
Another potential source of porting problems is the support for large
files (LFS) in configure for those operating systems that provide it.
Please report any bugs that you find in this area. If you run into
difficulties, then as a workaround you should be able to disable LFS by
adding the `--disable-largefile' option to the `configure' script.
On systems that support micro- and nano-second timestamp values and
where stat(2) provides this information, GNU make will use it when
comparing timestamps to get the most accurate possible result. However,
note that many current implementations of tools that *set* timestamps do
not preserve micro- or nano-second granularity. This means that "cp -p"
and other similar tools (tar, etc.) may not exactly duplicate timestamps
with micro- and nano-second granularity on some systems. If your build
system contains rules that depend on proper behavior of tools like "cp
-p", you should consider using the .LOW_RESOLUTION_TIME pseudo-target to
force make to treat them properly. See the manual for details.
Ports
-----
- See README.customs for details on integrating GNU make with the
Customs distributed build environment from the Pmake distribution.
- See readme.vms for details about GNU Make on OpenVMS.
- See README.Amiga for details about GNU Make on AmigaDOS.
- See README.W32 for details about GNU Make on Windows NT, 95, or 98.
- See README.DOS for compilation instructions on MS-DOS and MS-Windows
using DJGPP tools.
A precompiled binary of the MSDOS port of GNU Make is available as part
of DJGPP; see the WWW page http://www.delorie.com/djgpp/ for more
information.
Please note there are two _separate_ ports of GNU make for Microsoft
systems: a native Windows tool built with (for example) MSVC or Cygwin,
and a DOS-based tool built with DJGPP. Please be sure you are looking
at the right README!

13
SCOPTIONS Normal file
View File

@@ -0,0 +1,13 @@
ERRORREXX
OPTIMIZE
NOVERSION
OPTIMIZERTIME
OPTIMIZERALIAS
DEFINE INCLUDEDIR="include:"
DEFINE LIBDIR="lib:"
DEFINE NO_ALLOCA
DEFINE NO_FLOAT
DEFINE NO_ARCHIVES
IGNORE=161
IGNORE=100
STARTUP=cres

213
SMakefile.template Normal file
View File

@@ -0,0 +1,213 @@
# NOTE: If you have no `make' program at all to process this makefile, run
# `build.sh' instead.
#
# Copyright (C) 1988, 89, 91, 92, 93, 94, 1995 Free Software Foundation, Inc.
# This file is part of GNU Make.
#
# GNU Make is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# GNU Make is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GNU Make; see the file COPYING. If not, write to
# the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
# Boston, MA 02111-1307, USA.
#
# Makefile for GNU Make
#
# Ultrix 2.2 make doesn't expand the value of VPATH.
VPATH = /make-%VERSION%/
# This must repeat the value, because configure will remove `VPATH = .'.
srcdir = /make-%VERSION%/
CC = sc
RM = delete
MAKE = smake
CFLAGS =
CPPFLAGS =
LDFLAGS =
# Define these for your system as follows:
# -DNO_ARCHIVES To disable `ar' archive support.
# -DNO_FLOAT To avoid using floating-point numbers.
# -DENUM_BITFIELDS If the compiler isn't GCC but groks enum foo:2.
# Some compilers apparently accept this
# without complaint but produce losing code,
# so beware.
# NeXT 1.0a uses an old version of GCC, which required -D__inline=inline.
# See also `config.h'.
defines =
# Which flavor of remote job execution support to use.
# The code is found in `remote-$(REMOTE).c'.
REMOTE = stub
# If you are using the GNU C library, or have the GNU getopt functions in
# your C library, you can comment these out.
GETOPT = getopt.o getopt1.o
GETOPT_SRC = $(srcdir)getopt.c $(srcdir)getopt1.c $(srcdir)getopt.h
# If you are using the GNU C library, or have the GNU glob functions in
# your C library, you can comment this out. GNU make uses special hooks
# into the glob functions to be more efficient (by using make's directory
# cache for globbing), so you must use the GNU functions even if your
# system's C library has the 1003.2 glob functions already. Also, the glob
# functions in the AIX and HPUX C libraries are said to be buggy.
GLOB = Lib glob/glob.lib
# If your system doesn't have alloca, or the one provided is bad, define this.
ALLOCA = alloca.o
ALLOCA_SRC = $(srcdir)alloca.c
# If your system needs extra libraries loaded in, define them here.
# System V probably need -lPW for alloca. HP-UX 7.0's alloca in
# libPW.a is broken on HP9000s300 and HP9000s400 machines. Use
# alloca.c instead on those machines.
LOADLIBES =
# Any extra object files your system needs.
extras = amiga.o
# Common prefix for machine-independent installed files.
prefix =
# Common prefix for machine-dependent installed files.
exec_prefix =
# Directory to install `make' in.
bindir = sc:c
# Directory to find libraries in for `-lXXX'.
libdir = lib:
# Directory to search by default for included makefiles.
includedir = include:
# Directory to install the Info files in.
infodir = doc:
# Directory to install the man page in.
mandir = t:
# Number to put on the man page filename.
manext = 1
# Prefix to put on installed `make' binary file name.
binprefix =
# Prefix to put on installed `make' man page file name.
manprefix = $(binprefix)
# Whether or not make needs to be installed setgid.
# The value should be either `true' or `false'.
# On many systems, the getloadavg function (used to implement the `-l'
# switch) will not work unless make is installed setgid kmem.
install_setgid = false
# Install make setgid to this group so it can read /dev/kmem.
group = sys
# Program to install `make'.
INSTALL_PROGRAM = copy
# Program to install the man page.
INSTALL_DATA = copy
# Generic install program.
INSTALL = copy
# Program to format Texinfo source into Info files.
MAKEINFO = makeinfo
# Program to format Texinfo source into DVI files.
TEXI2DVI = texi2dvi
# Programs to make tags files.
ETAGS = etags -w
CTAGS = ctags -w
objs = commands.o job.o dir.o file.o misc.o main.o read.o remake.o \
rule.o implicit.o default.o variable.o expand.o function.o \
vpath.o version.o ar.o arscan.o signame.o remote-$(REMOTE).o \
$(GLOB) $(GETOPT) $(ALLOCA) $(extras)
srcs = $(srcdir)commands.c $(srcdir)job.c $(srcdir)dir.c \
$(srcdir)file.c $(srcdir)getloadavg.c $(srcdir)misc.c \
$(srcdir)main.c $(srcdir)read.c $(srcdir)remake.c \
$(srcdir)rule.c $(srcdir)implicit.c $(srcdir)default.c \
$(srcdir)variable.c $(srcdir)expand.c $(srcdir)function.c \
$(srcdir)vpath.c $(srcdir)version.c \
$(srcdir)remote-$(REMOTE).c \
$(srcdir)ar.c $(srcdir)arscan.c \
$(srcdir)signame.c $(srcdir)signame.h $(GETOPT_SRC) \
$(srcdir)commands.h $(srcdir)dep.h $(srcdir)file.h \
$(srcdir)job.h $(srcdir)make.h $(srcdir)rule.h \
$(srcdir)variable.h $(ALLOCA_SRC) $(srcdir)config.h.in
.SUFFIXES:
.SUFFIXES: .o .c .h .ps .dvi .info .texinfo
all: make
info: make.info
dvi: make.dvi
# Some makes apparently use .PHONY as the default goal if it is before `all'.
.PHONY: all check info dvi
make.info: make.texinfo
$(MAKEINFO) -I$(srcdir) $(srcdir)make.texinfo -o make.info
make.dvi: make.texinfo
$(TEXI2DVI) $(srcdir)make.texinfo
make.ps: make.dvi
dvi2ps make.dvi > make.ps
make: $(objs) glob/glob.lib
$(CC) Link $(LDFLAGS) $(objs) $(LOADLIBES) To make.new
-delete quiet make
rename make.new make
# -I. is needed to find config.h in the build directory.
.c.o:
$(CC) $(defines) IDir "" IDir $(srcdir)glob \
$(CPPFLAGS) $(CFLAGS) $< $(OUTPUT_OPTION)
glob/glob.lib:
execute <<
cd glob
smake
<
tagsrcs = $(srcs) $(srcdir)remote-*.c
TAGS: $(tagsrcs)
$(ETAGS) $(tagsrcs)
tags: $(tagsrcs)
$(CTAGS) $(tagsrcs)
.PHONY: install installdirs
install:
copy make sc:c
loadavg: loadavg.c config.h
$(CC) $(defines) -DTEST -I. -I$(srcdir) $(CFLAGS) $(LDFLAGS) \
loadavg.c $(LOADLIBES) -o $@
clean: glob-clean
-$(RM) -f make loadavg *.o core make.dvi
distclean: clean glob-realclean
-$(RM) -f Makefile config.h config.status build.sh
-$(RM) -f config.log config.cache
-$(RM) -f TAGS tags
-$(RM) -f make.?? make.??s make.log make.toc make.*aux
-$(RM) -f loadavg.c
realclean: distclean
-$(RM) -f make.info*
mostlyclean: clean
.PHONY: glob-clean glob-realclean
glob-clean glob-realclean:
execute <<
cd glob
smake $@
<

140
TODO.private Normal file
View File

@@ -0,0 +1,140 @@
-*-Indented-Text-*-
GNU Make TODO List
------------------
This list comes both from the authors and from users of GNU make.
They are listed in no particular order!
Also, I don't gaurantee that all of them will be ultimately deemed "good
ideas" and implemented. These are just the ones that, at first blush,
seem to have some merit (and that I can remember).
However, if you see something here you really, really want, speak up.
All other things being equal, I will tend to implement things that seem
to maximize user satisfaction.
If you want to implement some of them yourself, barring the ones I've
marked below, have at it! Please contact me first to let me know you're
working on it, and give me some info about the design--and, critically,
information about any user-visible syntax change, etc.
The Top Item
------------
If you know perl (or want to learn DejaGNU or similar), the number one
priority on my list of things I don't have time to do right now is
fixing up the GNU make test suite. Most importantly it needs to be made
"parallelizable", so more than one regression can run at the same time
(essentially, make the "work" directory local). Also, the CWD during
the test should be in the work directory or, better, a test-specific
temporary directory so each test gets a new directory; right now
sometimes tests leak files into the main directory which causes
subsequent tests to fail (some tests may need to be tweaked). Beyond
that, any cleanup done to make writing, reading, or handling tests
simpler would be great! Please feel free to make whatever changes you
like to the current tests, given some high-level goals, and that you'll
port the current tests to whatever you do :).
The Rest of the List
--------------------
1) Allow variables/functions to expand to other make rules which are
then interpreted, with newlines handled correctly. This is a
biggee, and is on my plate. I already have partially-working code.
2) Option to check more than timestamps to determine if targets have
changed. This is also a very big one. It's _close_ to my plate :),
and I have very definite ideas about how I would like it done.
Please pick something else unless you must have this feature. If
you try it, please work _extremely_ closely with me on it.
2a) Possibly a special case of this is the .KEEP_STATE feature of Sun's
make. Some great folks at W U. in Canada did an implementation of
this for a class project. Their approach is reasonable and
workable, but doesn't really fit into my ideas for #2. Maybe
that's OK. I have paperwork for their work so if you want to do
this one talk to me to get what they've already done.
[K R Praveen <praveen@cair.res.in>]
3) Currently you can use "%.foo %.bar : %.baz" to mean that one
invocation of the rule builds both targets. GNU make needs a way to
do that for explicit rules, too. I heard a rumor that some versions
of make all you to say "a.foo + a.bar : a.baz" to do this (i.e., a
"+" means one invocation builds both). Don't know if this is the
best syntax or not... what if you say "a.foo + a.bar a.bam : a.baz";
what does that mean?
4) Multi-token pattern rule matching (allow %1/%2.c : %1/obj/%2.o,
etc., or something like that). I have an implementation of this
already, it just needs some refinement... maybe. Additionally I
think it only works for static pattern rules; it might need to be
fixed up to work with normal pattern rules, too.
5) More robust clock skew detection algorithm: less false hits. I have
some notes on this from various discussions.
6) Provide MAKETARGETS and MAKEVARIABLES variables, containing the
names of the targets and variables defined in the makefile.
Actually, I now think a $(targets ...) function, at least, would be
better than a MAKETARGETS variable. The argument would be types of
targets to list: "phony" is the most useful one. I suppose
"default" might also be useful. Maybe some others; check the
bitfields to see what might be handy. This one is pretty easy.
7) Some sort of operating-system independent way of handling paths
would be outstanding, so makefiles can be written for UNIX, VMS,
DOS, MS-Windows, Amiga, etc. with a minimum of specialization.
Or, perhaps related/instead of, some sort of meta-quoting syntax so
make can deal with filenames containing spaces, colons, etc. I
dunno, maybe something like $[...]? This may well not be worth
doing until #1 is done.
9) Right now the .PRECIOUS, .INTERMEDIATE, and .SECONDARY
pseudo-targets have different capabilities. For example, .PRECIOUS
can take a "%", the others can't. Etc. These should all work the
same, insofar as that makes sense.
10) A syntax that specifies a build order _without_ implying a
dependency relationship. That is, a way to say "A must be built
before B" that doesn't force B to be built when A changes. This is
very important for parallel builds: sometimes you need some stuff
done first but you don't want to rebuild everything because of it.
11) Improved debugging/logging/etc. capabilities. Part of this is done:
I introduced a number of debugging enhancements. Tim Magill is (I
think) looking into options to control output more selectively.
One thing I want to do in debugging is add a flag to allow debugging
of variables as they're expanded (!). This would be incredibly
verbose, but could be invaluable when nothing else seems to work and
you just can't figure it out. The way variables are expanded now
means this isn't 100% trivial, but it probably won't be hard.
12) Integration of Guile as an embedded scripting language. This means:
allowing Guile functions to be declared in makefiles somehow, then
providing a syntax for invoking them. At least one formulation of
that would have the function resolve to a string which would be
substituted in the makefile, kind of like $(shell ...) does now, but
using the embedded interpreter so there's no process forked of
course. Obviously this is an optional add-on feature.
It could be more advanced than that, even, who knows? Maybe make
could provide Guile functions that allow Guile scripts more direct
access to internal make structures, somehow. This kind of thing
needs a lot of thought.
Also there's always the flip side: in some very fundamental ways
make isn't the best choice right now for a complex build tool. It's
great for simple-to-medium tasks, but there are already other tools
available for the really tough situations. Ask yourself,
realistically, how much work is worthwhile to add to make, given the
fundamentals you can't really overcome without significantly
affecting backward compatibility--and then why not use another tool
in the first place?
Something to think about.

164
acinclude.m4 Normal file
View File

@@ -0,0 +1,164 @@
dnl acinclude.m4 -- Extra macros needed for GNU make.
dnl
dnl Automake will incorporate this into its generated aclocal.m4.
dnl ---------------------------------------------------------------------------
dnl Got this from the lynx 2.8 distribution.
dnl by T.E.Dickey <dickey@clark.net>
dnl and Jim Spath <jspath@mail.bcpl.lib.md.us>
dnl and Philippe De Muyter <phdm@macqel.be>
dnl
dnl Created: 1997/1/28
dnl Updated: 1997/12/23
dnl ---------------------------------------------------------------------------
dnl After checking for functions in the default $LIBS, make a further check
dnl for the functions that are netlib-related (these aren't always in the
dnl libc, etc., and have to be handled specially because there are conflicting
dnl and broken implementations.
dnl Common library requirements (in order):
dnl -lresolv -lsocket -lnsl
dnl -lnsl -lsocket
dnl -lsocket
dnl -lbsd
AC_DEFUN([CF_NETLIBS],[
cf_test_netlibs=no
AC_MSG_CHECKING(for network libraries)
AC_CACHE_VAL(cf_cv_netlibs,[
AC_MSG_RESULT(working...)
cf_cv_netlibs=""
cf_test_netlibs=yes
AC_CHECK_FUNCS(gethostname,,[
CF_RECHECK_FUNC(gethostname,nsl,cf_cv_netlibs,[
CF_RECHECK_FUNC(gethostname,socket,cf_cv_netlibs)])])
#
# FIXME: sequent needs this library (i.e., -lsocket -linet -lnsl), but
# I don't know the entrypoints - 97/7/22 TD
AC_CHECK_LIB(inet,main,cf_cv_netlibs="-linet $cf_cv_netlibs")
#
if test "$ac_cv_func_lsocket" != no ; then
AC_CHECK_FUNCS(socket,,[
CF_RECHECK_FUNC(socket,socket,cf_cv_netlibs,[
CF_RECHECK_FUNC(socket,bsd,cf_cv_netlibs)])])
fi
#
AC_CHECK_FUNCS(gethostbyname,,[
CF_RECHECK_FUNC(gethostbyname,nsl,cf_cv_netlibs)])
#
AC_CHECK_FUNCS(strcasecmp,,[
CF_RECHECK_FUNC(strcasecmp,resolv,cf_cv_netlibs)])
])
LIBS="$LIBS $cf_cv_netlibs"
test $cf_test_netlibs = no && echo "$cf_cv_netlibs" >&AC_FD_MSG
])dnl
dnl ---------------------------------------------------------------------------
dnl Re-check on a function to see if we can pick it up by adding a library.
dnl $1 = function to check
dnl $2 = library to check in
dnl $3 = environment to update (e.g., $LIBS)
dnl $4 = what to do if this fails
dnl
dnl This uses 'unset' if the shell happens to support it, but leaves the
dnl configuration variable set to 'unknown' if not. This is a little better
dnl than the normal autoconf test, which gives misleading results if a test
dnl for the function is made (e.g., with AC_CHECK_FUNC) after this macro is
dnl used (autoconf does not distinguish between a null token and one that is
dnl set to 'no').
AC_DEFUN([CF_RECHECK_FUNC],[
AC_CHECK_LIB($2,$1,[
CF_UPPER(cf_tr_func,$1)
AC_DEFINE_UNQUOTED(HAVE_$cf_tr_func,1,[Define if you have function $1])
ac_cv_func_$1=yes
$3="-l$2 [$]$3"],[
ac_cv_func_$1=unknown
unset ac_cv_func_$1 2>/dev/null
$4],
[[$]$3])
])dnl
dnl ---------------------------------------------------------------------------
dnl Make an uppercase version of a variable
dnl $1=uppercase($2)
AC_DEFUN([CF_UPPER],
[
changequote(,)dnl
$1=`echo $2 | tr '[a-z]' '[A-Z]'`
changequote([,])dnl
])dnl
dnl ---------------------------------------------------------------------------
dnl From Paul Eggert <eggert@twinsun.com>
AC_DEFUN(AC_STRUCT_ST_MTIM_NSEC,
[AC_CACHE_CHECK([for nanoseconds field of struct stat.st_mtim],
ac_cv_struct_st_mtim_nsec,
[ac_save_CPPFLAGS="$CPPFLAGS"
ac_cv_struct_st_mtim_nsec=no
# tv_nsec -- the usual case
# _tv_nsec -- Solaris 2.6, if
# (defined _XOPEN_SOURCE && _XOPEN_SOURCE_EXTENDED == 1
# && !defined __EXTENSIONS__)
# st__tim.tv_nsec -- UnixWare 2.1.2
for ac_val in tv_nsec _tv_nsec st__tim.tv_nsec; do
CPPFLAGS="$ac_save_CPPFLAGS -DST_MTIM_NSEC=$ac_val"
AC_TRY_COMPILE([#include <sys/types.h>
#include <sys/stat.h>], [struct stat s; s.st_mtim.ST_MTIM_NSEC;],
[ac_cv_struct_st_mtim_nsec=$ac_val; break])
done
CPPFLAGS="$ac_save_CPPFLAGS"])
if test $ac_cv_struct_st_mtim_nsec != no; then
AC_DEFINE_UNQUOTED(ST_MTIM_NSEC, $ac_cv_struct_st_mtim_nsec, [Define if 'struct stat' contains a nanoseconds field])
fi
]
)
dnl ---------------------------------------------------------------------------
dnl This will be in the next version of autoconf; take this out then!
# make_FUNC_SETVBUF_REVERSED
# ------------------------
AC_DEFUN([make_FUNC_SETVBUF_REVERSED],
[AC_REQUIRE([AC_C_PROTOTYPES])dnl
AC_CACHE_CHECK(whether setvbuf arguments are reversed,
ac_cv_func_setvbuf_reversed,
[ac_cv_func_setvbuf_reversed=no
AC_LINK_IFELSE(
[AC_LANG_PROGRAM(
[[#include <stdio.h>
# if PROTOTYPES
int (setvbuf) (FILE *, int, char *, size_t);
# endif]],
[[char buf; return setvbuf (stdout, _IOLBF, &buf, 1);]])],
[AC_LINK_IFELSE(
[AC_LANG_PROGRAM(
[[#include <stdio.h>
# if PROTOTYPES
int (setvbuf) (FILE *, int, char *, size_t);
# endif]],
[[char buf; return setvbuf (stdout, &buf, _IOLBF, 1);]])],
[# It compiles and links either way, so it must not be declared
# with a prototype and most likely this is a K&R C compiler.
# Try running it.
AC_RUN_IFELSE(
[AC_LANG_PROGRAM(
[[#include <stdio.h>]],
[[/* This call has the arguments reversed.
A reversed system may check and see that the address of buf
is not _IOLBF, _IONBF, or _IOFBF, and return nonzero. */
char buf;
if (setvbuf (stdout, _IOLBF, &buf, 1) != 0)
exit (1);
putchar ('\r');
exit (0); /* Non-reversed systems SEGV here. */]])],
ac_cv_func_setvbuf_reversed=yes,
rm -f core core.* *.core,
[[: # Assume setvbuf is not reversed when cross-compiling.]])]
ac_cv_func_setvbuf_reversed=yes)])])
if test $ac_cv_func_setvbuf_reversed = yes; then
AC_DEFINE(SETVBUF_REVERSED, 1,
[Define to 1 if the `setvbuf' function takes the buffering type as
its second argument and the buffer pointer as the third, as on
System V before release 3.])
fi
])# make_FUNC_SETVBUF_REVERSED

504
alloca.c Normal file
View File

@@ -0,0 +1,504 @@
/* alloca.c -- allocate automatically reclaimed memory
(Mostly) portable public-domain implementation -- D A Gwyn
This implementation of the PWB library alloca function,
which is used to allocate space off the run-time stack so
that it is automatically reclaimed upon procedure exit,
was inspired by discussions with J. Q. Johnson of Cornell.
J.Otto Tennant <jot@cray.com> contributed the Cray support.
There are some preprocessor constants that can
be defined when compiling for your specific system, for
improved efficiency; however, the defaults should be okay.
The general concept of this implementation is to keep
track of all alloca-allocated blocks, and reclaim any
that are found to be deeper in the stack than the current
invocation. This heuristic does not reclaim storage as
soon as it becomes invalid, but it will do so eventually.
As a special case, alloca(0) reclaims storage without
allocating any. It is a good idea to use alloca(0) in
your main control loop, etc. to force garbage collection. */
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#ifdef HAVE_STRING_H
#include <string.h>
#endif
#ifdef HAVE_STDLIB_H
#include <stdlib.h>
#endif
#ifdef emacs
#include "blockinput.h"
#endif
/* If compiling with GCC 2, this file's not needed. */
#if !defined (__GNUC__) || __GNUC__ < 2
/* If someone has defined alloca as a macro,
there must be some other way alloca is supposed to work. */
#ifndef alloca
#ifdef emacs
#ifdef static
/* actually, only want this if static is defined as ""
-- this is for usg, in which emacs must undefine static
in order to make unexec workable
*/
#ifndef STACK_DIRECTION
you
lose
-- must know STACK_DIRECTION at compile-time
#endif /* STACK_DIRECTION undefined */
#endif /* static */
#endif /* emacs */
/* If your stack is a linked list of frames, you have to
provide an "address metric" ADDRESS_FUNCTION macro. */
#if defined (CRAY) && defined (CRAY_STACKSEG_END)
long i00afunc ();
#define ADDRESS_FUNCTION(arg) (char *) i00afunc (&(arg))
#else
#define ADDRESS_FUNCTION(arg) &(arg)
#endif
#if __STDC__
typedef void *pointer;
#else
typedef char *pointer;
#endif
#ifndef NULL
#define NULL 0
#endif
/* Different portions of Emacs need to call different versions of
malloc. The Emacs executable needs alloca to call xmalloc, because
ordinary malloc isn't protected from input signals. On the other
hand, the utilities in lib-src need alloca to call malloc; some of
them are very simple, and don't have an xmalloc routine.
Non-Emacs programs expect this to call use xmalloc.
Callers below should use malloc. */
#ifndef emacs
#define malloc xmalloc
#endif
extern pointer malloc ();
/* Define STACK_DIRECTION if you know the direction of stack
growth for your system; otherwise it will be automatically
deduced at run-time.
STACK_DIRECTION > 0 => grows toward higher addresses
STACK_DIRECTION < 0 => grows toward lower addresses
STACK_DIRECTION = 0 => direction of growth unknown */
#ifndef STACK_DIRECTION
#define STACK_DIRECTION 0 /* Direction unknown. */
#endif
#if STACK_DIRECTION != 0
#define STACK_DIR STACK_DIRECTION /* Known at compile-time. */
#else /* STACK_DIRECTION == 0; need run-time code. */
static int stack_dir; /* 1 or -1 once known. */
#define STACK_DIR stack_dir
static void
find_stack_direction ()
{
static char *addr = NULL; /* Address of first `dummy', once known. */
auto char dummy; /* To get stack address. */
if (addr == NULL)
{ /* Initial entry. */
addr = ADDRESS_FUNCTION (dummy);
find_stack_direction (); /* Recurse once. */
}
else
{
/* Second entry. */
if (ADDRESS_FUNCTION (dummy) > addr)
stack_dir = 1; /* Stack grew upward. */
else
stack_dir = -1; /* Stack grew downward. */
}
}
#endif /* STACK_DIRECTION == 0 */
/* An "alloca header" is used to:
(a) chain together all alloca'ed blocks;
(b) keep track of stack depth.
It is very important that sizeof(header) agree with malloc
alignment chunk size. The following default should work okay. */
#ifndef ALIGN_SIZE
#define ALIGN_SIZE sizeof(double)
#endif
typedef union hdr
{
char align[ALIGN_SIZE]; /* To force sizeof(header). */
struct
{
union hdr *next; /* For chaining headers. */
char *deep; /* For stack depth measure. */
} h;
} header;
static header *last_alloca_header = NULL; /* -> last alloca header. */
/* Return a pointer to at least SIZE bytes of storage,
which will be automatically reclaimed upon exit from
the procedure that called alloca. Originally, this space
was supposed to be taken from the current stack frame of the
caller, but that method cannot be made to work for some
implementations of C, for example under Gould's UTX/32. */
pointer
alloca (size)
unsigned size;
{
auto char probe; /* Probes stack depth: */
register char *depth = ADDRESS_FUNCTION (probe);
#if STACK_DIRECTION == 0
if (STACK_DIR == 0) /* Unknown growth direction. */
find_stack_direction ();
#endif
/* Reclaim garbage, defined as all alloca'd storage that
was allocated from deeper in the stack than currently. */
{
register header *hp; /* Traverses linked list. */
#ifdef emacs
BLOCK_INPUT;
#endif
for (hp = last_alloca_header; hp != NULL;)
if ((STACK_DIR > 0 && hp->h.deep > depth)
|| (STACK_DIR < 0 && hp->h.deep < depth))
{
register header *np = hp->h.next;
free ((pointer) hp); /* Collect garbage. */
hp = np; /* -> next header. */
}
else
break; /* Rest are not deeper. */
last_alloca_header = hp; /* -> last valid storage. */
#ifdef emacs
UNBLOCK_INPUT;
#endif
}
if (size == 0)
return NULL; /* No allocation required. */
/* Allocate combined header + user data storage. */
{
register pointer new = malloc (sizeof (header) + size);
/* Address of header. */
if (new == 0)
abort();
((header *) new)->h.next = last_alloca_header;
((header *) new)->h.deep = depth;
last_alloca_header = (header *) new;
/* User storage begins just after header. */
return (pointer) ((char *) new + sizeof (header));
}
}
#if defined (CRAY) && defined (CRAY_STACKSEG_END)
#ifdef DEBUG_I00AFUNC
#include <stdio.h>
#endif
#ifndef CRAY_STACK
#define CRAY_STACK
#ifndef CRAY2
/* Stack structures for CRAY-1, CRAY X-MP, and CRAY Y-MP */
struct stack_control_header
{
long shgrow:32; /* Number of times stack has grown. */
long shaseg:32; /* Size of increments to stack. */
long shhwm:32; /* High water mark of stack. */
long shsize:32; /* Current size of stack (all segments). */
};
/* The stack segment linkage control information occurs at
the high-address end of a stack segment. (The stack
grows from low addresses to high addresses.) The initial
part of the stack segment linkage control information is
0200 (octal) words. This provides for register storage
for the routine which overflows the stack. */
struct stack_segment_linkage
{
long ss[0200]; /* 0200 overflow words. */
long sssize:32; /* Number of words in this segment. */
long ssbase:32; /* Offset to stack base. */
long:32;
long sspseg:32; /* Offset to linkage control of previous
segment of stack. */
long:32;
long sstcpt:32; /* Pointer to task common address block. */
long sscsnm; /* Private control structure number for
microtasking. */
long ssusr1; /* Reserved for user. */
long ssusr2; /* Reserved for user. */
long sstpid; /* Process ID for pid based multi-tasking. */
long ssgvup; /* Pointer to multitasking thread giveup. */
long sscray[7]; /* Reserved for Cray Research. */
long ssa0;
long ssa1;
long ssa2;
long ssa3;
long ssa4;
long ssa5;
long ssa6;
long ssa7;
long sss0;
long sss1;
long sss2;
long sss3;
long sss4;
long sss5;
long sss6;
long sss7;
};
#else /* CRAY2 */
/* The following structure defines the vector of words
returned by the STKSTAT library routine. */
struct stk_stat
{
long now; /* Current total stack size. */
long maxc; /* Amount of contiguous space which would
be required to satisfy the maximum
stack demand to date. */
long high_water; /* Stack high-water mark. */
long overflows; /* Number of stack overflow ($STKOFEN) calls. */
long hits; /* Number of internal buffer hits. */
long extends; /* Number of block extensions. */
long stko_mallocs; /* Block allocations by $STKOFEN. */
long underflows; /* Number of stack underflow calls ($STKRETN). */
long stko_free; /* Number of deallocations by $STKRETN. */
long stkm_free; /* Number of deallocations by $STKMRET. */
long segments; /* Current number of stack segments. */
long maxs; /* Maximum number of stack segments so far. */
long pad_size; /* Stack pad size. */
long current_address; /* Current stack segment address. */
long current_size; /* Current stack segment size. This
number is actually corrupted by STKSTAT to
include the fifteen word trailer area. */
long initial_address; /* Address of initial segment. */
long initial_size; /* Size of initial segment. */
};
/* The following structure describes the data structure which trails
any stack segment. I think that the description in 'asdef' is
out of date. I only describe the parts that I am sure about. */
struct stk_trailer
{
long this_address; /* Address of this block. */
long this_size; /* Size of this block (does not include
this trailer). */
long unknown2;
long unknown3;
long link; /* Address of trailer block of previous
segment. */
long unknown5;
long unknown6;
long unknown7;
long unknown8;
long unknown9;
long unknown10;
long unknown11;
long unknown12;
long unknown13;
long unknown14;
};
#endif /* CRAY2 */
#endif /* not CRAY_STACK */
#ifdef CRAY2
/* Determine a "stack measure" for an arbitrary ADDRESS.
I doubt that "lint" will like this much. */
static long
i00afunc (long *address)
{
struct stk_stat status;
struct stk_trailer *trailer;
long *block, size;
long result = 0;
/* We want to iterate through all of the segments. The first
step is to get the stack status structure. We could do this
more quickly and more directly, perhaps, by referencing the
$LM00 common block, but I know that this works. */
STKSTAT (&status);
/* Set up the iteration. */
trailer = (struct stk_trailer *) (status.current_address
+ status.current_size
- 15);
/* There must be at least one stack segment. Therefore it is
a fatal error if "trailer" is null. */
if (trailer == 0)
abort ();
/* Discard segments that do not contain our argument address. */
while (trailer != 0)
{
block = (long *) trailer->this_address;
size = trailer->this_size;
if (block == 0 || size == 0)
abort ();
trailer = (struct stk_trailer *) trailer->link;
if ((block <= address) && (address < (block + size)))
break;
}
/* Set the result to the offset in this segment and add the sizes
of all predecessor segments. */
result = address - block;
if (trailer == 0)
{
return result;
}
do
{
if (trailer->this_size <= 0)
abort ();
result += trailer->this_size;
trailer = (struct stk_trailer *) trailer->link;
}
while (trailer != 0);
/* We are done. Note that if you present a bogus address (one
not in any segment), you will get a different number back, formed
from subtracting the address of the first block. This is probably
not what you want. */
return (result);
}
#else /* not CRAY2 */
/* Stack address function for a CRAY-1, CRAY X-MP, or CRAY Y-MP.
Determine the number of the cell within the stack,
given the address of the cell. The purpose of this
routine is to linearize, in some sense, stack addresses
for alloca. */
static long
i00afunc (long address)
{
long stkl = 0;
long size, pseg, this_segment, stack;
long result = 0;
struct stack_segment_linkage *ssptr;
/* Register B67 contains the address of the end of the
current stack segment. If you (as a subprogram) store
your registers on the stack and find that you are past
the contents of B67, you have overflowed the segment.
B67 also points to the stack segment linkage control
area, which is what we are really interested in. */
stkl = CRAY_STACKSEG_END ();
ssptr = (struct stack_segment_linkage *) stkl;
/* If one subtracts 'size' from the end of the segment,
one has the address of the first word of the segment.
If this is not the first segment, 'pseg' will be
nonzero. */
pseg = ssptr->sspseg;
size = ssptr->sssize;
this_segment = stkl - size;
/* It is possible that calling this routine itself caused
a stack overflow. Discard stack segments which do not
contain the target address. */
while (!(this_segment <= address && address <= stkl))
{
#ifdef DEBUG_I00AFUNC
fprintf (stderr, "%011o %011o %011o\n", this_segment, address, stkl);
#endif
if (pseg == 0)
break;
stkl = stkl - pseg;
ssptr = (struct stack_segment_linkage *) stkl;
size = ssptr->sssize;
pseg = ssptr->sspseg;
this_segment = stkl - size;
}
result = address - this_segment;
/* If you subtract pseg from the current end of the stack,
you get the address of the previous stack segment's end.
This seems a little convoluted to me, but I'll bet you save
a cycle somewhere. */
while (pseg != 0)
{
#ifdef DEBUG_I00AFUNC
fprintf (stderr, "%011o %011o\n", pseg, size);
#endif
stkl = stkl - pseg;
ssptr = (struct stack_segment_linkage *) stkl;
size = ssptr->sssize;
pseg = ssptr->sspseg;
result += size;
}
return (result);
}
#endif /* not CRAY2 */
#endif /* CRAY */
#endif /* no alloca */
#endif /* not GCC version 2 */

123
amiga.c Normal file
View File

@@ -0,0 +1,123 @@
/* Running commands on Amiga
Copyright (C) 1995, 1996 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
MA 02111-1307, USA. */
#include "make.h"
#include "variable.h"
#include "amiga.h"
#include <assert.h>
#include <exec/memory.h>
#include <dos/dostags.h>
#include <proto/exec.h>
#include <proto/dos.h>
static const char Amiga_version[] = "$VER: Make 3.74.3 (12.05.96) \n"
"Amiga Port by A. Digulla (digulla@home.lake.de)";
int
MyExecute (argv)
char ** argv;
{
char * buffer, * ptr;
char ** aptr;
int len = 0;
int status;
for (aptr=argv; *aptr; aptr++)
{
len += strlen (*aptr) + 4;
}
buffer = AllocMem (len, MEMF_ANY);
if (!buffer)
fatal (NILF, "MyExecute: Cannot allocate space for calling a command");
ptr = buffer;
for (aptr=argv; *aptr; aptr++)
{
if (((*aptr)[0] == ';' && !(*aptr)[1]))
{
*ptr ++ = '"';
strcpy (ptr, *aptr);
ptr += strlen (ptr);
*ptr ++ = '"';
}
else if ((*aptr)[0] == '@' && (*aptr)[1] == '@' && !(*aptr)[2])
{
*ptr ++ = '\n';
continue;
}
else
{
strcpy (ptr, *aptr);
ptr += strlen (ptr);
}
*ptr ++ = ' ';
*ptr = 0;
}
ptr[-1] = '\n';
status = SystemTags (buffer,
SYS_UserShell, TRUE,
TAG_END);
FreeMem (buffer, len);
if (SetSignal(0L,0L) & SIGBREAKF_CTRL_C)
status = 20;
/* Warnings don't count */
if (status == 5)
status = 0;
return status;
}
char *
wildcard_expansion (wc, o)
char * wc, * o;
{
# define PATH_SIZE 1024
struct AnchorPath * apath;
if ( (apath = AllocMem (sizeof (struct AnchorPath) + PATH_SIZE,
MEMF_CLEAR))
)
{
apath->ap_Strlen = PATH_SIZE;
if (MatchFirst (wc, apath) == 0)
{
do
{
o = variable_buffer_output (o, apath->ap_Buf,
strlen (apath->ap_Buf));
o = variable_buffer_output (o, " ",1);
} while (MatchNext (apath) == 0);
}
MatchEnd (apath);
FreeMem (apath, sizeof (struct AnchorPath) + PATH_SIZE);
}
return o;
}

22
amiga.h Normal file
View File

@@ -0,0 +1,22 @@
/* Definitions for amiga specific things
Copyright (C) 1995, 1996 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
MA 02111-1307, USA. */
extern int MyExecute PARAMS ((char ** argv));
extern char * wildcard_expansion PARAMS ((char * wc, char * o));

329
ar.c Normal file
View File

@@ -0,0 +1,329 @@
/* Interface to `ar' archives for GNU Make.
Copyright (C) 1988, 1989, 1990, 1991, 1992, 1993, 1997,
2002 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "make.h"
#ifndef NO_ARCHIVES
#include "filedef.h"
#include "dep.h"
#include <fnmatch.h>
/* Defined in arscan.c. */
extern long int ar_scan PARAMS ((char *archive, long int (*function) (), long int arg));
extern int ar_name_equal PARAMS ((char *name, char *mem, int truncated));
#ifndef VMS
extern int ar_member_touch PARAMS ((char *arname, char *memname));
#endif
/* Return nonzero if NAME is an archive-member reference, zero if not.
An archive-member reference is a name like `lib(member)'.
If a name like `lib((entry))' is used, a fatal error is signaled at
the attempt to use this unsupported feature. */
int
ar_name (name)
char *name;
{
char *p = strchr (name, '(');
char *end;
if (p == 0 || p == name)
return 0;
end = p + strlen (p) - 1;
if (*end != ')')
return 0;
if (p[1] == '(' && end[-1] == ')')
fatal (NILF, _("attempt to use unsupported feature: `%s'"), name);
return 1;
}
/* Parse the archive-member reference NAME into the archive and member names.
Put the malloc'd archive name in *ARNAME_P if ARNAME_P is non-nil;
put the malloc'd member name in *MEMNAME_P if MEMNAME_P is non-nil. */
void
ar_parse_name (name, arname_p, memname_p)
char *name, **arname_p, **memname_p;
{
char *p = strchr (name, '('), *end = name + strlen (name) - 1;
if (arname_p != 0)
*arname_p = savestring (name, p - name);
if (memname_p != 0)
*memname_p = savestring (p + 1, end - (p + 1));
}
static long int ar_member_date_1 PARAMS ((int desc, char *mem, int truncated, long int hdrpos,
long int datapos, long int size, long int date, int uid, int gid, int mode, char *name));
/* Return the modtime of NAME. */
time_t
ar_member_date (name)
char *name;
{
char *arname;
int arname_used = 0;
char *memname;
long int val;
ar_parse_name (name, &arname, &memname);
/* Make sure we know the modtime of the archive itself because we are
likely to be called just before commands to remake a member are run,
and they will change the archive itself.
But we must be careful not to enter_file the archive itself if it does
not exist, because pattern_search assumes that files found in the data
base exist or can be made. */
{
struct file *arfile;
arfile = lookup_file (arname);
if (arfile == 0 && file_exists_p (arname))
{
arfile = enter_file (arname);
arname_used = 1;
}
if (arfile != 0)
(void) f_mtime (arfile, 0);
}
val = ar_scan (arname, ar_member_date_1, (long int) memname);
if (!arname_used)
free (arname);
free (memname);
return (val <= 0 ? (time_t) -1 : (time_t) val);
}
/* This function is called by `ar_scan' to find which member to look at. */
/* ARGSUSED */
static long int
ar_member_date_1 (desc, mem, truncated,
hdrpos, datapos, size, date, uid, gid, mode, name)
int desc;
char *mem;
int truncated;
long int hdrpos, datapos, size, date;
int uid, gid, mode;
char *name;
{
return ar_name_equal (name, mem, truncated) ? date : 0;
}
/* Set the archive-member NAME's modtime to now. */
#ifdef VMS
int
ar_touch (name)
char *name;
{
error (NILF, _("touch archive member is not available on VMS"));
return -1;
}
#else
int
ar_touch (name)
char *name;
{
char *arname, *memname;
int arname_used = 0;
register int val;
ar_parse_name (name, &arname, &memname);
/* Make sure we know the modtime of the archive itself before we
touch the member, since this will change the archive itself. */
{
struct file *arfile;
arfile = lookup_file (arname);
if (arfile == 0)
{
arfile = enter_file (arname);
arname_used = 1;
}
(void) f_mtime (arfile, 0);
}
val = 1;
switch (ar_member_touch (arname, memname))
{
case -1:
error (NILF, _("touch: Archive `%s' does not exist"), arname);
break;
case -2:
error (NILF, _("touch: `%s' is not a valid archive"), arname);
break;
case -3:
perror_with_name ("touch: ", arname);
break;
case 1:
error (NILF,
_("touch: Member `%s' does not exist in `%s'"), memname, arname);
break;
case 0:
val = 0;
break;
default:
error (NILF,
_("touch: Bad return code from ar_member_touch on `%s'"), name);
}
if (!arname_used)
free (arname);
free (memname);
return val;
}
#endif /* !VMS */
/* State of an `ar_glob' run, passed to `ar_glob_match'. */
struct ar_glob_state
{
char *arname;
char *pattern;
unsigned int size;
struct nameseq *chain;
unsigned int n;
};
/* This function is called by `ar_scan' to match one archive
element against the pattern in STATE. */
static long int
ar_glob_match (desc, mem, truncated,
hdrpos, datapos, size, date, uid, gid, mode,
state)
int desc;
char *mem;
int truncated;
long int hdrpos, datapos, size, date;
int uid, gid, mode;
struct ar_glob_state *state;
{
if (fnmatch (state->pattern, mem, FNM_PATHNAME|FNM_PERIOD) == 0)
{
/* We have a match. Add it to the chain. */
struct nameseq *new = (struct nameseq *) xmalloc (state->size);
new->name = concat (state->arname, mem, ")");
new->next = state->chain;
state->chain = new;
++state->n;
}
return 0L;
}
/* Return nonzero if PATTERN contains any metacharacters.
Metacharacters can be quoted with backslashes if QUOTE is nonzero. */
static int
glob_pattern_p (pattern, quote)
const char *pattern;
const int quote;
{
register const char *p;
int open = 0;
for (p = pattern; *p != '\0'; ++p)
switch (*p)
{
case '?':
case '*':
return 1;
case '\\':
if (quote)
++p;
break;
case '[':
open = 1;
break;
case ']':
if (open)
return 1;
break;
}
return 0;
}
/* Glob for MEMBER_PATTERN in archive ARNAME.
Return a malloc'd chain of matching elements (or nil if none). */
struct nameseq *
ar_glob (arname, member_pattern, size)
char *arname, *member_pattern;
unsigned int size;
{
struct ar_glob_state state;
char **names;
struct nameseq *n;
unsigned int i;
if (! glob_pattern_p (member_pattern, 1))
return 0;
/* Scan the archive for matches.
ar_glob_match will accumulate them in STATE.chain. */
i = strlen (arname);
state.arname = (char *) alloca (i + 2);
bcopy (arname, state.arname, i);
state.arname[i] = '(';
state.arname[i + 1] = '\0';
state.pattern = member_pattern;
state.size = size;
state.chain = 0;
state.n = 0;
(void) ar_scan (arname, ar_glob_match, (long int) &state);
if (state.chain == 0)
return 0;
/* Now put the names into a vector for sorting. */
names = (char **) alloca (state.n * sizeof (char *));
i = 0;
for (n = state.chain; n != 0; n = n->next)
names[i++] = n->name;
/* Sort them alphabetically. */
qsort ((char *) names, i, sizeof (*names), alpha_compare);
/* Put them back into the chain in the sorted order. */
i = 0;
for (n = state.chain; n != 0; n = n->next)
n->name = names[i++];
return state.chain;
}
#endif /* Not NO_ARCHIVES. */

861
arscan.c Normal file
View File

@@ -0,0 +1,861 @@
/* Library function for scanning an archive file.
Copyright (C) 1987,89,91,92,93,94,95,97 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
USA. */
#include "make.h"
#ifdef HAVE_FCNTL_H
#include <fcntl.h>
#else
#include <sys/file.h>
#endif
#ifndef NO_ARCHIVES
#ifdef VMS
#include <lbrdef.h>
#include <mhddef.h>
#include <credef.h>
#include <descrip.h>
#include <ctype.h>
#if __DECC
#include <unixlib.h>
#include <lbr$routines.h>
#endif
static void *VMS_lib_idx;
static char *VMS_saved_memname;
static time_t VMS_member_date;
static long int (*VMS_function) ();
static int
VMS_get_member_info (module, rfa)
struct dsc$descriptor_s *module;
unsigned long *rfa;
{
int status, i;
long int fnval;
time_t val;
static struct dsc$descriptor_s bufdesc =
{ 0, DSC$K_DTYPE_T, DSC$K_CLASS_S, NULL };
struct mhddef *mhd;
char filename[128];
bufdesc.dsc$a_pointer = filename;
bufdesc.dsc$w_length = sizeof (filename);
status = lbr$set_module (&VMS_lib_idx, rfa, &bufdesc,
&bufdesc.dsc$w_length, 0);
if (! (status & 1))
{
error (NILF, _("lbr$set_module failed to extract module info, status = %d"),
status);
lbr$close (&VMS_lib_idx);
return 0;
}
mhd = (struct mhddef *) filename;
#ifdef __DECC
/* John Fowler <jfowler@nyx.net> writes this is needed in his environment,
* but that decc$fix_time() isn't documented to work this way. Let me
* know if this causes problems in other VMS environments.
*/
val = decc$fix_time (&mhd->mhd$l_datim) + timezone - daylight*3600;
#endif
for (i = 0; i < module->dsc$w_length; i++)
filename[i] = _tolower ((unsigned char)module->dsc$a_pointer[i]);
filename[i] = '\0';
VMS_member_date = (time_t) -1;
fnval =
(*VMS_function) (-1, filename, 0, 0, 0, 0, val, 0, 0, 0,
VMS_saved_memname);
if (fnval)
{
VMS_member_date = fnval;
return 0;
}
else
return 1;
}
/* Takes three arguments ARCHIVE, FUNCTION and ARG.
Open the archive named ARCHIVE, find its members one by one,
and for each one call FUNCTION with the following arguments:
archive file descriptor for reading the data,
member name,
member name might be truncated flag,
member header position in file,
member data position in file,
member data size,
member date,
member uid,
member gid,
member protection mode,
ARG.
NOTE: on VMS systems, only name, date, and arg are meaningful!
The descriptor is poised to read the data of the member
when FUNCTION is called. It does not matter how much
data FUNCTION reads.
If FUNCTION returns nonzero, we immediately return
what FUNCTION returned.
Returns -1 if archive does not exist,
Returns -2 if archive has invalid format.
Returns 0 if have scanned successfully. */
long int
ar_scan (archive, function, arg)
char *archive;
long int (*function) ();
long int arg;
{
char *p;
static struct dsc$descriptor_s libdesc =
{ 0, DSC$K_DTYPE_T, DSC$K_CLASS_S, NULL };
unsigned long func = LBR$C_READ;
unsigned long type = LBR$C_TYP_UNK;
unsigned long index = 1;
int status;
status = lbr$ini_control (&VMS_lib_idx, &func, &type, 0);
if (! (status & 1))
{
error (NILF, _("lbr$ini_control failed with status = %d"),status);
return -2;
}
libdesc.dsc$a_pointer = archive;
libdesc.dsc$w_length = strlen (archive);
status = lbr$open (&VMS_lib_idx, &libdesc, 0, 0, 0, 0, 0);
if (! (status & 1))
{
error (NILF, _("unable to open library `%s' to lookup member `%s'"),
archive, (char *)arg);
return -1;
}
VMS_saved_memname = (char *)arg;
/* For comparison, delete .obj from arg name. */
p = strrchr (VMS_saved_memname, '.');
if (p)
*p = '\0';
VMS_function = function;
VMS_member_date = (time_t) -1;
lbr$get_index (&VMS_lib_idx, &index, VMS_get_member_info, 0);
/* Undo the damage. */
if (p)
*p = '.';
lbr$close (&VMS_lib_idx);
return VMS_member_date > 0 ? VMS_member_date : 0;
}
#else /* !VMS */
/* SCO Unix's compiler defines both of these. */
#ifdef M_UNIX
#undef M_XENIX
#endif
/* On the sun386i and in System V rel 3, ar.h defines two different archive
formats depending upon whether you have defined PORTAR (normal) or PORT5AR
(System V Release 1). There is no default, one or the other must be defined
to have a nonzero value. */
#if (!defined (PORTAR) || PORTAR == 0) && (!defined (PORT5AR) || PORT5AR == 0)
#undef PORTAR
#ifdef M_XENIX
/* According to Jim Sievert <jas1@rsvl.unisys.com>, for SCO XENIX defining
PORTAR to 1 gets the wrong archive format, and defining it to 0 gets the
right one. */
#define PORTAR 0
#else
#define PORTAR 1
#endif
#endif
/* On AIX, define these symbols to be sure to get both archive formats.
AIX 4.3 introduced the "big" archive format to support 64-bit object
files, so on AIX 4.3 systems we need to support both the "normal" and
"big" archive formats. An archive's format is indicated in the
"fl_magic" field of the "FL_HDR" structure. For a normal archive,
this field will be the string defined by the AIAMAG symbol. For a
"big" archive, it will be the string defined by the AIAMAGBIG symbol
(at least on AIX it works this way).
Note: we'll define these symbols regardless of which AIX version
we're compiling on, but this is okay since we'll use the new symbols
only if they're present. */
#ifdef _AIX
# define __AR_SMALL__
# define __AR_BIG__
#endif
#ifndef WINDOWS32
# ifndef __BEOS__
# include <ar.h>
# else
/* BeOS 5 doesn't have <ar.h> but has archives in the same format
* as many other Unices. This was taken from GNU binutils for BeOS.
*/
# define ARMAG "!<arch>\n" /* String that begins an archive file. */
# define SARMAG 8 /* Size of that string. */
# define ARFMAG "`\n" /* String in ar_fmag at end of each header. */
struct ar_hdr
{
char ar_name[16]; /* Member file name, sometimes / terminated. */
char ar_date[12]; /* File date, decimal seconds since Epoch. */
char ar_uid[6], ar_gid[6]; /* User and group IDs, in ASCII decimal. */
char ar_mode[8]; /* File mode, in ASCII octal. */
char ar_size[10]; /* File size, in ASCII decimal. */
char ar_fmag[2]; /* Always contains ARFMAG. */
};
# endif
#else
/* These should allow us to read Windows (VC++) libraries (according to Frank
* Libbrecht <frankl@abzx.belgium.hp.com>)
*/
# include <windows.h>
# include <windef.h>
# include <io.h>
# define ARMAG IMAGE_ARCHIVE_START
# define SARMAG IMAGE_ARCHIVE_START_SIZE
# define ar_hdr _IMAGE_ARCHIVE_MEMBER_HEADER
# define ar_name Name
# define ar_mode Mode
# define ar_size Size
# define ar_date Date
# define ar_uid UserID
# define ar_gid GroupID
#endif
/* Cray's <ar.h> apparently defines this. */
#ifndef AR_HDR_SIZE
# define AR_HDR_SIZE (sizeof (struct ar_hdr))
#endif
/* Takes three arguments ARCHIVE, FUNCTION and ARG.
Open the archive named ARCHIVE, find its members one by one,
and for each one call FUNCTION with the following arguments:
archive file descriptor for reading the data,
member name,
member name might be truncated flag,
member header position in file,
member data position in file,
member data size,
member date,
member uid,
member gid,
member protection mode,
ARG.
The descriptor is poised to read the data of the member
when FUNCTION is called. It does not matter how much
data FUNCTION reads.
If FUNCTION returns nonzero, we immediately return
what FUNCTION returned.
Returns -1 if archive does not exist,
Returns -2 if archive has invalid format.
Returns 0 if have scanned successfully. */
long int
ar_scan (archive, function, arg)
char *archive;
long int (*function) ();
long int arg;
{
#ifdef AIAMAG
FL_HDR fl_header;
#ifdef AIAMAGBIG
int big_archive = 0;
FL_HDR_BIG fl_header_big;
#endif
#else
int long_name = 0;
#endif
char *namemap = 0;
register int desc = open (archive, O_RDONLY, 0);
if (desc < 0)
return -1;
#ifdef SARMAG
{
char buf[SARMAG];
register int nread = read (desc, buf, SARMAG);
if (nread != SARMAG || bcmp (buf, ARMAG, SARMAG))
{
(void) close (desc);
return -2;
}
}
#else
#ifdef AIAMAG
{
register int nread = read (desc, (char *) &fl_header, FL_HSZ);
if (nread != FL_HSZ)
{
(void) close (desc);
return -2;
}
#ifdef AIAMAGBIG
/* If this is a "big" archive, then set the flag and
re-read the header into the "big" structure. */
if (!bcmp (fl_header.fl_magic, AIAMAGBIG, SAIAMAG))
{
big_archive = 1;
/* seek back to beginning of archive */
if (lseek (desc, 0, 0) < 0)
{
(void) close (desc);
return -2;
}
/* re-read the header into the "big" structure */
nread = read (desc, (char *) &fl_header_big, FL_HSZ_BIG);
if (nread != FL_HSZ_BIG)
{
(void) close (desc);
return -2;
}
}
else
#endif
/* Check to make sure this is a "normal" archive. */
if (bcmp (fl_header.fl_magic, AIAMAG, SAIAMAG))
{
(void) close (desc);
return -2;
}
}
#else
{
#ifndef M_XENIX
int buf;
#else
unsigned short int buf;
#endif
register int nread = read(desc, &buf, sizeof (buf));
if (nread != sizeof (buf) || buf != ARMAG)
{
(void) close (desc);
return -2;
}
}
#endif
#endif
/* Now find the members one by one. */
{
#ifdef SARMAG
register long int member_offset = SARMAG;
#else
#ifdef AIAMAG
long int member_offset;
long int last_member_offset;
#ifdef AIAMAGBIG
if ( big_archive )
{
sscanf (fl_header_big.fl_fstmoff, "%20ld", &member_offset);
sscanf (fl_header_big.fl_lstmoff, "%20ld", &last_member_offset);
}
else
#endif
{
sscanf (fl_header.fl_fstmoff, "%12ld", &member_offset);
sscanf (fl_header.fl_lstmoff, "%12ld", &last_member_offset);
}
if (member_offset == 0)
{
/* Empty archive. */
close (desc);
return 0;
}
#else
#ifndef M_XENIX
register long int member_offset = sizeof (int);
#else /* Xenix. */
register long int member_offset = sizeof (unsigned short int);
#endif /* Not Xenix. */
#endif
#endif
while (1)
{
register int nread;
struct ar_hdr member_header;
#ifdef AIAMAGBIG
struct ar_hdr_big member_header_big;
#endif
#ifdef AIAMAG
char name[256];
int name_len;
long int dateval;
int uidval, gidval;
long int data_offset;
#else
char namebuf[sizeof member_header.ar_name + 1];
char *name;
int is_namemap; /* Nonzero if this entry maps long names. */
#endif
long int eltsize;
int eltmode;
long int fnval;
if (lseek (desc, member_offset, 0) < 0)
{
(void) close (desc);
return -2;
}
#ifdef AIAMAG
#define AR_MEMHDR_SZ(x) (sizeof(x) - sizeof (x._ar_name))
#ifdef AIAMAGBIG
if (big_archive)
{
nread = read (desc, (char *) &member_header_big,
AR_MEMHDR_SZ(member_header_big) );
if (nread != AR_MEMHDR_SZ(member_header_big))
{
(void) close (desc);
return -2;
}
sscanf (member_header_big.ar_namlen, "%4d", &name_len);
nread = read (desc, name, name_len);
if (nread != name_len)
{
(void) close (desc);
return -2;
}
name[name_len] = 0;
sscanf (member_header_big.ar_date, "%12ld", &dateval);
sscanf (member_header_big.ar_uid, "%12d", &uidval);
sscanf (member_header_big.ar_gid, "%12d", &gidval);
sscanf (member_header_big.ar_mode, "%12o", &eltmode);
sscanf (member_header_big.ar_size, "%20ld", &eltsize);
data_offset = (member_offset + AR_MEMHDR_SZ(member_header_big)
+ name_len + 2);
}
else
#endif
{
nread = read (desc, (char *) &member_header,
AR_MEMHDR_SZ(member_header) );
if (nread != AR_MEMHDR_SZ(member_header))
{
(void) close (desc);
return -2;
}
sscanf (member_header.ar_namlen, "%4d", &name_len);
nread = read (desc, name, name_len);
if (nread != name_len)
{
(void) close (desc);
return -2;
}
name[name_len] = 0;
sscanf (member_header.ar_date, "%12ld", &dateval);
sscanf (member_header.ar_uid, "%12d", &uidval);
sscanf (member_header.ar_gid, "%12d", &gidval);
sscanf (member_header.ar_mode, "%12o", &eltmode);
sscanf (member_header.ar_size, "%12ld", &eltsize);
data_offset = (member_offset + AR_MEMHDR_SZ(member_header)
+ name_len + 2);
}
data_offset += data_offset % 2;
fnval =
(*function) (desc, name, 0,
member_offset, data_offset, eltsize,
dateval, uidval, gidval,
eltmode, arg);
#else /* Not AIAMAG. */
nread = read (desc, (char *) &member_header, AR_HDR_SIZE);
if (nread == 0)
/* No data left means end of file; that is OK. */
break;
if (nread != AR_HDR_SIZE
#if defined(ARFMAG) || defined(ARFZMAG)
|| (
# ifdef ARFMAG
bcmp (member_header.ar_fmag, ARFMAG, 2)
# else
1
# endif
&&
# ifdef ARFZMAG
bcmp (member_header.ar_fmag, ARFZMAG, 2)
# else
1
# endif
)
#endif
)
{
(void) close (desc);
return -2;
}
name = namebuf;
bcopy (member_header.ar_name, name, sizeof member_header.ar_name);
{
register char *p = name + sizeof member_header.ar_name;
do
*p = '\0';
while (p > name && *--p == ' ');
#ifndef AIAMAG
/* If the member name is "//" or "ARFILENAMES/" this may be
a list of file name mappings. The maximum file name
length supported by the standard archive format is 14
characters. This member will actually always be the
first or second entry in the archive, but we don't check
that. */
is_namemap = (!strcmp (name, "//")
|| !strcmp (name, "ARFILENAMES/"));
#endif /* Not AIAMAG. */
/* On some systems, there is a slash after each member name. */
if (*p == '/')
*p = '\0';
#ifndef AIAMAG
/* If the member name starts with a space or a slash, this
is an index into the file name mappings (used by GNU ar).
Otherwise if the member name looks like #1/NUMBER the
real member name appears in the element data (used by
4.4BSD). */
if (! is_namemap
&& (name[0] == ' ' || name[0] == '/')
&& namemap != 0)
{
name = namemap + atoi (name + 1);
long_name = 1;
}
else if (name[0] == '#'
&& name[1] == '1'
&& name[2] == '/')
{
int namesize = atoi (name + 3);
name = (char *) alloca (namesize + 1);
nread = read (desc, name, namesize);
if (nread != namesize)
{
close (desc);
return -2;
}
name[namesize] = '\0';
long_name = 1;
}
#endif /* Not AIAMAG. */
}
#ifndef M_XENIX
sscanf (member_header.ar_mode, "%o", &eltmode);
eltsize = atol (member_header.ar_size);
#else /* Xenix. */
eltmode = (unsigned short int) member_header.ar_mode;
eltsize = member_header.ar_size;
#endif /* Not Xenix. */
fnval =
(*function) (desc, name, ! long_name, member_offset,
member_offset + AR_HDR_SIZE, eltsize,
#ifndef M_XENIX
atol (member_header.ar_date),
atoi (member_header.ar_uid),
atoi (member_header.ar_gid),
#else /* Xenix. */
member_header.ar_date,
member_header.ar_uid,
member_header.ar_gid,
#endif /* Not Xenix. */
eltmode, arg);
#endif /* AIAMAG. */
if (fnval)
{
(void) close (desc);
return fnval;
}
#ifdef AIAMAG
if (member_offset == last_member_offset)
/* End of the chain. */
break;
#ifdef AIAMAGBIG
if (big_archive)
sscanf (member_header_big.ar_nxtmem, "%20ld", &member_offset);
else
#endif
sscanf (member_header.ar_nxtmem, "%12ld", &member_offset);
if (lseek (desc, member_offset, 0) != member_offset)
{
(void) close (desc);
return -2;
}
#else
/* If this member maps archive names, we must read it in. The
name map will always precede any members whose names must
be mapped. */
if (is_namemap)
{
char *clear;
char *limit;
namemap = (char *) alloca (eltsize);
nread = read (desc, namemap, eltsize);
if (nread != eltsize)
{
(void) close (desc);
return -2;
}
/* The names are separated by newlines. Some formats have
a trailing slash. Null terminate the strings for
convenience. */
limit = namemap + eltsize;
for (clear = namemap; clear < limit; clear++)
{
if (*clear == '\n')
{
*clear = '\0';
if (clear[-1] == '/')
clear[-1] = '\0';
}
}
is_namemap = 0;
}
member_offset += AR_HDR_SIZE + eltsize;
if (member_offset % 2 != 0)
member_offset++;
#endif
}
}
close (desc);
return 0;
}
#endif /* !VMS */
/* Return nonzero iff NAME matches MEM.
If TRUNCATED is nonzero, MEM may be truncated to
sizeof (struct ar_hdr.ar_name) - 1. */
int
ar_name_equal (name, mem, truncated)
char *name, *mem;
int truncated;
{
char *p;
p = strrchr (name, '/');
if (p != 0)
name = p + 1;
#ifndef VMS
if (truncated)
{
#ifdef AIAMAG
/* TRUNCATED should never be set on this system. */
abort ();
#else
struct ar_hdr hdr;
#if !defined (__hpux) && !defined (cray)
return strneq (name, mem, sizeof(hdr.ar_name) - 1);
#else
return strneq (name, mem, sizeof(hdr.ar_name) - 2);
#endif /* !__hpux && !cray */
#endif /* !AIAMAG */
}
#endif /* !VMS */
return !strcmp (name, mem);
}
#ifndef VMS
/* ARGSUSED */
static long int
ar_member_pos (desc, mem, truncated,
hdrpos, datapos, size, date, uid, gid, mode, name)
int desc;
char *mem;
int truncated;
long int hdrpos, datapos, size, date;
int uid, gid, mode;
char *name;
{
if (!ar_name_equal (name, mem, truncated))
return 0;
return hdrpos;
}
/* Set date of member MEMNAME in archive ARNAME to current time.
Returns 0 if successful,
-1 if file ARNAME does not exist,
-2 if not a valid archive,
-3 if other random system call error (including file read-only),
1 if valid but member MEMNAME does not exist. */
int
ar_member_touch (arname, memname)
char *arname, *memname;
{
register long int pos = ar_scan (arname, ar_member_pos, (long int) memname);
register int fd;
struct ar_hdr ar_hdr;
register int i;
struct stat statbuf;
if (pos < 0)
return (int) pos;
if (!pos)
return 1;
fd = open (arname, O_RDWR, 0666);
if (fd < 0)
return -3;
/* Read in this member's header */
if (lseek (fd, pos, 0) < 0)
goto lose;
if (AR_HDR_SIZE != read (fd, (char *) &ar_hdr, AR_HDR_SIZE))
goto lose;
/* Write back the header, thus touching the archive file. */
if (lseek (fd, pos, 0) < 0)
goto lose;
if (AR_HDR_SIZE != write (fd, (char *) &ar_hdr, AR_HDR_SIZE))
goto lose;
/* The file's mtime is the time we we want. */
if (fstat (fd, &statbuf) < 0)
goto lose;
#if defined(ARFMAG) || defined(ARFZMAG) || defined(AIAMAG) || defined(WINDOWS32)
/* Advance member's time to that time */
for (i = 0; i < sizeof ar_hdr.ar_date; i++)
ar_hdr.ar_date[i] = ' ';
sprintf (ar_hdr.ar_date, "%ld", (long int) statbuf.st_mtime);
#ifdef AIAMAG
ar_hdr.ar_date[strlen(ar_hdr.ar_date)] = ' ';
#endif
#else
ar_hdr.ar_date = statbuf.st_mtime;
#endif
/* Write back this member's header */
if (lseek (fd, pos, 0) < 0)
goto lose;
if (AR_HDR_SIZE != write (fd, (char *) &ar_hdr, AR_HDR_SIZE))
goto lose;
close (fd);
return 0;
lose:
i = errno;
close (fd);
errno = i;
return -3;
}
#endif
#ifdef TEST
long int
describe_member (desc, name, truncated,
hdrpos, datapos, size, date, uid, gid, mode)
int desc;
char *name;
int truncated;
long int hdrpos, datapos, size, date;
int uid, gid, mode;
{
extern char *ctime ();
printf (_("Member `%s'%s: %ld bytes at %ld (%ld).\n"),
name, truncated ? _(" (name might be truncated)") : "",
size, hdrpos, datapos);
printf (_(" Date %s"), ctime (&date));
printf (_(" uid = %d, gid = %d, mode = 0%o.\n"), uid, gid, mode);
return 0;
}
main (argc, argv)
int argc;
char **argv;
{
ar_scan (argv[1], describe_member);
return 0;
}
#endif /* TEST. */
#endif /* NO_ARCHIVES. */

80
build.template Normal file
View File

@@ -0,0 +1,80 @@
#!/bin/sh
# Shell script to build GNU Make in the absence of any `make' program.
# @configure_input@
# Copyright (C) 1993, 1994, 1997 Free Software Foundation, Inc.
# This file is part of GNU Make.
#
# GNU Make is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# GNU Make is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GNU Make; see the file COPYING. If not, write to
# the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
# Boston, MA 02111-1307, USA.
# See Makefile.in for comments describing these variables.
srcdir='@srcdir@'
CC='@CC@'
CFLAGS='@CFLAGS@'
CPPFLAGS='@CPPFLAGS@'
LDFLAGS='@LDFLAGS@'
ALLOCA='@ALLOCA@'
LOADLIBES='@LIBS@'
extras='@LIBOBJS@'
REMOTE='@REMOTE@'
GLOBLIB='@GLOBLIB@'
# Common prefix for machine-independent installed files.
prefix='@prefix@'
# Common prefix for machine-dependent installed files.
exec_prefix=`eval echo @exec_prefix@`
# Directory to find libraries in for `-lXXX'.
libdir=${exec_prefix}/lib
# Directory to search by default for included makefiles.
includedir=${prefix}/include
localedir=${prefix}/share/locale
aliaspath=${localedir}:.
defines="-DALIASPATH=\"${aliaspath}\" -DLOCALEDIR=\"${localedir}\" -DLIBDIR=\"${libdir}\" -DINCLUDEDIR=\"${includedir}\""' @DEFS@'
# Exit as soon as any command fails.
set -e
# These are all the objects we need to link together.
objs="%objs% remote-${REMOTE}.o ${extras} ${ALLOCA}"
if [ x"$GLOBLIB" != x ]; then
objs="$objs %globobjs%"
globinc=-I${srcdir}/glob
fi
# Compile the source files into those objects.
for file in `echo ${objs} | sed 's/\.o/.c/g'`; do
echo compiling ${file}...
$CC $defines $CPPFLAGS $CFLAGS \
-c -I. -I${srcdir} ${globinc} ${srcdir}/$file
done
# The object files were actually all put in the current directory.
# Remove the source directory names from the list.
srcobjs="$objs"
objs=
for obj in $srcobjs; do
objs="$objs `basename $obj`"
done
# Link all the objects together.
echo linking make...
$CC $LDFLAGS $objs $LOADLIBES -o make.new
echo done
mv -f make.new make

138
build_w32.bat Normal file
View File

@@ -0,0 +1,138 @@
set make=gnumake
+if not exist config.h copy config.h.W32 config.h
cd w32\subproc
echo "Creating the subproc library"
%ComSpec% /c build.bat
cd ..\..
del link.dbg link.rel
del config.h
copy config.h.W32 config.h
echo off
echo "Creating GNU make for Windows 95/NT"
echo on
if not exist .\WinDebug\nul mkdir .\WinDebug
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D TIVOLI /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c variable.c
echo WinDebug\variable.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c rule.c
echo WinDebug\rule.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c remote-stub.c
echo WinDebug\remote-stub.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c commands.c
echo WinDebug\commands.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c file.c
echo WinDebug\file.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c getloadavg.c
echo WinDebug\getloadavg.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c default.c
echo WinDebug\default.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c signame.c
echo WinDebug\signame.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c expand.c
echo WinDebug\expand.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c dir.c
echo WinDebug\dir.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c main.c
echo WinDebug\main.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c getopt1.c
echo WinDebug\getopt1.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c job.c
echo WinDebug\job.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c read.c
echo WinDebug\read.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c version.c
echo WinDebug\version.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c getopt.c
echo WinDebug\getopt.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c arscan.c
echo WinDebug\arscan.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c remake.c
echo WinDebug\remake.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c misc.c
echo WinDebug\misc.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c ar.c
echo WinDebug\ar.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c function.c
echo WinDebug\function.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c vpath.c
echo WinDebug\vpath.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c implicit.c
echo WinDebug\implicit.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c .\w32\compat\dirent.c
echo WinDebug\dirent.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c .\glob\glob.c
echo WinDebug\glob.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c .\glob\fnmatch.c
echo WinDebug\fnmatch.obj >>link.dbg
cl.exe /nologo /MT /W3 /GX /Zi /YX /Od /I . /I glob /I w32/include /D _DEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinDebug/ /Fp.\WinDebug/%make%.pch /Fo.\WinDebug/ /Fd.\WinDebug/%make%.pdb /c .\w32\pathstuff.c
echo WinDebug\pathstuff.obj >>link.dbg
echo off
echo "Linking WinDebug/%make%.exe"
rem link.exe kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib w32\subproc\windebug\subproc.lib /NOLOGO /SUBSYSTEM:console /INCREMENTAL:yes /PDB:.\WinDebug/%make%.pdb /DEBUG /MACHINE:I386 /OUT:.\WinDebug/%make%.exe .\WinDebug/variable.obj .\WinDebug/rule.obj .\WinDebug/remote-stub.obj .\WinDebug/commands.obj .\WinDebug/file.obj .\WinDebug/getloadavg.obj .\WinDebug/default.obj .\WinDebug/signame.obj .\WinDebug/expand.obj .\WinDebug/dir.obj .\WinDebug/main.obj .\WinDebug/getopt1.obj .\WinDebug/job.obj .\WinDebug/read.obj .\WinDebug/version.obj .\WinDebug/getopt.obj .\WinDebug/arscan.obj .\WinDebug/remake.obj .\WinDebug/misc.obj .\WinDebug/ar.obj .\WinDebug/function.obj .\WinDebug/vpath.obj .\WinDebug/implicit.obj .\WinDebug/dirent.obj .\WinDebug/glob.obj .\WinDebug/fnmatch.obj .\WinDebug/pathstuff.obj
echo kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib w32\subproc\windebug\subproc.lib >>link.dbg
link.exe /NOLOGO /SUBSYSTEM:console /INCREMENTAL:yes /PDB:.\WinDebug/%make%.pdb /DEBUG /MACHINE:I386 /OUT:.\WinDebug/%make%.exe @link.dbg
if not exist .\WinDebug/%make%.exe echo "WinDebug build failed"
if exist .\WinDebug/%make%.exe echo "WinDebug build succeeded!"
if not exist .\WinRel\nul mkdir .\WinRel
echo on
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /D TIVOLI /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c variable.c
echo WinRel\variable.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c rule.c
echo WinRel\rule.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c remote-stub.c
echo WinRel\remote-stub.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c commands.c
echo WinRel\commands.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c file.c
echo WinRel\file.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c getloadavg.c
echo WinRel\getloadavg.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c default.c
echo WinRel\default.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c signame.c
echo WinRel\signame.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c expand.c
echo WinRel\expand.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c dir.c
echo WinRel\dir.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c main.c
echo WinRel\main.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c getopt1.c
echo WinRel\getopt1.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c job.c
echo WinRel\job.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c read.c
echo WinRel\read.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c version.c
echo WinRel\version.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c getopt.c
echo WinRel\getopt.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c arscan.c
echo WinRel\arscan.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c remake.c
echo WinRel\remake.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c misc.c
echo WinRel\misc.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c ar.c
echo WinRel\ar.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c function.c
echo WinRel\function.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c vpath.c
echo WinRel\vpath.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c implicit.c
echo WinRel\implicit.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c .\w32\compat\dirent.c
echo WinRel\dirent.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c .\glob\glob.c
echo WinRel\glob.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c .\glob\fnmatch.c
echo WinRel\fnmatch.obj >>link.rel
cl.exe /nologo /MT /W3 /GX /YX /O2 /I . /I glob /I w32/include /D NDEBUG /D WINDOWS32 /D WIN32 /D _CONSOLE /D HAVE_CONFIG_H /FR.\WinRel/ /Fp.\WinRel/%make%.pch /Fo.\WinRel/ /c .\w32\pathstuff.c
echo WinRel\pathstuff.obj >>link.rel
echo off
echo "Linking WinRel/%make%.exe"
rem link.exe kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib w32\subproc\winrel\subproc.lib /NOLOGO /SUBSYSTEM:console /INCREMENTAL:no /PDB:.\WinRel/%make%.pdb /MACHINE:I386 /OUT:.\WinRel/%make%.exe .\WinRel/variable.obj .\WinRel/rule.obj .\WinRel/remote-stub.obj .\WinRel/commands.obj .\WinRel/file.obj .\WinRel/getloadavg.obj .\WinRel/default.obj .\WinRel/signame.obj .\WinRel/expand.obj .\WinRel/dir.obj .\WinRel/main.obj .\WinRel/getopt1.obj .\WinRel/job.obj .\WinRel/read.obj .\WinRel/version.obj .\WinRel/getopt.obj .\WinRel/arscan.obj .\WinRel/remake.obj .\WinRel/misc.obj .\WinRel/ar.obj .\WinRel/function.obj .\WinRel/vpath.obj .\WinRel/implicit.obj .\WinRel/dirent.obj .\WinRel/glob.obj .\WinRel/fnmatch.obj .\WinRel/pathstuff.obj
echo kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib w32\subproc\winrel\subproc.lib >>link.rel
link.exe /NOLOGO /SUBSYSTEM:console /INCREMENTAL:no /PDB:.\WinRel/%make%.pdb /MACHINE:I386 /OUT:.\WinRel/%make%.exe @link.rel
if not exist .\WinRel/%make%.exe echo "WinRel build failed"
if exist .\WinRel/%make%.exe echo "WinRel build succeeded!"
echo on

584
commands.c Normal file
View File

@@ -0,0 +1,584 @@
/* Command processing for GNU Make.
Copyright (C) 1988,89,91,92,93,94,95,96,97 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "make.h"
#include "dep.h"
#include "filedef.h"
#include "variable.h"
#include "job.h"
#include "commands.h"
#if VMS
# define FILE_LIST_SEPARATOR ','
#else
# define FILE_LIST_SEPARATOR ' '
#endif
extern int remote_kill PARAMS ((int id, int sig));
#ifndef HAVE_UNISTD_H
extern int getpid ();
#endif
/* Set FILE's automatic variables up. */
static void
set_file_variables (file)
register struct file *file;
{
char *at, *percent, *star, *less;
#ifndef NO_ARCHIVES
/* If the target is an archive member `lib(member)',
then $@ is `lib' and $% is `member'. */
if (ar_name (file->name))
{
unsigned int len;
char *p;
p = strchr (file->name, '(');
at = (char *) alloca (p - file->name + 1);
bcopy (file->name, at, p - file->name);
at[p - file->name] = '\0';
len = strlen (p + 1);
percent = (char *) alloca (len);
bcopy (p + 1, percent, len - 1);
percent[len - 1] = '\0';
}
else
#endif /* NO_ARCHIVES. */
{
at = file->name;
percent = "";
}
/* $* is the stem from an implicit or static pattern rule. */
if (file->stem == 0)
{
/* In Unix make, $* is set to the target name with
any suffix in the .SUFFIXES list stripped off for
explicit rules. We store this in the `stem' member. */
register struct dep *d;
char *name;
unsigned int len;
#ifndef NO_ARCHIVES
if (ar_name (file->name))
{
name = strchr (file->name, '(') + 1;
len = strlen (name) - 1;
}
else
#endif
{
name = file->name;
len = strlen (name);
}
for (d = enter_file (".SUFFIXES")->deps; d != 0; d = d->next)
{
unsigned int slen = strlen (dep_name (d));
if (len > slen && strneq (dep_name (d), name + (len - slen), slen))
{
file->stem = savestring (name, len - slen);
break;
}
}
if (d == 0)
file->stem = "";
}
star = file->stem;
/* $< is the first dependency. */
less = file->deps != 0 ? dep_name (file->deps) : "";
if (file->cmds == default_file->cmds)
/* This file got its commands from .DEFAULT.
In this case $< is the same as $@. */
less = at;
#define DEFINE_VARIABLE(name, len, value) \
(void) define_variable_for_file (name,len,value,o_automatic,0,file)
/* Define the variables. */
DEFINE_VARIABLE ("<", 1, less);
DEFINE_VARIABLE ("*", 1, star);
DEFINE_VARIABLE ("@", 1, at);
DEFINE_VARIABLE ("%", 1, percent);
/* Compute the values for $^, $+, $?, and $|. */
{
unsigned int qmark_len, plus_len, bar_len;
char *caret_value, *plus_value;
char *cp;
char *qmark_value;
char *bar_value;
char *qp;
char *bp;
struct dep *d;
unsigned int len;
/* Compute first the value for $+, which is supposed to contain
duplicate dependencies as they were listed in the makefile. */
plus_len = 0;
for (d = file->deps; d != 0; d = d->next)
if (! d->ignore_mtime)
plus_len += strlen (dep_name (d)) + 1;
if (plus_len == 0)
plus_len++;
cp = plus_value = (char *) alloca (plus_len);
qmark_len = plus_len + 1; /* Will be this or less. */
for (d = file->deps; d != 0; d = d->next)
if (! d->ignore_mtime)
{
char *c = dep_name (d);
#ifndef NO_ARCHIVES
if (ar_name (c))
{
c = strchr (c, '(') + 1;
len = strlen (c) - 1;
}
else
#endif
len = strlen (c);
bcopy (c, cp, len);
cp += len;
*cp++ = FILE_LIST_SEPARATOR;
if (! d->changed)
qmark_len -= len + 1; /* Don't space in $? for this one. */
}
/* Kill the last space and define the variable. */
cp[cp > plus_value ? -1 : 0] = '\0';
DEFINE_VARIABLE ("+", 1, plus_value);
/* Make sure that no dependencies are repeated. This does not
really matter for the purpose of updating targets, but it
might make some names be listed twice for $^ and $?. */
uniquize_deps (file->deps);
bar_len = 0;
for (d = file->deps; d != 0; d = d->next)
if (d->ignore_mtime)
bar_len += strlen (dep_name (d)) + 1;
if (bar_len == 0)
bar_len++;
/* Compute the values for $^, $?, and $|. */
cp = caret_value = plus_value; /* Reuse the buffer; it's big enough. */
qp = qmark_value = (char *) alloca (qmark_len);
bp = bar_value = (char *) alloca (bar_len);
for (d = file->deps; d != 0; d = d->next)
{
char *c = dep_name (d);
#ifndef NO_ARCHIVES
if (ar_name (c))
{
c = strchr (c, '(') + 1;
len = strlen (c) - 1;
}
else
#endif
len = strlen (c);
if (d->ignore_mtime)
{
bcopy (c, bp, len);
bp += len;
*bp++ = FILE_LIST_SEPARATOR;
}
else
{
bcopy (c, cp, len);
cp += len;
*cp++ = FILE_LIST_SEPARATOR;
if (d->changed)
{
bcopy (c, qp, len);
qp += len;
*qp++ = FILE_LIST_SEPARATOR;
}
}
}
/* Kill the last spaces and define the variables. */
cp[cp > caret_value ? -1 : 0] = '\0';
DEFINE_VARIABLE ("^", 1, caret_value);
qp[qp > qmark_value ? -1 : 0] = '\0';
DEFINE_VARIABLE ("?", 1, qmark_value);
bp[bp > bar_value ? -1 : 0] = '\0';
DEFINE_VARIABLE ("|", 1, bar_value);
}
#undef DEFINE_VARIABLE
}
/* Chop CMDS up into individual command lines if necessary.
Also set the `lines_flags' and `any_recurse' members. */
void
chop_commands (cmds)
register struct commands *cmds;
{
register char *p;
unsigned int nlines, idx;
char **lines;
/* If we don't have any commands,
or we already parsed them, never mind. */
if (!cmds || cmds->command_lines != 0)
return;
/* Chop CMDS->commands up into lines in CMDS->command_lines.
Also set the corresponding CMDS->lines_flags elements,
and the CMDS->any_recurse flag. */
nlines = 5;
lines = (char **) xmalloc (5 * sizeof (char *));
idx = 0;
p = cmds->commands;
while (*p != '\0')
{
char *end = p;
find_end:;
end = strchr (end, '\n');
if (end == 0)
end = p + strlen (p);
else if (end > p && end[-1] == '\\')
{
int backslash = 1;
register char *b;
for (b = end - 2; b >= p && *b == '\\'; --b)
backslash = !backslash;
if (backslash)
{
++end;
goto find_end;
}
}
if (idx == nlines)
{
nlines += 2;
lines = (char **) xrealloc ((char *) lines,
nlines * sizeof (char *));
}
lines[idx++] = savestring (p, end - p);
p = end;
if (*p != '\0')
++p;
}
if (idx != nlines)
{
nlines = idx;
lines = (char **) xrealloc ((char *) lines,
nlines * sizeof (char *));
}
cmds->ncommand_lines = nlines;
cmds->command_lines = lines;
cmds->any_recurse = 0;
cmds->lines_flags = (char *) xmalloc (nlines);
for (idx = 0; idx < nlines; ++idx)
{
int flags = 0;
for (p = lines[idx];
isblank ((unsigned char)*p) || *p == '-' || *p == '@' || *p == '+';
++p)
switch (*p)
{
case '+':
flags |= COMMANDS_RECURSE;
break;
case '@':
flags |= COMMANDS_SILENT;
break;
case '-':
flags |= COMMANDS_NOERROR;
break;
}
if (!(flags & COMMANDS_RECURSE))
{
unsigned int len = strlen (p);
if (sindex (p, len, "$(MAKE)", 7) != 0
|| sindex (p, len, "${MAKE}", 7) != 0)
flags |= COMMANDS_RECURSE;
}
cmds->lines_flags[idx] = flags;
cmds->any_recurse |= flags & COMMANDS_RECURSE;
}
}
/* Execute the commands to remake FILE. If they are currently executing,
return or have already finished executing, just return. Otherwise,
fork off a child process to run the first command line in the sequence. */
void
execute_file_commands (file)
struct file *file;
{
register char *p;
/* Don't go through all the preparations if
the commands are nothing but whitespace. */
for (p = file->cmds->commands; *p != '\0'; ++p)
if (!isspace ((unsigned char)*p) && *p != '-' && *p != '@')
break;
if (*p == '\0')
{
/* If there are no commands, assume everything worked. */
set_command_state (file, cs_running);
file->update_status = 0;
notice_finished_file (file);
return;
}
/* First set the automatic variables according to this file. */
initialize_file_variables (file, 0);
set_file_variables (file);
/* Start the commands running. */
new_job (file);
}
/* This is set while we are inside fatal_error_signal,
so things can avoid nonreentrant operations. */
int handling_fatal_signal = 0;
/* Handle fatal signals. */
RETSIGTYPE
fatal_error_signal (sig)
int sig;
{
#ifdef __MSDOS__
extern int dos_status, dos_command_running;
if (dos_command_running)
{
/* That was the child who got the signal, not us. */
dos_status |= (sig << 8);
return;
}
remove_intermediates (1);
exit (EXIT_FAILURE);
#else /* not __MSDOS__ */
#ifdef _AMIGA
remove_intermediates (1);
if (sig == SIGINT)
fputs (_("*** Break.\n"), stderr);
exit (10);
#else /* not Amiga */
handling_fatal_signal = 1;
/* Set the handling for this signal to the default.
It is blocked now while we run this handler. */
signal (sig, SIG_DFL);
/* A termination signal won't be sent to the entire
process group, but it means we want to kill the children. */
if (sig == SIGTERM)
{
register struct child *c;
for (c = children; c != 0; c = c->next)
if (!c->remote)
(void) kill (c->pid, SIGTERM);
}
/* If we got a signal that means the user
wanted to kill make, remove pending targets. */
if (sig == SIGTERM || sig == SIGINT
#ifdef SIGHUP
|| sig == SIGHUP
#endif
#ifdef SIGQUIT
|| sig == SIGQUIT
#endif
)
{
register struct child *c;
/* Remote children won't automatically get signals sent
to the process group, so we must send them. */
for (c = children; c != 0; c = c->next)
if (c->remote)
(void) remote_kill (c->pid, sig);
for (c = children; c != 0; c = c->next)
delete_child_targets (c);
/* Clean up the children. We don't just use the call below because
we don't want to print the "Waiting for children" message. */
while (job_slots_used > 0)
reap_children (1, 0);
}
else
/* Wait for our children to die. */
while (job_slots_used > 0)
reap_children (1, 1);
/* Delete any non-precious intermediate files that were made. */
remove_intermediates (1);
#ifdef SIGQUIT
if (sig == SIGQUIT)
/* We don't want to send ourselves SIGQUIT, because it will
cause a core dump. Just exit instead. */
exit (EXIT_FAILURE);
#endif
/* Signal the same code; this time it will really be fatal. The signal
will be unblocked when we return and arrive then to kill us. */
if (kill (getpid (), sig) < 0)
pfatal_with_name ("kill");
#endif /* not Amiga */
#endif /* not __MSDOS__ */
}
/* Delete FILE unless it's precious or not actually a file (phony),
and it has changed on disk since we last stat'd it. */
static void
delete_target (file, on_behalf_of)
struct file *file;
char *on_behalf_of;
{
struct stat st;
if (file->precious || file->phony)
return;
#ifndef NO_ARCHIVES
if (ar_name (file->name))
{
time_t file_date = (file->last_mtime == NONEXISTENT_MTIME
? (time_t) -1
: (time_t) FILE_TIMESTAMP_S (file->last_mtime));
if (ar_member_date (file->name) != file_date)
{
if (on_behalf_of)
error (NILF, _("*** [%s] Archive member `%s' may be bogus; not deleted"),
on_behalf_of, file->name);
else
error (NILF, _("*** Archive member `%s' may be bogus; not deleted"),
file->name);
}
return;
}
#endif
if (stat (file->name, &st) == 0
&& S_ISREG (st.st_mode)
&& FILE_TIMESTAMP_STAT_MODTIME (file->name, st) != file->last_mtime)
{
if (on_behalf_of)
error (NILF, _("*** [%s] Deleting file `%s'"), on_behalf_of, file->name);
else
error (NILF, _("*** Deleting file `%s'"), file->name);
if (unlink (file->name) < 0
&& errno != ENOENT) /* It disappeared; so what. */
perror_with_name ("unlink: ", file->name);
}
}
/* Delete all non-precious targets of CHILD unless they were already deleted.
Set the flag in CHILD to say they've been deleted. */
void
delete_child_targets (child)
struct child *child;
{
struct dep *d;
if (child->deleted)
return;
/* Delete the target file if it changed. */
delete_target (child->file, (char *) 0);
/* Also remove any non-precious targets listed in the `also_make' member. */
for (d = child->file->also_make; d != 0; d = d->next)
delete_target (d->file, child->file->name);
child->deleted = 1;
}
/* Print out the commands in CMDS. */
void
print_commands (cmds)
register struct commands *cmds;
{
register char *s;
fputs (_("# commands to execute"), stdout);
if (cmds->fileinfo.filenm == 0)
puts (_(" (built-in):"));
else
printf (_(" (from `%s', line %lu):\n"),
cmds->fileinfo.filenm, cmds->fileinfo.lineno);
s = cmds->commands;
while (*s != '\0')
{
char *end;
while (isspace ((unsigned char)*s))
++s;
end = strchr (s, '\n');
if (end == 0)
end = s + strlen (s);
printf ("\t%.*s\n", (int) (end - s), s);
s = end;
}
}

42
commands.h Normal file
View File

@@ -0,0 +1,42 @@
/* Definition of data structures describing shell commands for GNU Make.
Copyright (C) 1988, 1989, 1991, 1993 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/* Structure that gives the commands to make a file
and information about where these commands came from. */
struct commands
{
struct floc fileinfo; /* Where commands were defined. */
char *commands; /* Commands text. */
unsigned int ncommand_lines;/* Number of command lines. */
char **command_lines; /* Commands chopped up into lines. */
char *lines_flags; /* One set of flag bits for each line. */
int any_recurse; /* Nonzero if any `lines_recurse' elt has */
/* the COMMANDS_RECURSE bit set. */
};
/* Bits in `lines_flags'. */
#define COMMANDS_RECURSE 1 /* Recurses: + or $(MAKE). */
#define COMMANDS_SILENT 2 /* Silent: @. */
#define COMMANDS_NOERROR 4 /* No errors: -. */
extern void execute_file_commands PARAMS ((struct file *file));
extern void print_commands PARAMS ((struct commands *cmds));
extern void delete_child_targets PARAMS ((struct child *child));
extern void chop_commands PARAMS ((struct commands *cmds));

317
config.ami.template Normal file
View File

@@ -0,0 +1,317 @@
/* config.h.in. Generated automatically from configure.in by autoheader. */
/* Define if on AIX 3.
System headers sometimes define this.
We just want to avoid a redefinition error message. */
#ifndef _ALL_SOURCE
/* #undef _ALL_SOURCE */
#endif
/* Define if using alloca.c. */
#define C_ALLOCA
/* Define if the closedir function returns void instead of int. */
/* #undef CLOSEDIR_VOID */
/* Define to empty if the keyword does not work. */
/* #undef const */
/* Define to one of _getb67, GETB67, getb67 for Cray-2 and Cray-YMP systems.
This function is required for alloca.c support on those systems. */
/* #undef CRAY_STACKSEG_END */
/* Define for DGUX with <sys/dg_sys_info.h>. */
/* #undef DGUX */
/* Define if the `getloadavg' function needs to be run setuid or setgid. */
/* #undef GETLOADAVG_PRIVILEGED */
/* Define to `unsigned long' or `unsigned long long'
if <inttypes.h> doesn't define. */
#define uintmax_t unsigned long
/* Define to `int' if <sys/types.h> doesn't define. */
#define gid_t int
/* Define if you have alloca, as a function or macro. */
/* #undef HAVE_ALLOCA */
/* Define if you have <alloca.h> and it should be used (not on Ultrix). */
/* #undef HAVE_ALLOCA_H */
/* Define if you don't have vprintf but do have _doprnt. */
/* #undef HAVE_DOPRNT */
/* Define if your system has a working fnmatch function. */
/* #undef HAVE_FNMATCH */
/* Define if your system has its own `getloadavg' function. */
/* #undef HAVE_GETLOADAVG */
/* Define if you have the getmntent function. */
/* #undef HAVE_GETMNTENT */
/* Define if the `long double' type works. */
/* #undef HAVE_LONG_DOUBLE */
/* Define if you support file names longer than 14 characters. */
#define HAVE_LONG_FILE_NAMES 1
/* Define if you have a working `mmap' system call. */
/* #undef HAVE_MMAP */
/* Define if system calls automatically restart after interruption
by a signal. */
/* #undef HAVE_RESTARTABLE_SYSCALLS */
/* Define if your struct stat has st_blksize. */
/* #undef HAVE_ST_BLKSIZE */
/* Define if your struct stat has st_blocks. */
/* #undef HAVE_ST_BLOCKS */
/* Define if you have the strcoll function and it is properly defined. */
#define HAVE_STRCOLL 1
/* Define if your struct stat has st_rdev. */
#define HAVE_ST_RDEV 1
/* Define if you have the strftime function. */
#define HAVE_STRFTIME 1
/* Define if you have <sys/wait.h> that is POSIX.1 compatible. */
/* #undef HAVE_SYS_WAIT_H */
/* Define if your struct tm has tm_zone. */
/* #undef HAVE_TM_ZONE */
/* Define if you don't have tm_zone but do have the external array
tzname. */
#define HAVE_TZNAME 1
/* Define if you have <unistd.h>. */
#define HAVE_UNISTD_H 1
/* Define if utime(file, NULL) sets file's timestamp to the present. */
/* #undef HAVE_UTIME_NULL */
/* Define if you have <vfork.h>. */
/* #undef HAVE_VFORK_H */
/* Define if you have the vprintf function. */
#define HAVE_VPRINTF 1
/* Define if you have the wait3 system call. */
/* #undef HAVE_WAIT3 */
/* Define if on MINIX. */
/* #undef _MINIX */
/* Define if your struct nlist has an n_un member. */
/* #undef NLIST_NAME_UNION */
/* Define if you have <nlist.h>. */
/* #undef NLIST_STRUCT */
/* Define if your C compiler doesn't accept -c and -o together. */
/* #undef NO_MINUS_C_MINUS_O */
/* Define to `int' if <sys/types.h> doesn't define. */
#define pid_t int
/* Define if the system does not provide POSIX.1 features except
with this defined. */
/* #undef _POSIX_1_SOURCE */
/* Define if you need to in order for stat and other things to work. */
/* #undef _POSIX_SOURCE */
/* Define as the return type of signal handlers (int or void). */
#define RETSIGTYPE void
/* Define if the setvbuf function takes the buffering type as its second
argument and the buffer pointer as the third, as on System V
before release 3. */
/* #undef SETVBUF_REVERSED */
/* If using the C implementation of alloca, define if you know the
direction of stack growth for your system; otherwise it will be
automatically deduced at run-time.
STACK_DIRECTION > 0 => grows toward higher addresses
STACK_DIRECTION < 0 => grows toward lower addresses
STACK_DIRECTION = 0 => direction of growth unknown
*/
#define STACK_DIRECTION -1
/* Define if the `S_IS*' macros in <sys/stat.h> do not work properly. */
/* #undef STAT_MACROS_BROKEN */
/* Define if you have the ANSI C header files. */
#define STDC_HEADERS
/* Define on System V Release 4. */
/* #undef SVR4 */
/* Define if `sys_siglist' is declared by <signal.h>. */
/* #undef SYS_SIGLIST_DECLARED */
/* Define to `int' if <sys/types.h> doesn't define. */
#define uid_t int
/* Define for Encore UMAX. */
/* #undef UMAX */
/* Define for Encore UMAX 4.3 that has <inq_status/cpustats.h>
instead of <sys/cpustats.h>. */
/* #undef UMAX4_3 */
/* Define vfork as fork if vfork does not work. */
/* #undef vfork */
/* Name of this package (needed by automake) */
#define PACKAGE "%PACKAGE%"
/* Version of this package (needed by automake) */
#define VERSION "%VERSION%"
/* Define to the name of the SCCS `get' command. */
#define SCCS_GET "get"
/* Define this if the SCCS `get' command understands the `-G<file>' option. */
/* #undef SCCS_GET_MINUS_G */
/* Define this to enable job server support in GNU make. */
/* #undef MAKE_JOBSERVER */
/* Define to be the nanoseconds member of struct stat's st_mtim,
if it exists. */
/* #undef ST_MTIM_NSEC */
/* Define this if the C library defines the variable `sys_siglist'. */
/* #undef HAVE_SYS_SIGLIST */
/* Define this if the C library defines the variable `_sys_siglist'. */
/* #undef HAVE__SYS_SIGLIST */
/* Define this if you have the `union wait' type in <sys/wait.h>. */
/* #undef HAVE_UNION_WAIT */
/* Define if you have the dup2 function. */
/* #undef HAVE_DUP2 */
/* Define if you have the getcwd function. */
#define HAVE_GETCWD 1
/* Define if you have the getgroups function. */
/* #undef HAVE_GETGROUPS */
/* Define if you have the gethostbyname function. */
/* #undef HAVE_GETHOSTBYNAME */
/* Define if you have the gethostname function. */
/* #undef HAVE_GETHOSTNAME */
/* Define if you have the memmove function. */
#define HAVE_MEMMOVE 1
/* Define if you have the mktemp function. */
#define HAVE_MKTEMP 1
/* Define if you have the psignal function. */
/* #undef HAVE_PSIGNAL */
/* Define if you have the pstat_getdynamic function. */
/* #undef HAVE_PSTAT_GETDYNAMIC */
/* Define if you have the setegid function. */
/* #undef HAVE_SETEGID */
/* Define if you have the seteuid function. */
/* #undef HAVE_SETEUID */
/* Define if you have the setlinebuf function. */
/* #undef HAVE_SETLINEBUF */
/* Define if you have the setregid function. */
/* #undef HAVE_SETREGID */
/* Define if you have the setreuid function. */
/* #undef HAVE_SETREUID */
/* Define if you have the sigsetmask function. */
/* #undef HAVE_SIGSETMASK */
/* Define if you have the socket function. */
/* #undef HAVE_SOCKET */
/* Define if you have the strcasecmp function. */
/* #undef HAVE_STRCASECMP */
/* Define if you have the strerror function. */
#define HAVE_STRERROR 1
/* Define if you have the strsignal function. */
/* #undef HAVE_STRSIGNAL */
/* Define if you have the wait3 function. */
/* #undef HAVE_WAIT3 */
/* Define if you have the waitpid function. */
/* #undef HAVE_WAITPID */
/* Define if you have the <dirent.h> header file. */
#define HAVE_DIRENT_H 1
/* Define if you have the <fcntl.h> header file. */
#define HAVE_FCNTL_H 1
/* Define if you have the <limits.h> header file. */
#define HAVE_LIMITS_H 1
/* Define if you have the <mach/mach.h> header file. */
/* #undef HAVE_MACH_MACH_H */
/* Define if you have the <memory.h> header file. */
/* #undef HAVE_MEMORY_H */
/* Define if you have the <ndir.h> header file. */
/* #undef HAVE_NDIR_H */
/* Define if you have the <stdlib.h> header file. */
/* #undef HAVE_STDLIB_H */
/* Define if you have the <string.h> header file. */
#define HAVE_STRING_H 1
/* Define if you have the <sys/dir.h> header file. */
#define HAVE_SYS_DIR_H 1
/* Define if you have the <sys/ndir.h> header file. */
/* #undef HAVE_SYS_NDIR_H */
/* Define if you have the <sys/param.h> header file. */
/* #undef HAVE_SYS_PARAM_H */
/* Define if you have the <sys/timeb.h> header file. */
/* #undef HAVE_SYS_TIMEB_H */
/* Define if you have the <sys/wait.h> header file. */
/* #undef HAVE_SYS_WAIT_H */
/* Define if you have the <unistd.h> header file. */
#define HAVE_UNISTD_H 1
/* Define if you have the dgc library (-ldgc). */
/* #undef HAVE_LIBDGC */
/* Define if you have the kstat library (-lkstat). */
/* #undef HAVE_LIBKSTAT */
/* Define if you have the sun library (-lsun). */
/* #undef HAVE_LIBSUN */
/* Define for Case Insensitve behavior */
#define HAVE_CASE_INSENSITIVE_FS
/* Build host information. */
#define MAKE_HOST "Amiga"

403
config.h-vms.template Normal file
View File

@@ -0,0 +1,403 @@
/* config.h-vms. Generated by hand by Klaus Kämpf <kkaempf@rmi.de> */
/* config.h. Generated automatically by configure. */
/* config.h.in. Generated automatically from configure.in by autoheader. */
/* Define if on AIX 3.
System headers sometimes define this.
We just want to avoid a redefinition error message. */
#ifndef _ALL_SOURCE
/* #undef _ALL_SOURCE */
#endif
/* Define to 1 if NLS is requested. */
/* #undef ENABLE_NLS */
/* Define as 1 if you have dcgettext. */
/* #undef HAVE_DCGETTEXT */
/* Define as 1 if you have gettext and don't want to use GNU gettext. */
/* #undef HAVE_GETTEXT */
/* Define if your locale.h file contains LC_MESSAGES. */
/* #undef HAVE_LC_MESSAGES */
/* Define to the installation directory for locales. */
#define LOCALEDIR ""
/* Define as 1 if you have the stpcpy function. */
/* #undef HAVE_STPCPY */
/* Define if the closedir function returns void instead of int. */
/* #undef CLOSEDIR_VOID */
/* Define to empty if the keyword does not work. */
/* #undef const */
/* Define to one of _getb67, GETB67, getb67 for Cray-2 and Cray-YMP systems.
This function is required for alloca.c support on those systems. */
/* #undef CRAY_STACKSEG_END */
/* Define for DGUX with <sys/dg_sys_info.h>. */
/* #undef DGUX */
/* Define if the `getloadavg' function needs to be run setuid or setgid. */
/* #undef GETLOADAVG_PRIVILEGED */
/* Define to `unsigned long' or `unsigned long long'
if <inttypes.h> doesn't define. */
#define uintmax_t unsigned long
/* Define to `int' if <sys/types.h> doesn't define. */
/* #undef gid_t */
/* Define if you have alloca, as a function or macro. */
#define HAVE_ALLOCA 1
/* Define if you have <alloca.h> and it should be used (not on Ultrix). */
/* #undef HAVE_ALLOCA_H */
/* Define if you don't have vprintf but do have _doprnt. */
/* #undef HAVE_DOPRNT */
/* Define if your system has a working fnmatch function. */
/* #undef HAVE_FNMATCH */
/* Define if your system has its own `getloadavg' function. */
/* #undef HAVE_GETLOADAVG */
/* Define if you have the getmntent function. */
/* #undef HAVE_GETMNTENT */
/* Define if the `long double' type works. */
/* #undef HAVE_LONG_DOUBLE */
/* Define if you support file names longer than 14 characters. */
#define HAVE_LONG_FILE_NAMES 1
/* Define if you have a working `mmap' system call. */
/* #undef HAVE_MMAP */
/* Define if system calls automatically restart after interruption
by a signal. */
/* #undef HAVE_RESTARTABLE_SYSCALLS */
/* Define if your struct stat has st_blksize. */
/* #undef HAVE_ST_BLKSIZE */
/* Define if your struct stat has st_blocks. */
/* #undef HAVE_ST_BLOCKS */
/* Define if you have the strcoll function and it is properly defined. */
/* #undef HAVE_STRCOLL */
/* Define if your struct stat has st_rdev. */
/* #undef HAVE_ST_RDEV */
/* Define if you have the strftime function. */
/* #undef HAVE_STRFTIME */
/* Define if you have <sys/wait.h> that is POSIX.1 compatible. */
/* #undef HAVE_SYS_WAIT_H */
/* Define if your struct tm has tm_zone. */
/* #undef HAVE_TM_ZONE */
/* Define if you don't have tm_zone but do have the external array
tzname. */
/* #undef HAVE_TZNAME */
/* Define if you have <unistd.h>. */
#ifdef __DECC
#define HAVE_UNISTD_H 1
#endif
/* Define if utime(file, NULL) sets file's timestamp to the present. */
/* #undef HAVE_UTIME_NULL */
/* Define if you have <vfork.h>. */
/* #undef HAVE_VFORK_H */
/* Define if you have the vprintf function. */
#define HAVE_VPRINTF 1
/* Define if you have the wait3 system call. */
/* #undef HAVE_WAIT3 */
/* Define if on MINIX. */
/* #undef _MINIX */
/* Define if your struct nlist has an n_un member. */
/* #undef NLIST_NAME_UNION */
/* Define if you have <nlist.h>. */
/* #undef NLIST_STRUCT */
/* Define if your C compiler doesn't accept -c and -o together. */
/* #undef NO_MINUS_C_MINUS_O */
/* Define to `int' if <sys/types.h> doesn't define. */
/* I assume types.h is available for all 5.0 cc/cxx compilers */
#if __DECC_VER < 50090000
#define pid_t int
#endif
/* Define if the system does not provide POSIX.1 features except
with this defined. */
/* #undef _POSIX_1_SOURCE */
/* Define if you need to in order for stat and other things to work. */
/* #undef _POSIX_SOURCE */
/* Define as the return type of signal handlers (int or void). */
#define RETSIGTYPE void
/* Define if the setvbuf function takes the buffering type as its second
argument and the buffer pointer as the third, as on System V
before release 3. */
/* #undef SETVBUF_REVERSED */
/* If using the C implementation of alloca, define if you know the
direction of stack growth for your system; otherwise it will be
automatically deduced at run-time.
STACK_DIRECTION > 0 => grows toward higher addresses
STACK_DIRECTION < 0 => grows toward lower addresses
STACK_DIRECTION = 0 => direction of growth unknown
*/
/* #undef STACK_DIRECTION */
/* Define if the `S_IS*' macros in <sys/stat.h> do not work properly. */
/* #undef STAT_MACROS_BROKEN */
/* Define if you have the ANSI C header files. */
/* #undef STDC_HEADERS */
/* Define on System V Release 4. */
/* #undef SVR4 */
/* Define if `sys_siglist' is declared by <signal.h>. */
/* #undef SYS_SIGLIST_DECLARED */
/* Define to `int' if <sys/types.h> doesn't define. */
#if __DECC_VER < 50090000
#define uid_t int
#endif
/* Define for Encore UMAX. */
/* #undef UMAX */
/* Define for Encore UMAX 4.3 that has <inq_status/cpustats.h>
instead of <sys/cpustats.h>. */
/* #undef UMAX4_3 */
/* Define vfork as fork if vfork does not work. */
/* #undef vfork */
/* Name of this package (needed by automake) */
#define PACKAGE "%PACKAGE%"
/* Version of this package (needed by automake) */
#define VERSION "%VERSION%"
/* Define to the name of the SCCS `get' command. */
/* #undef SCCS_GET */
/* Define this if the SCCS `get' command understands the `-G<file>' option. */
/* #undef SCCS_GET_MINUS_G */
/* Define this to enable job server support in GNU make. */
/* #undef MAKE_JOBSERVER */
/* Define to be the nanoseconds member of struct stat's st_mtim,
if it exists. */
/* #undef ST_MTIM_NSEC */
/* Define this if the C library defines the variable `sys_siglist'. */
/* #undefine HAVE_SYS_SIGLIST */
/* Define this if the C library defines the variable `_sys_siglist'. */
/* #undef HAVE__SYS_SIGLIST */
/* Define this if you have the `union wait' type in <sys/wait.h>. */
/* #undef HAVE_UNION_WAIT */
/* Define if you have the dup2 function. */
#define HAVE_DUP2 1
/* Define if you have the getcwd function. */
#define HAVE_GETCWD 1
/* Define if you have the getgroups function. */
/* #undef HAVE_GETGROUPS */
/* Define if you have the gethostbyname function. */
/* #undef HAVE_GETHOSTBYNAME */
/* Define if you have the gethostname function. */
/* #undef HAVE_GETHOSTNAME */
/* Define if you have the getloadavg function. */
/* #undef HAVE_GETLOADAVG */
/* Define if you have the memmove function. */
#define HAVE_MEMMOVE 1
/* Define if you have the mktemp function. */
#define HAVE_MKTEMP 1
/* Define if you have the psignal function. */
/* #undef HAVE_PSIGNAL */
/* Define if you have the pstat_getdynamic function. */
/* #undef HAVE_PSTAT_GETDYNAMIC */
/* Define if you have the setegid function. */
/* #undef HAVE_SETEGID */
/* Define if you have the seteuid function. */
/* #undef HAVE_SETEUID */
/* Define if you have the setlinebuf function. */
/* #undef HAVE_SETLINEBUF */
/* Define if you have the setregid function. */
/* #undefine HAVE_SETREGID */
/* Define if you have the setreuid function. */
/* #define HAVE_SETREUID */
/* Define if you have the sigsetmask function. */
#define HAVE_SIGSETMASK 1
/* Define if you have the socket function. */
/* #undef HAVE_SOCKET */
/* Define if you have the strcasecmp function. */
/* #undef HAVE_STRCASECMP */
/* Define if you have the strerror function. */
#define HAVE_STRERROR 1
/* Define if you have the strsignal function. */
/* #undef HAVE_STRSIGNAL */
/* Define if you have the wait3 function. */
/* #undef HAVE_WAIT3 */
/* Define if you have the waitpid function. */
/* #undef HAVE_WAITPID */
/* Define if you have the <dirent.h> header file. */
#define HAVE_DIRENT_H 1
/* Define if you have the <fcntl.h> header file. */
#ifdef __DECC
#define HAVE_FCNTL_H 1
#endif
/* Define if you have the <limits.h> header file. */
#define HAVE_LIMITS_H 1
/* Define if you have the <mach/mach.h> header file. */
/* #undef HAVE_MACH_MACH_H */
/* Define if you have the <memory.h> header file. */
/* #undef HAVE_MEMORY_H */
/* Define if you have the <ndir.h> header file. */
/* #undef HAVE_NDIR_H */
/* Define if you have the <stdlib.h> header file. */
#define HAVE_STDLIB_H 1
/* Define if you have the <string.h> header file. */
#define HAVE_STRING_H 1
/* Define if you have the <sys/dir.h> header file. */
/* #undef HAVE_SYS_DIR_H */
/* Define if you have the <sys/ndir.h> header file. */
/* #undef HAVE_SYS_NDIR_H */
/* Define if you have the <sys/param.h> header file. */
/* #undef HAVE_SYS_PARAM_H */
/* Define if you have the <sys/timeb.h> header file. */
#ifndef __GNUC__
#define HAVE_SYS_TIMEB_H 1
#endif
/* Define if you have the <sys/wait.h> header file. */
/* #undef HAVE_SYS_WAIT_H */
/* Define if you have the dgc library (-ldgc). */
/* #undef HAVE_LIBDGC */
/* Define if you have the kstat library (-lkstat). */
/* #undef HAVE_LIBKSTAT *
/* Define if you have the sun library (-lsun). */
/* #undef HAVE_LIBSUN */
/* Use high resolution file timestamps if nonzero. */
#define FILE_TIMESTAMP_HI_RES 0
/* Define for case insensitve filenames */
#define HAVE_CASE_INSENSITIVE_FS 1
/* VMS specific, define it if you want to use case sensitve targets */
/* #undef WANT_CASE_SENSITIVE_TARGETS */
/* VMS specific, V7.0 has opendir() and friends, so it's undefined */
/* If you want to use non-VMS code for opendir() etc. on V7.0 and greater
define the first or both macros AND change the compile command to get the
non-VMS versions linked: (prefix=(all,except=(opendir,... */
/* #undef HAVE_VMSDIR_H */
/* #undef _DIRENT_HAVE_D_NAMLEN */
/* On older systems without 7.0 backport of CRTL the first one is defined */
#ifdef __CRTL_VER
# if __CRTL_VER < 70000000
# define HAVE_VMSDIR_H 1
# endif
#else
# if __VMS_VER < 70000000
# define HAVE_VMSDIR_H 1
# endif
#endif
#if defined(HAVE_VMSDIR_H) && defined(HAVE_DIRENT_H)
#undef HAVE_DIRENT_H
#endif
#define HAVE_STDLIB_H 1
#define INCLUDEDIR "sys$sysroot:[syslib]"
#define LIBDIR "sys$sysroot:[syslib]"
/* Don't use RTL functions of OpenVMS */
#ifdef __DECC
#include <stdio.h>
#include <unistd.h>
#define getopt gnu_getopt
#define optarg gnu_optarg
#define optopt gnu_optopt
#define optind gnu_optind
#define opterr gnu_opterr
#endif
#if defined (__cplusplus) || (defined (__STDC__) && __STDC__)
#undef PARAMS
#define PARAMS(protos) protos
#else /* Not C++ or ANSI C. */
#undef PARAMS
#define PARAMS(protos) ()
#endif /* C++ or ANSI C. */
/* Define if using alloca.c. */
/* #undef C_ALLOCA */
/* maybe this should be placed into make.h */
#if defined(__VAX) && defined(__DECC)
#define alloca(n) __ALLOCA(n)
#endif
/* Build host information. */
#define MAKE_HOST "VMS"

399
config.h.W32.template Normal file
View File

@@ -0,0 +1,399 @@
/* config.h.in. Generated automatically from configure.in by autoheader. */
/* Define if on AIX 3.
System headers sometimes define this.
We just want to avoid a redefinition error message. */
#ifndef _ALL_SOURCE
/* #undef _ALL_SOURCE */
#endif
/* Define if using alloca.c. */
/* #undef C_ALLOCA */
/* Define if the closedir function returns void instead of int. */
/* #undef CLOSEDIR_VOID */
/* Define to empty if the keyword does not work. */
/* #undef const */
/* Define to one of _getb67, GETB67, getb67 for Cray-2 and Cray-YMP systems.
This function is required for alloca.c support on those systems. */
/* #undef CRAY_STACKSEG_END */
/* Define for DGUX with <sys/dg_sys_info.h>. */
/* #undef DGUX */
/* Define if the `getloadavg' function needs to be run setuid or setgid. */
/* #undef GETLOADAVG_PRIVILEGED */
/* Define to `unsigned long' or `unsigned long long'
if <inttypes.h> doesn't define. */
#define uintmax_t unsigned long
/* Define to `int' if <sys/types.h> doesn't define. */
#undef gid_t
#define gid_t int
/* Define if you have alloca, as a function or macro. */
#undef HAVE_ALLOCA
#define HAVE_ALLOCA 1
/* Define if you have <alloca.h> and it should be used (not on Ultrix). */
/* #undef HAVE_ALLOCA_H */
/* Define if you don't have vprintf but do have _doprnt. */
/* #undef HAVE_DOPRNT */
/* Define if your system has a working fnmatch function. */
/* #undef HAVE_FNMATCH */
/* Define if your system has its own `getloadavg' function. */
/* #undef HAVE_GETLOADAVG */
/* Define if you have the getmntent function. */
/* #undef HAVE_GETMNTENT */
/* Define if the `long double' type works. */
/* #undef HAVE_LONG_DOUBLE */
/* Define if you support file names longer than 14 characters. */
#undef HAVE_LONG_FILE_NAMES
#define HAVE_LONG_FILE_NAMES 1
/* Define if you have a working `mmap' system call. */
/* #undef HAVE_MMAP */
/* Define if system calls automatically restart after interruption
by a signal. */
/* #undef HAVE_RESTARTABLE_SYSCALLS */
/* Define if your struct stat has st_blksize. */
/* #undef HAVE_ST_BLKSIZE */
/* Define if your struct stat has st_blocks. */
/* #undef HAVE_ST_BLOCKS */
/* Define if you have the strcoll function and it is properly defined. */
#undef HAVE_STRCOLL
#define HAVE_STRCOLL 1
/* Define if your struct stat has st_rdev. */
#undef HAVE_ST_RDEV
#define HAVE_ST_RDEV 1
/* Define if you have the strftime function. */
#undef HAVE_STRFTIME
#define HAVE_STRFTIME 1
/* Define if you have <sys/wait.h> that is POSIX.1 compatible. */
/* #undef HAVE_SYS_WAIT_H */
/* Define if your struct tm has tm_zone. */
/* #undef HAVE_TM_ZONE */
/* Define if you don't have tm_zone but do have the external array
tzname. */
#undef HAVE_TZNAME
#define HAVE_TZNAME 1
/* Define if you have <unistd.h>. */
/* #undef HAVE_UNISTD_H */
/* Define if utime(file, NULL) sets file's timestamp to the present. */
#undef HAVE_UTIME_NULL
#define HAVE_UTIME_NULL 1
/* Define if you have <vfork.h>. */
/* #undef HAVE_VFORK_H */
/* Define if you have the vprintf function. */
#undef HAVE_VPRINTF
#define HAVE_VPRINTF 1
/* Define if you have the wait3 system call. */
/* #undef HAVE_WAIT3 */
/* Define if on MINIX. */
/* #undef _MINIX */
/* Define if your struct nlist has an n_un member. */
/* #undef NLIST_NAME_UNION */
/* Define if you have <nlist.h>. */
/* #undef NLIST_STRUCT */
/* Define if your C compiler doesn't accept -c and -o together. */
/* #undef NO_MINUS_C_MINUS_O */
/* Define to `int' if <sys/types.h> doesn't define. */
#undef pid_t
#define pid_t int
/* Define if the system does not provide POSIX.1 features except
with this defined. */
/* #undef _POSIX_1_SOURCE */
/* Define if you need to in order for stat and other things to work. */
#undef _POSIX_SOURCE
#define _POSIX_SOURCE 1
/* Define as the return type of signal handlers (int or void). */
#undef RETSIGTYPE
#define RETSIGTYPE void
/* Define if the setvbuf function takes the buffering type as its second
argument and the buffer pointer as the third, as on System V
before release 3. */
/* #undef SETVBUF_REVERSED */
/* If using the C implementation of alloca, define if you know the
direction of stack growth for your system; otherwise it will be
automatically deduced at run-time.
STACK_DIRECTION > 0 => grows toward higher addresses
STACK_DIRECTION < 0 => grows toward lower addresses
STACK_DIRECTION = 0 => direction of growth unknown
*/
/* #undef STACK_DIRECTION */
/* Define if the `S_IS*' macros in <sys/stat.h> do not work properly. */
/* #undef STAT_MACROS_BROKEN */
/* Define if you have the ANSI C header files. */
#undef STDC_HEADERS
#define STDC_HEADERS 1
/* Define on System V Release 4. */
/* #undef SVR4 */
/* Define if `sys_siglist' is declared by <signal.h>. */
/* #undef SYS_SIGLIST_DECLARED */
/* Define to `int' if <sys/types.h> doesn't define. */
#undef uid_t
#define uid_t int
/* Define for Encore UMAX. */
/* #undef UMAX */
/* Define for Encore UMAX 4.3 that has <inq_status/cpustats.h>
instead of <sys/cpustats.h>. */
/* #undef UMAX4_3 */
/* Define vfork as fork if vfork does not work. */
/* #undef vfork */
/* Name of this package (needed by automake) */
#define PACKAGE "%PACKAGE%"
/* Version of this package (needed by automake) */
#define VERSION "%VERSION%"
/* Define to the name of the SCCS `get' command. */
#undef SCCS_GET
#define SCCS_GET "echo no sccs get"
/* Define to 1 if NLS is requested. */
/* #undef ENABLE_NLS */
/* Define as 1 if you have dcgettext. */
/* #undef HAVE_DCGETTEXT */
/* Define as 1 if you have gettext and don't want to use GNU gettext. */
/* #undef HAVE_GETTEXT */
/* Define if your locale.h file contains LC_MESSAGES. */
/* #undef HAVE_LC_MESSAGES */
/* Define to the installation directory for locales. */
#define LOCALEDIR ""
/* Define this if the SCCS `get' command understands the `-G<file>' option. */
/* #undef SCCS_GET_MINUS_G */
/* Define this to enable job server support in GNU make. */
/* #undef MAKE_JOBSERVER */
/* Define to be the nanoseconds member of struct stat's st_mtim,
if it exists. */
/* #undef ST_MTIM_NSEC */
/* Define this if the C library defines the variable `sys_siglist'. */
/* #undef HAVE_SYS_SIGLIST */
/* Define this if the C library defines the variable `_sys_siglist'. */
/* #undef HAVE__SYS_SIGLIST */
/* Define this if you have the `union wait' type in <sys/wait.h>. */
/* #undef HAVE_UNION_WAIT */
/* Define if you have the dup2 function. */
#undef HAVE_DUP2
#define HAVE_DUP2 1
/* Define if you have the getcwd function. */
#undef HAVE_GETCWD
#define HAVE_GETCWD 1
/* Define if you have the getgroups function. */
/* #undef HAVE_GETGROUPS */
/* Define if you have the gethostbyname function. */
/* #undef HAVE_GETHOSTBYNAME */
/* Define if you have the gethostname function. */
/* #undef HAVE_GETHOSTNAME */
/* Define if you have the getloadavg function. */
/* #undef HAVE_GETLOADAVG */
/* Define if you have the memmove function. */
#undef HAVE_MEMMOVE
#define HAVE_MEMMOVE 1
/* Define if you have the mktemp function. */
#undef HAVE_MKTEMP
#define HAVE_MKTEMP 1
/* Define if you have the psignal function. */
/* #undef HAVE_PSIGNAL */
/* Define if you have the pstat_getdynamic function. */
/* #undef HAVE_PSTAT_GETDYNAMIC */
/* Define if you have the setegid function. */
/* #undef HAVE_SETEGID */
/* Define if you have the seteuid function. */
/* #undef HAVE_SETEUID */
/* Define if you have the setlinebuf function. */
/* #undef HAVE_SETLINEBUF */
/* Define if you have the setregid function. */
/* #undef HAVE_SETREGID */
/* Define if you have the setreuid function. */
/* #undef HAVE_SETREUID */
/* Define if you have the sigsetmask function. */
/* #undef HAVE_SIGSETMASK */
/* Define if you have the socket function. */
/* #undef HAVE_SOCKET */
/* Define if you have the strcasecmp function. */
/* #undef HAVE_STRCASECMP */
/* Define if you have the strerror function. */
#undef HAVE_STRERROR
#define HAVE_STRERROR 1
/* Define if you have the strsignal function. */
/* #undef HAVE_STRSIGNAL */
/* Define if you have the wait3 function. */
/* #undef HAVE_WAIT3 */
/* Define if you have the waitpid function. */
/* #undef HAVE_WAITPID */
/* Define if you have the <dirent.h> header file. */
#undef HAVE_DIRENT_H
#define HAVE_DIRENT_H 1
/* Define if you have the <fcntl.h> header file. */
#undef HAVE_FCNTL_H
#define HAVE_FCNTL_H 1
/* Define if you have the <limits.h> header file. */
#undef HAVE_LIMITS_H
#define HAVE_LIMITS_H 1
/* Define if you have the <mach/mach.h> header file. */
/* #undef HAVE_MACH_MACH_H */
/* Define if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H
#define HAVE_MEMORY_H 1
/* Define if you have the <ndir.h> header file. */
/* #undef HAVE_NDIR_H */
/* Define if you have the <string.h> header file. */
#undef HAVE_STRING_H
#define HAVE_STRING_H 1
/* Define if you have the <sys/dir.h> header file. */
/* #undef HAVE_SYS_DIR_H */
/* Define if you have the <sys/ndir.h> header file. */
/* #undef HAVE_SYS_NDIR_H */
/* Define if you have the <sys/param.h> header file. */
/* #undef HAVE_SYS_PARAM_H */
/* Define if you have the <sys/timeb.h> header file. */
#undef HAVE_SYS_TIMEB_H
#define HAVE_SYS_TIMEB_H 1
/* Define if you have the <sys/wait.h> header file. */
/* #undef HAVE_SYS_WAIT_H */
/* Define if you have the <unistd.h> header file. */
/* #undef HAVE_UNISTD_H */
/* Define if you have the dgc library (-ldgc). */
/* #undef HAVE_LIBDGC */
/* Define if you have the kstat library (-lkstat). */
/* #undef HAVE_LIBKSTAT */
/* Define if you have the sun library (-lsun). */
/* #undef HAVE_LIBSUN */
/* Use high resolution file timestamps if nonzero. */
#define FILE_TIMESTAMP_HI_RES 0
/* Build host information. */
#define MAKE_HOST "Windows32"
/* Grok DOS paths (drive specs and backslash path element separators) */
#define HAVE_DOS_PATHS
/*
* Refer to README.W32 for info on the following settings
*/
/*
* If you have a shell that does not grok 'sh -c quoted-command-line'
* correctly, you need this setting. Please see below for specific
* shell support.
*/
#undef BATCH_MODE_ONLY_SHELL
#define BATCH_MODE_ONLY_SHELL 1
/*
* Define if you have the Cygnus "Cygwin" GNU Windows32 tool set.
* Do NOT define BATCH_MODE_ONLY_SHELL if you define HAVE_CYGWIN_SHELL
*/
#undef HAVE_CYGWIN_SHELL
/*
* Define if you have the MKS tool set or shell. Do NOT define
* BATCH_MODE_ONLY_SHELL if you define HAVE_MKS_SHELL
*/
#undef HAVE_MKS_SHELL
/*
* Enforce the mutual exclusivity restriction.
*/
#ifdef HAVE_MKS_SHELL
#undef BATCH_MODE_ONLY_SHELL
#endif
#ifdef HAVE_CYGWIN_SHELL
#undef BATCH_MODE_ONLY_SHELL
#endif
/* Define if you prefer Case Insensitive behavior */
#undef HAVE_CASE_INSENSITIVE_FS

4
config/.cvsignore Normal file
View File

@@ -0,0 +1,4 @@
*.m4
config.*
Makefile Makefile.in

14
config/ChangeLog Normal file
View File

@@ -0,0 +1,14 @@
2002-04-21 gettextize <bug-gnu-gettext@gnu.org>
* codeset.m4: New file, from gettext-0.11.1.
* gettext.m4: New file, from gettext-0.11.1.
* glibc21.m4: New file, from gettext-0.11.1.
* iconv.m4: New file, from gettext-0.11.1.
* isc-posix.m4: New file, from gettext-0.11.1.
* lcmessage.m4: New file, from gettext-0.11.1.
* lib-ld.m4: New file, from gettext-0.11.1.
* lib-link.m4: New file, from gettext-0.11.1.
* lib-prefix.m4: New file, from gettext-0.11.1.
* progtest.m4: New file, from gettext-0.11.1.
* Makefile.am: New file.

4
config/Makefile.am Normal file
View File

@@ -0,0 +1,4 @@
EXTRA_DIST = codeset.m4 gettext.m4 glibc21.m4 iconv.m4 isc-posix.m4 \
intdiv0.m4 inttypes-pri.m4 inttypes.m4 inttypes_h.m4 \
isc-posix.m4 lcmessage.m4 lib-ld.m4 lib-link.m4 lib-prefix.m4 \
progtest.m4 stdint_h.m4 uintmax_t.m4 ulonglong.m4

94
configh.dos.template Normal file
View File

@@ -0,0 +1,94 @@
/* Many things are defined already by a system header. */
#include <sys/config.h>
#if __DJGPP__ > 2 || __DJGPP_MINOR__ > 1
/* Define if `sys_siglist' is declared by <signal.h>. */
# define SYS_SIGLIST_DECLARED 1
/* Define this if the C library defines the variable `_sys_siglist'. */
# define HAVE_SYS_SIGLIST 1
#else
/* Define NSIG. */
# define NSIG SIGMAX
#endif
/* Use high resolution file timestamps if nonzero. */
#define FILE_TIMESTAMP_HI_RES 0
/* Define to 1 if you have `alloca', as a function or macro. */
#define HAVE_ALLOCA 1
/* Define if you have the fdopen function. */
#define HAVE_FDOPEN 1
/* Define to 1 if you have the `getgroups' function. */
#define HAVE_GETGROUPS 1
/* Define if you have the <memory.h> header file. */
#define HAVE_MEMORY_H 1
/* Define if you have the mkstemp function. */
#define HAVE_MKSTEMP 1
/* Define to 1 if you have the `mktemp' function. */
#define HAVE_MKTEMP 1
/* Define to 1 if you have the `setlinebuf' function. */
#define HAVE_SETLINEBUF 1
/* Define to 1 if you have the `setvbuf' function. */
#define HAVE_SETVBUF 1
#define SCCS_GET "get"
/* Define to `unsigned long' or `unsigned long long'
if <inttypes.h> doesn't define. */
#define uintmax_t unsigned long long
/* Define the type of the first arg to select(). */
#define fd_set_size_t int
/* Define if you have the select function. */
#define HAVE_SELECT 1
/* Define if you have the vprintf library function. */
#undef HAVE_VPRINTF
#define HAVE_VPRINTF 1
/* Name of the package */
#define PACKAGE "%PACKAGE%"
/* Define to the address where bug reports for this package should be sent. */
#define PACKAGE_BUGREPORT "bug-%PACKAGE%@gnu.org"
/* Define to the full name of this package. */
#define PACKAGE_NAME "GNU %PACKAGE%"
/* Define to the full name and version of this package. */
#define PACKAGE_STRING "GNU %PACKAGE% %VERSION%"
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "%PACKAGE%"
/* Define to the version of this package. */
#define PACKAGE_VERSION "%VERSION%"
/* Define to 1 if the C compiler supports function prototypes. */
#define PROTOTYPES 1
/* Define to 1 if `sys_siglist' is declared by <signal.h> or <unistd.h>. */
#define SYS_SIGLIST_DECLARED 1
/* Version number of package */
#define VERSION "%VERSION%"
/* Build host information. */
#define MAKE_HOST "i386-pc-msdosdjgpp"
/* Grok DOS paths (drive specs and backslash path element separators) */
#define HAVE_DOS_PATHS

44
configure.bat Normal file
View File

@@ -0,0 +1,44 @@
@echo off
echo Configuring MAKE for DJGPP
rem The SmallEnv trick protects against too small environment block,
rem in which case the values will be truncated and the whole thing
rem goes awry. COMMAND.COM will say "Out of environment space", but
rem many people don't care, so we force them to care by refusing to go.
rem Where is the srcdir?
set XSRC=.
if not "%XSRC%"=="." goto SmallEnv
if "%1%"=="" goto SrcDone
set XSRC=%1
if not "%XSRC%"=="%1" goto SmallEnv
:SrcDone
update %XSRC%/configh.dos ./config.h
rem Do they have Make?
redir -o junk.$$$ -eo make -n -f NUL
rem REDIR will return 1 if it cannot run Make.
rem If it can run Make, it will usually return 2,
rem but 0 is also OK with us.
if errorlevel 2 goto MakeOk
if not errorlevel 1 goto MakeOk
if exist junk.$$$ del junk.$$$
echo No Make program found--use DOSBUILD.BAT to build Make.
goto End
rem They do have Make. Generate the Makefile.
:MakeOk
del junk.$$$
update %XSRC%/Makefile.DOS ./Makefile
echo Done.
if not "%XSRC%"=="." echo Invoke Make thus: "make srcdir=%XSRC%"
goto End
:SmallEnv
echo Your environment is too small. Please enlarge it and run me again.
:End
set XRSC=

390
configure.in Normal file
View File

@@ -0,0 +1,390 @@
# Process this file with autoconf to produce a configure script.
AC_INIT(GNU make,3.80,bug-make@gnu.org)
AC_PREREQ(2.54)
AC_REVISION([[$Id$]])
# Autoconf setup
AC_CONFIG_AUX_DIR(config)
AC_CONFIG_SRCDIR(vpath.c)
AC_CONFIG_HEADERS(config.h)
# Automake setup
AM_INIT_AUTOMAKE
AC_PROG_MAKE_SET
# Checks for programs.
AC_PROG_CC
AC_PROG_INSTALL
AC_PROG_RANLIB
AC_PROG_CPP
AC_CHECK_PROG(AR, ar, ar, ar)
# Perl is needed for the test suite (only)
AC_CHECK_PROG(PERL, perl, perl, perl)
# Specialized system macros
AC_CANONICAL_HOST
AC_AIX
AC_ISC_POSIX
AC_MINIX
# Enable gettext, in "external" mode.
AM_GNU_GETTEXT_VERSION(0.11.5)
AM_GNU_GETTEXT([external])
# This test must come as early as possible after the compiler configuration
# tests, because the choice of the file model can (in principle) affect
# whether functions and headers are available, whether they work, etc.
AC_SYS_LARGEFILE
# Checks for libraries.
AC_SEARCH_LIBS(getpwnam, [sun])
# Checks for header files.
AC_HEADER_STDC
AC_HEADER_DIRENT
AC_HEADER_STAT
AC_HEADER_TIME
AC_CHECK_HEADERS(stdlib.h locale.h unistd.h limits.h fcntl.h string.h \
memory.h sys/param.h sys/time.h sys/timeb.h)
AM_PROG_CC_C_O
AM_PROG_CC_STDC
AC_C_CONST
AC_TYPE_SIGNAL
AC_TYPE_UID_T
AC_TYPE_PID_T
# Find some definition for uintmax_t
AC_CHECK_TYPE(uintmax_t,,[
uintmax_t="unsigned long"
AC_CHECK_TYPE(unsigned long long,[uintmax_t="unsigned long long"])
AC_DEFINE_UNQUOTED(uintmax_t,$uintmax_t,[Define uintmax_t if not defined in <stdint.h> or <inttypes.h>.])])
# Find out whether our struct stat returns nanosecond resolution timestamps.
AC_STRUCT_ST_MTIM_NSEC
AC_MSG_CHECKING([whether to use high resolution file timestamps])
AC_CACHE_VAL(make_cv_file_timestamp_hi_res, [
make_cv_file_timestamp_hi_res=no
if test "$ac_cv_struct_st_mtim_nsec" != no; then
AC_TRY_COMPILE([
# if HAVE_INTTYPES_H
# include <inttypes.h>
# endif],
[char a[0x7fffffff < (uintmax_t) -1 >> 30 ? 1 : -1];],
make_cv_file_timestamp_hi_res=yes)
fi])
AC_MSG_RESULT($make_cv_file_timestamp_hi_res)
if test "$make_cv_file_timestamp_hi_res" = yes; then
val=1
else
val=0
fi
AC_DEFINE_UNQUOTED(FILE_TIMESTAMP_HI_RES, $val,
[Use high resolution file timestamps if nonzero.])
if test "$make_cv_file_timestamp_hi_res" = yes; then
# Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
# Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
AC_SEARCH_LIBS(clock_gettime, [rt posix4])
if test "$ac_cv_search_clock_gettime" != no; then
AC_DEFINE(HAVE_CLOCK_GETTIME, 1,
[Define if you have the clock_gettime function.])
fi
fi
# See if we have a standard version of gettimeofday(). Since actual
# implementations can differ, just make sure we have the most common
# one.
AC_CACHE_CHECK([for standard gettimeofday], ac_cv_func_gettimeofday,
[ac_cv_func_gettimeofday=no
AC_TRY_RUN([#include <sys/time.h>
int main ()
{
struct timeval t; t.tv_sec = -1; t.tv_usec = -1;
exit (gettimeofday (&t, 0) != 0
|| t.tv_sec < 0 || t.tv_usec < 0);
}],
ac_cv_func_gettimeofday=yes,
ac_cv_func_gettimeofday=no,
ac_cv_func_gettimeofday="no (cross-compiling)")])
if test "$ac_cv_func_gettimeofday" = yes; then
AC_DEFINE(HAVE_GETTIMEOFDAY, 1,
[Define if you have a standard gettimeofday function])
fi
AC_CHECK_FUNCS( memcpy memmove strchr strdup mkstemp mktemp fdopen \
bsd_signal dup2 getcwd sigsetmask sigaction getgroups \
seteuid setegid setlinebuf setreuid setregid setvbuf pipe \
strerror strsignal)
make_FUNC_SETVBUF_REVERSED
# strcoll() is used by the GNU glob library
AC_FUNC_STRCOLL
AC_FUNC_ALLOCA
AC_FUNC_VFORK
AC_FUNC_VPRINTF
AC_FUNC_CLOSEDIR_VOID
AC_FUNC_GETLOADAVG
# AC_FUNC_GETLOADAVG is documented to set the NLIST_STRUCT value, but it
# doesn't. So, we will.
if test "$ac_cv_header_nlist_h" = yes; then
AC_TRY_COMPILE([#include <nlist.h>],
[struct nlist nl;
nl.n_name = "string";
return 0;],
make_cv_nlist_struct=yes,
make_cv_nlist_struct=no)
if test "$make_cv_nlist_struct" = yes; then
AC_DEFINE(NLIST_STRUCT, 1,
[Define if struct nlist.n_name is a pointer rather than an array.])
fi
fi
AC_DECL_SYS_SIGLIST
# Check out the wait reality.
AC_CHECK_HEADERS(sys/wait.h)
AC_CHECK_FUNCS(waitpid wait3)
AC_MSG_CHECKING(for union wait)
AC_CACHE_VAL(make_cv_union_wait, [dnl
AC_TRY_LINK([#include <sys/types.h>
#include <sys/wait.h>],
[union wait status; int pid; pid = wait (&status);
#ifdef WEXITSTATUS
/* Some POSIXoid systems have both the new-style macros and the old
union wait type, and they do not work together. If union wait
conflicts with WEXITSTATUS et al, we don't want to use it at all. */
if (WEXITSTATUS (status) != 0) pid = -1;
#ifdef WTERMSIG
/* If we have WEXITSTATUS and WTERMSIG, just use them on ints. */
-- blow chunks here --
#endif
#endif
#ifdef HAVE_WAITPID
/* Make sure union wait works with waitpid. */
pid = waitpid (-1, &status, 0);
#endif
],
[make_cv_union_wait=yes], [make_cv_union_wait=no])])
if test "$make_cv_union_wait" = yes; then
AC_DEFINE(HAVE_UNION_WAIT, 1, [Define this if you have the \`union wait' type in <sys/wait.h>.])
fi
AC_MSG_RESULT($make_cv_union_wait)
# See if the user wants to use pmake's "customs" distributed build capability
use_customs=false
AC_ARG_WITH(customs,
AC_HELP_STRING([--with-customs=DIR],
[enable remote jobs via Customs--see README.customs]),
[case $withval in
n|no) : ;;
*) make_cppflags="$CPPFLAGS"
case $withval in
y|ye|yes) : ;;
*) CPPFLAGS="$CPPFLAGS -I$with_customs/include/customs"
make_ldflags="$LDFLAGS -L$with_customs/lib" ;;
esac
CF_NETLIBS
AC_CHECK_HEADER(customs.h,
[use_customs=true
LIBS="$LIBS -lcustoms" LDFLAGS="$make_ldflags"],
[with_customs=no
CPPFLAGS="$make_cppflags" make_badcust=yes])
;;
esac])
# Tell automake about this, so it can include the right .c files.
AM_CONDITIONAL(USE_CUSTOMS, test "$use_customs" = true)
# See if we can handle the job server feature, and if the user wants it.
AC_ARG_ENABLE(job-server,
AC_HELP_STRING([--disable-job-server],
[disallow recursive make communication during -jN]),
[make_cv_job_server="$enableval" user_job_server="$enableval"],
[make_cv_job_server="yes"])
has_wait_nohang=yes
case "$ac_cv_func_waitpid/$ac_cv_func_wait3" in
no/no) has_wait_nohang=no ;;
esac
AC_CACHE_CHECK(for SA_RESTART, make_cv_sa_restart, [
AC_TRY_COMPILE([#include <signal.h>],
[return SA_RESTART;],
make_cv_sa_restart=yes,
make_cv_sa_restart=no)])
if test "$make_cv_sa_restart" != no; then
AC_DEFINE(HAVE_SA_RESTART, 1,
[Define if <signal.h> defines the SA_RESTART constant.])
fi
case "$ac_cv_func_pipe/$ac_cv_func_sigaction/$make_cv_sa_restart/$has_wait_nohang/$make_cv_job_server" in
yes/yes/yes/yes/yes)
AC_DEFINE(MAKE_JOBSERVER, 1,
[Define this to enable job server support in GNU make.]);;
esac
# Find the SCCS commands, so we can include them in our default rules.
AC_CACHE_CHECK(for location of SCCS get command, make_cv_path_sccs_get, [
if test -f /usr/sccs/get; then
make_cv_path_sccs_get=/usr/sccs/get
else
make_cv_path_sccs_get=get
fi])
AC_DEFINE_UNQUOTED(SCCS_GET, ["$make_cv_path_sccs_get"], [Define to the name of the SCCS 'get' command.])
ac_clean_files="$ac_clean_files s.conftest conftoast" # Remove these later.
if ( /usr/sccs/admin -n s.conftest || admin -n s.conftest ) >/dev/null 2>&1 &&
test -f s.conftest; then
# We successfully created an SCCS file.
AC_CACHE_CHECK(if SCCS get command understands -G, make_cv_sys_get_minus_G, [
if $make_cv_path_sccs_get -Gconftoast s.conftest >/dev/null 2>&1 &&
test -f conftoast; then
make_cv_sys_get_minus_G=yes
else
make_cv_sys_get_minus_G=no
fi])
case "$make_cv_sys_get_minus_G" in
yes) AC_DEFINE(SCCS_GET_MINUS_G, 1,
[Define this if the SCCS 'get' command understands the '-G<file>' option.]);;
esac
fi
rm -f s.conftest conftoast
# Check the system to see if it provides GNU glob. If not, use our
# local version.
AC_MSG_CHECKING(if system libc has GNU glob)
AC_CACHE_VAL(make_cv_sys_gnu_glob, [
AC_EGREP_CPP(gnu glob,[
#include <features.h>
#include <glob.h>
#include <fnmatch.h>
#define GLOB_INTERFACE_VERSION 1
#if !defined _LIBC && defined __GNU_LIBRARY__ && __GNU_LIBRARY__ > 1
# include <gnu-versions.h>
# if _GNU_GLOB_INTERFACE_VERSION == GLOB_INTERFACE_VERSION
gnu glob
# endif
#endif
], [AC_MSG_RESULT(yes)
make_cv_sys_gnu_glob=yes], [AC_MSG_RESULT([no; using local copy])
AC_SUBST(GLOBINC) GLOBINC='-I$(srcdir)/glob'
AC_SUBST(GLOBLIB) GLOBLIB=glob/libglob.a
make_cv_sys_gnu_glob=no])])
# Tell automake about this, so it can build the right .c files.
AM_CONDITIONAL(USE_LOCAL_GLOB, test "$make_cv_sys_gnu_glob" = no)
# PTX systems have a broken implementation of SA_RESTART. I know of
# no way to test for this behavior, so I'll just test for PTX
case "$host" in
i386-sequent-sysv4)
AC_DEFINE(HAVE_BROKEN_RESTART, 1, [This system has SA_RESTART, but it doesn't work properly.])
echo ""
echo "WARNING: The SA_RESTART sigaction() flag does not work on PTX."
echo " This causes 'make -j' to fail at random times."
echo " I am installing a workaround, which is mostly but not 100%"
echo " effective. If you see random failures during 'make -j'"
echo " you should either contact the bug list, or not use -j."
echo "" ;;
esac
# Let the makefile know what our build host is
AC_DEFINE_UNQUOTED(MAKE_HOST,"$host",[Build host information.])
MAKE_HOST="$host"
AC_SUBST(MAKE_HOST)
# Include the Maintainer's Makefile section, if it's here.
MAINT_MAKEFILE=/dev/null
if test -r "$srcdir/maintMakefile"; then
MAINT_MAKEFILE="$srcdir/maintMakefile"
fi
AC_SUBST_FILE(MAINT_MAKEFILE)
# Allow building with dmalloc
AM_WITH_DMALLOC
# Sanity check and inform the user of what we found
case "$make_badcust" in
yes) echo
echo "WARNING: --with-customs specified but no customs.h could be found;"
echo " disabling Customs support."
echo ;;
esac
case "$with_customs" in
""|n|no|y|ye|yes) ;;
*) if test -f "$with_customs/lib/libcustoms.a"; then
:
else
echo
echo "WARNING: '$with_customs/lib' does not appear to contain the"
echo " Customs library. You must build and install Customs"
echo " before compiling GNU make."
echo
fi ;;
esac
case "$has_wait_nohang" in
no) echo
echo "WARNING: Your system has neither waitpid() nor wait3()."
echo " Without one of these, signal handling is unreliable."
echo " You should be aware that running GNU make with -j"
echo " could result in erratic behavior."
echo ;;
esac
case "$make_cv_job_server/$user_job_server" in
no/yes) echo
echo "WARNING: Make job server requires a POSIX-ish system that"
echo " supports the pipe(), sigaction(), and either"
echo " waitpid() or wait3() functions. Your system doesn't"
echo " appear to provide one or more of those."
echo " Disabling job server support."
echo ;;
esac
# Specify what files are to be created.
# We only generate the build.sh if we have a build.sh.in; we won't have
# one before we've created a distribution.
AC_CONFIG_FILES(Makefile glob/Makefile po/Makefile.in config/Makefile doc/Makefile)
if test -f $srcdir/build.sh.in; then
AC_CONFIG_FILES(build.sh)
fi
# OK, do it!
AC_OUTPUT
dnl Local Variables:
dnl comment-start: "dnl "
dnl comment-end: ""
dnl comment-start-skip: "\\bdnl\\b\\s *"
dnl compile-command: "make configure config.h.in"
dnl End:

41
debug.h Normal file
View File

@@ -0,0 +1,41 @@
/* Debugging macros and interface.
Copyright (C) 1999 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#define DB_NONE (0x000)
#define DB_BASIC (0x001)
#define DB_VERBOSE (0x002)
#define DB_JOBS (0x004)
#define DB_IMPLICIT (0x008)
#define DB_MAKEFILES (0x100)
#define DB_ALL (0xfff)
extern int db_level;
#define ISDB(_l) ((_l)&db_level)
#define DBS(_l,_x) do{ if(ISDB(_l)) {print_spaces (depth); \
printf _x; fflush (stdout);} }while(0)
#define DBF(_l,_x) do{ if(ISDB(_l)) {print_spaces (depth); \
printf (_x, file->name); \
fflush (stdout);} }while(0)
#define DB(_l,_x) do{ if(ISDB(_l)) {printf _x; fflush (stdout);} }while(0)

585
default.c Normal file
View File

@@ -0,0 +1,585 @@
/* Data base of default implicit rules for GNU Make.
Copyright (C) 1988,89,90,91,92,93,94,95,96 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "make.h"
#include "rule.h"
#include "dep.h"
#include "filedef.h"
#include "job.h"
#include "commands.h"
#include "variable.h"
/* Define GCC_IS_NATIVE if gcc is the native development environment on
your system (gcc/bison/flex vs cc/yacc/lex). */
#ifdef __MSDOS__
#define GCC_IS_NATIVE
#endif
/* This is the default list of suffixes for suffix rules.
`.s' must come last, so that a `.o' file will be made from
a `.c' or `.p' or ... file rather than from a .s file. */
static char default_suffixes[]
#ifdef VMS
= ".exe .olb .ln .obj .c .cxx .cc .pas .p .for .f .r .y .l .mar \
.s .ss .i .ii .mod .sym .def .h .info .dvi .tex .texinfo .texi .txinfo \
.w .ch .cweb .web .com .sh .elc .el";
#else
= ".out .a .ln .o .c .cc .C .cpp .p .f .F .r .y .l .s .S \
.mod .sym .def .h .info .dvi .tex .texinfo .texi .txinfo \
.w .ch .web .sh .elc .el";
#endif
static struct pspec default_pattern_rules[] =
{
{ "(%)", "%",
"$(AR) $(ARFLAGS) $@ $<" },
/* The X.out rules are only in BSD's default set because
BSD Make has no null-suffix rules, so `foo.out' and
`foo' are the same thing. */
#ifdef VMS
{ "%.exe", "%",
"copy $< $@" },
#else
{ "%.out", "%",
"@rm -f $@ \n cp $< $@" },
#endif
/* Syntax is "ctangle foo.w foo.ch foo.c". */
{ "%.c", "%.w %.ch",
"$(CTANGLE) $^ $@" },
{ "%.tex", "%.w %.ch",
"$(CWEAVE) $^ $@" },
{ 0, 0, 0 }
};
static struct pspec default_terminal_rules[] =
{
#ifdef VMS
/* RCS. */
{ "%", "%$$5lv", /* Multinet style */
"if f$$search($@) .nes. \"\" then +$(CHECKOUT,v)" },
{ "%", "[.$$rcs]%$$5lv", /* Multinet style */
"if f$$search($@) .nes. \"\" then +$(CHECKOUT,v)" },
{ "%", "%_v", /* Normal style */
"if f$$search($@) .nes. \"\" then +$(CHECKOUT,v)" },
{ "%", "[.rcs]%_v", /* Normal style */
"if f$$search($@) .nes. \"\" then +$(CHECKOUT,v)" },
/* SCCS. */
/* ain't no SCCS on vms */
#else
/* RCS. */
{ "%", "%,v",
"$(CHECKOUT,v)" },
{ "%", "RCS/%,v",
"$(CHECKOUT,v)" },
{ "%", "RCS/%",
"$(CHECKOUT,v)" },
/* SCCS. */
{ "%", "s.%",
"$(GET) $(GFLAGS) $(SCCS_OUTPUT_OPTION) $<" },
{ "%", "SCCS/s.%",
"$(GET) $(GFLAGS) $(SCCS_OUTPUT_OPTION) $<" },
#endif /* !VMS */
{ 0, 0, 0 }
};
static char *default_suffix_rules[] =
{
#ifdef VMS
".obj.exe",
"$(LINK.obj) $^ $(LOADLIBES) $(LDLIBS) $(CRT0) /exe=$@",
".mar.exe",
"$(COMPILE.mar) $^ \n $(LINK.obj) $(subst .mar,.obj,$^) $(LOADLIBES) $(LDLIBS) $(CRT0) /exe=$@",
".s.exe",
"$(COMPILE.s) $^ \n $(LINK.obj) $(subst .s,.obj,$^) $(LOADLIBES) $(LDLIBS) $(CRT0) /exe=$@",
".c.exe",
"$(COMPILE.c) $^ \n $(LINK.obj) $(subst .c,.obj,$^) $(LOADLIBES) $(LDLIBS) $(CRT0) /exe=$@",
".cc.exe",
#ifdef GCC_IS_NATIVE
"$(COMPILE.cc) $^ \n $(LINK.obj) $(CXXSTARTUP),sys$$disk:[]$(subst .cc,.obj,$^) $(LOADLIBES) $(LXLIBS) $(LDLIBS) $(CXXRT0) /exe=$@",
#else
"$(COMPILE.cc) $^ \n $(CXXLINK.obj) $(subst .cc,.obj,$^) $(LOADLIBES) $(LXLIBS) $(LDLIBS) $(CXXRT0) /exe=$@",
".cxx.exe",
"$(COMPILE.cxx) $^ \n $(CXXLINK.obj) $(subst .cxx,.obj,$^) $(LOADLIBES) $(LXLIBS) $(LDLIBS) $(CXXRT0) /exe=$@",
#endif
".for.exe",
"$(COMPILE.for) $^ \n $(LINK.obj) $(subst .for,.obj,$^) $(LOADLIBES) $(LDLIBS) /exe=$@",
".pas.exe",
"$(COMPILE.pas) $^ \n $(LINK.obj) $(subst .pas,.obj,$^) $(LOADLIBES) $(LDLIBS) /exe=$@",
".com",
"copy $< >$@",
".mar.obj",
"$(COMPILE.mar) /obj=$@ $<",
".s.obj",
"$(COMPILE.s) /obj=$@ $<",
".ss.obj",
"$(COMPILE.s) /obj=$@ $<",
".c.i",
"$(COMPILE.c)/prep /list=$@ $<",
".c.s",
"$(COMPILE.c)/noobj/machine /list=$@ $<",
".i.s",
"$(COMPILE.c)/noprep/noobj/machine /list=$@ $<",
".c.obj",
"$(COMPILE.c) /obj=$@ $<",
".cc.ii",
"$(COMPILE.cc)/prep /list=$@ $<",
".cc.ss",
"$(COMPILE.cc)/noobj/machine /list=$@ $<",
".ii.ss",
"$(COMPILE.cc)/noprep/noobj/machine /list=$@ $<",
".cc.obj",
"$(COMPILE.cc) /obj=$@ $<",
".for.obj",
"$(COMPILE.for) /obj=$@ $<",
".pas.obj",
"$(COMPILE.pas) /obj=$@ $<",
".y.c",
"$(YACC.y) $< \n rename y_tab.c $@",
".l.c",
"$(LEX.l) $< \n rename lexyy.c $@",
".texinfo.info",
"$(MAKEINFO) $<",
".tex.dvi",
"$(TEX) $<",
#else /* ! VMS */
".o",
"$(LINK.o) $^ $(LOADLIBES) $(LDLIBS) -o $@",
".s",
"$(LINK.s) $^ $(LOADLIBES) $(LDLIBS) -o $@",
".S",
"$(LINK.S) $^ $(LOADLIBES) $(LDLIBS) -o $@",
".c",
"$(LINK.c) $^ $(LOADLIBES) $(LDLIBS) -o $@",
".cc",
"$(LINK.cc) $^ $(LOADLIBES) $(LDLIBS) -o $@",
".C",
"$(LINK.C) $^ $(LOADLIBES) $(LDLIBS) -o $@",
".cpp",
"$(LINK.cpp) $^ $(LOADLIBES) $(LDLIBS) -o $@",
".f",
"$(LINK.f) $^ $(LOADLIBES) $(LDLIBS) -o $@",
".p",
"$(LINK.p) $^ $(LOADLIBES) $(LDLIBS) -o $@",
".F",
"$(LINK.F) $^ $(LOADLIBES) $(LDLIBS) -o $@",
".r",
"$(LINK.r) $^ $(LOADLIBES) $(LDLIBS) -o $@",
".mod",
"$(COMPILE.mod) -o $@ -e $@ $^",
".def.sym",
"$(COMPILE.def) -o $@ $<",
".sh",
"cat $< >$@ \n chmod a+x $@",
".s.o",
"$(COMPILE.s) -o $@ $<",
".S.o",
"$(COMPILE.S) -o $@ $<",
".c.o",
"$(COMPILE.c) $(OUTPUT_OPTION) $<",
".cc.o",
"$(COMPILE.cc) $(OUTPUT_OPTION) $<",
".C.o",
"$(COMPILE.C) $(OUTPUT_OPTION) $<",
".cpp.o",
"$(COMPILE.cpp) $(OUTPUT_OPTION) $<",
".f.o",
"$(COMPILE.f) $(OUTPUT_OPTION) $<",
".p.o",
"$(COMPILE.p) $(OUTPUT_OPTION) $<",
".F.o",
"$(COMPILE.F) $(OUTPUT_OPTION) $<",
".r.o",
"$(COMPILE.r) $(OUTPUT_OPTION) $<",
".mod.o",
"$(COMPILE.mod) -o $@ $<",
".c.ln",
"$(LINT.c) -C$* $<",
".y.ln",
#ifndef __MSDOS__
"$(YACC.y) $< \n $(LINT.c) -C$* y.tab.c \n $(RM) y.tab.c",
#else
"$(YACC.y) $< \n $(LINT.c) -C$* y_tab.c \n $(RM) y_tab.c",
#endif
".l.ln",
"@$(RM) $*.c\n $(LEX.l) $< > $*.c\n$(LINT.c) -i $*.c -o $@\n $(RM) $*.c",
".y.c",
#ifndef __MSDOS__
"$(YACC.y) $< \n mv -f y.tab.c $@",
#else
"$(YACC.y) $< \n mv -f y_tab.c $@",
#endif
".l.c",
"@$(RM) $@ \n $(LEX.l) $< > $@",
".F.f",
"$(PREPROCESS.F) $(OUTPUT_OPTION) $<",
".r.f",
"$(PREPROCESS.r) $(OUTPUT_OPTION) $<",
/* This might actually make lex.yy.c if there's no %R%
directive in $*.l, but in that case why were you
trying to make $*.r anyway? */
".l.r",
"$(LEX.l) $< > $@ \n mv -f lex.yy.r $@",
".S.s",
"$(PREPROCESS.S) $< > $@",
".texinfo.info",
"$(MAKEINFO) $(MAKEINFO_FLAGS) $< -o $@",
".texi.info",
"$(MAKEINFO) $(MAKEINFO_FLAGS) $< -o $@",
".txinfo.info",
"$(MAKEINFO) $(MAKEINFO_FLAGS) $< -o $@",
".tex.dvi",
"$(TEX) $<",
".texinfo.dvi",
"$(TEXI2DVI) $(TEXI2DVI_FLAGS) $<",
".texi.dvi",
"$(TEXI2DVI) $(TEXI2DVI_FLAGS) $<",
".txinfo.dvi",
"$(TEXI2DVI) $(TEXI2DVI_FLAGS) $<",
".w.c",
"$(CTANGLE) $< - $@", /* The `-' says there is no `.ch' file. */
".web.p",
"$(TANGLE) $<",
".w.tex",
"$(CWEAVE) $< - $@", /* The `-' says there is no `.ch' file. */
".web.tex",
"$(WEAVE) $<",
#endif /* !VMS */
0, 0,
};
static char *default_variables[] =
{
#ifdef VMS
#ifdef __ALPHA
"ARCH", "ALPHA",
#else
"ARCH", "VAX",
#endif
"AR", "library/obj",
"ARFLAGS", "/replace",
"AS", "macro",
"MACRO", "macro",
#ifdef GCC_IS_NATIVE
"CC", "gcc",
#else
"CC", "cc",
#endif
"CD", "builtin_cd",
"MAKE", "make",
"ECHO", "write sys$$output \"",
#ifdef GCC_IS_NATIVE
"C++", "gcc/plus",
"CXX", "gcc/plus",
#else
"C++", "cxx",
"CXX", "cxx",
"CXXLD", "cxxlink",
#endif
"CO", "co",
"CPP", "$(CC) /preprocess_only",
"FC", "fortran",
/* System V uses these, so explicit rules using them should work.
However, there is no way to make implicit rules use them and FC. */
"F77", "$(FC)",
"F77FLAGS", "$(FFLAGS)",
"LD", "link",
"LEX", "lex",
"PC", "pascal",
"YACC", "bison/yacc",
"YFLAGS", "/Define/Verbose",
"BISON", "bison",
"MAKEINFO", "makeinfo",
"TEX", "tex",
"TEXINDEX", "texindex",
"RM", "delete/nolog",
"CSTARTUP", "",
#ifdef GCC_IS_NATIVE
"CRT0", ",sys$$library:vaxcrtl.olb/lib,gnu_cc_library:crt0.obj",
"CXXSTARTUP", "gnu_cc_library:crtbegin.obj",
"CXXRT0", ",sys$$library:vaxcrtl.olb/lib,gnu_cc_library:crtend.obj,gnu_cc_library:gxx_main.obj",
"LXLIBS", ",gnu_cc_library:libstdcxx.olb/lib,gnu_cc_library:libgccplus.olb/lib",
"LDLIBS", ",gnu_cc_library:libgcc.olb/lib",
#else
"CRT0", "",
"CXXSTARTUP", "",
"CXXRT0", "",
"LXLIBS", "",
"LDLIBS", "",
#endif
"LINK.obj", "$(LD) $(LDFLAGS)",
#ifndef GCC_IS_NATIVE
"CXXLINK.obj", "$(CXXLD) $(LDFLAGS)",
"COMPILE.cxx", "$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(TARGET_ARCH)",
#endif
"COMPILE.c", "$(CC) $(CFLAGS) $(CPPFLAGS) $(TARGET_ARCH)",
"COMPILE.cc", "$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(TARGET_ARCH)",
"YACC.y", "$(YACC) $(YFLAGS)",
"LEX.l", "$(LEX) $(LFLAGS)",
"COMPILE.for", "$(FC) $(FFLAGS) $(TARGET_ARCH)",
"COMPILE.pas", "$(PC) $(PFLAGS) $(CPPFLAGS) $(TARGET_ARCH)",
"COMPILE.mar", "$(MACRO) $(MACROFLAGS)",
"COMPILE.s", "$(AS) $(ASFLAGS) $(TARGET_MACH)",
"LINT.c", "$(LINT) $(LINTFLAGS) $(CPPFLAGS) $(TARGET_ARCH)",
"MV", "rename/new_version",
"CP", "copy",
#else /* !VMS */
"AR", "ar",
"ARFLAGS", "rv",
"AS", "as",
#ifdef GCC_IS_NATIVE
"CC", "gcc",
# ifdef __MSDOS__
"CXX", "gpp", /* g++ is an invalid name on MSDOS */
# else
"CXX", "gcc",
# endif /* __MSDOS__ */
#else
"CC", "cc",
"CXX", "g++",
#endif
/* This expands to $(CO) $(COFLAGS) $< $@ if $@ does not exist,
and to the empty string if $@ does exist. */
"CHECKOUT,v", "+$(if $(wildcard $@),,$(CO) $(COFLAGS) $< $@)",
"CO", "co",
"COFLAGS", "",
"CPP", "$(CC) -E",
#ifdef CRAY
"CF77PPFLAGS", "-P",
"CF77PP", "/lib/cpp",
"CFT", "cft77",
"CF", "cf77",
"FC", "$(CF)",
#else /* Not CRAY. */
#ifdef _IBMR2
"FC", "xlf",
#else
#ifdef __convex__
"FC", "fc",
#else
"FC", "f77",
#endif /* __convex__ */
#endif /* _IBMR2 */
/* System V uses these, so explicit rules using them should work.
However, there is no way to make implicit rules use them and FC. */
"F77", "$(FC)",
"F77FLAGS", "$(FFLAGS)",
#endif /* Cray. */
"GET", SCCS_GET,
"LD", "ld",
#ifdef GCC_IS_NATIVE
"LEX", "flex",
#else
"LEX", "lex",
#endif
"LINT", "lint",
"M2C", "m2c",
#ifdef pyr
"PC", "pascal",
#else
#ifdef CRAY
"PC", "PASCAL",
"SEGLDR", "segldr",
#else
"PC", "pc",
#endif /* CRAY. */
#endif /* pyr. */
#ifdef GCC_IS_NATIVE
"YACC", "bison -y",
#else
"YACC", "yacc", /* Or "bison -y" */
#endif
"MAKEINFO", "makeinfo",
"TEX", "tex",
"TEXI2DVI", "texi2dvi",
"WEAVE", "weave",
"CWEAVE", "cweave",
"TANGLE", "tangle",
"CTANGLE", "ctangle",
"RM", "rm -f",
"LINK.o", "$(CC) $(LDFLAGS) $(TARGET_ARCH)",
"COMPILE.c", "$(CC) $(CFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -c",
"LINK.c", "$(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) $(TARGET_ARCH)",
"COMPILE.cc", "$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -c",
"COMPILE.C", "$(COMPILE.cc)",
"COMPILE.cpp", "$(COMPILE.cc)",
"LINK.cc", "$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) $(TARGET_ARCH)",
"LINK.C", "$(LINK.cc)",
"LINK.cpp", "$(LINK.cc)",
"YACC.y", "$(YACC) $(YFLAGS)",
"LEX.l", "$(LEX) $(LFLAGS) -t",
"COMPILE.f", "$(FC) $(FFLAGS) $(TARGET_ARCH) -c",
"LINK.f", "$(FC) $(FFLAGS) $(LDFLAGS) $(TARGET_ARCH)",
"COMPILE.F", "$(FC) $(FFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -c",
"LINK.F", "$(FC) $(FFLAGS) $(CPPFLAGS) $(LDFLAGS) $(TARGET_ARCH)",
"COMPILE.r", "$(FC) $(FFLAGS) $(RFLAGS) $(TARGET_ARCH) -c",
"LINK.r", "$(FC) $(FFLAGS) $(RFLAGS) $(LDFLAGS) $(TARGET_ARCH)",
"COMPILE.def", "$(M2C) $(M2FLAGS) $(DEFFLAGS) $(TARGET_ARCH)",
"COMPILE.mod", "$(M2C) $(M2FLAGS) $(MODFLAGS) $(TARGET_ARCH)",
"COMPILE.p", "$(PC) $(PFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -c",
"LINK.p", "$(PC) $(PFLAGS) $(CPPFLAGS) $(LDFLAGS) $(TARGET_ARCH)",
"LINK.s", "$(CC) $(ASFLAGS) $(LDFLAGS) $(TARGET_MACH)",
"COMPILE.s", "$(AS) $(ASFLAGS) $(TARGET_MACH)",
"LINK.S", "$(CC) $(ASFLAGS) $(CPPFLAGS) $(LDFLAGS) $(TARGET_MACH)",
"COMPILE.S", "$(CC) $(ASFLAGS) $(CPPFLAGS) $(TARGET_MACH) -c",
"PREPROCESS.S", "$(CC) -E $(CPPFLAGS)",
"PREPROCESS.F", "$(FC) $(FFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -F",
"PREPROCESS.r", "$(FC) $(FFLAGS) $(RFLAGS) $(TARGET_ARCH) -F",
"LINT.c", "$(LINT) $(LINTFLAGS) $(CPPFLAGS) $(TARGET_ARCH)",
#ifndef NO_MINUS_C_MINUS_O
"OUTPUT_OPTION", "-o $@",
#endif
#ifdef SCCS_GET_MINUS_G
"SCCS_OUTPUT_OPTION", "-G$@",
#endif
#ifdef _AMIGA
".LIBPATTERNS", "%.lib",
#else
#ifdef __MSDOS__
".LIBPATTERNS", "lib%.a $(DJDIR)/lib/lib%.a",
#else
".LIBPATTERNS", "lib%.so lib%.a",
#endif
#endif
#endif /* !VMS */
0, 0
};
/* Set up the default .SUFFIXES list. */
void
set_default_suffixes ()
{
suffix_file = enter_file (".SUFFIXES");
if (no_builtin_rules_flag)
(void) define_variable ("SUFFIXES", 8, "", o_default, 0);
else
{
char *p = default_suffixes;
suffix_file->deps = (struct dep *)
multi_glob (parse_file_seq (&p, '\0', sizeof (struct dep), 1),
sizeof (struct dep));
(void) define_variable ("SUFFIXES", 8, default_suffixes, o_default, 0);
}
}
/* Enter the default suffix rules as file rules. This used to be done in
install_default_implicit_rules, but that loses because we want the
suffix rules installed before reading makefiles, and thee pattern rules
installed after. */
void
install_default_suffix_rules ()
{
register char **s;
if (no_builtin_rules_flag)
return;
for (s = default_suffix_rules; *s != 0; s += 2)
{
register struct file *f = enter_file (s[0]);
/* Don't clobber cmds given in a makefile if there were any. */
if (f->cmds == 0)
{
f->cmds = (struct commands *) xmalloc (sizeof (struct commands));
f->cmds->fileinfo.filenm = 0;
f->cmds->commands = s[1];
f->cmds->command_lines = 0;
}
}
}
/* Install the default pattern rules. */
void
install_default_implicit_rules ()
{
register struct pspec *p;
if (no_builtin_rules_flag)
return;
for (p = default_pattern_rules; p->target != 0; ++p)
install_pattern_rule (p, 0);
for (p = default_terminal_rules; p->target != 0; ++p)
install_pattern_rule (p, 1);
}
void
define_default_variables ()
{
register char **s;
if (no_builtin_variables_flag)
return;
for (s = default_variables; *s != 0; s += 2)
(void) define_variable (s[0], strlen (s[0]), s[1], o_default, 1);
}

78
dep.h Normal file
View File

@@ -0,0 +1,78 @@
/* Definitions of dependency data structures for GNU Make.
Copyright (C) 1988, 1989, 1991, 1992, 1993, 1996 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/* Flag bits for the second argument to `read_makefile'.
These flags are saved in the `changed' field of each
`struct dep' in the chain returned by `read_all_makefiles'. */
#define RM_NO_DEFAULT_GOAL (1 << 0) /* Do not set default goal. */
#define RM_INCLUDED (1 << 1) /* Search makefile search path. */
#define RM_DONTCARE (1 << 2) /* No error if it doesn't exist. */
#define RM_NO_TILDE (1 << 3) /* Don't expand ~ in file name. */
#define RM_NOFLAG 0
/* Structure representing one dependency of a file.
Each struct file's `deps' points to a chain of these,
chained through the `next'.
Note that the first two words of this match a struct nameseq. */
struct dep
{
struct dep *next;
char *name;
struct file *file;
unsigned int changed : 8;
unsigned int ignore_mtime : 1;
};
/* Structure used in chains of names, for parsing and globbing. */
struct nameseq
{
struct nameseq *next;
char *name;
};
extern struct nameseq *multi_glob PARAMS ((struct nameseq *chain, unsigned int size));
#ifdef VMS
extern struct nameseq *parse_file_seq ();
#else
extern struct nameseq *parse_file_seq PARAMS ((char **stringp, int stopchar, unsigned int size, int strip));
#endif
extern char *tilde_expand PARAMS ((char *name));
#ifndef NO_ARCHIVES
extern struct nameseq *ar_glob PARAMS ((char *arname, char *member_pattern, unsigned int size));
#endif
#ifndef iAPX286
#define dep_name(d) ((d)->name == 0 ? (d)->file->name : (d)->name)
#else
/* Buggy compiler can't hack this. */
extern char *dep_name ();
#endif
extern struct dep *copy_dep_chain PARAMS ((struct dep *d));
extern struct dep *read_all_makefiles PARAMS ((char **makefiles));
extern int eval_buffer PARAMS ((char *buffer));
extern int update_goal_chain PARAMS ((struct dep *goals, int makefiles));
extern void uniquize_deps PARAMS ((struct dep *));

1212
dir.c Normal file

File diff suppressed because it is too large Load Diff

7
doc/.cvsignore Normal file
View File

@@ -0,0 +1,7 @@
Makefile Makefile.in
fdl.texi make-stds.texi texinfo.tex
make.info*
make*.html
make.aux make.cp make.cps make.fn make.fns make.ky
make.pg make.toc make.tp make.vr make.log
make.dvi make.ps make.pdf

23
doc/Makefile.am Normal file
View File

@@ -0,0 +1,23 @@
## Process this file with automake to create Makefile.in.
## Makefile for GNU make documentation.
## Copyright 2002 Free Software Foundation, Inc.
TEXI2HTML = texi2html
TEXI2HTML_FLAGS = -split_chapter
info_TEXINFOS = make.texi
make_TEXINFOS = fdl.texi make-stds.texi
CLEANFILES = make*.html
## ----------------------------- ##
## Other documentation formats. ##
## ----------------------------- ##
html: make_1.html
make_1.html: $(info_TEXINFOS) $(make_TEXINFOS)
$(TEXI2HTML) $(TEXI2HTML_FLAGS) $(srcdir)/make.texi
.PHONY: html

10284
doc/make.texi Normal file

File diff suppressed because it is too large Load Diff

42
dosbuild.bat Normal file
View File

@@ -0,0 +1,42 @@
@echo Building Make for MSDOS
@rem Echo ON so they will see what is going on.
@echo on
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g commands.c -o commands.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g job.c -o job.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g dir.c -o dir.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g file.c -o file.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g misc.c -o misc.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g main.c -o main.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -DINCLUDEDIR=\"c:/djgpp/include\" -O2 -g read.c -o read.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -DLIBDIR=\"c:/djgpp/lib\" -O2 -g remake.c -o remake.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g rule.c -o rule.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g implicit.c -o implicit.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g default.c -o default.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g variable.c -o variable.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g expand.c -o expand.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g function.c -o function.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g vpath.c -o vpath.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g version.c -o version.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g ar.c -o ar.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g arscan.c -o arscan.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g signame.c -o signame.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g remote-stub.c -o remote-stub.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g getopt.c -o getopt.o
gcc -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g getopt1.c -o getopt1.o
@cd glob
@if exist libglob.a del libglob.a
gcc -I. -c -DHAVE_CONFIG_H -I.. -O2 -g glob.c -o glob.o
gcc -I. -c -DHAVE_CONFIG_H -I.. -O2 -g fnmatch.c -o fnmatch.o
ar rv libglob.a glob.o fnmatch.o
@echo off
cd ..
echo commands.o > respf.$$$
for %%f in (job dir file misc main read remake rule implicit default variable) do echo %%f.o >> respf.$$$
for %%f in (expand function vpath version ar arscan signame remote-stub getopt getopt1) do echo %%f.o >> respf.$$$
echo glob/libglob.a >> respf.$$$
@echo Linking...
@echo on
gcc -o make.new @respf.$$$
@if exist make.exe echo Make.exe is now built!
@if not exist make.exe echo Make.exe build failed...
@if exist make.exe del respf.$$$

566
expand.c Normal file
View File

@@ -0,0 +1,566 @@
/* Variable expansion functions for GNU Make.
Copyright (C) 1988, 89, 91, 92, 93, 95 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "make.h"
#include <assert.h>
#include "filedef.h"
#include "job.h"
#include "commands.h"
#include "variable.h"
#include "rule.h"
/* The next two describe the variable output buffer.
This buffer is used to hold the variable-expansion of a line of the
makefile. It is made bigger with realloc whenever it is too small.
variable_buffer_length is the size currently allocated.
variable_buffer is the address of the buffer.
For efficiency, it's guaranteed that the buffer will always have
VARIABLE_BUFFER_ZONE extra bytes allocated. This allows you to add a few
extra chars without having to call a function. Note you should never use
these bytes unless you're _sure_ you have room (you know when the buffer
length was last checked. */
#define VARIABLE_BUFFER_ZONE 5
static unsigned int variable_buffer_length;
char *variable_buffer;
/* Subroutine of variable_expand and friends:
The text to add is LENGTH chars starting at STRING to the variable_buffer.
The text is added to the buffer at PTR, and the updated pointer into
the buffer is returned as the value. Thus, the value returned by
each call to variable_buffer_output should be the first argument to
the following call. */
char *
variable_buffer_output (ptr, string, length)
char *ptr, *string;
unsigned int length;
{
register unsigned int newlen = length + (ptr - variable_buffer);
if ((newlen + VARIABLE_BUFFER_ZONE) > variable_buffer_length)
{
unsigned int offset = ptr - variable_buffer;
variable_buffer_length = (newlen + 100 > 2 * variable_buffer_length
? newlen + 100
: 2 * variable_buffer_length);
variable_buffer = (char *) xrealloc (variable_buffer,
variable_buffer_length);
ptr = variable_buffer + offset;
}
bcopy (string, ptr, length);
return ptr + length;
}
/* Return a pointer to the beginning of the variable buffer. */
static char *
initialize_variable_output ()
{
/* If we don't have a variable output buffer yet, get one. */
if (variable_buffer == 0)
{
variable_buffer_length = 200;
variable_buffer = (char *) xmalloc (variable_buffer_length);
variable_buffer[0] = '\0';
}
return variable_buffer;
}
/* Recursively expand V. The returned string is malloc'd. */
static char *allocated_variable_append PARAMS ((const struct variable *v));
char *
recursively_expand_for_file (v, file)
struct variable *v;
struct file *file;
{
char *value;
struct variable_set_list *save = 0;
if (v->expanding)
{
if (!v->exp_count)
/* Expanding V causes infinite recursion. Lose. */
fatal (reading_file,
_("Recursive variable `%s' references itself (eventually)"),
v->name);
--v->exp_count;
}
if (file)
{
save = current_variable_set_list;
current_variable_set_list = file->variables;
}
v->expanding = 1;
if (v->append)
value = allocated_variable_append (v);
else
value = allocated_variable_expand (v->value);
v->expanding = 0;
if (file)
current_variable_set_list = save;
return value;
}
/* Expand a simple reference to variable NAME, which is LENGTH chars long. */
#ifdef __GNUC__
__inline
#endif
static char *
reference_variable (o, name, length)
char *o;
char *name;
unsigned int length;
{
register struct variable *v;
char *value;
v = lookup_variable (name, length);
if (v == 0)
warn_undefined (name, length);
if (v == 0 || *v->value == '\0')
return o;
value = (v->recursive ? recursively_expand (v) : v->value);
o = variable_buffer_output (o, value, strlen (value));
if (v->recursive)
free (value);
return o;
}
/* Scan STRING for variable references and expansion-function calls. Only
LENGTH bytes of STRING are actually scanned. If LENGTH is -1, scan until
a null byte is found.
Write the results to LINE, which must point into `variable_buffer'. If
LINE is NULL, start at the beginning of the buffer.
Return a pointer to LINE, or to the beginning of the buffer if LINE is
NULL. */
char *
variable_expand_string (line, string, length)
register char *line;
char *string;
long length;
{
register struct variable *v;
register char *p, *o, *p1;
char save_char = '\0';
unsigned int line_offset;
if (!line)
line = initialize_variable_output();
p = string;
o = line;
line_offset = line - variable_buffer;
if (length >= 0)
{
save_char = string[length];
string[length] = '\0';
}
while (1)
{
/* Copy all following uninteresting chars all at once to the
variable output buffer, and skip them. Uninteresting chars end
at the next $ or the end of the input. */
p1 = strchr (p, '$');
o = variable_buffer_output (o, p, p1 != 0 ? p1 - p : strlen (p) + 1);
if (p1 == 0)
break;
p = p1 + 1;
/* Dispatch on the char that follows the $. */
switch (*p)
{
case '$':
/* $$ seen means output one $ to the variable output buffer. */
o = variable_buffer_output (o, p, 1);
break;
case '(':
case '{':
/* $(...) or ${...} is the general case of substitution. */
{
char openparen = *p;
char closeparen = (openparen == '(') ? ')' : '}';
register char *beg = p + 1;
int free_beg = 0;
char *op, *begp;
char *end, *colon;
op = o;
begp = p;
if (handle_function (&op, &begp))
{
o = op;
p = begp;
break;
}
/* Is there a variable reference inside the parens or braces?
If so, expand it before expanding the entire reference. */
end = strchr (beg, closeparen);
if (end == 0)
/* Unterminated variable reference. */
fatal (reading_file, _("unterminated variable reference"));
p1 = lindex (beg, end, '$');
if (p1 != 0)
{
/* BEG now points past the opening paren or brace.
Count parens or braces until it is matched. */
int count = 0;
for (p = beg; *p != '\0'; ++p)
{
if (*p == openparen)
++count;
else if (*p == closeparen && --count < 0)
break;
}
/* If COUNT is >= 0, there were unmatched opening parens
or braces, so we go to the simple case of a variable name
such as `$($(a)'. */
if (count < 0)
{
beg = expand_argument (beg, p); /* Expand the name. */
free_beg = 1; /* Remember to free BEG when finished. */
end = strchr (beg, '\0');
}
}
else
/* Advance P to the end of this reference. After we are
finished expanding this one, P will be incremented to
continue the scan. */
p = end;
/* This is not a reference to a built-in function and
any variable references inside are now expanded.
Is the resultant text a substitution reference? */
colon = lindex (beg, end, ':');
if (colon)
{
/* This looks like a substitution reference: $(FOO:A=B). */
char *subst_beg, *subst_end, *replace_beg, *replace_end;
subst_beg = colon + 1;
subst_end = strchr (subst_beg, '=');
if (subst_end == 0)
/* There is no = in sight. Punt on the substitution
reference and treat this as a variable name containing
a colon, in the code below. */
colon = 0;
else
{
replace_beg = subst_end + 1;
replace_end = end;
/* Extract the variable name before the colon
and look up that variable. */
v = lookup_variable (beg, colon - beg);
if (v == 0)
warn_undefined (beg, colon - beg);
if (v != 0 && *v->value != '\0')
{
char *value = (v->recursive ? recursively_expand (v)
: v->value);
char *pattern, *percent;
if (free_beg)
{
*subst_end = '\0';
pattern = subst_beg;
}
else
{
pattern = (char *) alloca (subst_end - subst_beg
+ 1);
bcopy (subst_beg, pattern, subst_end - subst_beg);
pattern[subst_end - subst_beg] = '\0';
}
percent = find_percent (pattern);
if (percent != 0)
{
char *replace;
if (free_beg)
{
*replace_end = '\0';
replace = replace_beg;
}
else
{
replace = (char *) alloca (replace_end
- replace_beg
+ 1);
bcopy (replace_beg, replace,
replace_end - replace_beg);
replace[replace_end - replace_beg] = '\0';
}
o = patsubst_expand (o, value, pattern, replace,
percent, (char *) 0);
}
else
o = subst_expand (o, value,
pattern, replace_beg,
strlen (pattern),
end - replace_beg,
0, 1);
if (v->recursive)
free (value);
}
}
}
if (colon == 0)
/* This is an ordinary variable reference.
Look up the value of the variable. */
o = reference_variable (o, beg, end - beg);
if (free_beg)
free (beg);
}
break;
case '\0':
break;
default:
if (isblank ((unsigned char)p[-1]))
break;
/* A $ followed by a random char is a variable reference:
$a is equivalent to $(a). */
{
/* We could do the expanding here, but this way
avoids code repetition at a small performance cost. */
char name[5];
name[0] = '$';
name[1] = '(';
name[2] = *p;
name[3] = ')';
name[4] = '\0';
p1 = allocated_variable_expand (name);
o = variable_buffer_output (o, p1, strlen (p1));
free (p1);
}
break;
}
if (*p == '\0')
break;
else
++p;
}
if (save_char)
string[length] = save_char;
(void)variable_buffer_output (o, "", 1);
return (variable_buffer + line_offset);
}
/* Scan LINE for variable references and expansion-function calls.
Build in `variable_buffer' the result of expanding the references and calls.
Return the address of the resulting string, which is null-terminated
and is valid only until the next time this function is called. */
char *
variable_expand (line)
char *line;
{
return variable_expand_string(NULL, line, (long)-1);
}
/* Expand an argument for an expansion function.
The text starting at STR and ending at END is variable-expanded
into a null-terminated string that is returned as the value.
This is done without clobbering `variable_buffer' or the current
variable-expansion that is in progress. */
char *
expand_argument (str, end)
char *str, *end;
{
char *tmp;
if (str == end)
return xstrdup("");
if (!end || *end == '\0')
tmp = str;
else
{
tmp = (char *) alloca (end - str + 1);
bcopy (str, tmp, end - str);
tmp[end - str] = '\0';
}
return allocated_variable_expand (tmp);
}
/* Expand LINE for FILE. Error messages refer to the file and line where
FILE's commands were found. Expansion uses FILE's variable set list. */
static char *
variable_expand_for_file (line, file)
char *line;
register struct file *file;
{
char *result;
struct variable_set_list *save;
if (file == 0)
return variable_expand (line);
save = current_variable_set_list;
current_variable_set_list = file->variables;
if (file->cmds && file->cmds->fileinfo.filenm)
reading_file = &file->cmds->fileinfo;
else
reading_file = 0;
result = variable_expand (line);
current_variable_set_list = save;
reading_file = 0;
return result;
}
/* Like allocated_variable_expand, but for += target-specific variables.
First recursively construct the variable value from its appended parts in
any upper variable sets. Then expand the resulting value. */
static char *
variable_append (name, length, set)
const char *name;
unsigned int length;
const struct variable_set_list *set;
{
const struct variable *v;
char *buf = 0;
/* If there's nothing left to check, return the empty buffer. */
if (!set)
return initialize_variable_output ();
/* Try to find the variable in this variable set. */
v = lookup_variable_in_set (name, length, set->set);
/* If there isn't one, look to see if there's one in a set above us. */
if (!v)
return variable_append (name, length, set->next);
/* If this variable type is append, first get any upper values.
If not, initialize the buffer. */
if (v->append)
buf = variable_append (name, length, set->next);
else
buf = initialize_variable_output ();
/* Append this value to the buffer, and return it.
If we already have a value, first add a space. */
if (buf > variable_buffer)
buf = variable_buffer_output (buf, " ", 1);
return variable_buffer_output (buf, v->value, strlen (v->value));
}
static char *
allocated_variable_append (v)
const struct variable *v;
{
char *val, *retval;
/* Construct the appended variable value. */
char *obuf = variable_buffer;
unsigned int olen = variable_buffer_length;
variable_buffer = 0;
val = variable_append (v->name, strlen (v->name), current_variable_set_list);
variable_buffer_output (val, "", 1);
val = variable_buffer;
variable_buffer = obuf;
variable_buffer_length = olen;
/* Now expand it and return that. */
retval = allocated_variable_expand (val);
free (val);
return retval;
}
/* Like variable_expand_for_file, but the returned string is malloc'd.
This function is called a lot. It wants to be efficient. */
char *
allocated_variable_expand_for_file (line, file)
char *line;
struct file *file;
{
char *value;
char *obuf = variable_buffer;
unsigned int olen = variable_buffer_length;
variable_buffer = 0;
value = variable_expand_for_file (line, file);
#if 0
/* Waste a little memory and save time. */
value = xrealloc (value, strlen (value))
#endif
variable_buffer = obuf;
variable_buffer_length = olen;
return value;
}

827
file.c Normal file
View File

@@ -0,0 +1,827 @@
/* Target file hash table management for GNU Make.
Copyright (C) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997,
2002 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "make.h"
#include <assert.h>
#include "dep.h"
#include "filedef.h"
#include "job.h"
#include "commands.h"
#include "variable.h"
#include "debug.h"
#include "hash.h"
/* Hash table of files the makefile knows how to make. */
static unsigned long
file_hash_1 (key)
const void *key;
{
return_ISTRING_HASH_1 (((struct file const *) key)->hname);
}
static unsigned long
file_hash_2 (key)
const void *key;
{
return_ISTRING_HASH_2 (((struct file const *) key)->hname);
}
static int
file_hash_cmp (x, y)
const void *x;
const void *y;
{
return_ISTRING_COMPARE (((struct file const *) x)->hname,
((struct file const *) y)->hname);
}
#ifndef FILE_BUCKETS
#define FILE_BUCKETS 1007
#endif
static struct hash_table files;
/* Whether or not .SECONDARY with no prerequisites was given. */
static int all_secondary = 0;
/* Access the hash table of all file records.
lookup_file given a name, return the struct file * for that name,
or nil if there is none.
enter_file similar, but create one if there is none. */
struct file *
lookup_file (name)
char *name;
{
register struct file *f;
struct file file_key;
#if defined(VMS) && !defined(WANT_CASE_SENSITIVE_TARGETS)
register char *lname, *ln;
#endif
assert (*name != '\0');
/* This is also done in parse_file_seq, so this is redundant
for names read from makefiles. It is here for names passed
on the command line. */
#ifdef VMS
# ifndef WANT_CASE_SENSITIVE_TARGETS
{
register char *n;
lname = (char *) malloc (strlen (name) + 1);
for (n = name, ln = lname; *n != '\0'; ++n, ++ln)
*ln = isupper ((unsigned char)*n) ? tolower ((unsigned char)*n) : *n;
*ln = '\0';
name = lname;
}
# endif
while (name[0] == '[' && name[1] == ']' && name[2] != '\0')
name += 2;
#endif
while (name[0] == '.' && name[1] == '/' && name[2] != '\0')
{
name += 2;
while (*name == '/')
/* Skip following slashes: ".//foo" is "foo", not "/foo". */
++name;
}
if (*name == '\0')
/* It was all slashes after a dot. */
#ifdef VMS
name = "[]";
#else
#ifdef _AMIGA
name = "";
#else
name = "./";
#endif /* AMIGA */
#endif /* VMS */
file_key.hname = name;
f = (struct file *) hash_find_item (&files, &file_key);
#if defined(VMS) && !defined(WANT_CASE_SENSITIVE_TARGETS)
free (lname);
#endif
return f;
}
struct file *
enter_file (name)
char *name;
{
register struct file *f;
register struct file *new;
register struct file **file_slot;
struct file file_key;
#if defined(VMS) && !defined(WANT_CASE_SENSITIVE_TARGETS)
char *lname, *ln;
#endif
assert (*name != '\0');
#if defined(VMS) && !defined(WANT_CASE_SENSITIVE_TARGETS)
{
register char *n;
lname = (char *) malloc (strlen (name) + 1);
for (n = name, ln = lname; *n != '\0'; ++n, ++ln)
{
if (isupper ((unsigned char)*n))
*ln = tolower ((unsigned char)*n);
else
*ln = *n;
}
*ln = 0;
/* Creates a possible leak, old value of name is unreachable, but I
currently don't know how to fix it. */
name = lname;
}
#endif
file_key.hname = name;
file_slot = (struct file **) hash_find_slot (&files, &file_key);
f = *file_slot;
if (! HASH_VACANT (f) && !f->double_colon)
{
#if defined(VMS) && !defined(WANT_CASE_SENSITIVE_TARGETS)
free(lname);
#endif
return f;
}
new = (struct file *) xmalloc (sizeof (struct file));
bzero ((char *) new, sizeof (struct file));
new->name = new->hname = name;
new->update_status = -1;
if (HASH_VACANT (f))
hash_insert_at (&files, new, file_slot);
else
{
/* There is already a double-colon entry for this file. */
new->double_colon = f;
while (f->prev != 0)
f = f->prev;
f->prev = new;
}
return new;
}
/* Rename FILE to NAME. This is not as simple as resetting
the `name' member, since it must be put in a new hash bucket,
and possibly merged with an existing file called NAME. */
void
rename_file (from_file, to_hname)
register struct file *from_file;
char *to_hname;
{
rehash_file (from_file, to_hname);
while (from_file)
{
from_file->name = from_file->hname;
from_file = from_file->prev;
}
}
/* Rehash FILE to NAME. This is not as simple as resetting
the `hname' member, since it must be put in a new hash bucket,
and possibly merged with an existing file called NAME. */
void
rehash_file (from_file, to_hname)
register struct file *from_file;
char *to_hname;
{
struct file file_key;
struct file **file_slot;
struct file *to_file;
struct file *deleted_file;
struct file *f;
file_key.hname = to_hname;
if (0 == file_hash_cmp (from_file, &file_key))
return;
file_key.hname = from_file->hname;
while (from_file->renamed != 0)
from_file = from_file->renamed;
if (file_hash_cmp (from_file, &file_key))
/* hname changed unexpectedly */
abort ();
deleted_file = hash_delete (&files, from_file);
if (deleted_file != from_file)
/* from_file isn't the one stored in files */
abort ();
file_key.hname = to_hname;
file_slot = (struct file **) hash_find_slot (&files, &file_key);
to_file = *file_slot;
from_file->hname = to_hname;
for (f = from_file->double_colon; f != 0; f = f->prev)
f->hname = to_hname;
if (HASH_VACANT (to_file))
hash_insert_at (&files, from_file, file_slot);
else
{
/* TO_FILE already exists under TO_HNAME.
We must retain TO_FILE and merge FROM_FILE into it. */
if (from_file->cmds != 0)
{
if (to_file->cmds == 0)
to_file->cmds = from_file->cmds;
else if (from_file->cmds != to_file->cmds)
{
/* We have two sets of commands. We will go with the
one given in the rule explicitly mentioning this name,
but give a message to let the user know what's going on. */
if (to_file->cmds->fileinfo.filenm != 0)
error (&from_file->cmds->fileinfo,
_("Commands were specified for file `%s' at %s:%lu,"),
from_file->name, to_file->cmds->fileinfo.filenm,
to_file->cmds->fileinfo.lineno);
else
error (&from_file->cmds->fileinfo,
_("Commands for file `%s' were found by implicit rule search,"),
from_file->name);
error (&from_file->cmds->fileinfo,
_("but `%s' is now considered the same file as `%s'."),
from_file->name, to_hname);
error (&from_file->cmds->fileinfo,
_("Commands for `%s' will be ignored in favor of those for `%s'."),
to_hname, from_file->name);
}
}
/* Merge the dependencies of the two files. */
if (to_file->deps == 0)
to_file->deps = from_file->deps;
else
{
register struct dep *deps = to_file->deps;
while (deps->next != 0)
deps = deps->next;
deps->next = from_file->deps;
}
merge_variable_set_lists (&to_file->variables, from_file->variables);
if (to_file->double_colon && from_file->is_target && !from_file->double_colon)
fatal (NILF, _("can't rename single-colon `%s' to double-colon `%s'"),
from_file->name, to_hname);
if (!to_file->double_colon && from_file->double_colon)
{
if (to_file->is_target)
fatal (NILF, _("can't rename double-colon `%s' to single-colon `%s'"),
from_file->name, to_hname);
else
to_file->double_colon = from_file->double_colon;
}
if (from_file->last_mtime > to_file->last_mtime)
/* %%% Kludge so -W wins on a file that gets vpathized. */
to_file->last_mtime = from_file->last_mtime;
to_file->mtime_before_update = from_file->mtime_before_update;
#define MERGE(field) to_file->field |= from_file->field
MERGE (precious);
MERGE (tried_implicit);
MERGE (updating);
MERGE (updated);
MERGE (is_target);
MERGE (cmd_target);
MERGE (phony);
MERGE (ignore_vpath);
#undef MERGE
from_file->renamed = to_file;
}
}
/* Remove all nonprecious intermediate files.
If SIG is nonzero, this was caused by a fatal signal,
meaning that a different message will be printed, and
the message will go to stderr rather than stdout. */
void
remove_intermediates (sig)
int sig;
{
register struct file **file_slot;
register struct file **file_end;
int doneany = 0;
/* If there's no way we will ever remove anything anyway, punt early. */
if (question_flag || touch_flag || all_secondary)
return;
if (sig && just_print_flag)
return;
file_slot = (struct file **) files.ht_vec;
file_end = file_slot + files.ht_size;
for ( ; file_slot < file_end; file_slot++)
if (! HASH_VACANT (*file_slot))
{
register struct file *f = *file_slot;
if (f->intermediate && (f->dontcare || !f->precious)
&& !f->secondary && !f->cmd_target)
{
int status;
if (f->update_status == -1)
/* If nothing would have created this file yet,
don't print an "rm" command for it. */
continue;
if (just_print_flag)
status = 0;
else
{
status = unlink (f->name);
if (status < 0 && errno == ENOENT)
continue;
}
if (!f->dontcare)
{
if (sig)
error (NILF, _("*** Deleting intermediate file `%s'"), f->name);
else
{
if (! doneany)
DB (DB_BASIC, (_("Removing intermediate files...\n")));
if (!silent_flag)
{
if (! doneany)
{
fputs ("rm ", stdout);
doneany = 1;
}
else
putchar (' ');
fputs (f->name, stdout);
fflush (stdout);
}
}
if (status < 0)
perror_with_name ("unlink: ", f->name);
}
}
}
if (doneany && !sig)
{
putchar ('\n');
fflush (stdout);
}
}
/* For each dependency of each file, make the `struct dep' point
at the appropriate `struct file' (which may have to be created).
Also mark the files depended on by .PRECIOUS, .PHONY, .SILENT,
and various other special targets. */
void
snap_deps ()
{
register struct file *f;
register struct file *f2;
register struct dep *d;
register struct file **file_slot_0;
register struct file **file_slot;
register struct file **file_end;
/* Enter each dependency name as a file. */
/* We must use hash_dump (), because within this loop
we might add new files to the table, possibly causing
an in-situ table expansion. */
file_slot_0 = (struct file **) hash_dump (&files, 0, 0);
file_end = file_slot_0 + files.ht_fill;
for (file_slot = file_slot_0; file_slot < file_end; file_slot++)
for (f2 = *file_slot; f2 != 0; f2 = f2->prev)
for (d = f2->deps; d != 0; d = d->next)
if (d->name != 0)
{
d->file = lookup_file (d->name);
if (d->file == 0)
d->file = enter_file (d->name);
else
free (d->name);
d->name = 0;
}
free (file_slot_0);
for (f = lookup_file (".PRECIOUS"); f != 0; f = f->prev)
for (d = f->deps; d != 0; d = d->next)
for (f2 = d->file; f2 != 0; f2 = f2->prev)
f2->precious = 1;
for (f = lookup_file (".LOW_RESOLUTION_TIME"); f != 0; f = f->prev)
for (d = f->deps; d != 0; d = d->next)
for (f2 = d->file; f2 != 0; f2 = f2->prev)
f2->low_resolution_time = 1;
for (f = lookup_file (".PHONY"); f != 0; f = f->prev)
for (d = f->deps; d != 0; d = d->next)
for (f2 = d->file; f2 != 0; f2 = f2->prev)
{
/* Mark this file as phony and nonexistent. */
f2->phony = 1;
f2->last_mtime = NONEXISTENT_MTIME;
f2->mtime_before_update = NONEXISTENT_MTIME;
}
for (f = lookup_file (".INTERMEDIATE"); f != 0; f = f->prev)
{
/* .INTERMEDIATE with deps listed
marks those deps as intermediate files. */
for (d = f->deps; d != 0; d = d->next)
for (f2 = d->file; f2 != 0; f2 = f2->prev)
f2->intermediate = 1;
/* .INTERMEDIATE with no deps does nothing.
Marking all files as intermediates is useless
since the goal targets would be deleted after they are built. */
}
for (f = lookup_file (".SECONDARY"); f != 0; f = f->prev)
{
/* .SECONDARY with deps listed
marks those deps as intermediate files
in that they don't get rebuilt if not actually needed;
but unlike real intermediate files,
these are not deleted after make finishes. */
if (f->deps)
for (d = f->deps; d != 0; d = d->next)
for (f2 = d->file; f2 != 0; f2 = f2->prev)
f2->intermediate = f2->secondary = 1;
/* .SECONDARY with no deps listed marks *all* files that way. */
else
all_secondary = 1;
}
f = lookup_file (".EXPORT_ALL_VARIABLES");
if (f != 0 && f->is_target)
export_all_variables = 1;
f = lookup_file (".IGNORE");
if (f != 0 && f->is_target)
{
if (f->deps == 0)
ignore_errors_flag = 1;
else
for (d = f->deps; d != 0; d = d->next)
for (f2 = d->file; f2 != 0; f2 = f2->prev)
f2->command_flags |= COMMANDS_NOERROR;
}
f = lookup_file (".SILENT");
if (f != 0 && f->is_target)
{
if (f->deps == 0)
silent_flag = 1;
else
for (d = f->deps; d != 0; d = d->next)
for (f2 = d->file; f2 != 0; f2 = f2->prev)
f2->command_flags |= COMMANDS_SILENT;
}
f = lookup_file (".POSIX");
if (f != 0 && f->is_target)
posix_pedantic = 1;
f = lookup_file (".NOTPARALLEL");
if (f != 0 && f->is_target)
not_parallel = 1;
}
/* Set the `command_state' member of FILE and all its `also_make's. */
void
set_command_state (file, state)
struct file *file;
int state;
{
struct dep *d;
file->command_state = state;
for (d = file->also_make; d != 0; d = d->next)
d->file->command_state = state;
}
/* Convert an external file timestamp to internal form. */
FILE_TIMESTAMP
file_timestamp_cons (fname, s, ns)
char const *fname;
time_t s;
int ns;
{
int offset = ORDINARY_MTIME_MIN + (FILE_TIMESTAMP_HI_RES ? ns : 0);
FILE_TIMESTAMP product = (FILE_TIMESTAMP) s << FILE_TIMESTAMP_LO_BITS;
FILE_TIMESTAMP ts = product + offset;
if (! (s <= FILE_TIMESTAMP_S (ORDINARY_MTIME_MAX)
&& product <= ts && ts <= ORDINARY_MTIME_MAX))
{
char buf[FILE_TIMESTAMP_PRINT_LEN_BOUND + 1];
ts = s <= OLD_MTIME ? ORDINARY_MTIME_MIN : ORDINARY_MTIME_MAX;
file_timestamp_sprintf (buf, ts);
error (NILF, _("%s: Timestamp out of range; substituting %s"),
fname ? fname : _("Current time"), buf);
}
return ts;
}
/* Return the current time as a file timestamp, setting *RESOLUTION to
its resolution. */
FILE_TIMESTAMP
file_timestamp_now (resolution)
int *resolution;
{
int r;
time_t s;
int ns;
/* Don't bother with high-resolution clocks if file timestamps have
only one-second resolution. The code below should work, but it's
not worth the hassle of debugging it on hosts where it fails. */
#if FILE_TIMESTAMP_HI_RES
# if HAVE_CLOCK_GETTIME && defined CLOCK_REALTIME
{
struct timespec timespec;
if (clock_gettime (CLOCK_REALTIME, &timespec) == 0)
{
r = 1;
s = timespec.tv_sec;
ns = timespec.tv_nsec;
goto got_time;
}
}
# endif
# if HAVE_GETTIMEOFDAY
{
struct timeval timeval;
if (gettimeofday (&timeval, 0) == 0)
{
r = 1000;
s = timeval.tv_sec;
ns = timeval.tv_usec * 1000;
goto got_time;
}
}
# endif
#endif
r = 1000000000;
s = time ((time_t *) 0);
ns = 0;
got_time:
*resolution = r;
return file_timestamp_cons (0, s, ns);
}
/* Place into the buffer P a printable representation of the file
timestamp TS. */
void
file_timestamp_sprintf (p, ts)
char *p;
FILE_TIMESTAMP ts;
{
time_t t = FILE_TIMESTAMP_S (ts);
struct tm *tm = localtime (&t);
if (tm)
sprintf (p, "%04d-%02d-%02d %02d:%02d:%02d",
tm->tm_year + 1900, tm->tm_mon + 1, tm->tm_mday,
tm->tm_hour, tm->tm_min, tm->tm_sec);
else if (t < 0)
sprintf (p, "%ld", (long) t);
else
sprintf (p, "%lu", (unsigned long) t);
p += strlen (p);
/* Append nanoseconds as a fraction, but remove trailing zeros.
We don't know the actual timestamp resolution, since clock_getres
applies only to local times, whereas this timestamp might come
from a remote filesystem. So removing trailing zeros is the
best guess that we can do. */
sprintf (p, ".%09d", FILE_TIMESTAMP_NS (ts));
p += strlen (p) - 1;
while (*p == '0')
p--;
p += *p != '.';
*p = '\0';
}
/* Print the data base of files. */
static void
print_file (f)
struct file *f;
{
struct dep *d;
struct dep *ood = 0;
putchar ('\n');
if (!f->is_target)
puts (_("# Not a target:"));
printf ("%s:%s", f->name, f->double_colon ? ":" : "");
/* Print all normal dependencies; note any order-only deps. */
for (d = f->deps; d != 0; d = d->next)
if (! d->ignore_mtime)
printf (" %s", dep_name (d));
else if (! ood)
ood = d;
/* Print order-only deps, if we have any. */
if (ood)
{
printf (" | %s", dep_name (ood));
for (d = ood->next; d != 0; d = d->next)
if (d->ignore_mtime)
printf (" %s", dep_name (d));
}
putchar ('\n');
if (f->precious)
puts (_("# Precious file (prerequisite of .PRECIOUS)."));
if (f->phony)
puts (_("# Phony target (prerequisite of .PHONY)."));
if (f->cmd_target)
puts (_("# Command-line target."));
if (f->dontcare)
puts (_("# A default or MAKEFILES makefile."));
puts (f->tried_implicit
? _("# Implicit rule search has been done.")
: _("# Implicit rule search has not been done."));
if (f->stem != 0)
printf (_("# Implicit/static pattern stem: `%s'\n"), f->stem);
if (f->intermediate)
puts (_("# File is an intermediate prerequisite."));
if (f->also_make != 0)
{
fputs (_("# Also makes:"), stdout);
for (d = f->also_make; d != 0; d = d->next)
printf (" %s", dep_name (d));
putchar ('\n');
}
if (f->last_mtime == UNKNOWN_MTIME)
puts (_("# Modification time never checked."));
else if (f->last_mtime == NONEXISTENT_MTIME)
puts (_("# File does not exist."));
else if (f->last_mtime == OLD_MTIME)
puts (_("# File is very old."));
else
{
char buf[FILE_TIMESTAMP_PRINT_LEN_BOUND + 1];
file_timestamp_sprintf (buf, f->last_mtime);
printf (_("# Last modified %s\n"), buf);
}
puts (f->updated
? _("# File has been updated.") : _("# File has not been updated."));
switch (f->command_state)
{
case cs_running:
puts (_("# Commands currently running (THIS IS A BUG)."));
break;
case cs_deps_running:
puts (_("# Dependencies commands running (THIS IS A BUG)."));
break;
case cs_not_started:
case cs_finished:
switch (f->update_status)
{
case -1:
break;
case 0:
puts (_("# Successfully updated."));
break;
case 1:
assert (question_flag);
puts (_("# Needs to be updated (-q is set)."));
break;
case 2:
puts (_("# Failed to be updated."));
break;
default:
puts (_("# Invalid value in `update_status' member!"));
fflush (stdout);
fflush (stderr);
abort ();
}
break;
default:
puts (_("# Invalid value in `command_state' member!"));
fflush (stdout);
fflush (stderr);
abort ();
}
if (f->variables != 0)
print_file_variables (f);
if (f->cmds != 0)
print_commands (f->cmds);
}
void
print_file_data_base ()
{
puts (_("\n# Files"));
hash_map (&files, print_file);
fputs (_("\n# files hash-table stats:\n# "), stdout);
hash_print_stats (&files, stdout);
}
#define EXPANSION_INCREMENT(_l) ((((_l) / 500) + 1) * 500)
char *
build_target_list (value)
char *value;
{
static unsigned long last_targ_count = 0;
if (files.ht_fill != last_targ_count)
{
unsigned long max = EXPANSION_INCREMENT (strlen (value));
unsigned long len;
char *p;
struct file **fp = (struct file **) files.ht_vec;
struct file **end = &fp[files.ht_size];
/* Make sure we have at least MAX bytes in the allocated buffer. */
value = xrealloc (value, max);
p = value;
len = 0;
for (; fp < end; ++fp)
if (!HASH_VACANT (*fp) && (*fp)->is_target)
{
struct file *f = *fp;
int l = strlen (f->name);
len += l + 1;
if (len > max)
{
unsigned long off = p - value;
max += EXPANSION_INCREMENT (l + 1);
value = xrealloc (value, max);
p = &value[off];
}
bcopy (f->name, p, l);
p += l;
*(p++) = ' ';
}
*(p-1) = '\0';
last_targ_count = files.ht_fill;
}
return value;
}
void
init_hash_files ()
{
hash_init (&files, 1000, file_hash_1, file_hash_2, file_hash_cmp);
}
/* EOF */

199
filedef.h Normal file
View File

@@ -0,0 +1,199 @@
/* Definition of target file data structures for GNU Make.
Copyright (C) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1997,
2002 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/* Structure that represents the info on one file
that the makefile says how to make.
All of these are chained together through `next'. */
#include "hash.h"
struct file
{
char *name;
char *hname; /* Hashed filename */
char *vpath; /* VPATH/vpath pathname */
struct dep *deps; /* all dependencies, including duplicates */
struct commands *cmds; /* Commands to execute for this target. */
int command_flags; /* Flags OR'd in for cmds; see commands.h. */
char *stem; /* Implicit stem, if an implicit
rule has been used */
struct dep *also_make; /* Targets that are made by making this. */
FILE_TIMESTAMP last_mtime; /* File's modtime, if already known. */
FILE_TIMESTAMP mtime_before_update; /* File's modtime before any updating
has been performed. */
struct file *prev; /* Previous entry for same file name;
used when there are multiple double-colon
entries for the same file. */
/* File that this file was renamed to. After any time that a
file could be renamed, call `check_renamed' (below). */
struct file *renamed;
/* List of variable sets used for this file. */
struct variable_set_list *variables;
/* Pattern-specific variable reference for this target, or null if there
isn't one. Also see the pat_searched flag, below. */
struct variable_set_list *pat_variables;
/* Immediate dependent that caused this target to be remade,
or nil if there isn't one. */
struct file *parent;
/* For a double-colon entry, this is the first double-colon entry for
the same file. Otherwise this is null. */
struct file *double_colon;
short int update_status; /* Status of the last attempt to update,
or -1 if none has been made. */
enum /* State of the commands. */
{ /* Note: It is important that cs_not_started be zero. */
cs_not_started, /* Not yet started. */
cs_deps_running, /* Dep commands running. */
cs_running, /* Commands running. */
cs_finished /* Commands finished. */
} command_state ENUM_BITFIELD (2);
unsigned int precious:1; /* Non-0 means don't delete file on quit */
unsigned int low_resolution_time:1; /* Nonzero if this file's time stamp
has only one-second resolution. */
unsigned int tried_implicit:1; /* Nonzero if have searched
for implicit rule for making
this file; don't search again. */
unsigned int updating:1; /* Nonzero while updating deps of this file */
unsigned int updated:1; /* Nonzero if this file has been remade. */
unsigned int is_target:1; /* Nonzero if file is described as target. */
unsigned int cmd_target:1; /* Nonzero if file was given on cmd line. */
unsigned int phony:1; /* Nonzero if this is a phony file
i.e., a dependency of .PHONY. */
unsigned int intermediate:1;/* Nonzero if this is an intermediate file. */
/* Nonzero, for an intermediate file,
means remove_intermediates should not delete it. */
unsigned int secondary:1;
unsigned int dontcare:1; /* Nonzero if no complaint is to be made if
this target cannot be remade. */
unsigned int ignore_vpath:1;/* Nonzero if we threw out VPATH name. */
unsigned int pat_searched:1;/* Nonzero if we already searched for
pattern-specific variables. */
unsigned int considered:1; /* equal to `considered' if file has been
considered on current scan of goal chain */
};
extern struct file *default_goal_file, *suffix_file, *default_file;
extern struct file *lookup_file PARAMS ((char *name));
extern struct file *enter_file PARAMS ((char *name));
extern void remove_intermediates PARAMS ((int sig));
extern void snap_deps PARAMS ((void));
extern void rename_file PARAMS ((struct file *file, char *name));
extern void rehash_file PARAMS ((struct file *file, char *name));
extern void set_command_state PARAMS ((struct file *file, int state));
extern void notice_finished_file PARAMS ((struct file *file));
extern void init_hash_files PARAMS ((void));
extern char *build_target_list PARAMS ((char *old_list));
#if FILE_TIMESTAMP_HI_RES
# define FILE_TIMESTAMP_STAT_MODTIME(fname, st) \
file_timestamp_cons (fname, (st).st_mtime, (st).st_mtim.ST_MTIM_NSEC)
#else
# define FILE_TIMESTAMP_STAT_MODTIME(fname, st) \
file_timestamp_cons (fname, (st).st_mtime, 0)
#endif
/* If FILE_TIMESTAMP is 64 bits (or more), use nanosecond resolution.
(Multiply by 2**30 instead of by 10**9 to save time at the cost of
slightly decreasing the number of available timestamps.) With
64-bit FILE_TIMESTAMP, this stops working on 2514-05-30 01:53:04
UTC, but by then uintmax_t should be larger than 64 bits. */
#define FILE_TIMESTAMPS_PER_S (FILE_TIMESTAMP_HI_RES ? 1000000000 : 1)
#define FILE_TIMESTAMP_LO_BITS (FILE_TIMESTAMP_HI_RES ? 30 : 0)
#define FILE_TIMESTAMP_S(ts) (((ts) - ORDINARY_MTIME_MIN) \
>> FILE_TIMESTAMP_LO_BITS)
#define FILE_TIMESTAMP_NS(ts) ((int) (((ts) - ORDINARY_MTIME_MIN) \
& ((1 << FILE_TIMESTAMP_LO_BITS) - 1)))
/* Upper bound on length of string "YYYY-MM-DD HH:MM:SS.NNNNNNNNN"
representing a file timestamp. The upper bound is not necessarily 19,
since the year might be less than -999 or greater than 9999.
Subtract one for the sign bit if in case file timestamps can be negative;
subtract FLOOR_LOG2_SECONDS_PER_YEAR to yield an upper bound on how many
file timestamp bits might affect the year;
302 / 1000 is log10 (2) rounded up;
add one for integer division truncation;
add one more for a minus sign if file timestamps can be negative;
add 4 to allow for any 4-digit epoch year (e.g. 1970);
add 25 to allow for "-MM-DD HH:MM:SS.NNNNNNNNN". */
#define FLOOR_LOG2_SECONDS_PER_YEAR 24
#define FILE_TIMESTAMP_PRINT_LEN_BOUND \
(((sizeof (FILE_TIMESTAMP) * CHAR_BIT - 1 - FLOOR_LOG2_SECONDS_PER_YEAR) \
* 302 / 1000) \
+ 1 + 1 + 4 + 25)
extern FILE_TIMESTAMP file_timestamp_cons PARAMS ((char const *,
time_t, int));
extern FILE_TIMESTAMP file_timestamp_now PARAMS ((int *));
extern void file_timestamp_sprintf PARAMS ((char *p, FILE_TIMESTAMP ts));
/* Return the mtime of file F (a struct file *), caching it.
The value is NONEXISTENT_MTIME if the file does not exist. */
#define file_mtime(f) file_mtime_1 ((f), 1)
/* Return the mtime of file F (a struct file *), caching it.
Don't search using vpath for the file--if it doesn't actually exist,
we don't find it.
The value is NONEXISTENT_MTIME if the file does not exist. */
#define file_mtime_no_search(f) file_mtime_1 ((f), 0)
extern FILE_TIMESTAMP f_mtime PARAMS ((struct file *file, int search));
#define file_mtime_1(f, v) \
((f)->last_mtime == UNKNOWN_MTIME ? f_mtime ((f), v) : (f)->last_mtime)
/* Special timestamp values. */
/* The file's timestamp is not yet known. */
#define UNKNOWN_MTIME 0
/* The file does not exist. */
#define NONEXISTENT_MTIME 1
/* The file does not exist, and we assume that it is older than any
actual file. */
#define OLD_MTIME 2
/* The smallest and largest ordinary timestamps. */
#define ORDINARY_MTIME_MIN (OLD_MTIME + 1)
#define ORDINARY_MTIME_MAX ((FILE_TIMESTAMP_S (NEW_MTIME) \
<< FILE_TIMESTAMP_LO_BITS) \
+ ORDINARY_MTIME_MIN + FILE_TIMESTAMPS_PER_S - 1)
/* Modtime value to use for `infinitely new'. We used to get the current time
from the system and use that whenever we wanted `new'. But that causes
trouble when the machine running make and the machine holding a file have
different ideas about what time it is; and can also lose for `force'
targets, which need to be considered newer than anything that depends on
them, even if said dependents' modtimes are in the future. */
#define NEW_MTIME INTEGER_TYPE_MAXIMUM (FILE_TIMESTAMP)
#define check_renamed(file) \
while ((file)->renamed != 0) (file) = (file)->renamed /* No ; here. */

2076
function.c Normal file

File diff suppressed because it is too large Load Diff

1034
getloadavg.c Normal file

File diff suppressed because it is too large Load Diff

1047
getopt.c Normal file

File diff suppressed because it is too large Load Diff

133
getopt.h Normal file
View File

@@ -0,0 +1,133 @@
/* Declarations for getopt.
Copyright (C) 1989,90,91,92,93,94,96,97 Free Software Foundation, Inc.
NOTE: The canonical source of this file is maintained with the GNU C Library.
Bugs can be reported to bug-glibc@gnu.org.
This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
Free Software Foundation; either version 2, or (at your option) any
later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
USA. */
#ifndef _GETOPT_H
#define _GETOPT_H 1
#ifdef __cplusplus
extern "C" {
#endif
/* For communication from `getopt' to the caller.
When `getopt' finds an option that takes an argument,
the argument value is returned here.
Also, when `ordering' is RETURN_IN_ORDER,
each non-option ARGV-element is returned here. */
extern char *optarg;
/* Index in ARGV of the next element to be scanned.
This is used for communication to and from the caller
and for communication between successive calls to `getopt'.
On entry to `getopt', zero means this is the first call; initialize.
When `getopt' returns -1, this is the index of the first of the
non-option elements that the caller should itself scan.
Otherwise, `optind' communicates from one call to the next
how much of ARGV has been scanned so far. */
extern int optind;
/* Callers store zero here to inhibit the error message `getopt' prints
for unrecognized options. */
extern int opterr;
/* Set to an option character which was unrecognized. */
extern int optopt;
/* Describe the long-named options requested by the application.
The LONG_OPTIONS argument to getopt_long or getopt_long_only is a vector
of `struct option' terminated by an element containing a name which is
zero.
The field `has_arg' is:
no_argument (or 0) if the option does not take an argument,
required_argument (or 1) if the option requires an argument,
optional_argument (or 2) if the option takes an optional argument.
If the field `flag' is not NULL, it points to a variable that is set
to the value given in the field `val' when the option is found, but
left unchanged if the option is not found.
To have a long-named option do something other than set an `int' to
a compiled-in constant, such as set a value from `optarg', set the
option's `flag' field to zero and its `val' field to a nonzero
value (the equivalent single-letter option character, if there is
one). For long options that have a zero `flag' field, `getopt'
returns the contents of the `val' field. */
struct option
{
#if defined (__STDC__) && __STDC__
const char *name;
#else
char *name;
#endif
/* has_arg can't be an enum because some compilers complain about
type mismatches in all the code that assumes it is an int. */
int has_arg;
int *flag;
int val;
};
/* Names for the values of the `has_arg' field of `struct option'. */
#define no_argument 0
#define required_argument 1
#define optional_argument 2
#if defined (__STDC__) && __STDC__
#ifdef __GNU_LIBRARY__
/* Many other libraries have conflicting prototypes for getopt, with
differences in the consts, in stdlib.h. To avoid compilation
errors, only prototype getopt for the GNU C library. */
extern int getopt (int argc, char *const *argv, const char *shortopts);
#else /* not __GNU_LIBRARY__ */
extern int getopt ();
#endif /* __GNU_LIBRARY__ */
extern int getopt_long (int argc, char *const *argv, const char *shortopts,
const struct option *longopts, int *longind);
extern int getopt_long_only (int argc, char *const *argv,
const char *shortopts,
const struct option *longopts, int *longind);
/* Internal only. Users should not call this directly. */
extern int _getopt_internal (int argc, char *const *argv,
const char *shortopts,
const struct option *longopts, int *longind,
int long_only);
#else /* not __STDC__ */
extern int getopt ();
extern int getopt_long ();
extern int getopt_long_only ();
extern int _getopt_internal ();
#endif /* __STDC__ */
#ifdef __cplusplus
}
#endif
#endif /* getopt.h */

190
getopt1.c Normal file
View File

@@ -0,0 +1,190 @@
/* getopt_long and getopt_long_only entry points for GNU getopt.
Copyright (C) 1987,88,89,90,91,92,93,94,96,97,98
Free Software Foundation, Inc.
NOTE: The canonical source of this file is maintained with the GNU C Library.
Bugs can be reported to bug-glibc@prep.ai.mit.edu.
This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
Free Software Foundation; either version 2, or (at your option) any
later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
USA. */
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include "getopt.h"
#if !defined __STDC__ || !__STDC__
/* This is a separate conditional since some stdc systems
reject `defined (const)'. */
#ifndef const
#define const
#endif
#endif
#include <stdio.h>
/* Comment out all this code if we are using the GNU C Library, and are not
actually compiling the library itself. This code is part of the GNU C
Library, but also included in many other GNU distributions. Compiling
and linking in this code is a waste when using the GNU C library
(especially if it is a shared library). Rather than having every GNU
program understand `configure --with-gnu-libc' and omit the object files,
it is simpler to just do this in the source for each such file. */
#define GETOPT_INTERFACE_VERSION 2
#if !defined _LIBC && defined __GLIBC__ && __GLIBC__ >= 2
#include <gnu-versions.h>
#if _GNU_GETOPT_INTERFACE_VERSION == GETOPT_INTERFACE_VERSION
#define ELIDE_CODE
#endif
#endif
#ifndef ELIDE_CODE
/* This needs to come after some library #include
to get __GNU_LIBRARY__ defined. */
#ifdef __GNU_LIBRARY__
#include <stdlib.h>
#endif
#ifndef NULL
#define NULL 0
#endif
int
getopt_long (argc, argv, options, long_options, opt_index)
int argc;
char *const *argv;
const char *options;
const struct option *long_options;
int *opt_index;
{
return _getopt_internal (argc, argv, options, long_options, opt_index, 0);
}
/* Like getopt_long, but '-' as well as '--' can indicate a long option.
If an option that starts with '-' (not '--') doesn't match a long option,
but does match a short option, it is parsed as a short option
instead. */
int
getopt_long_only (argc, argv, options, long_options, opt_index)
int argc;
char *const *argv;
const char *options;
const struct option *long_options;
int *opt_index;
{
return _getopt_internal (argc, argv, options, long_options, opt_index, 1);
}
#endif /* Not ELIDE_CODE. */
#ifdef TEST
#include <stdio.h>
int
main (argc, argv)
int argc;
char **argv;
{
int c;
int digit_optind = 0;
while (1)
{
int this_option_optind = optind ? optind : 1;
int option_index = 0;
static struct option long_options[] =
{
{"add", 1, 0, 0},
{"append", 0, 0, 0},
{"delete", 1, 0, 0},
{"verbose", 0, 0, 0},
{"create", 0, 0, 0},
{"file", 1, 0, 0},
{0, 0, 0, 0}
};
c = getopt_long (argc, argv, "abc:d:0123456789",
long_options, &option_index);
if (c == -1)
break;
switch (c)
{
case 0:
printf ("option %s", long_options[option_index].name);
if (optarg)
printf (" with arg %s", optarg);
printf ("\n");
break;
case '0':
case '1':
case '2':
case '3':
case '4':
case '5':
case '6':
case '7':
case '8':
case '9':
if (digit_optind != 0 && digit_optind != this_option_optind)
printf ("digits occur in two different argv-elements.\n");
digit_optind = this_option_optind;
printf ("option %c\n", c);
break;
case 'a':
printf ("option a\n");
break;
case 'b':
printf ("option b\n");
break;
case 'c':
printf ("option c with value `%s'\n", optarg);
break;
case 'd':
printf ("option d with value `%s'\n", optarg);
break;
case '?':
break;
default:
printf ("?? getopt returned character code 0%o ??\n", c);
}
}
if (optind < argc)
{
printf ("non-option ARGV-elements: ");
while (optind < argc)
printf ("%s ", argv[optind++]);
printf ("\n");
}
exit (0);
}
#endif /* TEST */

59
gettext.h Normal file
View File

@@ -0,0 +1,59 @@
/* Convenience header for conditional use of GNU <libintl.h>.
Copyright (C) 1995-1998, 2000-2002 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify it
under the terms of the GNU Library General Public License as published
by the Free Software Foundation; either version 2, or (at your option)
any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
USA. */
#ifndef _LIBGETTEXT_H
#define _LIBGETTEXT_H 1
/* NLS can be disabled through the configure --disable-nls option. */
#if ENABLE_NLS
/* Get declarations of GNU message catalog functions. */
# include <libintl.h>
#else
/* Disabled NLS.
The casts to 'const char *' serve the purpose of producing warnings
for invalid uses of the value returned from these functions.
On pre-ANSI systems without 'const', the config.h file is supposed to
contain "#define const". */
# define gettext(Msgid) ((const char *) (Msgid))
# define dgettext(Domainname, Msgid) ((const char *) (Msgid))
# define dcgettext(Domainname, Msgid, Category) ((const char *) (Msgid))
# define ngettext(Msgid1, Msgid2, N) \
((N) == 1 ? (const char *) (Msgid1) : (const char *) (Msgid2))
# define dngettext(Domainname, Msgid1, Msgid2, N) \
((N) == 1 ? (const char *) (Msgid1) : (const char *) (Msgid2))
# define dcngettext(Domainname, Msgid1, Msgid2, N, Category) \
((N) == 1 ? (const char *) (Msgid1) : (const char *) (Msgid2))
# define textdomain(Domainname) ((const char *) (Domainname))
# define bindtextdomain(Domainname, Dirname) ((const char *) (Dirname))
# define bind_textdomain_codeset(Domainname, Codeset) ((const char *) (Codeset))
#endif
/* A pseudo function call that serves as a marker for the automated
extraction of messages, but does not call gettext(). The run-time
translation is done at a different place in the code.
The argument, String, should be a literal string. Concatenated strings
and other string expressions won't work.
The macro's expansion is not parenthesized, so that it is suitable as
initializer for static 'char[]' or 'const char[]' variables. */
#define gettext_noop(String) String
#endif /* _LIBGETTEXT_H */

2
glob/.cvsignore Normal file
View File

@@ -0,0 +1,2 @@
Makefile Makefile.in
.deps

481
glob/COPYING.LIB Normal file
View File

@@ -0,0 +1,481 @@
GNU LIBRARY GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1991 Free Software Foundation, Inc.
675 Mass Ave, Cambridge, MA 02139, USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
[This is the first released version of the library GPL. It is
numbered 2 because it goes with version 2 of the ordinary GPL.]
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
Licenses are intended to guarantee your freedom to share and change
free software--to make sure the software is free for all its users.
This license, the Library General Public License, applies to some
specially designated Free Software Foundation software, and to any
other libraries whose authors decide to use it. You can use it for
your libraries, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if
you distribute copies of the library, or if you modify it.
For example, if you distribute copies of the library, whether gratis
or for a fee, you must give the recipients all the rights that we gave
you. You must make sure that they, too, receive or can get the source
code. If you link a program with the library, you must provide
complete object files to the recipients so that they can relink them
with the library, after making changes to the library and recompiling
it. And you must show them these terms so they know their rights.
Our method of protecting your rights has two steps: (1) copyright
the library, and (2) offer you this license which gives you legal
permission to copy, distribute and/or modify the library.
Also, for each distributor's protection, we want to make certain
that everyone understands that there is no warranty for this free
library. If the library is modified by someone else and passed on, we
want its recipients to know that what they have is not the original
version, so that any problems introduced by others will not reflect on
the original authors' reputations.
Finally, any free program is threatened constantly by software
patents. We wish to avoid the danger that companies distributing free
software will individually obtain patent licenses, thus in effect
transforming the program into proprietary software. To prevent this,
we have made it clear that any patent must be licensed for everyone's
free use or not licensed at all.
Most GNU software, including some libraries, is covered by the ordinary
GNU General Public License, which was designed for utility programs. This
license, the GNU Library General Public License, applies to certain
designated libraries. This license is quite different from the ordinary
one; be sure to read it in full, and don't assume that anything in it is
the same as in the ordinary license.
The reason we have a separate public license for some libraries is that
they blur the distinction we usually make between modifying or adding to a
program and simply using it. Linking a program with a library, without
changing the library, is in some sense simply using the library, and is
analogous to running a utility program or application program. However, in
a textual and legal sense, the linked executable is a combined work, a
derivative of the original library, and the ordinary General Public License
treats it as such.
Because of this blurred distinction, using the ordinary General
Public License for libraries did not effectively promote software
sharing, because most developers did not use the libraries. We
concluded that weaker conditions might promote sharing better.
However, unrestricted linking of non-free programs would deprive the
users of those programs of all benefit from the free status of the
libraries themselves. This Library General Public License is intended to
permit developers of non-free programs to use free libraries, while
preserving your freedom as a user of such programs to change the free
libraries that are incorporated in them. (We have not seen how to achieve
this as regards changes in header files, but we have achieved it as regards
changes in the actual functions of the Library.) The hope is that this
will lead to faster development of free libraries.
The precise terms and conditions for copying, distribution and
modification follow. Pay close attention to the difference between a
"work based on the library" and a "work that uses the library". The
former contains code derived from the library, while the latter only
works together with the library.
Note that it is possible for a library to be covered by the ordinary
General Public License rather than by this special one.
GNU LIBRARY GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License Agreement applies to any software library which
contains a notice placed by the copyright holder or other authorized
party saying it may be distributed under the terms of this Library
General Public License (also called "this License"). Each licensee is
addressed as "you".
A "library" means a collection of software functions and/or data
prepared so as to be conveniently linked with application programs
(which use some of those functions and data) to form executables.
The "Library", below, refers to any such software library or work
which has been distributed under these terms. A "work based on the
Library" means either the Library or any derivative work under
copyright law: that is to say, a work containing the Library or a
portion of it, either verbatim or with modifications and/or translated
straightforwardly into another language. (Hereinafter, translation is
included without limitation in the term "modification".)
"Source code" for a work means the preferred form of the work for
making modifications to it. For a library, complete source code means
all the source code for all modules it contains, plus any associated
interface definition files, plus the scripts used to control compilation
and installation of the library.
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running a program using the Library is not restricted, and output from
such a program is covered only if its contents constitute a work based
on the Library (independent of the use of the Library in a tool for
writing it). Whether that is true depends on what the Library does
and what the program that uses the Library does.
1. You may copy and distribute verbatim copies of the Library's
complete source code as you receive it, in any medium, provided that
you conspicuously and appropriately publish on each copy an
appropriate copyright notice and disclaimer of warranty; keep intact
all the notices that refer to this License and to the absence of any
warranty; and distribute a copy of this License along with the
Library.
You may charge a fee for the physical act of transferring a copy,
and you may at your option offer warranty protection in exchange for a
fee.
2. You may modify your copy or copies of the Library or any portion
of it, thus forming a work based on the Library, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) The modified work must itself be a software library.
b) You must cause the files modified to carry prominent notices
stating that you changed the files and the date of any change.
c) You must cause the whole of the work to be licensed at no
charge to all third parties under the terms of this License.
d) If a facility in the modified Library refers to a function or a
table of data to be supplied by an application program that uses
the facility, other than as an argument passed when the facility
is invoked, then you must make a good faith effort to ensure that,
in the event an application does not supply such function or
table, the facility still operates, and performs whatever part of
its purpose remains meaningful.
(For example, a function in a library to compute square roots has
a purpose that is entirely well-defined independent of the
application. Therefore, Subsection 2d requires that any
application-supplied function or table used by this function must
be optional: if the application does not supply it, the square
root function must still compute square roots.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Library,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Library, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote
it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Library.
In addition, mere aggregation of another work not based on the Library
with the Library (or with a work based on the Library) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may opt to apply the terms of the ordinary GNU General Public
License instead of this License to a given copy of the Library. To do
this, you must alter all the notices that refer to this License, so
that they refer to the ordinary GNU General Public License, version 2,
instead of to this License. (If a newer version than version 2 of the
ordinary GNU General Public License has appeared, then you can specify
that version instead if you wish.) Do not make any other change in
these notices.
Once this change is made in a given copy, it is irreversible for
that copy, so the ordinary GNU General Public License applies to all
subsequent copies and derivative works made from that copy.
This option is useful when you wish to copy part of the code of
the Library into a program that is not a library.
4. You may copy and distribute the Library (or a portion or
derivative of it, under Section 2) in object code or executable form
under the terms of Sections 1 and 2 above provided that you accompany
it with the complete corresponding machine-readable source code, which
must be distributed under the terms of Sections 1 and 2 above on a
medium customarily used for software interchange.
If distribution of object code is made by offering access to copy
from a designated place, then offering equivalent access to copy the
source code from the same place satisfies the requirement to
distribute the source code, even though third parties are not
compelled to copy the source along with the object code.
5. A program that contains no derivative of any portion of the
Library, but is designed to work with the Library by being compiled or
linked with it, is called a "work that uses the Library". Such a
work, in isolation, is not a derivative work of the Library, and
therefore falls outside the scope of this License.
However, linking a "work that uses the Library" with the Library
creates an executable that is a derivative of the Library (because it
contains portions of the Library), rather than a "work that uses the
library". The executable is therefore covered by this License.
Section 6 states terms for distribution of such executables.
When a "work that uses the Library" uses material from a header file
that is part of the Library, the object code for the work may be a
derivative work of the Library even though the source code is not.
Whether this is true is especially significant if the work can be
linked without the Library, or if the work is itself a library. The
threshold for this to be true is not precisely defined by law.
If such an object file uses only numerical parameters, data
structure layouts and accessors, and small macros and small inline
functions (ten lines or less in length), then the use of the object
file is unrestricted, regardless of whether it is legally a derivative
work. (Executables containing this object code plus portions of the
Library will still fall under Section 6.)
Otherwise, if the work is a derivative of the Library, you may
distribute the object code for the work under the terms of Section 6.
Any executables containing that work also fall under Section 6,
whether or not they are linked directly with the Library itself.
6. As an exception to the Sections above, you may also compile or
link a "work that uses the Library" with the Library to produce a
work containing portions of the Library, and distribute that work
under terms of your choice, provided that the terms permit
modification of the work for the customer's own use and reverse
engineering for debugging such modifications.
You must give prominent notice with each copy of the work that the
Library is used in it and that the Library and its use are covered by
this License. You must supply a copy of this License. If the work
during execution displays copyright notices, you must include the
copyright notice for the Library among them, as well as a reference
directing the user to the copy of this License. Also, you must do one
of these things:
a) Accompany the work with the complete corresponding
machine-readable source code for the Library including whatever
changes were used in the work (which must be distributed under
Sections 1 and 2 above); and, if the work is an executable linked
with the Library, with the complete machine-readable "work that
uses the Library", as object code and/or source code, so that the
user can modify the Library and then relink to produce a modified
executable containing the modified Library. (It is understood
that the user who changes the contents of definitions files in the
Library will not necessarily be able to recompile the application
to use the modified definitions.)
b) Accompany the work with a written offer, valid for at
least three years, to give the same user the materials
specified in Subsection 6a, above, for a charge no more
than the cost of performing this distribution.
c) If distribution of the work is made by offering access to copy
from a designated place, offer equivalent access to copy the above
specified materials from the same place.
d) Verify that the user has already received a copy of these
materials or that you have already sent this user a copy.
For an executable, the required form of the "work that uses the
Library" must include any data and utility programs needed for
reproducing the executable from it. However, as a special exception,
the source code distributed need not include anything that is normally
distributed (in either source or binary form) with the major
components (compiler, kernel, and so on) of the operating system on
which the executable runs, unless that component itself accompanies
the executable.
It may happen that this requirement contradicts the license
restrictions of other proprietary libraries that do not normally
accompany the operating system. Such a contradiction means you cannot
use both them and the Library together in an executable that you
distribute.
7. You may place library facilities that are a work based on the
Library side-by-side in a single library together with other library
facilities not covered by this License, and distribute such a combined
library, provided that the separate distribution of the work based on
the Library and of the other library facilities is otherwise
permitted, and provided that you do these two things:
a) Accompany the combined library with a copy of the same work
based on the Library, uncombined with any other library
facilities. This must be distributed under the terms of the
Sections above.
b) Give prominent notice with the combined library of the fact
that part of it is a work based on the Library, and explaining
where to find the accompanying uncombined form of the same work.
8. You may not copy, modify, sublicense, link with, or distribute
the Library except as expressly provided under this License. Any
attempt otherwise to copy, modify, sublicense, link with, or
distribute the Library is void, and will automatically terminate your
rights under this License. However, parties who have received copies,
or rights, from you under this License will not have their licenses
terminated so long as such parties remain in full compliance.
9. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Library or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Library (or any work based on the
Library), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Library or works based on it.
10. Each time you redistribute the Library (or any work based on the
Library), the recipient automatically receives a license from the
original licensor to copy, distribute, link with or modify the Library
subject to these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.
11. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Library at all. For example, if a patent
license would not permit royalty-free redistribution of the Library by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Library.
If any portion of this section is held invalid or unenforceable under any
particular circumstance, the balance of the section is intended to apply,
and the section as a whole is intended to apply in other circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
12. If the distribution and/or use of the Library is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Library under this License may add
an explicit geographical distribution limitation excluding those countries,
so that distribution is permitted only in or among countries not thus
excluded. In such case, this License incorporates the limitation as if
written in the body of this License.
13. The Free Software Foundation may publish revised and/or new
versions of the Library General Public License from time to time.
Such new versions will be similar in spirit to the present version,
but may differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the Library
specifies a version number of this License which applies to it and
"any later version", you have the option of following the terms and
conditions either of that version or of any later version published by
the Free Software Foundation. If the Library does not specify a
license version number, you may choose any version ever published by
the Free Software Foundation.
14. If you wish to incorporate parts of the Library into other free
programs whose distribution conditions are incompatible with these,
write to the author to ask for permission. For software which is
copyrighted by the Free Software Foundation, write to the Free
Software Foundation; we sometimes make exceptions for this. Our
decision will be guided by the two goals of preserving the free status
of all derivatives of our free software and of promoting the sharing
and reuse of software generally.
NO WARRANTY
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
DAMAGES.
END OF TERMS AND CONDITIONS
Appendix: How to Apply These Terms to Your New Libraries
If you develop a new library, and you want it to be of the greatest
possible use to the public, we recommend making it free software that
everyone can redistribute and change. You can do so by permitting
redistribution under these terms (or, alternatively, under the terms of the
ordinary General Public License).
To apply these terms, attach the following notices to the library. It is
safest to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least the
"copyright" line and a pointer to where the full notice is found.
<one line to give the library's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; if not, write to the Free
Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
Also add information on how to contact you by electronic and paper mail.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the library, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the
library `Frob' (a library for tweaking knobs) written by James Random Hacker.
<signature of Ty Coon>, 1 April 1990
Ty Coon, President of Vice
That's all there is to it!

136
glob/ChangeLog Normal file
View File

@@ -0,0 +1,136 @@
2002-04-22 Paul D. Smith <psmith@gnu.org>
* Makefile.am: Use automake 1.6.
Use new automake condition USE_LOCAL_GLOB to decide whether or not
to build the local GNU glob library or use the system one.
1999-09-12 Paul D. Smith <psmith@gnu.org>
* fnmatch.c: Last GLIBC version wouldn't compile outside of GLIBC
(undefined reference to internal_function). Update to the latest
version
1999-09-11 Paul Eggert <eggert@twinsun.com>
* glob.h (glob): If #defining to glob64, do this before
declaring it, so that all declarations and uses match, and
do not declare glob64, to avoid a declaration clash.
(globfree): Likewise with globfree64.
1999-09-08 Eli Zaretskii <eliz@is.elta.co.il>
* glob.c (prefix_array) [__MSDOS__,WINDOWS32]: Keep the trailing
slash unless DIRNAME is just "x:/".
1999-09-06 Paul D. Smith <psmith@gnu.org>
* fnmatch.c: Update to latest version from GLIBC.
1999-07-21 Paul D. Smith <psmith@gnu.org>
* glob.c, glob.h, fnmatch.c, fnmatch.h: Update to latest version
from GLIBC.
* fnmatch.c (internal_fnmatch): Use K&R definition syntax, not ANSI.
(__strchrnul): This won't exist outside GLIBC, so create one.
* glob.c: Move getlogin{,_r} prototypes below glob.h to get __P()
macro.
1998-08-05 Paul D. Smith <psmith@gnu.org>
* configure.in: Remove; configuration for glob is handled by the
make configure.in.
1998-07-29 Paul D. Smith <psmith@gnu.org>
* glob.c, fnmatch.c: New versions from the GLIBC folks (Ulrich
Drepper). Fixes a bug reported by Eli Zaretski. Integrates
DOS/Windows32 support.
1998-07-27 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* glob.c (glob): Cast away const on assignment of pattern to dirname.
Cast the return type of __alloca() for traditional C compilers.
1998-07-23 Paul D. Smith <psmith@gnu.org>
* glob.c, fnmatch.c: New versions of these files from the GLIBC
folks (Ulrich Drepper). Had to re-integrate some DOS/Windows
code.
1998-07-10 Paul D. Smith <psmith@gnu.org>
* glob.c (glob_in_dir): If no meta chars exist in PATTERN and
GLOB_NOCHECK is present, don't look for the file--whether it's
found or not, we'll always return it, so why bother searching?
Also, if we are searching and there are no meta chars, don't
bother trying fnmatch() if the strcmp() fails.
1998-05-30 Eli Zaretskii <eliz@is.elta.co.il>
* glob.c (glob) [__MSDOS__, WINDOWS32]: Compute the directory and
filename parts of the pattern correctly when it includes a drive
spec. Disallow wildcards in the drive spec. Prevent recursion
when dirname is of the form "d:/" or "d:".
(prefix_array) [__MSDOS__, WINDOWS32]: Don't append a slash to
"d:/" and "d:".
1998-05-13 Paul D. Smith <psmith@gnu.org>
* SMakefile, Makefile.ami, glob.c, glob.h, fnmatch.c: Updated from
the latest glibc version.
1998-04-17 Paul D. Smith <psmith@gnu.org>
* configure.in: Create a config.h file instead of setting things
on the compile line. This is because when build.sh runs it merely
passes -DHAVE_CONFIG_H to the glob files, just as it does to the
make files.
* config.h.in: Created by autoheader.
Tue Aug 12 10:52:34 1997 Paul D. Smith <psmith@baynetworks.com>
* configure.in: Require autoconf 2.12.
* glob: Updates from latest GNU libc glob code.
* glob.c,glob.h,fnmatch.h: Change all WIN32 references to WINDOWS32.
* glob.h: OSF4 defines macros in such a way that GLOB_ALTDIRFUNC
is not defined. Added a test to the #if which defines it if
_GNU_SOURCE is defined; that's set by both glob.c and GNU make.
* glob.c: SunOS4 w/ cc needs #include <stdio.h>, since assert.h
requires stderr but doesn't include stdio.h :-/.
(next_brace_sub): De-protoize function definition.
(glob): Cast __alloca(); on SunOS4 it uses the default return type
of int.
(glob): Irix defines getlogin_r() to return a char*; move the
extern for that into the _LIBC area since it isn't used except in
LIBC anyway. Likewise, move extern getlogin() into the "else".
Sat Jul 20 21:55:31 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
Win32 hacks from <Rob_Tulloh@tivoli.com>.
* posix/glob.c [WIN32]: Don't include <pwd.h>; don't use d_ino;
use void * for my_realloc; include <malloc.h> for alloca.
(glob) [WIN32]: Use "c:/users/default" for ~ if no HOME variable.
* posix/fnmatch.h [WIN32]: Use prototypes even if [!__STDC__].
* posix/glob.h: Likewise.
Fri Jul 19 16:56:41 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* posix/glob.h [!_AMIGA && !VMS]: Check this instead of just [!_AMIGA]
for `struct stat;' forward decl.
Sat Jun 22 10:44:09 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* posix/glob.c: Include <alloca.h> only [HAVE_ALLOCA_H], not [sparc].
Fri Jun 21 00:27:51 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* posix/fnmatch.c (fnmatch): Fix \*[*?]+ case to increment name ptr
only for ?s, not for *s. Fix from Chet Ramey.

14
glob/Makefile.am Normal file
View File

@@ -0,0 +1,14 @@
# -*-Makefile-*-, or close enough
AUTOMAKE_OPTIONS = 1.7 foreign
# Only build the library when the system doesn't already have GNU glob.
if USE_LOCAL_GLOB
noinst_LIBRARIES = libglob.a
endif
libglob_a_SOURCES = glob.c glob.h fnmatch.c fnmatch.h
EXTRA_DIST = COPYING.LIB Makefile.ami SCOPTIONS SMakefile \
configure.bat

69
glob/Makefile.ami Normal file
View File

@@ -0,0 +1,69 @@
# Makefile for standalone distribution of libglob.a (fnmatch, glob).
# Copyright (C) 1991, 92, 93, 94, 95, 97, 98 Free Software Foundation, Inc.
# This file is part of the GNU C Library.
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Library General Public License
# as published by the Free Software Foundation; either version 2 of
# the License, or (at your option) any later version.
# This library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Library General Public License for more details.
# You should have received a copy of the GNU Library General Public
# License along with this library; see the file COPYING.LIB. If
# not, write to the Free Software Foundation, Inc.,
# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
# Ultrix 2.2 make doesn't expand the value of VPATH.
VPATH = /glob/
# This must repeat the value, because configure will remove `VPATH = .'.
srcdir = /glob/
CC = sc
RM = delete
CPPFLAGS =
CFLAGS =
# Information determined by configure.
DEFS = Define HAVE_HEADER_STDC Define HAVE_UNISTD_H Define HAVE_STRING_H \
Define HAVE_DIRENT_H
# How to invoke ar.
AR = join
ARFLAGS = as
# How to invoke ranlib.
RANLIB = ;
.PHONY: all
all: glob.lib
glob.lib : glob.o fnmatch.o
$(AR) $(ARFLAGS) $@ glob.o fnmatch.o
$(RANLIB) $@
# For some reason, Unix make wants the dependencies on the source files.
# Otherwise it refuses to use an implicit rule!
# And, get this: it doesn't work to use $(srcdir)foo.c!!
glob.o: $(srcdir)glob.h $(srcdir)fnmatch.h glob.c
fnmatch.o: $(srcdir)fnmatch.h fnmatch.c
OUTPUT_OPTION =
.c.o:
$(CC) IDir "" \
$(DEFS) $(CPPFLAGS) $(CFLAGS) $< $(OUTPUT_OPTION)
.PHONY: clean realclean glob-clean glob-realclean distclean
clean glob-clean:
-$(RM) glob.lib "#?.o" core
distclean glob-realclean: clean
-$(RM) TAGS tags Makefile config.status config.h config.log
realcean: distclean
# For inside the C library.
glob.tar glob.tar.Z:
$(MAKE) -C .. $@

13
glob/SCOPTIONS Normal file
View File

@@ -0,0 +1,13 @@
ERRORREXX
OPTIMIZE
NOVERSION
OPTIMIZERTIME
OPTIMIZERALIAS
DEFINE INCLUDEDIR="include:"
DEFINE LIBDIR="lib:"
DEFINE NO_ALLOCA
DEFINE NO_FLOAT
DEFINE NO_ARCHIVES
IGNORE=161
IGNORE=100
STARTUP=cres

69
glob/SMakefile Normal file
View File

@@ -0,0 +1,69 @@
# Makefile for standalone distribution of libglob.a (fnmatch, glob).
# Copyright (C) 1991, 92, 93, 94, 95, 97, 98 Free Software Foundation, Inc.
# This file is part of the GNU C Library.
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Library General Public License
# as published by the Free Software Foundation; either version 2 of
# the License, or (at your option) any later version.
# This library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Library General Public License for more details.
# You should have received a copy of the GNU Library General Public
# License along with this library; see the file COPYING.LIB. If
# not, write to the Free Software Foundation, Inc.,
# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
# Ultrix 2.2 make doesn't expand the value of VPATH.
VPATH = /glob/
# This must repeat the value, because configure will remove `VPATH = .'.
srcdir = /glob/
CC = sc
CPPFLAGS =
CFLAGS =
MAKE = smake
RM = delete
# Information determined by configure.
DEFS = Define HAVE_HEADER_STDC Define HAVE_UNISTD_H Define HAVE_STRING_H \
Define HAVE_DIRENT_H
# How to invoke ar.
AR = join
ARFLAGS = as
# How to invoke ranlib.
RANLIB = ;
.PHONY: all
all: glob.lib
glob.lib : glob.o fnmatch.o
$(AR) $(ARFLAGS) $@ glob.o fnmatch.o
$(RANLIB) $@
# For some reason, Unix make wants the dependencies on the source files.
# Otherwise it refuses to use an implicit rule!
# And, get this: it doesn't work to use $(srcdir)foo.c!!
glob.o: $(srcdir)glob.h $(srcdir)fnmatch.h glob.c
fnmatch.o: $(srcdir)fnmatch.h fnmatch.c
.c.o:
$(CC) IDir "" \
$(DEFS) $(CPPFLAGS) $(CFLAGS) $< $(OUTPUT_OPTION)
.PHONY: clean realclean glob-clean glob-realclean distclean
clean glob-clean:
-$(RM) -f glob.lib *.o core
distclean glob-realclean: clean
-$(RM) -f TAGS tags Makefile config.status config.h config.log
realcean: distclean
# For inside the C library.
glob.tar glob.tar.Z:
$(MAKE) -C .. $@

26
glob/configure.bat Normal file
View File

@@ -0,0 +1,26 @@
@echo off
echo Configuring glob for DJGPP
rem This batch file assumes a unix-type "sed" program
echo # Makefile generated by "configure.bat"> Makefile
if exist config.sed del config.sed
echo "s/@srcdir@/./ ">> config.sed
echo "s/@CC@/gcc/ ">> config.sed
echo "s/@CFLAGS@/-O2 -g/ ">> config.sed
echo "s/@CPPFLAGS@/-DHAVE_CONFIG_H -I../ ">> config.sed
echo "s/@AR@/ar/ ">> config.sed
echo "s/@RANLIB@/ranlib/ ">> config.sed
echo "s/@LDFLAGS@// ">> config.sed
echo "s/@DEFS@// ">> config.sed
echo "s/@ALLOCA@// ">> config.sed
echo "s/@LIBS@// ">> config.sed
echo "s/@LIBOBJS@// ">> config.sed
echo "s/^Makefile *:/_Makefile:/ ">> config.sed
echo "s/^config.h *:/_config.h:/ ">> config.sed
sed -e "s/^\"//" -e "s/\"$//" -e "s/[ ]*$//" config.sed > config2.sed
sed -f config2.sed Makefile.in >> Makefile
del config.sed
del config2.sed

488
glob/fnmatch.c Normal file
View File

@@ -0,0 +1,488 @@
/* Copyright (C) 1991, 92, 93, 96, 97, 98, 99 Free Software Foundation, Inc.
This file is part of the GNU C Library.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; see the file COPYING.LIB. If not,
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#if HAVE_CONFIG_H
# include <config.h>
#endif
/* Enable GNU extensions in fnmatch.h. */
#ifndef _GNU_SOURCE
# define _GNU_SOURCE 1
#endif
#include <errno.h>
#include <fnmatch.h>
#include <ctype.h>
#if HAVE_STRING_H || defined _LIBC
# include <string.h>
#else
# include <strings.h>
#endif
#if defined STDC_HEADERS || defined _LIBC
# include <stdlib.h>
#endif
/* For platform which support the ISO C amendement 1 functionality we
support user defined character classes. */
#if defined _LIBC || (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H)
/* Solaris 2.5 has a bug: <wchar.h> must be included before <wctype.h>. */
# include <wchar.h>
# include <wctype.h>
#endif
/* Comment out all this code if we are using the GNU C Library, and are not
actually compiling the library itself. This code is part of the GNU C
Library, but also included in many other GNU distributions. Compiling
and linking in this code is a waste when using the GNU C library
(especially if it is a shared library). Rather than having every GNU
program understand `configure --with-gnu-libc' and omit the object files,
it is simpler to just do this in the source for each such file. */
#if defined _LIBC || !defined __GNU_LIBRARY__
# if defined STDC_HEADERS || !defined isascii
# define ISASCII(c) 1
# else
# define ISASCII(c) isascii(c)
# endif
# ifdef isblank
# define ISBLANK(c) (ISASCII (c) && isblank (c))
# else
# define ISBLANK(c) ((c) == ' ' || (c) == '\t')
# endif
# ifdef isgraph
# define ISGRAPH(c) (ISASCII (c) && isgraph (c))
# else
# define ISGRAPH(c) (ISASCII (c) && isprint (c) && !isspace (c))
# endif
# define ISPRINT(c) (ISASCII (c) && isprint (c))
# define ISDIGIT(c) (ISASCII (c) && isdigit (c))
# define ISALNUM(c) (ISASCII (c) && isalnum (c))
# define ISALPHA(c) (ISASCII (c) && isalpha (c))
# define ISCNTRL(c) (ISASCII (c) && iscntrl (c))
# define ISLOWER(c) (ISASCII (c) && islower (c))
# define ISPUNCT(c) (ISASCII (c) && ispunct (c))
# define ISSPACE(c) (ISASCII (c) && isspace (c))
# define ISUPPER(c) (ISASCII (c) && isupper (c))
# define ISXDIGIT(c) (ISASCII (c) && isxdigit (c))
# define STREQ(s1, s2) ((strcmp (s1, s2) == 0))
# if defined _LIBC || (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H)
/* The GNU C library provides support for user-defined character classes
and the functions from ISO C amendement 1. */
# ifdef CHARCLASS_NAME_MAX
# define CHAR_CLASS_MAX_LENGTH CHARCLASS_NAME_MAX
# else
/* This shouldn't happen but some implementation might still have this
problem. Use a reasonable default value. */
# define CHAR_CLASS_MAX_LENGTH 256
# endif
# ifdef _LIBC
# define IS_CHAR_CLASS(string) __wctype (string)
# else
# define IS_CHAR_CLASS(string) wctype (string)
# endif
# else
# define CHAR_CLASS_MAX_LENGTH 6 /* Namely, `xdigit'. */
# define IS_CHAR_CLASS(string) \
(STREQ (string, "alpha") || STREQ (string, "upper") \
|| STREQ (string, "lower") || STREQ (string, "digit") \
|| STREQ (string, "alnum") || STREQ (string, "xdigit") \
|| STREQ (string, "space") || STREQ (string, "print") \
|| STREQ (string, "punct") || STREQ (string, "graph") \
|| STREQ (string, "cntrl") || STREQ (string, "blank"))
# endif
/* Avoid depending on library functions or files
whose names are inconsistent. */
# if !defined _LIBC && !defined getenv
extern char *getenv ();
# endif
# ifndef errno
extern int errno;
# endif
/* This function doesn't exist on most systems. */
# if !defined HAVE___STRCHRNUL && !defined _LIBC
static char *
__strchrnul (s, c)
const char *s;
int c;
{
char *result = strchr (s, c);
if (result == NULL)
result = strchr (s, '\0');
return result;
}
# endif
# ifndef internal_function
/* Inside GNU libc we mark some function in a special way. In other
environments simply ignore the marking. */
# define internal_function
# endif
/* Match STRING against the filename pattern PATTERN, returning zero if
it matches, nonzero if not. */
static int internal_fnmatch __P ((const char *pattern, const char *string,
int no_leading_period, int flags))
internal_function;
static int
internal_function
internal_fnmatch (pattern, string, no_leading_period, flags)
const char *pattern;
const char *string;
int no_leading_period;
int flags;
{
register const char *p = pattern, *n = string;
register unsigned char c;
/* Note that this evaluates C many times. */
# ifdef _LIBC
# define FOLD(c) ((flags & FNM_CASEFOLD) ? tolower (c) : (c))
# else
# define FOLD(c) ((flags & FNM_CASEFOLD) && ISUPPER (c) ? tolower (c) : (c))
# endif
while ((c = *p++) != '\0')
{
c = FOLD (c);
switch (c)
{
case '?':
if (*n == '\0')
return FNM_NOMATCH;
else if (*n == '/' && (flags & FNM_FILE_NAME))
return FNM_NOMATCH;
else if (*n == '.' && no_leading_period
&& (n == string
|| (n[-1] == '/' && (flags & FNM_FILE_NAME))))
return FNM_NOMATCH;
break;
case '\\':
if (!(flags & FNM_NOESCAPE))
{
c = *p++;
if (c == '\0')
/* Trailing \ loses. */
return FNM_NOMATCH;
c = FOLD (c);
}
if (FOLD ((unsigned char) *n) != c)
return FNM_NOMATCH;
break;
case '*':
if (*n == '.' && no_leading_period
&& (n == string
|| (n[-1] == '/' && (flags & FNM_FILE_NAME))))
return FNM_NOMATCH;
for (c = *p++; c == '?' || c == '*'; c = *p++)
{
if (*n == '/' && (flags & FNM_FILE_NAME))
/* A slash does not match a wildcard under FNM_FILE_NAME. */
return FNM_NOMATCH;
else if (c == '?')
{
/* A ? needs to match one character. */
if (*n == '\0')
/* There isn't another character; no match. */
return FNM_NOMATCH;
else
/* One character of the string is consumed in matching
this ? wildcard, so *??? won't match if there are
less than three characters. */
++n;
}
}
if (c == '\0')
/* The wildcard(s) is/are the last element of the pattern.
If the name is a file name and contains another slash
this does mean it cannot match. */
return ((flags & FNM_FILE_NAME) && strchr (n, '/') != NULL
? FNM_NOMATCH : 0);
else
{
const char *endp;
endp = __strchrnul (n, (flags & FNM_FILE_NAME) ? '/' : '\0');
if (c == '[')
{
int flags2 = ((flags & FNM_FILE_NAME)
? flags : (flags & ~FNM_PERIOD));
for (--p; n < endp; ++n)
if (internal_fnmatch (p, n,
(no_leading_period
&& (n == string
|| (n[-1] == '/'
&& (flags
& FNM_FILE_NAME)))),
flags2)
== 0)
return 0;
}
else if (c == '/' && (flags & FNM_FILE_NAME))
{
while (*n != '\0' && *n != '/')
++n;
if (*n == '/'
&& (internal_fnmatch (p, n + 1, flags & FNM_PERIOD,
flags) == 0))
return 0;
}
else
{
int flags2 = ((flags & FNM_FILE_NAME)
? flags : (flags & ~FNM_PERIOD));
if (c == '\\' && !(flags & FNM_NOESCAPE))
c = *p;
c = FOLD (c);
for (--p; n < endp; ++n)
if (FOLD ((unsigned char) *n) == c
&& (internal_fnmatch (p, n,
(no_leading_period
&& (n == string
|| (n[-1] == '/'
&& (flags
& FNM_FILE_NAME)))),
flags2) == 0))
return 0;
}
}
/* If we come here no match is possible with the wildcard. */
return FNM_NOMATCH;
case '[':
{
/* Nonzero if the sense of the character class is inverted. */
static int posixly_correct;
register int not;
char cold;
if (posixly_correct == 0)
posixly_correct = getenv ("POSIXLY_CORRECT") != NULL ? 1 : -1;
if (*n == '\0')
return FNM_NOMATCH;
if (*n == '.' && no_leading_period && (n == string
|| (n[-1] == '/'
&& (flags
& FNM_FILE_NAME))))
return FNM_NOMATCH;
if (*n == '/' && (flags & FNM_FILE_NAME))
/* `/' cannot be matched. */
return FNM_NOMATCH;
not = (*p == '!' || (posixly_correct < 0 && *p == '^'));
if (not)
++p;
c = *p++;
for (;;)
{
unsigned char fn = FOLD ((unsigned char) *n);
if (!(flags & FNM_NOESCAPE) && c == '\\')
{
if (*p == '\0')
return FNM_NOMATCH;
c = FOLD ((unsigned char) *p);
++p;
if (c == fn)
goto matched;
}
else if (c == '[' && *p == ':')
{
/* Leave room for the null. */
char str[CHAR_CLASS_MAX_LENGTH + 1];
size_t c1 = 0;
# if defined _LIBC || (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H)
wctype_t wt;
# endif
const char *startp = p;
for (;;)
{
if (c1 == CHAR_CLASS_MAX_LENGTH)
/* The name is too long and therefore the pattern
is ill-formed. */
return FNM_NOMATCH;
c = *++p;
if (c == ':' && p[1] == ']')
{
p += 2;
break;
}
if (c < 'a' || c >= 'z')
{
/* This cannot possibly be a character class name.
Match it as a normal range. */
p = startp;
c = '[';
goto normal_bracket;
}
str[c1++] = c;
}
str[c1] = '\0';
# if defined _LIBC || (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H)
wt = IS_CHAR_CLASS (str);
if (wt == 0)
/* Invalid character class name. */
return FNM_NOMATCH;
if (__iswctype (__btowc ((unsigned char) *n), wt))
goto matched;
# else
if ((STREQ (str, "alnum") && ISALNUM ((unsigned char) *n))
|| (STREQ (str, "alpha") && ISALPHA ((unsigned char) *n))
|| (STREQ (str, "blank") && ISBLANK ((unsigned char) *n))
|| (STREQ (str, "cntrl") && ISCNTRL ((unsigned char) *n))
|| (STREQ (str, "digit") && ISDIGIT ((unsigned char) *n))
|| (STREQ (str, "graph") && ISGRAPH ((unsigned char) *n))
|| (STREQ (str, "lower") && ISLOWER ((unsigned char) *n))
|| (STREQ (str, "print") && ISPRINT ((unsigned char) *n))
|| (STREQ (str, "punct") && ISPUNCT ((unsigned char) *n))
|| (STREQ (str, "space") && ISSPACE ((unsigned char) *n))
|| (STREQ (str, "upper") && ISUPPER ((unsigned char) *n))
|| (STREQ (str, "xdigit") && ISXDIGIT ((unsigned char) *n)))
goto matched;
# endif
}
else if (c == '\0')
/* [ (unterminated) loses. */
return FNM_NOMATCH;
else
{
normal_bracket:
if (FOLD (c) == fn)
goto matched;
cold = c;
c = *p++;
if (c == '-' && *p != ']')
{
/* It is a range. */
unsigned char cend = *p++;
if (!(flags & FNM_NOESCAPE) && cend == '\\')
cend = *p++;
if (cend == '\0')
return FNM_NOMATCH;
if (cold <= fn && fn <= FOLD (cend))
goto matched;
c = *p++;
}
}
if (c == ']')
break;
}
if (!not)
return FNM_NOMATCH;
break;
matched:
/* Skip the rest of the [...] that already matched. */
while (c != ']')
{
if (c == '\0')
/* [... (unterminated) loses. */
return FNM_NOMATCH;
c = *p++;
if (!(flags & FNM_NOESCAPE) && c == '\\')
{
if (*p == '\0')
return FNM_NOMATCH;
/* XXX 1003.2d11 is unclear if this is right. */
++p;
}
else if (c == '[' && *p == ':')
{
do
if (*++p == '\0')
return FNM_NOMATCH;
while (*p != ':' || p[1] == ']');
p += 2;
c = *p;
}
}
if (not)
return FNM_NOMATCH;
}
break;
default:
if (c != FOLD ((unsigned char) *n))
return FNM_NOMATCH;
}
++n;
}
if (*n == '\0')
return 0;
if ((flags & FNM_LEADING_DIR) && *n == '/')
/* The FNM_LEADING_DIR flag says that "foo*" matches "foobar/frobozz". */
return 0;
return FNM_NOMATCH;
# undef FOLD
}
int
fnmatch (pattern, string, flags)
const char *pattern;
const char *string;
int flags;
{
return internal_fnmatch (pattern, string, flags & FNM_PERIOD, flags);
}
#endif /* _LIBC or not __GNU_LIBRARY__. */

84
glob/fnmatch.h Normal file
View File

@@ -0,0 +1,84 @@
/* Copyright (C) 1991, 92, 93, 96, 97, 98, 99 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
The GNU C Library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with the GNU C Library; see the file COPYING.LIB. If not,
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _FNMATCH_H
#define _FNMATCH_H 1
#ifdef __cplusplus
extern "C" {
#endif
#if defined __cplusplus || (defined __STDC__ && __STDC__) || defined WINDOWS32
# if !defined __GLIBC__ || !defined __P
# undef __P
# define __P(protos) protos
# endif
#else /* Not C++ or ANSI C. */
# undef __P
# define __P(protos) ()
/* We can get away without defining `const' here only because in this file
it is used only inside the prototype for `fnmatch', which is elided in
non-ANSI C where `const' is problematical. */
#endif /* C++ or ANSI C. */
#ifndef const
# if (defined __STDC__ && __STDC__) || defined __cplusplus
# define __const const
# else
# define __const
# endif
#endif
/* We #undef these before defining them because some losing systems
(HP-UX A.08.07 for example) define these in <unistd.h>. */
#undef FNM_PATHNAME
#undef FNM_NOESCAPE
#undef FNM_PERIOD
/* Bits set in the FLAGS argument to `fnmatch'. */
#define FNM_PATHNAME (1 << 0) /* No wildcard can ever match `/'. */
#define FNM_NOESCAPE (1 << 1) /* Backslashes don't quote special chars. */
#define FNM_PERIOD (1 << 2) /* Leading `.' is matched only explicitly. */
#if !defined _POSIX_C_SOURCE || _POSIX_C_SOURCE < 2 || defined _GNU_SOURCE
# define FNM_FILE_NAME FNM_PATHNAME /* Preferred GNU name. */
# define FNM_LEADING_DIR (1 << 3) /* Ignore `/...' after a match. */
# define FNM_CASEFOLD (1 << 4) /* Compare without regard to case. */
#endif
/* Value returned by `fnmatch' if STRING does not match PATTERN. */
#define FNM_NOMATCH 1
/* This value is returned if the implementation does not support
`fnmatch'. Since this is not the case here it will never be
returned but the conformance test suites still require the symbol
to be defined. */
#ifdef _XOPEN_SOURCE
# define FNM_NOSYS (-1)
#endif
/* Match NAME against the filename pattern PATTERN,
returning zero if it matches, FNM_NOMATCH if not. */
extern int fnmatch __P ((__const char *__pattern, __const char *__name,
int __flags));
#ifdef __cplusplus
}
#endif
#endif /* fnmatch.h */

1428
glob/glob.c Normal file

File diff suppressed because it is too large Load Diff

205
glob/glob.h Normal file
View File

@@ -0,0 +1,205 @@
/* Copyright (C) 1991, 92, 95, 96, 97, 98 Free Software Foundation, Inc.
The GNU C Library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
The GNU C Library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with the GNU C Library; see the file COPYING.LIB. If not,
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _GLOB_H
#define _GLOB_H 1
#ifdef __cplusplus
extern "C" {
#endif
#undef __ptr_t
#if defined __cplusplus || (defined __STDC__ && __STDC__) || defined WINDOWS32
# if !defined __GLIBC__ || !defined __P
# undef __P
# undef __PMT
# define __P(protos) protos
# define __PMT(protos) protos
# if !defined __GNUC__ || __GNUC__ < 2
# undef __const
# define __const const
# endif
# endif
# define __ptr_t void *
#else /* Not C++ or ANSI C. */
# undef __P
# undef __PMT
# define __P(protos) ()
# define __PMT(protos) ()
# undef __const
# define __const
# define __ptr_t char *
#endif /* C++ or ANSI C. */
/* We need `size_t' for the following definitions. */
#ifndef __size_t
# if defined __GNUC__ && __GNUC__ >= 2
typedef __SIZE_TYPE__ __size_t;
# else
/* This is a guess. */
/*hb
* Conflicts with DECCs aready defined type __size_t.
* Defining an own type with a name beginning with '__' is no good.
* Anyway if DECC is used and __SIZE_T is defined then __size_t is
* already defined (and I hope it's exactly the one we need here).
*/
#if !(defined __DECC && defined __SIZE_T)
typedef unsigned long int __size_t;
#endif
# endif
#else
/* The GNU CC stddef.h version defines __size_t as empty. We need a real
definition. */
# undef __size_t
# define __size_t size_t
#endif
/* Bits set in the FLAGS argument to `glob'. */
#define GLOB_ERR (1 << 0)/* Return on read errors. */
#define GLOB_MARK (1 << 1)/* Append a slash to each name. */
#define GLOB_NOSORT (1 << 2)/* Don't sort the names. */
#define GLOB_DOOFFS (1 << 3)/* Insert PGLOB->gl_offs NULLs. */
#define GLOB_NOCHECK (1 << 4)/* If nothing matches, return the pattern. */
#define GLOB_APPEND (1 << 5)/* Append to results of a previous call. */
#define GLOB_NOESCAPE (1 << 6)/* Backslashes don't quote metacharacters. */
#define GLOB_PERIOD (1 << 7)/* Leading `.' can be matched by metachars. */
#if (!defined _POSIX_C_SOURCE || _POSIX_C_SOURCE < 2 || defined _BSD_SOURCE \
|| defined _GNU_SOURCE)
# define GLOB_MAGCHAR (1 << 8)/* Set in gl_flags if any metachars seen. */
# define GLOB_ALTDIRFUNC (1 << 9)/* Use gl_opendir et al functions. */
# define GLOB_BRACE (1 << 10)/* Expand "{a,b}" to "a" "b". */
# define GLOB_NOMAGIC (1 << 11)/* If no magic chars, return the pattern. */
# define GLOB_TILDE (1 << 12)/* Expand ~user and ~ to home directories. */
# define GLOB_ONLYDIR (1 << 13)/* Match only directories. */
# define GLOB_TILDE_CHECK (1 << 14)/* Like GLOB_TILDE but return an error
if the user name is not available. */
# define __GLOB_FLAGS (GLOB_ERR|GLOB_MARK|GLOB_NOSORT|GLOB_DOOFFS| \
GLOB_NOESCAPE|GLOB_NOCHECK|GLOB_APPEND| \
GLOB_PERIOD|GLOB_ALTDIRFUNC|GLOB_BRACE| \
GLOB_NOMAGIC|GLOB_TILDE|GLOB_ONLYDIR|GLOB_TILDE_CHECK)
#else
# define __GLOB_FLAGS (GLOB_ERR|GLOB_MARK|GLOB_NOSORT|GLOB_DOOFFS| \
GLOB_NOESCAPE|GLOB_NOCHECK|GLOB_APPEND| \
GLOB_PERIOD)
#endif
/* Error returns from `glob'. */
#define GLOB_NOSPACE 1 /* Ran out of memory. */
#define GLOB_ABORTED 2 /* Read error. */
#define GLOB_NOMATCH 3 /* No matches found. */
#define GLOB_NOSYS 4 /* Not implemented. */
#ifdef _GNU_SOURCE
/* Previous versions of this file defined GLOB_ABEND instead of
GLOB_ABORTED. Provide a compatibility definition here. */
# define GLOB_ABEND GLOB_ABORTED
#endif
/* Structure describing a globbing run. */
#if !defined _AMIGA && !defined VMS /* Buggy compiler. */
struct stat;
#endif
typedef struct
{
__size_t gl_pathc; /* Count of paths matched by the pattern. */
char **gl_pathv; /* List of matched pathnames. */
__size_t gl_offs; /* Slots to reserve in `gl_pathv'. */
int gl_flags; /* Set to FLAGS, maybe | GLOB_MAGCHAR. */
/* If the GLOB_ALTDIRFUNC flag is set, the following functions
are used instead of the normal file access functions. */
void (*gl_closedir) __PMT ((void *));
struct dirent *(*gl_readdir) __PMT ((void *));
__ptr_t (*gl_opendir) __PMT ((__const char *));
int (*gl_lstat) __PMT ((__const char *, struct stat *));
#if defined(VMS) && defined(__DECC) && !defined(_POSIX_C_SOURCE)
int (*gl_stat) __PMT ((__const char *, struct stat *, ...));
#else
int (*gl_stat) __PMT ((__const char *, struct stat *));
#endif
} glob_t;
#ifdef _LARGEFILE64_SOURCE
struct stat64;
typedef struct
{
__size_t gl_pathc;
char **gl_pathv;
__size_t gl_offs;
int gl_flags;
/* If the GLOB_ALTDIRFUNC flag is set, the following functions
are used instead of the normal file access functions. */
void (*gl_closedir) __PMT ((void *));
struct dirent64 *(*gl_readdir) __PMT ((void *));
__ptr_t (*gl_opendir) __PMT ((__const char *));
int (*gl_lstat) __PMT ((__const char *, struct stat64 *));
int (*gl_stat) __PMT ((__const char *, struct stat64 *));
} glob64_t;
#endif
#if _FILE_OFFSET_BITS == 64 && __GNUC__ < 2
# define glob glob64
# define globfree globfree64
#else
# ifdef _LARGEFILE64_SOURCE
extern int glob64 __P ((__const char *__pattern, int __flags,
int (*__errfunc) (__const char *, int),
glob64_t *__pglob));
extern void globfree64 __P ((glob64_t *__pglob));
# endif
#endif
/* Do glob searching for PATTERN, placing results in PGLOB.
The bits defined above may be set in FLAGS.
If a directory cannot be opened or read and ERRFUNC is not nil,
it is called with the pathname that caused the error, and the
`errno' value from the failing call; if it returns non-zero
`glob' returns GLOB_ABEND; if it returns zero, the error is ignored.
If memory cannot be allocated for PGLOB, GLOB_NOSPACE is returned.
Otherwise, `glob' returns zero. */
#if _FILE_OFFSET_BITS != 64 || __GNUC__ < 2
extern int glob __P ((__const char *__pattern, int __flags,
int (*__errfunc) (__const char *, int),
glob_t *__pglob));
/* Free storage allocated in PGLOB by a previous `glob' call. */
extern void globfree __P ((glob_t *__pglob));
#else
extern int glob __P ((__const char *__pattern, int __flags,
int (*__errfunc) (__const char *, int),
glob_t *__pglob)) __asm__ ("glob64");
extern void globfree __P ((glob_t *__pglob)) __asm__ ("globfree64");
#endif
#ifdef _GNU_SOURCE
/* Return nonzero if PATTERN contains any metacharacters.
Metacharacters can be quoted with backslashes if QUOTE is nonzero.
This function is not part of the interface specified by POSIX.2
but several programs want to use it. */
extern int glob_pattern_p __P ((__const char *__pattern, int __quote));
#endif
#ifdef __cplusplus
}
#endif
#endif /* glob.h */

369
hash.c Normal file
View File

@@ -0,0 +1,369 @@
/* hash.c -- hash table maintenance
Copyright (C) 1995, 1999, 2002 Free Software Foundation, Inc.
Written by Greg McGary <gkm@gnu.org> <greg@mcgary.org>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include "make.h"
#include "hash.h"
#define CALLOC(t, n) ((t *) calloc (sizeof (t), (n)))
#define MALLOC(t, n) ((t *) xmalloc (sizeof (t) * (n)))
#define REALLOC(o, t, n) ((t *) xrealloc ((o), sizeof (t) * (n)))
#define CLONE(o, t, n) ((t *) memcpy (MALLOC (t, (n)), (o), sizeof (t) * (n)))
static void hash_rehash __P((struct hash_table* ht));
static unsigned long round_up_2 __P((unsigned long rough));
/* Implement double hashing with open addressing. The table size is
always a power of two. The secondary (`increment') hash function
is forced to return an odd-value, in order to be relatively prime
to the table size. This guarantees that the increment can
potentially hit every slot in the table during collision
resolution. */
void *hash_deleted_item = &hash_deleted_item;
/* Force the table size to be a power of two, possibly rounding up the
given size. */
void
hash_init (ht, size, hash_1, hash_2, hash_cmp)
struct hash_table* ht;
unsigned long size;
hash_func_t hash_1;
hash_func_t hash_2;
hash_cmp_func_t hash_cmp;
{
ht->ht_size = round_up_2 (size);
ht->ht_empty_slots = ht->ht_size;
ht->ht_vec = (void**) CALLOC (struct token *, ht->ht_size);
if (ht->ht_vec == 0)
{
fprintf (stderr, _("can't allocate %ld bytes for hash table: memory exhausted"),
ht->ht_size * sizeof(struct token *));
exit (1);
}
ht->ht_capacity = ht->ht_size - (ht->ht_size / 16); /* 93.75% loading factor */
ht->ht_fill = 0;
ht->ht_collisions = 0;
ht->ht_lookups = 0;
ht->ht_rehashes = 0;
ht->ht_hash_1 = hash_1;
ht->ht_hash_2 = hash_2;
ht->ht_compare = hash_cmp;
}
/* Load an array of items into `ht'. */
void
hash_load (ht, item_table, cardinality, size)
struct hash_table* ht;
void *item_table;
unsigned long cardinality;
unsigned long size;
{
char *items = (char *) item_table;
while (cardinality--)
{
hash_insert (ht, items);
items += size;
}
}
/* Returns the address of the table slot matching `key'. If `key' is
not found, return the address of an empty slot suitable for
inserting `key'. The caller is responsible for incrementing
ht_fill on insertion. */
void **
hash_find_slot (ht, key)
struct hash_table* ht;
void const *key;
{
void **slot;
void **deleted_slot = 0;
unsigned int hash_2 = 0;
unsigned int hash_1 = (*ht->ht_hash_1) (key);
ht->ht_lookups++;
for (;;)
{
hash_1 &= (ht->ht_size - 1);
slot = &ht->ht_vec[hash_1];
if (*slot == 0)
return (deleted_slot ? deleted_slot : slot);
if (*slot == hash_deleted_item)
{
if (deleted_slot == 0)
deleted_slot = slot;
}
else
{
if (key == *slot)
return slot;
if ((*ht->ht_compare) (key, *slot) == 0)
return slot;
ht->ht_collisions++;
}
if (!hash_2)
hash_2 = (*ht->ht_hash_2) (key) | 1;
hash_1 += hash_2;
}
}
void *
hash_find_item (ht, key)
struct hash_table* ht;
void const *key;
{
void **slot = hash_find_slot (ht, key);
return ((HASH_VACANT (*slot)) ? 0 : *slot);
}
void *
hash_insert (ht, item)
struct hash_table* ht;
void *item;
{
void **slot = hash_find_slot (ht, item);
void *old_item = slot ? *slot : 0;
hash_insert_at (ht, item, slot);
return ((HASH_VACANT (old_item)) ? 0 : old_item);
}
void *
hash_insert_at (ht, item, slot)
struct hash_table* ht;
void *item;
void const *slot;
{
void *old_item = *(void **) slot;
if (HASH_VACANT (old_item))
{
ht->ht_fill++;
if (old_item == 0)
ht->ht_empty_slots--;
old_item = item;
}
*(void const **) slot = item;
if (ht->ht_empty_slots < ht->ht_size - ht->ht_capacity)
{
hash_rehash (ht);
return (void *) hash_find_slot (ht, item);
}
else
return (void *) slot;
}
void *
hash_delete (ht, item)
struct hash_table* ht;
void const *item;
{
void **slot = hash_find_slot (ht, item);
return hash_delete_at (ht, slot);
}
void *
hash_delete_at (ht, slot)
struct hash_table* ht;
void const *slot;
{
void *item = *(void **) slot;
if (!HASH_VACANT (item))
{
*(void const **) slot = hash_deleted_item;
ht->ht_fill--;
return item;
}
else
return 0;
}
void
hash_free_items (ht)
struct hash_table* ht;
{
void **vec = ht->ht_vec;
void **end = &vec[ht->ht_size];
for (; vec < end; vec++)
{
void *item = *vec;
if (!HASH_VACANT (item))
free (item);
*vec = 0;
}
ht->ht_fill = 0;
ht->ht_empty_slots = ht->ht_size;
}
void
hash_delete_items (ht)
struct hash_table* ht;
{
void **vec = ht->ht_vec;
void **end = &vec[ht->ht_size];
for (; vec < end; vec++)
*vec = 0;
ht->ht_fill = 0;
ht->ht_collisions = 0;
ht->ht_lookups = 0;
ht->ht_rehashes = 0;
ht->ht_empty_slots = ht->ht_size;
}
void
hash_free (ht, free_items)
struct hash_table* ht;
int free_items;
{
if (free_items)
hash_free_items (ht);
else
{
ht->ht_fill = 0;
ht->ht_empty_slots = ht->ht_size;
}
free (ht->ht_vec);
ht->ht_vec = 0;
ht->ht_capacity = 0;
}
void
hash_map (ht, map)
struct hash_table *ht;
hash_map_func_t map;
{
void **slot;
void **end = &ht->ht_vec[ht->ht_size];
for (slot = ht->ht_vec; slot < end; slot++)
{
if (!HASH_VACANT (*slot))
(*map) (*slot);
}
}
void
hash_map_arg (ht, map, arg)
struct hash_table *ht;
hash_map_arg_func_t map;
void *arg;
{
void **slot;
void **end = &ht->ht_vec[ht->ht_size];
for (slot = ht->ht_vec; slot < end; slot++)
{
if (!HASH_VACANT (*slot))
(*map) (*slot, arg);
}
}
/* Double the size of the hash table in the event of overflow... */
static void
hash_rehash (ht)
struct hash_table* ht;
{
unsigned long old_ht_size = ht->ht_size;
void **old_vec = ht->ht_vec;
void **ovp;
if (ht->ht_fill >= ht->ht_capacity)
{
ht->ht_size *= 2;
ht->ht_capacity = ht->ht_size - (ht->ht_size >> 4);
}
ht->ht_rehashes++;
ht->ht_vec = (void **) CALLOC (struct token *, ht->ht_size);
for (ovp = old_vec; ovp < &old_vec[old_ht_size]; ovp++)
{
if (! HASH_VACANT (*ovp))
{
void **slot = hash_find_slot (ht, *ovp);
*slot = *ovp;
}
}
ht->ht_empty_slots = ht->ht_size - ht->ht_fill;
free (old_vec);
}
void
hash_print_stats (ht, out_FILE)
struct hash_table *ht;
FILE *out_FILE;
{
/* GKM FIXME: honor NO_FLOAT */
fprintf (out_FILE, _("Load=%ld/%ld=%.0f%%, "), ht->ht_fill, ht->ht_size,
100.0 * (double) ht->ht_fill / (double) ht->ht_size);
fprintf (out_FILE, _("Rehash=%d, "), ht->ht_rehashes);
fprintf (out_FILE, _("Collisions=%ld/%ld=%.0f%%"), ht->ht_collisions, ht->ht_lookups,
(ht->ht_lookups
? (100.0 * (double) ht->ht_collisions / (double) ht->ht_lookups)
: 0));
}
/* Dump all items into a NULL-terminated vector. Use the
user-supplied vector, or malloc one. */
void **
hash_dump (ht, vector_0, compare)
struct hash_table *ht;
void **vector_0;
qsort_cmp_t compare;
{
void **vector;
void **slot;
void **end = &ht->ht_vec[ht->ht_size];
if (vector_0 == 0)
vector_0 = MALLOC (void *, ht->ht_fill + 1);
vector = vector_0;
for (slot = ht->ht_vec; slot < end; slot++)
if (!HASH_VACANT (*slot))
*vector++ = *slot;
*vector = 0;
if (compare)
qsort (vector_0, ht->ht_fill, sizeof (void *), compare);
return vector_0;
}
/* Round a given number up to the nearest power of 2. */
static unsigned long
round_up_2 (n)
unsigned long n;
{
n |= (n >> 1);
n |= (n >> 2);
n |= (n >> 4);
n |= (n >> 8);
n |= (n >> 16);
#if !defined(HAVE_LIMITS_H) || ULONG_MAX > 4294967295
/* We only need this on systems where unsigned long is >32 bits. */
n |= (n >> 32);
#endif
return n + 1;
}

233
hash.h Normal file
View File

@@ -0,0 +1,233 @@
/* hash.h -- decls for hash table
Copyright (C) 1995, 1999, 2002 Free Software Foundation, Inc.
Written by Greg McGary <gkm@gnu.org> <greg@mcgary.org>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef _hash_h_
#define _hash_h_
#include <stdio.h>
#include <ctype.h>
#if defined __cplusplus || (defined __STDC__ && __STDC__) || defined WINDOWS32
# if !defined __GLIBC__ || !defined __P
# undef __P
# define __P(protos) protos
# endif
#else /* Not C++ or ANSI C. */
# undef __P
# define __P(protos) ()
/* We can get away without defining `const' here only because in this file
it is used only inside the prototype for `fnmatch', which is elided in
non-ANSI C where `const' is problematical. */
#endif /* C++ or ANSI C. */
typedef unsigned long (*hash_func_t) __P((void const *key));
typedef int (*hash_cmp_func_t) __P((void const *x, void const *y));
typedef void (*hash_map_func_t) __P((void const *item));
typedef void (*hash_map_arg_func_t) __P((void const *item, void *arg));
struct hash_table
{
void **ht_vec;
unsigned long ht_size; /* total number of slots (power of 2) */
unsigned long ht_capacity; /* usable slots, limited by loading-factor */
unsigned long ht_fill; /* items in table */
unsigned long ht_empty_slots; /* empty slots not including deleted slots */
unsigned long ht_collisions; /* # of failed calls to comparison function */
unsigned long ht_lookups; /* # of queries */
unsigned int ht_rehashes; /* # of times we've expanded table */
hash_func_t ht_hash_1; /* primary hash function */
hash_func_t ht_hash_2; /* secondary hash function */
hash_cmp_func_t ht_compare; /* comparison function */
};
typedef int (*qsort_cmp_t) __P((void const *, void const *));
void hash_init __P((struct hash_table *ht, unsigned long size,
hash_func_t hash_1, hash_func_t hash_2, hash_cmp_func_t hash_cmp));
void hash_load __P((struct hash_table *ht, void *item_table,
unsigned long cardinality, unsigned long size));
void **hash_find_slot __P((struct hash_table *ht, void const *key));
void *hash_find_item __P((struct hash_table *ht, void const *key));
void *hash_insert __P((struct hash_table *ht, void *item));
void *hash_insert_at __P((struct hash_table *ht, void *item, void const *slot));
void *hash_delete __P((struct hash_table *ht, void const *item));
void *hash_delete_at __P((struct hash_table *ht, void const *slot));
void hash_delete_items __P((struct hash_table *ht));
void hash_free_items __P((struct hash_table *ht));
void hash_free __P((struct hash_table *ht, int free_items));
void hash_map __P((struct hash_table *ht, hash_map_func_t map));
void hash_map_arg __P((struct hash_table *ht, hash_map_arg_func_t map, void *arg));
void hash_print_stats __P((struct hash_table *ht, FILE *out_FILE));
void **hash_dump __P((struct hash_table *ht, void **vector_0, qsort_cmp_t compare));
extern void *hash_deleted_item;
#define HASH_VACANT(item) ((item) == 0 || (void *) (item) == hash_deleted_item)
/* hash and comparison macros for case-sensitive string keys. */
#define STRING_HASH_1(KEY, RESULT) do { \
unsigned char const *_key_ = (unsigned char const *) (KEY) - 1; \
while (*++_key_) \
(RESULT) += (*_key_ << (_key_[1] & 0xf)); \
} while (0)
#define return_STRING_HASH_1(KEY) do { \
unsigned long _result_ = 0; \
STRING_HASH_1 ((KEY), _result_); \
return _result_; \
} while (0)
#define STRING_HASH_2(KEY, RESULT) do { \
unsigned char const *_key_ = (unsigned char const *) (KEY) - 1; \
while (*++_key_) \
(RESULT) += (*_key_ << (_key_[1] & 0x7)); \
} while (0)
#define return_STRING_HASH_2(KEY) do { \
unsigned long _result_ = 0; \
STRING_HASH_2 ((KEY), _result_); \
return _result_; \
} while (0)
#define STRING_COMPARE(X, Y, RESULT) do { \
RESULT = strcmp ((X), (Y)); \
} while (0)
#define return_STRING_COMPARE(X, Y) do { \
return strcmp ((X), (Y)); \
} while (0)
#define STRING_N_HASH_1(KEY, N, RESULT) do { \
unsigned char const *_key_ = (unsigned char const *) (KEY) - 1; \
int _n_ = (N); \
if (_n_) \
while (--_n_ && *++_key_) \
(RESULT) += (*_key_ << (_key_[1] & 0xf)); \
(RESULT) += *++_key_; \
} while (0)
#define return_STRING_N_HASH_1(KEY, N) do { \
unsigned long _result_ = 0; \
STRING_N_HASH_1 ((KEY), (N), _result_); \
return _result_; \
} while (0)
#define STRING_N_HASH_2(KEY, N, RESULT) do { \
unsigned char const *_key_ = (unsigned char const *) (KEY) - 1; \
int _n_ = (N); \
if (_n_) \
while (--_n_ && *++_key_) \
(RESULT) += (*_key_ << (_key_[1] & 0x7)); \
(RESULT) += *++_key_; \
} while (0)
#define return_STRING_N_HASH_2(KEY, N) do { \
unsigned long _result_ = 0; \
STRING_N_HASH_2 ((KEY), (N), _result_); \
return _result_; \
} while (0)
#define STRING_N_COMPARE(X, Y, N, RESULT) do { \
RESULT = strncmp ((X), (Y), (N)); \
} while (0)
#define return_STRING_N_COMPARE(X, Y, N) do { \
return strncmp ((X), (Y), (N)); \
} while (0)
#ifdef HAVE_CASE_INSENSITIVE_FS
/* hash and comparison macros for case-insensitive string _key_s. */
#define ISTRING_HASH_1(KEY, RESULT) do { \
unsigned char const *_key_ = (unsigned char const *) (KEY) - 1; \
while (*++_key_) \
(RESULT) += ((isupper (*_key_) ? tolower (*_key_) : *_key_) << (_key_[1] & 0xf)); \
} while (0)
#define return_ISTRING_HASH_1(KEY) do { \
unsigned long _result_ = 0; \
ISTRING_HASH_1 ((KEY), _result_); \
return _result_; \
} while (0)
#define ISTRING_HASH_2(KEY, RESULT) do { \
unsigned char const *_key_ = (unsigned char const *) (KEY) - 1; \
while (*++_key_) \
(RESULT) += ((isupper (*_key_) ? tolower (*_key_) : *_key_) << (_key_[1] & 0x7)); \
} while (0)
#define return_ISTRING_HASH_2(KEY) do { \
unsigned long _result_ = 0; \
ISTRING_HASH_2 ((KEY), _result_); \
return _result_; \
} while (0)
#define ISTRING_COMPARE(X, Y, RESULT) do { \
RESULT = strcmpi ((X), (Y)); \
} while (0)
#define return_ISTRING_COMPARE(X, Y) do { \
return strcmpi ((X), (Y)); \
} while (0)
#else
#define ISTRING_HASH_1(KEY, RESULT) STRING_HASH_1 ((KEY), (RESULT))
#define return_ISTRING_HASH_1(KEY) return_STRING_HASH_1 (KEY)
#define ISTRING_HASH_2(KEY, RESULT) STRING_HASH_2 ((KEY), (RESULT))
#define return_ISTRING_HASH_2(KEY) return_STRING_HASH_2 (KEY)
#define ISTRING_COMPARE(X, Y, RESULT) STRING_COMPARE ((X), (Y), (RESULT))
#define return_ISTRING_COMPARE(X, Y) return_STRING_COMPARE ((X), (Y))
#endif
/* hash and comparison macros for integer _key_s. */
#define INTEGER_HASH_1(KEY, RESULT) do { \
(RESULT) += ((unsigned long)(KEY)); \
} while (0)
#define return_INTEGER_HASH_1(KEY) do { \
unsigned long _result_ = 0; \
INTEGER_HASH_1 ((KEY), _result_); \
return _result_; \
} while (0)
#define INTEGER_HASH_2(KEY, RESULT) do { \
(RESULT) += ~((unsigned long)(KEY)); \
} while (0)
#define return_INTEGER_HASH_2(KEY) do { \
unsigned long _result_ = 0; \
INTEGER_HASH_2 ((KEY), _result_); \
return _result_; \
} while (0)
#define INTEGER_COMPARE(X, Y, RESULT) do { \
(RESULT) = X - Y; \
} while (0)
#define return_INTEGER_COMPARE(X, Y) do { \
int _result_; \
INTEGER_COMPARE (X, Y, _result_); \
return _result_; \
} while (0)
/* hash and comparison macros for address keys. */
#define ADDRESS_HASH_1(KEY, RESULT) INTEGER_HASH_1 (((unsigned long)(KEY)) >> 3, (RESULT))
#define ADDRESS_HASH_2(KEY, RESULT) INTEGER_HASH_2 (((unsigned long)(KEY)) >> 3, (RESULT))
#define ADDRESS_COMPARE(X, Y, RESULT) INTEGER_COMPARE ((X), (Y), (RESULT))
#define return_ADDRESS_HASH_1(KEY) return_INTEGER_HASH_1 (((unsigned long)(KEY)) >> 3)
#define return_ADDRESS_HASH_2(KEY) return_INTEGER_HASH_2 (((unsigned long)(KEY)) >> 3)
#define return_ADDRESS_COMPARE(X, Y) return_INTEGER_COMPARE ((X), (Y))
#endif /* not _hash_h_ */

635
implicit.c Normal file
View File

@@ -0,0 +1,635 @@
/* Implicit rule searching for GNU Make.
Copyright (C) 1988,89,90,91,92,93,94,97,2000 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "make.h"
#include "rule.h"
#include "dep.h"
#include "filedef.h"
#include "debug.h"
static int pattern_search PARAMS ((struct file *file, int archive, unsigned int depth,
unsigned int recursions));
/* For a FILE which has no commands specified, try to figure out some
from the implicit pattern rules.
Returns 1 if a suitable implicit rule was found,
after modifying FILE to contain the appropriate commands and deps,
or returns 0 if no implicit rule was found. */
int
try_implicit_rule (file, depth)
struct file *file;
unsigned int depth;
{
DBF (DB_IMPLICIT, _("Looking for an implicit rule for `%s'.\n"));
/* The order of these searches was previously reversed. My logic now is
that since the non-archive search uses more information in the target
(the archive search omits the archive name), it is more specific and
should come first. */
if (pattern_search (file, 0, depth, 0))
return 1;
#ifndef NO_ARCHIVES
/* If this is an archive member reference, use just the
archive member name to search for implicit rules. */
if (ar_name (file->name))
{
DBF (DB_IMPLICIT,
_("Looking for archive-member implicit rule for `%s'.\n"));
if (pattern_search (file, 1, depth, 0))
return 1;
}
#endif
return 0;
}
/* Search the pattern rules for a rule with an existing dependency to make
FILE. If a rule is found, the appropriate commands and deps are put in FILE
and 1 is returned. If not, 0 is returned.
If ARCHIVE is nonzero, FILE->name is of the form "LIB(MEMBER)". A rule for
"(MEMBER)" will be searched for, and "(MEMBER)" will not be chopped up into
directory and filename parts.
If an intermediate file is found by pattern search, the intermediate file
is set up as a target by the recursive call and is also made a dependency
of FILE.
DEPTH is used for debugging messages. */
static int
pattern_search (file, archive, depth, recursions)
struct file *file;
int archive;
unsigned int depth;
unsigned int recursions;
{
/* Filename we are searching for a rule for. */
char *filename = archive ? strchr (file->name, '(') : file->name;
/* Length of FILENAME. */
unsigned int namelen = strlen (filename);
/* The last slash in FILENAME (or nil if there is none). */
char *lastslash;
/* This is a file-object used as an argument in
recursive calls. It never contains any data
except during a recursive call. */
struct file *intermediate_file = 0;
/* List of dependencies found recursively. */
struct file **intermediate_files
= (struct file **) xmalloc (max_pattern_deps * sizeof (struct file *));
/* List of the patterns used to find intermediate files. */
char **intermediate_patterns
= (char **) alloca (max_pattern_deps * sizeof (char *));
/* This buffer records all the dependencies actually found for a rule. */
char **found_files = (char **) alloca (max_pattern_deps * sizeof (char *));
/* Number of dep names now in FOUND_FILES. */
unsigned int deps_found = 0;
/* Names of possible dependencies are constructed in this buffer. */
register char *depname = (char *) alloca (namelen + max_pattern_dep_length);
/* The start and length of the stem of FILENAME for the current rule. */
register char *stem = 0;
register unsigned int stemlen = 0;
register unsigned int fullstemlen = 0;
/* Buffer in which we store all the rules that are possibly applicable. */
struct rule **tryrules
= (struct rule **) xmalloc (num_pattern_rules * max_pattern_targets
* sizeof (struct rule *));
/* Number of valid elements in TRYRULES. */
unsigned int nrules;
/* The numbers of the rule targets of each rule
in TRYRULES that matched the target file. */
unsigned int *matches
= (unsigned int *) alloca (num_pattern_rules * sizeof (unsigned int));
/* Each element is nonzero if LASTSLASH was used in
matching the corresponding element of TRYRULES. */
char *checked_lastslash
= (char *) alloca (num_pattern_rules * sizeof (char));
/* The index in TRYRULES of the rule we found. */
unsigned int foundrule;
/* Nonzero if should consider intermediate files as dependencies. */
int intermed_ok;
/* Nonzero if we have matched a pattern-rule target
that is not just `%'. */
int specific_rule_matched = 0;
register unsigned int i = 0; /* uninit checks OK */
register struct rule *rule;
register struct dep *dep;
char *p, *vp;
#ifndef NO_ARCHIVES
if (archive || ar_name (filename))
lastslash = 0;
else
#endif
{
/* Set LASTSLASH to point at the last slash in FILENAME
but not counting any slash at the end. (foo/bar/ counts as
bar/ in directory foo/, not empty in directory foo/bar/.) */
#ifdef VMS
lastslash = strrchr (filename, ']');
if (lastslash == 0)
lastslash = strrchr (filename, ':');
#else
lastslash = strrchr (filename, '/');
#ifdef HAVE_DOS_PATHS
/* Handle backslashes (possibly mixed with forward slashes)
and the case of "d:file". */
{
char *bslash = strrchr (filename, '\\');
if (lastslash == 0 || bslash > lastslash)
lastslash = bslash;
if (lastslash == 0 && filename[0] && filename[1] == ':')
lastslash = filename + 1;
}
#endif
#endif
if (lastslash != 0 && lastslash[1] == '\0')
lastslash = 0;
}
/* First see which pattern rules match this target
and may be considered. Put them in TRYRULES. */
nrules = 0;
for (rule = pattern_rules; rule != 0; rule = rule->next)
{
/* If the pattern rule has deps but no commands, ignore it.
Users cancel built-in rules by redefining them without commands. */
if (rule->deps != 0 && rule->cmds == 0)
continue;
/* If this rule is in use by a parent pattern_search,
don't use it here. */
if (rule->in_use)
{
DBS (DB_IMPLICIT, (_("Avoiding implicit rule recursion.\n")));
continue;
}
for (i = 0; rule->targets[i] != 0; ++i)
{
char *target = rule->targets[i];
char *suffix = rule->suffixes[i];
int check_lastslash;
/* Rules that can match any filename and are not terminal
are ignored if we're recursing, so that they cannot be
intermediate files. */
if (recursions > 0 && target[1] == '\0' && !rule->terminal)
continue;
if (rule->lens[i] > namelen)
/* It can't possibly match. */
continue;
/* From the lengths of the filename and the pattern parts,
find the stem: the part of the filename that matches the %. */
stem = filename + (suffix - target - 1);
stemlen = namelen - rule->lens[i] + 1;
/* Set CHECK_LASTSLASH if FILENAME contains a directory
prefix and the target pattern does not contain a slash. */
#ifdef VMS
check_lastslash = lastslash != 0
&& ((strchr (target, ']') == 0)
&& (strchr (target, ':') == 0));
#else
check_lastslash = lastslash != 0 && strchr (target, '/') == 0;
#endif
if (check_lastslash)
{
/* In that case, don't include the
directory prefix in STEM here. */
unsigned int difference = lastslash - filename + 1;
if (difference > stemlen)
continue;
stemlen -= difference;
stem += difference;
}
/* Check that the rule pattern matches the text before the stem. */
if (check_lastslash)
{
if (stem > (lastslash + 1)
&& !strneq (target, lastslash + 1, stem - lastslash - 1))
continue;
}
else if (stem > filename
&& !strneq (target, filename, stem - filename))
continue;
/* Check that the rule pattern matches the text after the stem.
We could test simply use streq, but this way we compare the
first two characters immediately. This saves time in the very
common case where the first character matches because it is a
period. */
if (*suffix != stem[stemlen]
|| (*suffix != '\0' && !streq (&suffix[1], &stem[stemlen + 1])))
continue;
/* Record if we match a rule that not all filenames will match. */
if (target[1] != '\0')
specific_rule_matched = 1;
/* A rule with no dependencies and no commands exists solely to set
specific_rule_matched when it matches. Don't try to use it. */
if (rule->deps == 0 && rule->cmds == 0)
continue;
/* Record this rule in TRYRULES and the index of the matching
target in MATCHES. If several targets of the same rule match,
that rule will be in TRYRULES more than once. */
tryrules[nrules] = rule;
matches[nrules] = i;
checked_lastslash[nrules] = check_lastslash;
++nrules;
}
}
/* If we have found a matching rule that won't match all filenames,
retroactively reject any non-"terminal" rules that do always match. */
if (specific_rule_matched)
for (i = 0; i < nrules; ++i)
if (!tryrules[i]->terminal)
{
register unsigned int j;
for (j = 0; tryrules[i]->targets[j] != 0; ++j)
if (tryrules[i]->targets[j][1] == '\0')
break;
if (tryrules[i]->targets[j] != 0)
tryrules[i] = 0;
}
/* Try each rule once without intermediate files, then once with them. */
for (intermed_ok = 0; intermed_ok == !!intermed_ok; ++intermed_ok)
{
/* Try each pattern rule till we find one that applies.
If it does, copy the names of its dependencies (as substituted)
and store them in FOUND_FILES. DEPS_FOUND is the number of them. */
for (i = 0; i < nrules; i++)
{
int check_lastslash;
rule = tryrules[i];
/* RULE is nil when we discover that a rule,
already placed in TRYRULES, should not be applied. */
if (rule == 0)
continue;
/* Reject any terminal rules if we're
looking to make intermediate files. */
if (intermed_ok && rule->terminal)
continue;
/* Mark this rule as in use so a recursive
pattern_search won't try to use it. */
rule->in_use = 1;
/* From the lengths of the filename and the matching pattern parts,
find the stem: the part of the filename that matches the %. */
stem = filename
+ (rule->suffixes[matches[i]] - rule->targets[matches[i]]) - 1;
stemlen = namelen - rule->lens[matches[i]] + 1;
check_lastslash = checked_lastslash[i];
if (check_lastslash)
{
stem += lastslash - filename + 1;
stemlen -= (lastslash - filename) + 1;
}
DBS (DB_IMPLICIT, (_("Trying pattern rule with stem `%.*s'.\n"),
(int) stemlen, stem));
/* Try each dependency; see if it "exists". */
deps_found = 0;
for (dep = rule->deps; dep != 0; dep = dep->next)
{
/* If the dependency name has a %, substitute the stem. */
p = strchr (dep_name (dep), '%');
if (p != 0)
{
register unsigned int i;
if (check_lastslash)
{
/* Copy directory name from the original FILENAME. */
i = lastslash - filename + 1;
bcopy (filename, depname, i);
}
else
i = 0;
bcopy (dep_name (dep), depname + i, p - dep_name (dep));
i += p - dep_name (dep);
bcopy (stem, depname + i, stemlen);
i += stemlen;
strcpy (depname + i, p + 1);
p = depname;
}
else
p = dep_name (dep);
/* P is now the actual dependency name as substituted. */
if (file_impossible_p (p))
{
/* If this dependency has already been ruled
"impossible", then the rule fails and don't
bother trying it on the second pass either
since we know that will fail too. */
DBS (DB_IMPLICIT,
(p == depname
? _("Rejecting impossible implicit prerequisite `%s'.\n")
: _("Rejecting impossible rule prerequisite `%s'.\n"),
p));
tryrules[i] = 0;
break;
}
intermediate_files[deps_found] = 0;
DBS (DB_IMPLICIT,
(p == depname
? _("Trying implicit prerequisite `%s'.\n")
: _("Trying rule prerequisite `%s'.\n"), p));
/* The DEP->changed flag says that this dependency resides in a
nonexistent directory. So we normally can skip looking for
the file. However, if CHECK_LASTSLASH is set, then the
dependency file we are actually looking for is in a different
directory (the one gotten by prepending FILENAME's directory),
so it might actually exist. */
if (lookup_file (p) != 0
|| ((!dep->changed || check_lastslash) && file_exists_p (p)))
{
found_files[deps_found++] = xstrdup (p);
continue;
}
/* This code, given FILENAME = "lib/foo.o", dependency name
"lib/foo.c", and VPATH=src, searches for "src/lib/foo.c". */
vp = p;
if (vpath_search (&vp, (FILE_TIMESTAMP *) 0))
{
DBS (DB_IMPLICIT,
(_("Found prerequisite `%s' as VPATH `%s'\n"), p, vp));
strcpy (vp, p);
found_files[deps_found++] = vp;
continue;
}
/* We could not find the file in any place we should look.
Try to make this dependency as an intermediate file,
but only on the second pass. */
if (intermed_ok)
{
if (intermediate_file == 0)
intermediate_file
= (struct file *) alloca (sizeof (struct file));
DBS (DB_IMPLICIT,
(_("Looking for a rule with intermediate file `%s'.\n"),
p));
bzero ((char *) intermediate_file, sizeof (struct file));
intermediate_file->name = p;
if (pattern_search (intermediate_file, 0, depth + 1,
recursions + 1))
{
p = xstrdup (p);
intermediate_patterns[deps_found]
= intermediate_file->name;
intermediate_file->name = p;
intermediate_files[deps_found] = intermediate_file;
intermediate_file = 0;
/* Allocate an extra copy to go in FOUND_FILES,
because every elt of FOUND_FILES is consumed
or freed later. */
found_files[deps_found] = xstrdup (p);
++deps_found;
continue;
}
/* If we have tried to find P as an intermediate
file and failed, mark that name as impossible
so we won't go through the search again later. */
file_impossible (p);
}
/* A dependency of this rule does not exist.
Therefore, this rule fails. */
break;
}
/* This rule is no longer `in use' for recursive searches. */
rule->in_use = 0;
if (dep != 0)
{
/* This pattern rule does not apply.
If some of its dependencies succeeded,
free the data structure describing them. */
while (deps_found-- > 0)
{
register struct file *f = intermediate_files[deps_found];
free (found_files[deps_found]);
if (f != 0
&& (f->stem < f->name
|| f->stem > f->name + strlen (f->name)))
free (f->stem);
}
}
else
/* This pattern rule does apply. Stop looking for one. */
break;
}
/* If we found an applicable rule without
intermediate files, don't try with them. */
if (i < nrules)
break;
rule = 0;
}
/* RULE is nil if the loop went all the way
through the list and everything failed. */
if (rule == 0)
goto done;
foundrule = i;
/* If we are recursing, store the pattern that matched
FILENAME in FILE->name for use in upper levels. */
if (recursions > 0)
/* Kludge-o-matic */
file->name = rule->targets[matches[foundrule]];
/* FOUND_FILES lists the dependencies for the rule we found.
This includes the intermediate files, if any.
Convert them into entries on the deps-chain of FILE. */
while (deps_found-- > 0)
{
register char *s;
if (intermediate_files[deps_found] != 0)
{
/* If we need to use an intermediate file,
make sure it is entered as a target, with the info that was
found for it in the recursive pattern_search call.
We know that the intermediate file did not already exist as
a target; therefore we can assume that the deps and cmds
of F below are null before we change them. */
struct file *imf = intermediate_files[deps_found];
register struct file *f = enter_file (imf->name);
f->deps = imf->deps;
f->cmds = imf->cmds;
f->stem = imf->stem;
f->also_make = imf->also_make;
imf = lookup_file (intermediate_patterns[deps_found]);
if (imf != 0 && imf->precious)
f->precious = 1;
f->intermediate = 1;
f->tried_implicit = 1;
for (dep = f->deps; dep != 0; dep = dep->next)
{
dep->file = enter_file (dep->name);
/* enter_file uses dep->name _if_ we created a new file. */
if (dep->name != dep->file->name)
free (dep->name);
dep->name = 0;
dep->file->tried_implicit |= dep->changed;
}
}
dep = (struct dep *) xmalloc (sizeof (struct dep));
dep->ignore_mtime = 0;
s = found_files[deps_found];
if (recursions == 0)
{
dep->name = 0;
dep->file = lookup_file (s);
if (dep->file == 0)
/* enter_file consumes S's storage. */
dep->file = enter_file (s);
else
/* A copy of S is already allocated in DEP->file->name.
So we can free S. */
free (s);
}
else
{
dep->name = s;
dep->file = 0;
dep->changed = 0;
}
if (intermediate_files[deps_found] == 0 && tryrules[foundrule]->terminal)
{
/* If the file actually existed (was not an intermediate file),
and the rule that found it was a terminal one, then we want
to mark the found file so that it will not have implicit rule
search done for it. If we are not entering a `struct file' for
it now, we indicate this with the `changed' flag. */
if (dep->file == 0)
dep->changed = 1;
else
dep->file->tried_implicit = 1;
}
dep->next = file->deps;
file->deps = dep;
}
if (!checked_lastslash[foundrule])
{
/* Always allocate new storage, since STEM might be
on the stack for an intermediate file. */
file->stem = savestring (stem, stemlen);
fullstemlen = stemlen;
}
else
{
int dirlen = (lastslash + 1) - filename;
/* We want to prepend the directory from
the original FILENAME onto the stem. */
fullstemlen = dirlen + stemlen;
file->stem = (char *) xmalloc (fullstemlen + 1);
bcopy (filename, file->stem, dirlen);
bcopy (stem, file->stem + dirlen, stemlen);
file->stem[fullstemlen] = '\0';
}
file->cmds = rule->cmds;
/* If this rule builds other targets, too, put the others into FILE's
`also_make' member. */
if (rule->targets[1] != 0)
for (i = 0; rule->targets[i] != 0; ++i)
if (i != matches[foundrule])
{
struct dep *new = (struct dep *) xmalloc (sizeof (struct dep));
/* GKM FIMXE: handle '|' here too */
new->ignore_mtime = 0;
new->name = p = (char *) xmalloc (rule->lens[i] + fullstemlen + 1);
bcopy (rule->targets[i], p,
rule->suffixes[i] - rule->targets[i] - 1);
p += rule->suffixes[i] - rule->targets[i] - 1;
bcopy (file->stem, p, fullstemlen);
p += fullstemlen;
bcopy (rule->suffixes[i], p,
rule->lens[i] - (rule->suffixes[i] - rule->targets[i]) + 1);
new->file = enter_file (new->name);
new->next = file->also_make;
file->also_make = new;
}
done:
free (intermediate_files);
free (tryrules);
return rule != 0;
}

3110
job.c Normal file

File diff suppressed because it is too large Load Diff

83
job.h Normal file
View File

@@ -0,0 +1,83 @@
/* Definitions for managing subprocesses in GNU Make.
Copyright (C) 1992, 1993, 1996, 1999 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef SEEN_JOB_H
#define SEEN_JOB_H
/* Structure describing a running or dead child process. */
struct child
{
struct child *next; /* Link in the chain. */
struct file *file; /* File being remade. */
char **environment; /* Environment for commands. */
char **command_lines; /* Array of variable-expanded cmd lines. */
unsigned int command_line; /* Index into above. */
char *command_ptr; /* Ptr into command_lines[command_line]. */
pid_t pid; /* Child process's ID number. */
#ifdef VMS
int efn; /* Completion event flag number */
int cstatus; /* Completion status */
#endif
char *sh_batch_file; /* Script file for shell commands */
unsigned int remote:1; /* Nonzero if executing remotely. */
unsigned int noerror:1; /* Nonzero if commands contained a `-'. */
unsigned int good_stdin:1; /* Nonzero if this child has a good stdin. */
unsigned int deleted:1; /* Nonzero if targets have been deleted. */
};
extern struct child *children;
extern void new_job PARAMS ((struct file *file));
extern void reap_children PARAMS ((int block, int err));
extern void start_waiting_jobs PARAMS ((void));
extern char **construct_command_argv PARAMS ((char *line, char **restp, struct file *file, char** batch_file));
#ifdef VMS
extern int child_execute_job PARAMS ((char *argv, struct child *child));
#else
extern void child_execute_job PARAMS ((int stdin_fd, int stdout_fd, char **argv, char **envp));
#endif
#ifdef _AMIGA
extern void exec_command PARAMS ((char **argv));
#else
extern void exec_command PARAMS ((char **argv, char **envp));
#endif
extern unsigned int job_slots_used;
extern void block_sigs PARAMS ((void));
#ifdef POSIX
extern void unblock_sigs PARAMS ((void));
#else
#ifdef HAVE_SIGSETMASK
extern int fatal_signal_mask;
#define unblock_sigs() sigsetmask (0)
#else
#define unblock_sigs()
#endif
#endif
#endif /* SEEN_JOB_H */

31
loadtest.c Normal file
View File

@@ -0,0 +1,31 @@
extern volatile void exit (int);
extern double load_average (void);
double max_load_average = -1;
unsigned int job_slots_used = 0;
int
main ()
{
printf ("load_average () = %.2f\n", load_average ());
exit (0);
}
void
error (char *fmt, ...)
{
exit (1);
}
void
perror_with_name (char *a, char *b)
{
exit (1);
}
void
wait_for_children (int i)
{
return;
}

2813
main.c Normal file

File diff suppressed because it is too large Load Diff

227
maintMakefile Normal file
View File

@@ -0,0 +1,227 @@
# Maintainer-only makefile segment. This contains things that are relevant
# only if you have the full copy of the GNU make sources from the CVS
# tree, not a dist copy.
#
# Find the glob source files... this might be dangerous, but we're maintainers!
#
globsrc := $(wildcard glob/*.c)
globhdr := $(wildcard glob/*.h)
TEMPLATES = README README.DOS README.W32 \
config.ami configh.dos config.h.W32 config.h-vms
MTEMPLATES = Makefile.DOS SMakefile
all-am: $(TEMPLATES) $(MTEMPLATES) build.sh.in
# We need this to ensure that README and build.sh.in are created on time to
# avoid errors by automake.
#
#Makefile.in: README build.sh.in
# General rule for turning a .template into a regular file.
#
$(TEMPLATES) : % : %.template Makefile
rm -f $@
sed -e 's@%VERSION%@$(VERSION)@g' \
-e 's@%PACKAGE%@$(PACKAGE)@g' \
$< > $@
chmod a-w $@
# Construct Makefiles by adding on dependencies, etc.
#
$(MTEMPLATES) : % : %.template .dep_segment Makefile
rm -f $@
sed -e 's@%VERSION%@$(VERSION)@g' \
-e 's@%PROGRAMS%@$(bin_PROGRAMS)@g' \
-e 's@%SOURCES%@$(filter-out remote-%,$(make_SOURCES)) remote-$$(REMOTE).c@g' \
-e 's@%OBJECTS%@$(filter-out remote-%,$(make_OBJECTS)) remote-$$(REMOTE).o@g' \
-e 's@%GLOB_SOURCES%@$(globsrc) $(globhdr)@g' \
-e 's@%GLOB_OBJECTS%@$(globsrc:glob/%.c=%.o)@g' \
$< > $@
echo >>$@; echo '# --------------- DEPENDENCIES' >>$@; echo '#' >>$@; \
cat $(word 2,$^) >>$@
chmod a-w $@
NMakefile: NMakefile.template .dep_segment Makefile
rm -f $@
cp $< $@
echo >>$@; echo '# --------------- DEPENDENCIES' >>$@; echo '#' >>$@; \
sed 's/^\([^ ]*\)\.o:/$$(OUTDIR)\/\1.obj:/' $(word 2,$^) >>$@
chmod a-w $@
# Construct build.sh.in
#
build.sh.in: build.template Makefile
rm -f $@
sed -e 's@%objs%@$(filter-out remote-%,$(make_OBJECTS)@g' \
-e 's@%globobjs%@$(patsubst %.c,%.o,$(globsrc)))@g' \
$< > $@
chmod a-w+x $@
# Use automake to build a dependency list file, for "foreign" makefiles like
# Makefile.DOS.
#
# Automake used to have a --generate-deps flag, but it's gone now, so we have
# to do it ourselves.
#
.dep_segment: Makefile.am maintMakefile $(DEP_FILES)
cat $(DEP_FILES) \
| sed -e '/^[^:]*\.[ch] *:/d' \
-e 's, /usr/[^ ]*,,g' \
-e 's, $(srcdir)/, ,g' \
-e '/^ \\$$/d' \
> $@
# Get rid of everything "else".
#
maintFILES = configure aclocal.m4 config.h.in Makefile.in stamp-h.in
CVS-CLEAN-FILES += $(maintFILES) $(TEMPLATES) $(MTEMPLATES) NMakefile \
missing build.sh.in .dep_segment
# This rule tries to clean the tree right down to how it looks when you do a
# virgin CVS checkout.
.PHONY: cvs-clean
cvs-clean: maintainer-clean
-rm -f *~
-rm -f config/*~ config/Makefile.in config/[a-z]*
-rm -f po/*~ po/Makefile.in.in po/Rules-quot po/[a-z]*
-rm -f doc/*~ doc/Makefile.in doc/fdl.texi doc/make-stds.texi \
doc/texinfo.tex
-rm -f glob/*~ glob/Makefile.in
-rm -f ABOUT-NLS $(CVS-CLEAN-FILES)
# ----------------------------------------------------------------------
#
# The sections below were stolen from the Makefile.maint used by fileutils,
# sh-utils, textutils, CPPI, Bison, and Autoconf.
## ---------------- ##
## Updating files. ##
## ---------------- ##
WGET = wget --passive-ftp --non-verbose
ftp-gnu = ftp://ftp.gnu.org/gnu
move_if_change = if test -r $(target) && cmp -s $(target).t $(target); then \
echo $(target) is unchanged; rm -f $(target).t; \
else \
mv $(target).t $(target); \
fi
# ------------------- #
# Updating PO files. #
# ------------------- #
po_repo = http://www.iro.umontreal.ca/contrib/po/maint/$(PACKAGE)
.PHONY: do-po-update po-update
do-po-update:
tmppo=/tmp/$(PACKAGE)-$(VERSION)-po &&\
rm -rf $$tmppo && \
mkdir $$tmppo && \
(cd $$tmppo && $(WGET) -r -l1 -nd --no-parent -A '*.po' $(po_repo)) &&\
cp $$tmppo/*.po po
cd po && $(MAKE) update-po
$(MAKE) po-check
po-update:
if test -d "po"; then \
$(MAKE) do-po-update; \
fi
# -------------------------- #
# Updating GNU build tools. #
# -------------------------- #
# The following pseudo table associates a local directory and a URL
# with each of the files that belongs to some other package and is
# regularly updated from the specified URL.
# $(srcdir)/src/ansi2knr.c
wget_files ?= $(srcdir)/config/config.guess $(srcdir)/config/config.sub \
$(srcdir)/doc/texinfo.tex $(srcdir)/doc/make-stds.texi \
$(srcdir)/doc/fdl.texi
wget-targets = $(patsubst %, get-%, $(wget_files))
config.guess-url_prefix = $(ftp-gnu)/config/
config.sub-url_prefix = $(ftp-gnu)/config/
ansi2knr.c-url_prefix = ftp://ftp.cs.wisc.edu/ghost/
texinfo.tex-url_prefix = $(ftp-gnu)/texinfo/
standards.texi-url_prefix = $(ftp-gnu)/GNUinfo/
make-stds.texi-url_prefix = $(ftp-gnu)/GNUinfo/
fdl.texi-url_prefix = $(ftp-gnu)/GNUinfo/
target = $(patsubst get-%,%,$@)
url = $($(notdir $(target))-url_prefix)$(notdir $(target))
.PHONY: $(wget-targets)
$(wget-targets):
@echo $(WGET) $(url) -O $(target) \
&& $(WGET) $(url) -O $(target).t \
&& $(move_if_change)
.PHONY: wget-update
wget-update: $(wget-targets)
# Updating tools via CVS.
cvs_files ?= depcomp missing
cvs-targets = $(patsubst %, get-%, $(cvs_files))
automake_repo = :pserver:anoncvs@anoncvs.cygnus.com:/cvs/automake
.PHONY: $(cvs-targets)
$(cvs-targets):
$(CVS) -d $(automake_repo) co -p automake/lib/$(notdir $(target)) \
>$(target).t \
&& $(move_if_change)
.PHONY: cvs-update
cvs-update: $(cvs-targets)
# --------------------- #
# Updating everything. #
# --------------------- #
.PHONY: update
update: wget-update po-update
# cvs-update
## --------------- ##
## Sanity checks. ##
## --------------- ##
# Checks that don't require cvs. Run `changelog-check' last as
# previous test may reveal problems requiring new ChangeLog entries.
local-check: po-check changelog-check
# copyright-check writable-files
changelog-check:
if head ChangeLog | grep 'Version $(VERSION)' >/dev/null; then \
:; \
else \
echo "$(VERSION) not in ChangeLog" 1>&2; \
exit 1; \
fi
# Verify that all source files using _() are listed in po/POTFILES.in.
po-check:
if test -f po/POTFILES.in; then \
grep -E -v '^(#|$$)' po/POTFILES.in | sort > $@-1; \
grep -E -l '\b_\(' *.c | sort > $@-2; \
diff -u $@-1 $@-2 || exit 1; \
rm -f $@-1 $@-2; \
fi

291
make.1 Normal file
View File

@@ -0,0 +1,291 @@
.TH MAKE 1L "22 August 1989" "GNU" "LOCAL USER COMMANDS"
.SH NAME
make \- GNU make utility to maintain groups of programs
.SH SYNOPSIS
.B "make "
[
.B \-f
.I makefile
] [ option ] ...
target ...
.SH WARNING
This man page is an extract of the documentation of
.I GNU make .
It is updated only occasionally, because the GNU project does not use nroff.
For complete, current documentation, refer to the Info file
.B make.info
which is made from the Texinfo source file
.BR make.texinfo .
.SH DESCRIPTION
.LP
The purpose of the
.I make
utility is to determine automatically which
pieces of a large program need to be recompiled, and issue the commands to
recompile them.
The manual describes the GNU implementation of
.IR make ,
which was written by Richard Stallman and Roland McGrath.
Our examples show C programs, since they are most common, but you can use
.I make
with any programming language whose compiler can be run with a
shell command.
In fact,
.I make
is not limited to programs.
You can use it to describe any task where some files must be
updated automatically from others whenever the others change.
.LP
To prepare to use
.IR make ,
you must write a file called the
.I makefile
that describes the relationships among files in your program, and the
states the commands for updating each file.
In a program, typically the executable file is updated from object
files, which are in turn made by compiling source files.
.LP
Once a suitable makefile exists, each time you change some source files,
this simple shell command:
.sp 1
.RS
.B make
.RE
.sp 1
suffices to perform all necessary recompilations.
The
.I make
program uses the makefile data base and the last-modification times
of the files to decide which of the files need to be updated.
For each of those files, it issues the commands recorded in the data base.
.LP
.I make
executes commands in the
.I makefile
to update
one or more target
.IR names ,
where
.I name
is typically a program.
If no
.B \-f
option is present,
.I make
will look for the makefiles
.IR GNUmakefile ,
.IR makefile ,
and
.IR Makefile ,
in that order.
.LP
Normally you should call your makefile either
.I makefile
or
.IR Makefile .
(We recommend
.I Makefile
because it appears prominently near the beginning of a directory
listing, right near other important files such as
.IR README .)
The first name checked,
.IR GNUmakefile ,
is not recommended for most makefiles.
You should use this name if you have a makefile that is specific to GNU
.IR make ,
and will not be understood by other versions of
.IR make .
If
.I makefile
is `\-', the standard input is read.
.LP
.I make
updates a target if it depends on prerequisite files
that have been modified since the target was last modified,
or if the target does not exist.
.SH OPTIONS
.sp 1
.TP 0.5i
.B \-b
.TP 0.5i
.B \-m
These options are ignored for compatibility with other versions of
.IR make .
.TP 0.5i
.BI "\-C " dir
Change to directory
.I dir
before reading the makefiles or doing anything else.
If multiple
.B \-C
options are specified, each is interpreted relative to the
previous one:
.BR "\-C " /
.BR "\-C " etc
is equivalent to
.BR "\-C " /etc.
This is typically used with recursive invocations of
.IR make .
.TP 0.5i
.B \-d
Print debugging information in addition to normal processing.
The debugging information says which files are being considered for
remaking, which file-times are being compared and with what results,
which files actually need to be remade, which implicit rules are
considered and which are applied---everything interesting about how
.I make
decides what to do.
.TP 0.5i
.B \-e
Give variables taken from the environment precedence
over variables from makefiles.
.TP 0.5i
.BI "\-f " file
Use
.I file
as a makefile.
.TP 0.5i
.B \-i
Ignore all errors in commands executed to remake files.
.TP 0.5i
.BI "\-I " dir
Specifies a directory
.I dir
to search for included makefiles.
If several
.B \-I
options are used to specify several directories, the directories are
searched in the order specified.
Unlike the arguments to other flags of
.IR make ,
directories given with
.B \-I
flags may come directly after the flag:
.BI \-I dir
is allowed, as well as
.BI "\-I " dir.
This syntax is allowed for compatibility with the C
preprocessor's
.B \-I
flag.
.TP 0.5i
.BI "\-j " jobs
Specifies the number of jobs (commands) to run simultaneously.
If there is more than one
.B \-j
option, the last one is effective.
If the
.B \-j
option is given without an argument,
.IR make
will not limit the number of jobs that can run simultaneously.
.TP 0.5i
.B \-k
Continue as much as possible after an error.
While the target that failed, and those that depend on it, cannot
be remade, the other dependencies of these targets can be processed
all the same.
.TP 0.5i
.B \-l
.TP 0.5i
.BI "\-l " load
Specifies that no new jobs (commands) should be started if there are
others jobs running and the load average is at least
.I load
(a floating-point number).
With no argument, removes a previous load limit.
.TP 0.5i
.B \-n
Print the commands that would be executed, but do not execute them.
.TP 0.5i
.BI "\-o " file
Do not remake the file
.I file
even if it is older than its dependencies, and do not remake anything
on account of changes in
.IR file .
Essentially the file is treated as very old and its rules are ignored.
.TP 0.5i
.B \-p
Print the data base (rules and variable values) that results from
reading the makefiles; then execute as usual or as otherwise
specified.
This also prints the version information given by the
.B \-v
switch (see below).
To print the data base without trying to remake any files, use
.B make
.B \-p
.BI \-f /dev/null.
.TP 0.5i
.B \-q
``Question mode''.
Do not run any commands, or print anything; just return an exit status
that is zero if the specified targets are already up to date, nonzero
otherwise.
.TP 0.5i
.B \-r
Eliminate use of the built-in implicit rules.
Also clear out the default list of suffixes for suffix rules.
.TP 0.5i
.B \-s
Silent operation; do not print the commands as they are executed.
.TP 0.5i
.B \-S
Cancel the effect of the
.B \-k
option.
This is never necessary except in a recursive
.I make
where
.B \-k
might be inherited from the top-level
.I make
via MAKEFLAGS or if you set
.B \-k
in MAKEFLAGS in your environment.
.TP 0.5i
.B \-t
Touch files (mark them up to date without really changing them)
instead of running their commands.
This is used to pretend that the commands were done, in order to fool
future invocations of
.IR make .
.TP 0.5i
.B \-v
Print the version of the
.I make
program plus a copyright, a list of authors and a notice that there
is no warranty.
.TP 0.5i
.B \-w
Print a message containing the working directory
before and after other processing.
This may be useful for tracking down errors from complicated nests of
recursive
.I make
commands.
.TP 0.5i
.BI "\-W " file
Pretend that the target
.I file
has just been modified.
When used with the
.B \-n
flag, this shows you what would happen if you were to modify that file.
Without
.BR \-n ,
it is almost the same as running a
.I touch
command on the given file before running
.IR make ,
except that the modification time is changed only in the imagination of
.IR make .
.SH "SEE ALSO"
.I "The GNU Make Manual"
.SH BUGS
See the chapter `Problems and Bugs' in
.I "The GNU Make Manual" .
.SH AUTHOR
This manual page contributed by Dennis Morse of Stanford University.
It has been reworked by Roland McGrath.

562
make.h Normal file
View File

@@ -0,0 +1,562 @@
/* Miscellaneous global declarations and portability cruft for GNU Make.
Copyright (C) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1999,
2002 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/* We use <config.h> instead of "config.h" so that a compilation
using -I. -I$srcdir will use ./config.h rather than $srcdir/config.h
(which it would do because make.h was found in $srcdir). */
#include <config.h>
#undef HAVE_CONFIG_H
#define HAVE_CONFIG_H 1
/* AIX requires this to be the first thing in the file. */
#ifndef __GNUC__
# if HAVE_ALLOCA_H
# include <alloca.h>
# else
# ifdef _AIX
#pragma alloca
# else
# ifndef alloca /* predefined by HP cc +Olibcalls */
char *alloca ();
# endif
# endif
# endif
#endif
/* Use prototypes if available. */
#if defined (__cplusplus) || (defined (__STDC__) && __STDC__)
# undef PARAMS
# define PARAMS(protos) protos
#else /* Not C++ or ANSI C. */
# undef PARAMS
# define PARAMS(protos) ()
#endif /* C++ or ANSI C. */
/* Specify we want GNU source code. This must be defined before any
system headers are included. */
#define _GNU_SOURCE 1
#ifdef CRAY
/* This must happen before #include <signal.h> so
that the declaration therein is changed. */
# define signal bsdsignal
#endif
/* If we're compiling for the dmalloc debugger, turn off string inlining. */
#if defined(HAVE_DMALLOC_H) && defined(__GNUC__)
# define __NO_STRING_INLINES
#endif
#include <sys/types.h>
#include <sys/stat.h>
#include <signal.h>
#include <stdio.h>
#include <ctype.h>
#ifdef HAVE_SYS_TIMEB_H
/* SCO 3.2 "devsys 4.2" has a prototype for `ftime' in <time.h> that bombs
unless <sys/timeb.h> has been included first. Does every system have a
<sys/timeb.h>? If any does not, configure should check for it. */
# include <sys/timeb.h>
#endif
#if TIME_WITH_SYS_TIME
# include <sys/time.h>
# include <time.h>
#else
# if HAVE_SYS_TIME_H
# include <sys/time.h>
# else
# include <time.h>
# endif
#endif
#include <errno.h>
#ifndef errno
extern int errno;
#endif
#ifndef isblank
# define isblank(c) ((c) == ' ' || (c) == '\t')
#endif
#ifdef HAVE_UNISTD_H
# include <unistd.h>
/* Ultrix's unistd.h always defines _POSIX_VERSION, but you only get
POSIX.1 behavior with `cc -YPOSIX', which predefines POSIX itself! */
# if defined (_POSIX_VERSION) && !defined (ultrix) && !defined (VMS)
# define POSIX 1
# endif
#endif
/* Some systems define _POSIX_VERSION but are not really POSIX.1. */
#if (defined (butterfly) || defined (__arm) || (defined (__mips) && defined (_SYSTYPE_SVR3)) || (defined (sequent) && defined (i386)))
# undef POSIX
#endif
#if !defined (POSIX) && defined (_AIX) && defined (_POSIX_SOURCE)
# define POSIX 1
#endif
#ifndef RETSIGTYPE
# define RETSIGTYPE void
#endif
#ifndef sigmask
# define sigmask(sig) (1 << ((sig) - 1))
#endif
#ifndef HAVE_SA_RESTART
# define SA_RESTART 0
#endif
#ifdef HAVE_LIMITS_H
# include <limits.h>
#endif
#ifdef HAVE_SYS_PARAM_H
# include <sys/param.h>
#endif
#ifndef PATH_MAX
# ifndef POSIX
# define PATH_MAX MAXPATHLEN
# endif
#endif
#ifndef MAXPATHLEN
# define MAXPATHLEN 1024
#endif
#ifdef PATH_MAX
# define GET_PATH_MAX PATH_MAX
# define PATH_VAR(var) char var[PATH_MAX]
#else
# define NEED_GET_PATH_MAX 1
# define GET_PATH_MAX (get_path_max ())
# define PATH_VAR(var) char *var = (char *) alloca (GET_PATH_MAX)
extern unsigned int get_path_max PARAMS ((void));
#endif
#ifndef CHAR_BIT
# define CHAR_BIT 8
#endif
/* Nonzero if the integer type T is signed. */
#define INTEGER_TYPE_SIGNED(t) ((t) -1 < 0)
/* The minimum and maximum values for the integer type T.
Use ~ (t) 0, not -1, for portability to 1's complement hosts. */
#define INTEGER_TYPE_MINIMUM(t) \
(! INTEGER_TYPE_SIGNED (t) ? (t) 0 : ~ (t) 0 << (sizeof (t) * CHAR_BIT - 1))
#define INTEGER_TYPE_MAXIMUM(t) (~ (t) 0 - INTEGER_TYPE_MINIMUM (t))
#ifndef CHAR_MAX
# define CHAR_MAX INTEGER_TYPE_MAXIMUM (char)
#endif
#ifdef STAT_MACROS_BROKEN
# ifdef S_ISREG
# undef S_ISREG
# endif
# ifdef S_ISDIR
# undef S_ISDIR
# endif
#endif /* STAT_MACROS_BROKEN. */
#ifndef S_ISREG
# define S_ISREG(mode) (((mode) & S_IFMT) == S_IFREG)
#endif
#ifndef S_ISDIR
# define S_ISDIR(mode) (((mode) & S_IFMT) == S_IFDIR)
#endif
#ifdef VMS
# include <types.h>
# include <unixlib.h>
# include <unixio.h>
# include <perror.h>
/* Needed to use alloca on VMS. */
# include <builtins.h>
#endif
#ifndef __attribute__
/* This feature is available in gcc versions 2.5 and later. */
# if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 5) || __STRICT_ANSI__
# define __attribute__(x)
# endif
/* The __-protected variants of `format' and `printf' attributes
are accepted by gcc versions 2.6.4 (effectively 2.7) and later. */
# if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 7)
# define __format__ format
# define __printf__ printf
# endif
#endif
#if defined (STDC_HEADERS) || defined (__GNU_LIBRARY__)
# include <stdlib.h>
# include <string.h>
# define ANSI_STRING 1
#else /* No standard headers. */
# ifdef HAVE_STRING_H
# include <string.h>
# define ANSI_STRING 1
# else
# include <strings.h>
# endif
# ifdef HAVE_MEMORY_H
# include <memory.h>
# endif
# ifdef HAVE_STDLIB_H
# include <stdlib.h>
# else
extern char *malloc PARAMS ((int));
extern char *realloc PARAMS ((char *, int));
extern void free PARAMS ((char *));
extern void abort PARAMS ((void)) __attribute__ ((noreturn));
extern void exit PARAMS ((int)) __attribute__ ((noreturn));
# endif /* HAVE_STDLIB_H. */
#endif /* Standard headers. */
/* These should be in stdlib.h. Make sure we have them. */
#ifndef EXIT_SUCCESS
# define EXIT_SUCCESS 0
#endif
#ifndef EXIT_FAILURE
# define EXIT_FAILURE 0
#endif
#ifdef ANSI_STRING
# ifndef bcmp
# define bcmp(s1, s2, n) memcmp ((s1), (s2), (n))
# endif
# ifndef bzero
# define bzero(s, n) memset ((s), 0, (n))
# endif
# if defined(HAVE_MEMMOVE) && !defined(bcopy)
# define bcopy(s, d, n) memmove ((d), (s), (n))
# endif
#else /* Not ANSI_STRING. */
# ifndef HAVE_STRCHR
# define strchr(s, c) index((s), (c))
# define strrchr(s, c) rindex((s), (c))
# endif
# ifndef bcmp
extern int bcmp PARAMS ((const char *, const char *, int));
# endif
# ifndef bzero
extern void bzero PARAMS ((char *, int));
#endif
# ifndef bcopy
extern void bcopy PARAMS ((const char *b1, char *b2, int));
# endif
#endif /* ANSI_STRING. */
#undef ANSI_STRING
/* SCO Xenix has a buggy macro definition in <string.h>. */
#undef strerror
#if !defined(ANSI_STRING) && !defined(__DECC)
extern char *strerror PARAMS ((int errnum));
#endif
#if HAVE_INTTYPES_H
# include <inttypes.h>
#endif
#define FILE_TIMESTAMP uintmax_t
#if !defined(HAVE_STRSIGNAL)
extern char *strsignal PARAMS ((int signum));
#endif
/* ISDIGIT offers the following features:
- Its arg may be any int or unsigned int; it need not be an unsigned char.
- It's guaranteed to evaluate its argument exactly once.
NOTE! Make relies on this behavior, don't change it!
- It's typically faster.
POSIX 1003.2-1992 section 2.5.2.1 page 50 lines 1556-1558 says that
only '0' through '9' are digits. Prefer ISDIGIT to isdigit() unless
it's important to use the locale's definition of `digit' even when the
host does not conform to POSIX. */
#define ISDIGIT(c) ((unsigned) (c) - '0' <= 9)
#ifndef iAPX286
# define streq(a, b) \
((a) == (b) || \
(*(a) == *(b) && (*(a) == '\0' || !strcmp ((a) + 1, (b) + 1))))
# ifdef HAVE_CASE_INSENSITIVE_FS
/* This is only used on Windows/DOS platforms, so we assume strcmpi(). */
# define strieq(a, b) \
((a) == (b) \
|| (tolower((unsigned char)*(a)) == tolower((unsigned char)*(b)) \
&& (*(a) == '\0' || !strcmpi ((a) + 1, (b) + 1))))
# else
# define strieq(a, b) streq(a, b)
# endif
#else
/* Buggy compiler can't handle this. */
# define streq(a, b) (strcmp ((a), (b)) == 0)
# define strieq(a, b) (strcmp ((a), (b)) == 0)
#endif
#define strneq(a, b, l) (strncmp ((a), (b), (l)) == 0)
#ifdef VMS
extern int strcmpi (const char *,const char *);
#endif
#if defined(__GNUC__) || defined(ENUM_BITFIELDS)
# define ENUM_BITFIELD(bits) :bits
#else
# define ENUM_BITFIELD(bits)
#endif
/* Handle gettext and locales. */
#if HAVE_LOCALE_H
# include <locale.h>
#else
# define setlocale(category, locale)
#endif
#include <gettext.h>
#define _(msgid) gettext (msgid)
#define N_(msgid) gettext_noop (msgid)
#define S_(msg1,msg2,num) ngettext (msg1,msg2,num)
/* Handle other OSs. */
#if defined(__MSDOS__) || defined(WINDOWS32)
# define PATH_SEPARATOR_CHAR ';'
#else
# if defined(VMS)
# define PATH_SEPARATOR_CHAR ','
# else
# define PATH_SEPARATOR_CHAR ':'
# endif
#endif
#ifdef WINDOWS32
# include <fcntl.h>
# include <malloc.h>
# define pipe(p) _pipe(p, 512, O_BINARY)
# define kill(pid,sig) w32_kill(pid,sig)
extern void sync_Path_environment(void);
extern int kill(int pid, int sig);
extern int safe_stat(char *file, struct stat *sb);
extern char *end_of_token_w32(char *s, char stopchar);
extern int find_and_set_default_shell(char *token);
/* indicates whether or not we have Bourne shell */
extern int no_default_sh_exe;
/* is default_shell unixy? */
extern int unixy_shell;
#endif /* WINDOWS32 */
struct floc
{
char *filenm;
unsigned long lineno;
};
#define NILF ((struct floc *)0)
#define STRING_SIZE_TUPLE(_s) (_s), (sizeof (_s)-1)
/* Fancy processing for variadic functions in both ANSI and pre-ANSI
compilers. */
#if defined __STDC__ && __STDC__
extern void message (int prefix, const char *fmt, ...)
__attribute__ ((__format__ (__printf__, 2, 3)));
extern void error (const struct floc *flocp, const char *fmt, ...)
__attribute__ ((__format__ (__printf__, 2, 3)));
extern void fatal (const struct floc *flocp, const char *fmt, ...)
__attribute__ ((noreturn, __format__ (__printf__, 2, 3)));
#else
extern void message ();
extern void error ();
extern void fatal ();
#endif
extern void die PARAMS ((int)) __attribute__ ((noreturn));
extern void log_working_directory PARAMS ((int));
extern void pfatal_with_name PARAMS ((const char *)) __attribute__ ((noreturn));
extern void perror_with_name PARAMS ((const char *, const char *));
extern char *savestring PARAMS ((const char *, unsigned int));
extern char *concat PARAMS ((const char *, const char *, const char *));
extern char *xmalloc PARAMS ((unsigned int));
extern char *xrealloc PARAMS ((char *, unsigned int));
extern char *xstrdup PARAMS ((const char *));
extern char *find_next_token PARAMS ((char **, unsigned int *));
extern char *next_token PARAMS ((const char *));
extern char *end_of_token PARAMS ((char *));
extern void collapse_continuations PARAMS ((char *));
extern void remove_comments PARAMS((char *));
extern char *sindex PARAMS ((const char *, unsigned int, \
const char *, unsigned int));
extern char *lindex PARAMS ((const char *, const char *, int));
extern int alpha_compare PARAMS ((const void *, const void *));
extern void print_spaces PARAMS ((unsigned int));
extern char *find_char_unquote PARAMS ((char *, int, int, int));
extern char *find_percent PARAMS ((char *));
extern FILE *open_tmpfile PARAMS ((char **, const char *));
#ifndef NO_ARCHIVES
extern int ar_name PARAMS ((char *));
extern void ar_parse_name PARAMS ((char *, char **, char **));
extern int ar_touch PARAMS ((char *));
extern time_t ar_member_date PARAMS ((char *));
#endif
extern int dir_file_exists_p PARAMS ((char *, char *));
extern int file_exists_p PARAMS ((char *));
extern int file_impossible_p PARAMS ((char *));
extern void file_impossible PARAMS ((char *));
extern char *dir_name PARAMS ((char *));
extern void hash_init_directories PARAMS ((void));
extern void define_default_variables PARAMS ((void));
extern void set_default_suffixes PARAMS ((void));
extern void install_default_suffix_rules PARAMS ((void));
extern void install_default_implicit_rules PARAMS ((void));
extern void build_vpath_lists PARAMS ((void));
extern void construct_vpath_list PARAMS ((char *pattern, char *dirpath));
extern int vpath_search PARAMS ((char **file, FILE_TIMESTAMP *mtime_ptr));
extern int gpath_search PARAMS ((char *file, int len));
extern void construct_include_path PARAMS ((char **arg_dirs));
extern void user_access PARAMS ((void));
extern void make_access PARAMS ((void));
extern void child_access PARAMS ((void));
#ifdef HAVE_VFORK_H
# include <vfork.h>
#endif
/* We omit these declarations on non-POSIX systems which define _POSIX_VERSION,
because such systems often declare them in header files anyway. */
#if !defined (__GNU_LIBRARY__) && !defined (POSIX) && !defined (_POSIX_VERSION) && !defined(WINDOWS32)
extern long int atol ();
# ifndef VMS
extern long int lseek ();
# endif
#endif /* Not GNU C library or POSIX. */
#ifdef HAVE_GETCWD
# if !defined(VMS) && !defined(__DECC)
extern char *getcwd ();
#endif
#else
extern char *getwd ();
# define getcwd(buf, len) getwd (buf)
#endif
extern const struct floc *reading_file;
extern char **environ;
extern int just_print_flag, silent_flag, ignore_errors_flag, keep_going_flag;
extern int print_data_base_flag, question_flag, touch_flag, always_make_flag;
extern int env_overrides, no_builtin_rules_flag, no_builtin_variables_flag;
extern int print_version_flag, print_directory_flag;
extern int warn_undefined_variables_flag, posix_pedantic, not_parallel;
extern int clock_skew_detected;
/* can we run commands via 'sh -c xxx' or must we use batch files? */
extern int batch_mode_shell;
extern unsigned int job_slots;
extern int job_fds[2];
extern int job_rfd;
#ifndef NO_FLOAT
extern double max_load_average;
#else
extern int max_load_average;
#endif
extern char *program;
extern char *starting_directory;
extern unsigned int makelevel;
extern char *version_string, *remote_description;
extern unsigned int commands_started;
extern int handling_fatal_signal;
#ifndef MIN
#define MIN(_a,_b) ((_a)<(_b)?(_a):(_b))
#endif
#ifndef MAX
#define MAX(_a,_b) ((_a)>(_b)?(_a):(_b))
#endif
#ifdef VMS
# define MAKE_SUCCESS 1
# define MAKE_TROUBLE 2
# define MAKE_FAILURE 3
#else
# define MAKE_SUCCESS 0
# define MAKE_TROUBLE 1
# define MAKE_FAILURE 2
#endif
/* Set up heap debugging library dmalloc. */
#ifdef HAVE_DMALLOC_H
#include <dmalloc.h>
#endif
/* If we have broken SA_RESTART support, then wrap stat() and readdir() with
versions that handle EINTR. Note that there are still plenty of system
calls that can fail with EINTR but this, reportedly, gets the vast
majority of failure cases. If you still experience failures you'll need
to either get a system where SA_RESTART works, or you need to avoid -j. */
#ifdef HAVE_BROKEN_RESTART
/* Here we make an assumption that a system with a broken SA_RESTART has
dirent.h. Right now the only system I know of in this category is PTX, and
it does have dirent.h.
*/
#include <dirent.h>
#define stat(_f,_b) atomic_stat ((_f), (_b))
#define readdir(_d) atomic_readdir (_d)
extern int atomic_stat PARAMS ((const char *file, struct stat *buf));
extern struct dirent *atomic_readdir PARAMS ((DIR *dir));
#endif

5
make.lnk Normal file
View File

@@ -0,0 +1,5 @@
FROM LIB:cres.o "commands.o"+"job.o"+"dir.o"+"file.o"+"misc.o"+"main.o"+"read.o"+"remake.o"+"rule.o"+"implicit.o"+"default.o"+"variable.o"+"expand.o"+"function.o"+"vpath.o"+"version.o"+"ar.o"+"arscan.o"+"signame.o"+"remote-stub.o"+"getopt.o"+"getopt1.o"+"alloca.o"+"amiga.o"
TO "make.new"
LIB glob/glob.lib LIB:sc.lib LIB:amiga.lib
QUIET

File diff suppressed because it is too large Load Diff

138
makefile.com Normal file
View File

@@ -0,0 +1,138 @@
$!
$! Makefile.com - builds GNU Make for VMS
$!
$! P1 is non-empty if you want to link with the VAXCRTL library instead
$! of the shareable executable
$! P2 = DEBUG will build an image with debug information
$! P3 = WALL will enable all warning messages (some are suppressed since
$! one macro intentionally causes an error condition)
$!
$! In case of problems with the install you might contact me at
$! zinser@decus.de (preferred) or zinser@sysdev.deutsche-boerse.com
$
$! hb
$! But don't ask Martin Zinser about the lines, I added/changed.
$! In case of an error do some cleanup
$ on error then $ goto cleanup
$! in case somebody set up her/his own symbol for cc
$ set symbol/scope=(nolocal,noglobal)
$!
$! Just some general constants...
$!
$ true = 1
$ false = 0
$ tmpnam = "temp_" + f$getjpi("","pid")
$ tt = tmpnam + ".txt"
$ tc = tmpnam + ".c"
$!
$! Look for the compiler used
$!
$ lval = ""
$ if f$search("SYS$SYSTEM:DECC$COMPILER.EXE").eqs.""
$ then
$ if f$trnlnm("SYS").eqs."" then def/nolog sys sys$library:
$ ccopt = ""
$ else
$ ccopt = "/decc/prefix=all"
$ if f$trnlnm("SYS").eqs.""
$ then
$ if f$trnlnm("DECC$LIBRARY_INCLUDE").nes.""
$ then
$ define sys decc$library_include:
$ else
$ if f$search("SYS$COMMON:[DECC$LIB.REFERENCE]DECC$RTLDEF.DIR").nes."" -
then lval = "SYS$COMMON:[DECC$LIB.REFERENCE.DECC$RTLDEF],"
$ if f$search("SYS$COMMON:[DECC$LIB.REFERENCE]SYS$STARLET_C.DIR").nes."" -
then lval = lval+"SYS$COMMON:[DECC$LIB.REFERENCE.SYS$STARLET_C],"
$ lval=lval+"SYS$LIBRARY:"
$ define sys 'lval
$ endif
$ endif
$ endif
$!
$! Should we build a debug image
$!
$ if (p2.eqs."DEBUG")
$ then
$ ccopt = ccopt + "/noopt/debug"
$ lopt = "/debug"
$ else
$ lopt = ""
$ endif
$!
$! Do we want to see all warnings
$!
$ if (p3.nes."WALL")
$ then
$ gosub check_cc_qual
$ endif
$ filelist = "alloca ar arscan commands default dir expand file function " + -
"hash implicit job main misc read remake remote-stub rule " + -
"signame variable version vmsfunctions vmsify vpath " + -
"[.glob]glob [.glob]fnmatch getopt1 getopt"
$ copy config.h-vms config.h
$ n=0
$ open/write optf make.opt
$ loop:
$ cfile = f$elem(n," ",filelist)
$ if cfile .eqs. " " then goto linkit
$ write sys$output "Compiling ''cfile'..."
$ call compileit 'cfile' 'p1'
$ n = n + 1
$ goto loop
$ linkit:
$ close optf
$ if p1 .nes. "" then goto link_using_library
$ link/exe=make make.opt/opt'lopt
$ goto cleanup
$
$ link_using_library:
$ link/exe=make make.opt/opt,sys$library:vaxcrtl/lib'lopt
$
$ cleanup:
$ if f$trnlnm("SYS").nes."" then $ deassign sys
$ if f$trnlnm("OPTF").nes."" then $ close optf
$ if f$search("make.opt").nes."" then $ del make.opt;*
$ exit
$!
$!------------------------------------------------------------------------------
$!
$! Check if this is a define relating to the properties of the C/C++
$! compiler
$!
$CHECK_CC_QUAL:
$ open/write tmpc 'tc
$ ccqual = "/warn=(disable=questcompare)"
$ write tmpc "#include <stdio.h>"
$ write tmpc "unsigned int i = 1;"
$ write tmpc "int main(){"
$ write tmpc "if (i < 0){printf(""Mission impossible\n"");}}"
$ close tmpc
$ gosub cc_qual_check
$ return
$!
$!------------------------------------------------------------------------------
$!
$! Check for properties of C/C++ compiler
$!
$CC_QUAL_CHECK:
$ cc_qual = false
$ set message/nofac/noident/nosever/notext
$ cc 'ccqual' 'tmpnam'
$ if $status then cc_qual = true
$ set message/fac/ident/sever/text
$ delete/nolog 'tmpnam'.*;*
$ if cc_qual then ccopt = ccopt + ccqual
$ return
$!------------------------------------------------------------------------------
$!
$ compileit : subroutine
$ ploc = f$locate("]",p1)
$ filnam = p1
$ if ploc .lt. f$length(p1) then filnam=f$extract(ploc+1,100,p1)
$ write optf "''filnam'"
$ cc'ccopt'/include=([],[.glob]) -
/define=("allocated_variable_expand_for_file=alloc_var_expand_for_file","unlink=remove","HAVE_CONFIG_H","VMS") -
'p1'
$ exit
$ endsubroutine : compileit

147
makefile.vms Normal file
View File

@@ -0,0 +1,147 @@
# Copyright (C) 1988, 1989, 1996, 1997 Free Software Foundation, Inc.
# This file is part of GNU Make.
#
# VMS extensions from GNU Make 3.60 imported by
# Klaus Kämpf (kkaempf@rmi.de)
# Modified for version 3.78.1 by Hartmut.Becker@compaq.com.
# Modified for version 3.80 by zinser@decus.de
#
# GNU Make is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# GNU Make is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GNU Make; see the file COPYING. If not, write to
# the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
# Boston, MA 02111-1307, USA.
CC = cc
CP = copy
%.obj: %.c
$(CC) $(CFLAGS)/obj=$@ $<
#
# Makefile for GNU Make
#
ifeq ($(CC),cc)
CFLAGS = $(defines) /include=([],[.glob])/prefix=all/standard=relaxed
else
CFLAGS = $(defines) /include=([],[.glob])
endif
#LDFLAGS = /deb
LDFLAGS =
ifeq ($(CC),cc)
defines = /define=("unlink=remove","HAVE_CONFIG_H","VMS","allocated_variable_expand_for_file=alloc_var_expand_for_file")
else
ifeq ($(ARCH),VAX)
defines = /define=("HAVE_CONFIG_H","GCC_IS_NATIVE","VAX")
else
defines = /define=("HAVE_CONFIG_H","GCC_IS_NATIVE")
endif
endif
LOAD_AVG = /define="NO_LDAV"
# If you don't want archive support, comment these out.
ARCHIVES = ,ar.obj,arscan.obj
ARCHIVES_SRC = ar.c arscan.c
# If your system needs extra libraries loaded in, define them here.
# System V probably need -lPW for alloca.
# if on vax, uncomment the following line
#LOADLIBES = ,c.opt/opt
ifeq ($(CC),cc)
#LOADLIBES =,sys$$library:vaxcrtl.olb/lib
CRT0 =
else
LOADLIBES =,gnu_cc_library:libgcc.olb/lib
endif
# If your system doesn't have alloca, or the one provided is bad,
# get it from the Emacs distribution and define these.
#ALLOCA = ,alloca.obj
#ALLOCASRC = alloca.c
# If there are remote execution facilities defined,
# enable them with switches here (see remote-*.c).
REMOTE =
# Any extra object files your system needs.
extras = ,signame.obj,remote-stub.obj,vmsfunctions.obj,vmsify.obj
#,directory.obj
# as an alternative:
glob = ,[.glob]glob.obj,[.glob]fnmatch.obj
getopt = ,getopt.obj,getopt1.obj
# Directory to install `make' in.
bindir = []
# Directory to install the man page in.
mandir = []
# Number to put on the man page filename.
manext = 1
objs = commands.obj,job.obj,dir.obj,file.obj,misc.obj,hash.obj,\
main.obj,read.obj,remake.obj,rule.obj,implicit.obj,\
default.obj,variable.obj,expand.obj,function.obj,\
vpath.obj,version.obj$(ARCHIVES)$(ALLOCA)$(extras)$(getopt)$(glob)
srcs = commands.c job.c dir.c file.c misc.c hash.c\
main.c read.c remake.c rule.c implicit.c \
default.c variable.c expand.c function.c \
vpath.c version.c vmsfunctions.c vmsify.c $(ARCHIVES_SRC) $(ALLOCASRC) \
commands.h dep.h filedef.h job.h make.h rule.h variable.h
.PHONY: all doc
all: config.h make.exe
doc: make.info make.dvi
make.exe: $(objs)
$(LD)$(LDFLAGS)/exe=$@ $^$(LOADLIBES)$(CRT0)
.PHONY: clean realclean
clean:
$$ purge [...]
-$(RM) make.exe;,*.obj;
-$(RM) *.opt;
-$(RM) [.glob]*.obj;
# Automatically generated dependencies.
commands.obj: commands.c make.h dep.h commands.h filedef.h variable.h job.h
job.obj: job.c make.h commands.h job.h filedef.h variable.h
dir.obj: dir.c make.h
file.obj: file.c make.h commands.h dep.h filedef.h variable.h
misc.obj: misc.c make.h dep.h
hash.obj: hash.c make.h hash.h
main.obj: main.c make.h commands.h dep.h filedef.h variable.h job.h
read.obj: read.c make.h commands.h dep.h filedef.h variable.h
remake.obj: remake.c make.h commands.h job.h dep.h filedef.h
rule.obj: rule.c make.h commands.h dep.h filedef.h variable.h rule.h
implicit.obj: implicit.c make.h rule.h dep.h filedef.h
default.obj: default.c make.h rule.h dep.h filedef.h commands.h variable.h
variable.obj: variable.c make.h commands.h variable.h dep.h filedef.h
expand.obj: expand.c make.h commands.h filedef.h variable.h
function.obj: function.c make.h variable.h dep.h commands.h job.h
vpath.obj: vpath.c make.h filedef.h variable.h
version.obj: version.c config.h
arscan.obj: arscan.c
ar.obj: ar.c make.h filedef.h
signame.obj: signame.c
remote-stub.obj: remote-stub.c
[.glob]glob.obj: [.glob]glob.c
[.glob]fnmatch.obj: [.glob]fnmatch.c
getopt.obj: getopt.c
getopt1.obj: getopt1.c
vmsfunctions.obj: vmsfunctions.c make.h vmsdir.h
vmsify.obj: vmsify.c make.h
config.h: config.h-vms
$(CP) $< $@

893
misc.c Normal file
View File

@@ -0,0 +1,893 @@
/* Miscellaneous generic support functions for GNU Make.
Copyright (C) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1997,
2002 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "make.h"
#include "dep.h"
#include "debug.h"
/* Variadic functions. We go through contortions to allow proper function
prototypes for both ANSI and pre-ANSI C compilers, and also for those
which support stdarg.h vs. varargs.h, and finally those which have
vfprintf(), etc. and those who have _doprnt... or nothing.
This fancy stuff all came from GNU fileutils, except for the VA_PRINTF and
VA_END macros used here since we have multiple print functions. */
#if HAVE_VPRINTF || HAVE_DOPRNT
# define HAVE_STDVARARGS 1
# if __STDC__
# include <stdarg.h>
# define VA_START(args, lastarg) va_start(args, lastarg)
# else
# include <varargs.h>
# define VA_START(args, lastarg) va_start(args)
# endif
# if HAVE_VPRINTF
# define VA_PRINTF(fp, lastarg, args) vfprintf((fp), (lastarg), (args))
# else
# define VA_PRINTF(fp, lastarg, args) _doprnt((lastarg), (args), (fp))
# endif
# define VA_END(args) va_end(args)
#else
/* # undef HAVE_STDVARARGS */
# define va_alist a1, a2, a3, a4, a5, a6, a7, a8
# define va_dcl char *a1, *a2, *a3, *a4, *a5, *a6, *a7, *a8;
# define VA_START(args, lastarg)
# define VA_PRINTF(fp, lastarg, args) fprintf((fp), (lastarg), va_alist)
# define VA_END(args)
#endif
/* Compare strings *S1 and *S2.
Return negative if the first is less, positive if it is greater,
zero if they are equal. */
int
alpha_compare (v1, v2)
const void *v1, *v2;
{
const char *s1 = *((char **)v1);
const char *s2 = *((char **)v2);
if (*s1 != *s2)
return *s1 - *s2;
return strcmp (s1, s2);
}
/* Discard each backslash-newline combination from LINE.
Backslash-backslash-newline combinations become backslash-newlines.
This is done by copying the text at LINE into itself. */
void
collapse_continuations (line)
char *line;
{
register char *in, *out, *p;
register int backslash;
register unsigned int bs_write;
in = strchr (line, '\n');
if (in == 0)
return;
out = in;
while (out > line && out[-1] == '\\')
--out;
while (*in != '\0')
{
/* BS_WRITE gets the number of quoted backslashes at
the end just before IN, and BACKSLASH gets nonzero
if the next character is quoted. */
backslash = 0;
bs_write = 0;
for (p = in - 1; p >= line && *p == '\\'; --p)
{
if (backslash)
++bs_write;
backslash = !backslash;
/* It should be impossible to go back this far without exiting,
but if we do, we can't get the right answer. */
if (in == out - 1)
abort ();
}
/* Output the appropriate number of backslashes. */
while (bs_write-- > 0)
*out++ = '\\';
/* Skip the newline. */
++in;
/* If the newline is quoted, discard following whitespace
and any preceding whitespace; leave just one space. */
if (backslash)
{
in = next_token (in);
while (out > line && isblank ((unsigned char)out[-1]))
--out;
*out++ = ' ';
}
else
/* If the newline isn't quoted, put it in the output. */
*out++ = '\n';
/* Now copy the following line to the output.
Stop when we find backslashes followed by a newline. */
while (*in != '\0')
if (*in == '\\')
{
p = in + 1;
while (*p == '\\')
++p;
if (*p == '\n')
{
in = p;
break;
}
while (in < p)
*out++ = *in++;
}
else
*out++ = *in++;
}
*out = '\0';
}
/* Remove comments from LINE.
This is done by copying the text at LINE onto itself. */
void
remove_comments (line)
char *line;
{
char *comment;
comment = find_char_unquote (line, '#', 0, 0);
if (comment != 0)
/* Cut off the line at the #. */
*comment = '\0';
}
/* Print N spaces (used in debug for target-depth). */
void
print_spaces (n)
unsigned int n;
{
while (n-- > 0)
putchar (' ');
}
/* Return a newly-allocated string whose contents
concatenate those of s1, s2, s3. */
char *
concat (s1, s2, s3)
const char *s1, *s2, *s3;
{
unsigned int len1, len2, len3;
char *result;
len1 = *s1 != '\0' ? strlen (s1) : 0;
len2 = *s2 != '\0' ? strlen (s2) : 0;
len3 = *s3 != '\0' ? strlen (s3) : 0;
result = (char *) xmalloc (len1 + len2 + len3 + 1);
if (*s1 != '\0')
bcopy (s1, result, len1);
if (*s2 != '\0')
bcopy (s2, result + len1, len2);
if (*s3 != '\0')
bcopy (s3, result + len1 + len2, len3);
*(result + len1 + len2 + len3) = '\0';
return result;
}
/* Print a message on stdout. */
void
#if __STDC__ && HAVE_STDVARARGS
message (int prefix, const char *fmt, ...)
#else
message (prefix, fmt, va_alist)
int prefix;
const char *fmt;
va_dcl
#endif
{
#if HAVE_STDVARARGS
va_list args;
#endif
log_working_directory (1);
if (fmt != 0)
{
if (prefix)
{
if (makelevel == 0)
printf ("%s: ", program);
else
printf ("%s[%u]: ", program, makelevel);
}
VA_START (args, fmt);
VA_PRINTF (stdout, fmt, args);
VA_END (args);
putchar ('\n');
}
fflush (stdout);
}
/* Print an error message. */
void
#if __STDC__ && HAVE_STDVARARGS
error (const struct floc *flocp, const char *fmt, ...)
#else
error (flocp, fmt, va_alist)
const struct floc *flocp;
const char *fmt;
va_dcl
#endif
{
#if HAVE_STDVARARGS
va_list args;
#endif
log_working_directory (1);
if (flocp && flocp->filenm)
fprintf (stderr, "%s:%lu: ", flocp->filenm, flocp->lineno);
else if (makelevel == 0)
fprintf (stderr, "%s: ", program);
else
fprintf (stderr, "%s[%u]: ", program, makelevel);
VA_START(args, fmt);
VA_PRINTF (stderr, fmt, args);
VA_END (args);
putc ('\n', stderr);
fflush (stderr);
}
/* Print an error message and exit. */
void
#if __STDC__ && HAVE_STDVARARGS
fatal (const struct floc *flocp, const char *fmt, ...)
#else
fatal (flocp, fmt, va_alist)
const struct floc *flocp;
const char *fmt;
va_dcl
#endif
{
#if HAVE_STDVARARGS
va_list args;
#endif
log_working_directory (1);
if (flocp && flocp->filenm)
fprintf (stderr, "%s:%lu: *** ", flocp->filenm, flocp->lineno);
else if (makelevel == 0)
fprintf (stderr, "%s: *** ", program);
else
fprintf (stderr, "%s[%u]: *** ", program, makelevel);
VA_START(args, fmt);
VA_PRINTF (stderr, fmt, args);
VA_END (args);
fputs (_(". Stop.\n"), stderr);
die (2);
}
#ifndef HAVE_STRERROR
#undef strerror
char *
strerror (errnum)
int errnum;
{
extern int errno, sys_nerr;
#ifndef __DECC
extern char *sys_errlist[];
#endif
static char buf[] = "Unknown error 12345678901234567890";
if (errno < sys_nerr)
return sys_errlist[errnum];
sprintf (buf, _("Unknown error %d"), errnum);
return buf;
}
#endif
/* Print an error message from errno. */
void
perror_with_name (str, name)
const char *str, *name;
{
error (NILF, _("%s%s: %s"), str, name, strerror (errno));
}
/* Print an error message from errno and exit. */
void
pfatal_with_name (name)
const char *name;
{
fatal (NILF, _("%s: %s"), name, strerror (errno));
/* NOTREACHED */
}
/* Like malloc but get fatal error if memory is exhausted. */
/* Don't bother if we're using dmalloc; it provides these for us. */
#ifndef HAVE_DMALLOC_H
#undef xmalloc
#undef xrealloc
#undef xstrdup
char *
xmalloc (size)
unsigned int size;
{
char *result = (char *) malloc (size);
if (result == 0)
fatal (NILF, _("virtual memory exhausted"));
return result;
}
char *
xrealloc (ptr, size)
char *ptr;
unsigned int size;
{
char *result;
/* Some older implementations of realloc() don't conform to ANSI. */
result = ptr ? realloc (ptr, size) : malloc (size);
if (result == 0)
fatal (NILF, _("virtual memory exhausted"));
return result;
}
char *
xstrdup (ptr)
const char *ptr;
{
char *result;
#ifdef HAVE_STRDUP
result = strdup (ptr);
#else
result = (char *) malloc (strlen (ptr) + 1);
#endif
if (result == 0)
fatal (NILF, _("virtual memory exhausted"));
#ifdef HAVE_STRDUP
return result;
#else
return strcpy(result, ptr);
#endif
}
#endif /* HAVE_DMALLOC_H */
char *
savestring (str, length)
const char *str;
unsigned int length;
{
register char *out = (char *) xmalloc (length + 1);
if (length > 0)
bcopy (str, out, length);
out[length] = '\0';
return out;
}
/* Search string BIG (length BLEN) for an occurrence of
string SMALL (length SLEN). Return a pointer to the
beginning of the first occurrence, or return nil if none found. */
char *
sindex (big, blen, small, slen)
const char *big;
unsigned int blen;
const char *small;
unsigned int slen;
{
if (!blen)
blen = strlen (big);
if (!slen)
slen = strlen (small);
if (slen && blen >= slen)
{
register unsigned int b;
/* Quit when there's not enough room left for the small string. */
--slen;
blen -= slen;
for (b = 0; b < blen; ++b, ++big)
if (*big == *small && strneq (big + 1, small + 1, slen))
return (char *)big;
}
return 0;
}
/* Limited INDEX:
Search through the string STRING, which ends at LIMIT, for the character C.
Returns a pointer to the first occurrence, or nil if none is found.
Like INDEX except that the string searched ends where specified
instead of at the first null. */
char *
lindex (s, limit, c)
register const char *s, *limit;
int c;
{
while (s < limit)
if (*s++ == c)
return (char *)(s - 1);
return 0;
}
/* Return the address of the first whitespace or null in the string S. */
char *
end_of_token (s)
char *s;
{
while (*s != '\0' && !isblank ((unsigned char)*s))
++s;
return s;
}
#ifdef WINDOWS32
/*
* Same as end_of_token, but take into account a stop character
*/
char *
end_of_token_w32 (s, stopchar)
char *s;
char stopchar;
{
register char *p = s;
register int backslash = 0;
while (*p != '\0' && *p != stopchar
&& (backslash || !isblank ((unsigned char)*p)))
{
if (*p++ == '\\')
{
backslash = !backslash;
while (*p == '\\')
{
backslash = !backslash;
++p;
}
}
else
backslash = 0;
}
return p;
}
#endif
/* Return the address of the first nonwhitespace or null in the string S. */
char *
next_token (s)
const char *s;
{
while (isblank ((unsigned char)*s))
++s;
return (char *)s;
}
/* Find the next token in PTR; return the address of it, and store the
length of the token into *LENGTHPTR if LENGTHPTR is not nil. */
char *
find_next_token (ptr, lengthptr)
char **ptr;
unsigned int *lengthptr;
{
char *p = next_token (*ptr);
char *end;
if (*p == '\0')
return 0;
*ptr = end = end_of_token (p);
if (lengthptr != 0)
*lengthptr = end - p;
return p;
}
/* Copy a chain of `struct dep', making a new chain
with the same contents as the old one. */
struct dep *
copy_dep_chain (d)
register struct dep *d;
{
register struct dep *c;
struct dep *firstnew = 0;
struct dep *lastnew = 0;
while (d != 0)
{
c = (struct dep *) xmalloc (sizeof (struct dep));
bcopy ((char *) d, (char *) c, sizeof (struct dep));
if (c->name != 0)
c->name = xstrdup (c->name);
c->next = 0;
if (firstnew == 0)
firstnew = lastnew = c;
else
lastnew = lastnew->next = c;
d = d->next;
}
return firstnew;
}
#ifdef iAPX286
/* The losing compiler on this machine can't handle this macro. */
char *
dep_name (dep)
struct dep *dep;
{
return dep->name == 0 ? dep->file->name : dep->name;
}
#endif
#ifdef GETLOADAVG_PRIVILEGED
#ifdef POSIX
/* Hopefully if a system says it's POSIX.1 and has the setuid and setgid
functions, they work as POSIX.1 says. Some systems (Alpha OSF/1 1.2,
for example) which claim to be POSIX.1 also have the BSD setreuid and
setregid functions, but they don't work as in BSD and only the POSIX.1
way works. */
#undef HAVE_SETREUID
#undef HAVE_SETREGID
#else /* Not POSIX. */
/* Some POSIX.1 systems have the seteuid and setegid functions. In a
POSIX-like system, they are the best thing to use. However, some
non-POSIX systems have them too but they do not work in the POSIX style
and we must use setreuid and setregid instead. */
#undef HAVE_SETEUID
#undef HAVE_SETEGID
#endif /* POSIX. */
#ifndef HAVE_UNISTD_H
extern int getuid (), getgid (), geteuid (), getegid ();
extern int setuid (), setgid ();
#ifdef HAVE_SETEUID
extern int seteuid ();
#else
#ifdef HAVE_SETREUID
extern int setreuid ();
#endif /* Have setreuid. */
#endif /* Have seteuid. */
#ifdef HAVE_SETEGID
extern int setegid ();
#else
#ifdef HAVE_SETREGID
extern int setregid ();
#endif /* Have setregid. */
#endif /* Have setegid. */
#endif /* No <unistd.h>. */
/* Keep track of the user and group IDs for user- and make- access. */
static int user_uid = -1, user_gid = -1, make_uid = -1, make_gid = -1;
#define access_inited (user_uid != -1)
static enum { make, user } current_access;
/* Under -d, write a message describing the current IDs. */
static void
log_access (flavor)
char *flavor;
{
if (! ISDB (DB_JOBS))
return;
/* All the other debugging messages go to stdout,
but we write this one to stderr because it might be
run in a child fork whose stdout is piped. */
fprintf (stderr, _("%s: user %lu (real %lu), group %lu (real %lu)\n"),
flavor, (unsigned long) geteuid (), (unsigned long) getuid (),
(unsigned long) getegid (), (unsigned long) getgid ());
fflush (stderr);
}
static void
init_access ()
{
#ifndef VMS
user_uid = getuid ();
user_gid = getgid ();
make_uid = geteuid ();
make_gid = getegid ();
/* Do these ever fail? */
if (user_uid == -1 || user_gid == -1 || make_uid == -1 || make_gid == -1)
pfatal_with_name ("get{e}[gu]id");
log_access (_("Initialized access"));
current_access = make;
#endif
}
#endif /* GETLOADAVG_PRIVILEGED */
/* Give the process appropriate permissions for access to
user data (i.e., to stat files, or to spawn a child process). */
void
user_access ()
{
#ifdef GETLOADAVG_PRIVILEGED
if (!access_inited)
init_access ();
if (current_access == user)
return;
/* We are in "make access" mode. This means that the effective user and
group IDs are those of make (if it was installed setuid or setgid).
We now want to set the effective user and group IDs to the real IDs,
which are the IDs of the process that exec'd make. */
#ifdef HAVE_SETEUID
/* Modern systems have the seteuid/setegid calls which set only the
effective IDs, which is ideal. */
if (seteuid (user_uid) < 0)
pfatal_with_name ("user_access: seteuid");
#else /* Not HAVE_SETEUID. */
#ifndef HAVE_SETREUID
/* System V has only the setuid/setgid calls to set user/group IDs.
There is an effective ID, which can be set by setuid/setgid.
It can be set (unless you are root) only to either what it already is
(returned by geteuid/getegid, now in make_uid/make_gid),
the real ID (return by getuid/getgid, now in user_uid/user_gid),
or the saved set ID (what the effective ID was before this set-ID
executable (make) was exec'd). */
if (setuid (user_uid) < 0)
pfatal_with_name ("user_access: setuid");
#else /* HAVE_SETREUID. */
/* In 4BSD, the setreuid/setregid calls set both the real and effective IDs.
They may be set to themselves or each other. So you have two alternatives
at any one time. If you use setuid/setgid, the effective will be set to
the real, leaving only one alternative. Using setreuid/setregid, however,
you can toggle between your two alternatives by swapping the values in a
single setreuid or setregid call. */
if (setreuid (make_uid, user_uid) < 0)
pfatal_with_name ("user_access: setreuid");
#endif /* Not HAVE_SETREUID. */
#endif /* HAVE_SETEUID. */
#ifdef HAVE_SETEGID
if (setegid (user_gid) < 0)
pfatal_with_name ("user_access: setegid");
#else
#ifndef HAVE_SETREGID
if (setgid (user_gid) < 0)
pfatal_with_name ("user_access: setgid");
#else
if (setregid (make_gid, user_gid) < 0)
pfatal_with_name ("user_access: setregid");
#endif
#endif
current_access = user;
log_access (_("User access"));
#endif /* GETLOADAVG_PRIVILEGED */
}
/* Give the process appropriate permissions for access to
make data (i.e., the load average). */
void
make_access ()
{
#ifdef GETLOADAVG_PRIVILEGED
if (!access_inited)
init_access ();
if (current_access == make)
return;
/* See comments in user_access, above. */
#ifdef HAVE_SETEUID
if (seteuid (make_uid) < 0)
pfatal_with_name ("make_access: seteuid");
#else
#ifndef HAVE_SETREUID
if (setuid (make_uid) < 0)
pfatal_with_name ("make_access: setuid");
#else
if (setreuid (user_uid, make_uid) < 0)
pfatal_with_name ("make_access: setreuid");
#endif
#endif
#ifdef HAVE_SETEGID
if (setegid (make_gid) < 0)
pfatal_with_name ("make_access: setegid");
#else
#ifndef HAVE_SETREGID
if (setgid (make_gid) < 0)
pfatal_with_name ("make_access: setgid");
#else
if (setregid (user_gid, make_gid) < 0)
pfatal_with_name ("make_access: setregid");
#endif
#endif
current_access = make;
log_access (_("Make access"));
#endif /* GETLOADAVG_PRIVILEGED */
}
/* Give the process appropriate permissions for a child process.
This is like user_access, but you can't get back to make_access. */
void
child_access ()
{
#ifdef GETLOADAVG_PRIVILEGED
if (!access_inited)
abort ();
/* Set both the real and effective UID and GID to the user's.
They cannot be changed back to make's. */
#ifndef HAVE_SETREUID
if (setuid (user_uid) < 0)
pfatal_with_name ("child_access: setuid");
#else
if (setreuid (user_uid, user_uid) < 0)
pfatal_with_name ("child_access: setreuid");
#endif
#ifndef HAVE_SETREGID
if (setgid (user_gid) < 0)
pfatal_with_name ("child_access: setgid");
#else
if (setregid (user_gid, user_gid) < 0)
pfatal_with_name ("child_access: setregid");
#endif
log_access (_("Child access"));
#endif /* GETLOADAVG_PRIVILEGED */
}
#ifdef NEED_GET_PATH_MAX
unsigned int
get_path_max ()
{
static unsigned int value;
if (value == 0)
{
long int x = pathconf ("/", _PC_PATH_MAX);
if (x > 0)
value = x;
else
return MAXPATHLEN;
}
return value;
}
#endif
#ifdef HAVE_BROKEN_RESTART
#undef stat
#undef readdir
int
atomic_stat(file, buf)
const char *file;
struct stat *buf;
{
int r;
while ((r = stat (file, buf)) < 0)
if (errno != EINTR)
break;
return r;
}
struct dirent *
atomic_readdir(dir)
DIR *dir;
{
struct dirent *r;
while ((r = readdir (dir)) == NULL)
if (errno != EINTR)
break;
return r;
}
#endif /* HAVE_BROKEN_RESTART */

6
po/.cvsignore Normal file
View File

@@ -0,0 +1,6 @@
*.gmo *.mo *.pot *.po
Makefile Makefile.in Makefile.in.in
Rules-quot
*.sed *.sin *.header
POTFILES

17
po/ChangeLog Normal file
View File

@@ -0,0 +1,17 @@
2002-08-08 Paul D. Smith <psmith@gnu.org>
* LINGUAS: Add a new translation for Chinese (simplified) (zh_CN).
2002-08-02 Paul D. Smith <psmith@gnu.org>
* LINGUAS: Add a new translation for Swedish (sv).
2002-04-21 Paul D. Smith <psmith@gnu.org>
* LINGUAS, hr.po: Added new translation: Croatian.
* da.po, de.po, es.po, fr.po, gl.po, he.po, ja.po, ko.po, nl.po,
pl.po, pt_BR.po, ru.po, tr.po: Moved from i18n to here.
* .cvsignore: Moved from i18n to here.
* POTFILES.in, LINGUAS, Makevars: Created.

5
po/LINGUAS Normal file
View File

@@ -0,0 +1,5 @@
# Set of available languages: 16 languages
da de es fr gl he hr ja ko nl pl pt_BR sv ru tr zh_CN
# Can't seem to get en@quot and en@boldquot to build properly?

25
po/Makevars Normal file
View File

@@ -0,0 +1,25 @@
# Makefile variables for PO directory in any package using GNU gettext.
# Usually the message domain is the same as the package name.
DOMAIN = $(PACKAGE)
# These two variables depend on the location of this directory.
subdir = po
top_builddir = ..
# These options get passed to xgettext.
XGETTEXT_OPTIONS = --keyword=_ --keyword=N_
# This is the copyright holder that gets inserted into the header of the
# $(DOMAIN).pot file. Set this to the copyright holder of the surrounding
# package. (Note that the msgstr strings, extracted from the package's
# sources, belong to the copyright holder of the package.) Translators are
# expected to transfer the copyright for their translations to this person
# or entity, or to disclaim their copyright. The empty string stands for
# the public domain; in this case the translators are expected to disclaim
# their copyright.
COPYRIGHT_HOLDER = Free Software Foundation, Inc.
# This is the list of locale categories, beyond LC_MESSAGES, for which the
# message catalogs shall be used. It is usually empty.
EXTRA_LOCALE_CATEGORIES =

24
po/POTFILES.in Normal file
View File

@@ -0,0 +1,24 @@
# List of source files containing translatable strings.
# Copyright (C) 2002 Free Software Foundation, Inc.
ar.c
arscan.c
commands.c
dir.c
expand.c
file.c
function.c
getopt.c
hash.c
implicit.c
job.c
main.c
misc.c
read.c
remake.c
remote-cstms.c
rule.c
signame.c
variable.c
vmsfunctions.c
vpath.c

3105
read.c Normal file

File diff suppressed because it is too large Load Diff

183
readme.vms Normal file
View File

@@ -0,0 +1,183 @@
This is the VMS port of GNU Make done by Hartmut.Becker@compaq.com.
It is based on the specific version 3.77k and on 3.78.1. 3.77k was done
by Klaus Kämpf <kkaempf@rmi.de>, the code was based on the VMS port of
GNU Make 3.60 by Mike Moretti.
It was ported on OpenVMS/Alpha V7.1, DECC V5.7-006. It was re-build and
tested on OpenVMS/Alpha V7.2, OpenVMS/VAX 7.1 and 5.5-2. Different
versions of DECC were used. VAXC was tried: it fails; but it doesn't
seem worth to get it working. There are still some PTRMISMATCH warnings
during the compile. Although perl is working on VMS the test scripts
don't work. The function $shell is still missing.
There is a known bug in some of the VMS CRTLs. It is in the shipped
versions of VMS V7.2 and V7.2-1 and in the currently (October 1999)
available ECOs for VMS V7.1 and newer versions. It is fixed in versions
shipped with newer VMS versions and all ECO kits after October 1999. It
only shows up during the daylight saving time period (DST): stat()
returns a modification time 1 hour ahead. This results in GNU make
warning messages. For a just created source you will see:
$ gmake x.exe
gmake.exe;1: *** Warning: File `x.c' has modification time in the future (940582863 > 940579269)
cc /obj=x.obj x.c
link x.obj /exe=x.exe
gmake.exe;1: *** Warning: Clock skew detected. Your build may be incomplete.
New in 3.78.1:
Fix a problem with automatically remaking makefiles. GNU make uses an
execve to restart itself after a successful remake of the makefile. On
UNIX systems execve replaces the running program with a new one and
resets all signal handling to the default. On VMS execve creates a child
process, signal and exit handlers of the parent are still active, and,
unfortunately, corrupt the exit code from the child. Fix in job.c:
ignore SIGCHLD.
Added some switches to reflect latest features of DECC. Modifications in
makefile.vms.
Set some definitions to reflect latest features of DECC. Modifications in
config.h-vms (which is copied to config.h).
Added extern strcmpi declaration to avoid 'implicitly declared' messages.
Modification in make.h.
Default rule for C++, conditionals for gcc (GCC_IS_NATIVE) or DEC/Digital/
Compaq c/c++ compilers. Modifications in default.c.
Usage of opendir() and friends, suppress file version. Modifications in dir.c.
Added VMS specific code to handle ctrl+c and ctrl+y to abort make.
Modifications in job.c.
Added support to have case sensitive targets and dependencies but to
still use case blind file names. This is especially useful for Java
makefiles on VMS:
.SUFFIXES :
.SUFFIXES : .class .java
.java.class :
javac "$<
HelloWorld.class : HelloWorld.java
A new macro WANT_CASE_SENSITIVE_TARGETS in config.h-vms was introduced.
It needs to be enabled to get this feature; default is disabled. The
macro HAVE_CASE_INSENSITIVE_FS must not be touched: it is still enabled.
Modifications in file.c and config.h-vms.
Bootstrap make to start building make is still makefile.com, but make
needs to be re-made with a make to make a correct version: ignore all
possible warnings, delete all objects, rename make.exe to a different
name and run it.
Made some minor modifications to the bootstrap build makefile.com.
This is the VMS port of GNU Make.
It is based on the VMS port of GNU Make 3.60 by Mike Moretti.
This port was done by Klaus Kämpf <kkaempf@rmi.de>
There is first-level support available from proGIS Software, Germany.
Visit their web-site at http://www.progis.de to get information
about other vms software and forthcoming updates to gnu make.
New for 3.77:
/bin/sh style I/O redirection is supported. You can now write lines like
mcr sys$disk:[]program.exe < input.txt > output.txt &> error.txt
Makefile variables are looked up in the current environment. You can set
symbols or logicals in DCL and evaluate them in the Makefile via
$(<name-of-symbol-or-logical>). Variables defined in the Makefile
override VMS symbols/logicals !
Functions for file names are working now. See the GNU Make manual for
$(dir ...) and $(wildcard ...). Unix-style and VMS-style names are
supported as arguments.
The default rules are set up for GNU C. Building an executable from a
single source file is as easy as 'make file.exe'.
The variable $(ARCH) is predefined as ALPHA or VAX resp. Makefiles for
different VMS systems can now be written by checking $(ARCH) as in
ifeq ($(ARCH),ALPHA)
$(ECHO) "On the Alpha"
else
$(ECHO) "On the VAX"
endif
Command lines of excessive length are correctly broken and written to a
batch file in sys$scratch for later execution. There's no limit to the
lengths of commands (and no need for .opt files :-) any more.
Empty commands are handled correctly and don't end in a new DCL process.
New for 3.76:
John W. Eaton has updated the VMS port to support libraries and VPATH.
To build Make, simply type @makefile. This should compile all the
necessary files and link Make. There is also a file called
makefile.vms. If you already have GNU Make built you can just use
Make with this makefile to rebuild.
Here are some notes about GNU Make for VMS:
The cd command is supported if it's called as $(CD). This invokes
the 'builtin_cd' command which changes the directory.
Calling 'set def' doesn't do the trick, since a sub-shell is
spawned for this command, the directory is changed *in this sub-shell*
and the sub-shell ends.
Libraries are not supported. They were in GNU Make 3.60 but somehow I
didn't care porting the code. If there is enough interest, I'll do it at
some later time.
The variable $^ separates files with commas instead of spaces (It's the
natural thing to do for VMS).
See defaults.c for VMS default suffixes and my definitions for default
rules and variables.
The shell function is not implemented yet.
Load average routines haven't been implemented for VMS yet.
The default include directory for including other makefiles is
SYS$SYSROOT:[SYSLIB] (I don't remember why I didn't just use
SYS$LIBRARY: instead; maybe it wouldn't work that way).
The default makefiles make looks for are: makefile.vms, gnumakefile,
makefile., and gnumakefile. .
The stat() function and handling of time stamps in VMS is broken, so I
replaced it with a hack in vmsfunctions.c. I will provide a full rewrite
somewhere in the future. Be warned, the time resolution inside make is
less than what vms provides. This might be a problem on the faster Alphas.
You can use a : in a filename only if you preceed it with a backslash ('\').
E.g.- hobbes\:[bogas.files]
Make ignores success, informational, or warning errors (-S-, -I-, or
-W-). But it will stop on -E- and -F- errors. (unless you do something
to override this in your makefile, or whatever).
Remote stuff isn't implemented yet.
Multiple line DCL commands, such as "if" statements, must be put inside
command files. You can run a command file by using \@.
VMS changes made for 3.74.3
Lots of default settings are adapted for VMS. See default.c.
Long command lines are now converted to command files.
Comma (',') as a separator is now allowed. See makefile.vms for an example.

1420
remake.c Normal file

File diff suppressed because it is too large Load Diff

310
remote-cstms.c Normal file
View File

@@ -0,0 +1,310 @@
/* GNU Make remote job exportation interface to the Customs daemon.
THIS CODE IS NOT SUPPORTED BY THE GNU PROJECT.
Please do not send bug reports or questions about it to
the Make maintainers.
Copyright (C) 1988, 1989, 1992, 1993 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "make.h"
#include "job.h"
#include "filedef.h"
#include "commands.h"
#include "job.h"
#include "debug.h"
#include <sys/time.h>
#include <netdb.h>
#include "customs.h"
char *remote_description = "Customs";
/* File name of the Customs `export' client command.
A full path name can be used to avoid some path-searching overhead. */
#define EXPORT_COMMAND "/usr/local/bin/export"
/* ExportPermit gotten by start_remote_job_p, and used by start_remote_job. */
static ExportPermit permit;
/* Normalized path name of the current directory. */
static char *normalized_cwd;
/* Call once at startup even if no commands are run. */
void
remote_setup ()
{
}
/* Called before exit. */
void
remote_cleanup ()
{
}
/* Return nonzero if the next job should be done remotely. */
int
start_remote_job_p (first_p)
int first_p;
{
static int inited = 0;
int status;
int njobs;
if (!inited)
{
/* Allow the user to turn off job exportation (useful while he is
debugging Customs, for example). */
if (getenv ("GNU_MAKE_NO_CUSTOMS") != 0)
{
inited = -1;
return 0;
}
/* For secure Customs, make is installed setuid root and
Customs requires a privileged source port be used. */
make_access ();
if (ISDB (DB_JOBS))
Rpc_Debug(1);
/* Ping the daemon once to see if it is there. */
inited = Customs_Ping () == RPC_SUCCESS ? 1 : -1;
/* Return to normal user access. */
user_access ();
if (starting_directory == 0)
/* main couldn't figure it out. */
inited = -1;
else
{
/* Normalize the current directory path name to something
that should work on all machines exported to. */
normalized_cwd = (char *) xmalloc (GET_PATH_MAX);
strcpy (normalized_cwd, starting_directory);
if (Customs_NormPath (normalized_cwd, GET_PATH_MAX) < 0)
/* Path normalization failure means using Customs
won't work, but it's not really an error. */
inited = -1;
}
}
if (inited < 0)
return 0;
njobs = job_slots_used;
if (!first_p)
njobs -= 1; /* correction for being called from reap_children() */
/* the first job should run locally, or, if the -l flag is given, we use
that as clue as to how many local jobs should be scheduled locally */
if (max_load_average < 0 && njobs == 0 || njobs < max_load_average)
return 0;
status = Customs_Host (EXPORT_SAME, &permit);
if (status != RPC_SUCCESS)
{
DB (DB_JOBS, (_("Customs won't export: %s\n"),
Rpc_ErrorMessage (status)));
return 0;
}
return !CUSTOMS_FAIL (&permit.addr);
}
/* Start a remote job running the command in ARGV, with environment from
ENVP. It gets standard input from STDIN_FD. On failure, return
nonzero. On success, return zero, and set *USED_STDIN to nonzero if it
will actually use STDIN_FD, zero if not, set *ID_PTR to a unique
identification, and set *IS_REMOTE to nonzero if the job is remote, zero
if it is local (meaning *ID_PTR is a process ID). */
int
start_remote_job (argv, envp, stdin_fd, is_remote, id_ptr, used_stdin)
char **argv, **envp;
int stdin_fd;
int *is_remote;
int *id_ptr;
int *used_stdin;
{
char waybill[MAX_DATA_SIZE], msg[128];
struct hostent *host;
struct timeval timeout;
struct sockaddr_in sin;
int len;
int retsock, retport, sock;
Rpc_Stat status;
int pid;
/* Create the return socket. */
retsock = Rpc_UdpCreate (True, 0);
if (retsock < 0)
{
error (NILF, "exporting: Couldn't create return socket.");
return 1;
}
/* Get the return socket's port number. */
len = sizeof (sin);
if (getsockname (retsock, (struct sockaddr *) &sin, &len) < 0)
{
(void) close (retsock);
perror_with_name ("exporting: ", "getsockname");
return 1;
}
retport = sin.sin_port;
/* Create the TCP socket for talking to the remote child. */
sock = Rpc_TcpCreate (False, 0);
/* Create a WayBill to give to the server. */
len = Customs_MakeWayBill (&permit, normalized_cwd, argv[0], argv,
envp, retport, waybill);
/* Modify the waybill as if the remote child had done `child_access ()'. */
{
WayBill *wb = (WayBill *) waybill;
wb->ruid = wb->euid;
wb->rgid = wb->egid;
}
/* Send the request to the server, timing out in 20 seconds. */
timeout.tv_usec = 0;
timeout.tv_sec = 20;
sin.sin_family = AF_INET;
sin.sin_port = htons (Customs_Port ());
sin.sin_addr = permit.addr;
status = Rpc_Call (sock, &sin, (Rpc_Proc) CUSTOMS_IMPORT,
len, (Rpc_Opaque) waybill,
sizeof(msg), (Rpc_Opaque) msg,
1, &timeout);
host = gethostbyaddr((char *)&permit.addr, sizeof(permit.addr), AF_INET);
if (status != RPC_SUCCESS)
{
(void) close (retsock);
(void) close (sock);
error (NILF, "exporting to %s: %s",
host ? host->h_name : inet_ntoa (permit.addr),
Rpc_ErrorMessage (status));
return 1;
}
else if (msg[0] != 'O' || msg[1] != 'k' || msg[2] != '\0')
{
(void) close (retsock);
(void) close (sock);
error (NILF, "exporting to %s: %s",
host ? host->h_name : inet_ntoa (permit.addr),
msg);
return 1;
}
else
{
error (NILF, "*** exported to %s (id %u)",
host ? host->h_name : inet_ntoa (permit.addr),
permit.id);
}
fflush (stdout);
fflush (stderr);
pid = vfork ();
if (pid < 0)
{
/* The fork failed! */
perror_with_name ("vfork", "");
return 1;
}
else if (pid == 0)
{
/* Child side. Run `export' to handle the connection. */
static char sock_buf[20], retsock_buf[20], id_buf[20];
static char *new_argv[6] =
{ EXPORT_COMMAND, "-id", sock_buf, retsock_buf, id_buf, 0 };
/* Set up the arguments. */
(void) sprintf (sock_buf, "%d", sock);
(void) sprintf (retsock_buf, "%d", retsock);
(void) sprintf (id_buf, "%x", permit.id);
/* Get the right stdin. */
if (stdin_fd != 0)
(void) dup2 (stdin_fd, 0);
/* Unblock signals in the child. */
unblock_sigs ();
/* Run the command. */
exec_command (new_argv, envp);
}
/* Parent side. Return the `export' process's ID. */
(void) close (retsock);
(void) close (sock);
*is_remote = 0;
*id_ptr = pid;
*used_stdin = 1;
return 0;
}
/* Get the status of a dead remote child. Block waiting for one to die
if BLOCK is nonzero. Set *EXIT_CODE_PTR to the exit status, *SIGNAL_PTR
to the termination signal or zero if it exited normally, and *COREDUMP_PTR
nonzero if it dumped core. Return the ID of the child that died,
0 if we would have to block and !BLOCK, or < 0 if there were none. */
int
remote_status (exit_code_ptr, signal_ptr, coredump_ptr, block)
int *exit_code_ptr, *signal_ptr, *coredump_ptr;
int block;
{
return -1;
}
/* Block asynchronous notification of remote child death.
If this notification is done by raising the child termination
signal, do not block that signal. */
void
block_remote_children ()
{
return;
}
/* Restore asynchronous notification of remote child death.
If this is done by raising the child termination signal,
do not unblock that signal. */
void
unblock_remote_children ()
{
return;
}
/* Send signal SIG to child ID. Return 0 if successful, -1 if not. */
int
remote_kill (id, sig)
int id;
int sig;
{
return -1;
}

109
remote-stub.c Normal file
View File

@@ -0,0 +1,109 @@
/* Template for the remote job exportation interface to GNU Make.
Copyright (C) 1988, 1989, 1992, 1993, 1996 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "make.h"
#include "filedef.h"
#include "job.h"
#include "commands.h"
char *remote_description = 0;
/* Call once at startup even if no commands are run. */
void
remote_setup ()
{
}
/* Called before exit. */
void
remote_cleanup ()
{
}
/* Return nonzero if the next job should be done remotely. */
int
start_remote_job_p (first_p)
int first_p;
{
return 0;
}
/* Start a remote job running the command in ARGV,
with environment from ENVP. It gets standard input from STDIN_FD. On
failure, return nonzero. On success, return zero, and set *USED_STDIN
to nonzero if it will actually use STDIN_FD, zero if not, set *ID_PTR to
a unique identification, and set *IS_REMOTE to zero if the job is local,
nonzero if it is remote (meaning *ID_PTR is a process ID). */
int
start_remote_job (argv, envp, stdin_fd, is_remote, id_ptr, used_stdin)
char **argv, **envp;
int stdin_fd;
int *is_remote;
int *id_ptr;
int *used_stdin;
{
return -1;
}
/* Get the status of a dead remote child. Block waiting for one to die
if BLOCK is nonzero. Set *EXIT_CODE_PTR to the exit status, *SIGNAL_PTR
to the termination signal or zero if it exited normally, and *COREDUMP_PTR
nonzero if it dumped core. Return the ID of the child that died,
0 if we would have to block and !BLOCK, or < 0 if there were none. */
int
remote_status (exit_code_ptr, signal_ptr, coredump_ptr, block)
int *exit_code_ptr, *signal_ptr, *coredump_ptr;
int block;
{
errno = ECHILD;
return -1;
}
/* Block asynchronous notification of remote child death.
If this notification is done by raising the child termination
signal, do not block that signal. */
void
block_remote_children ()
{
return;
}
/* Restore asynchronous notification of remote child death.
If this is done by raising the child termination signal,
do not unblock that signal. */
void
unblock_remote_children ()
{
return;
}
/* Send signal SIG to child ID. Return 0 if successful, -1 if not. */
int
remote_kill (id, sig)
int id;
int sig;
{
return -1;
}

717
rule.c Normal file
View File

@@ -0,0 +1,717 @@
/* Pattern and suffix rule internals for GNU Make.
Copyright (C) 1988,89,90,91,92,93, 1998 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "make.h"
#include "dep.h"
#include "filedef.h"
#include "job.h"
#include "commands.h"
#include "variable.h"
#include "rule.h"
static void freerule PARAMS ((struct rule *rule, struct rule *lastrule));
/* Chain of all pattern rules. */
struct rule *pattern_rules;
/* Pointer to last rule in the chain, so we can add onto the end. */
struct rule *last_pattern_rule;
/* Number of rules in the chain. */
unsigned int num_pattern_rules;
/* Maximum number of target patterns of any pattern rule. */
unsigned int max_pattern_targets;
/* Maximum number of dependencies of any pattern rule. */
unsigned int max_pattern_deps;
/* Maximum length of the name of a dependencies of any pattern rule. */
unsigned int max_pattern_dep_length;
/* Chain of all pattern-specific variables. */
static struct pattern_var *pattern_vars;
/* Pointer to last struct in the chain, so we can add onto the end. */
static struct pattern_var *last_pattern_var;
/* Pointer to structure for the file .SUFFIXES
whose dependencies are the suffixes to be searched. */
struct file *suffix_file;
/* Maximum length of a suffix. */
unsigned int maxsuffix;
/* Compute the maximum dependency length and maximum number of
dependencies of all implicit rules. Also sets the subdir
flag for a rule when appropriate, possibly removing the rule
completely when appropriate. */
void
count_implicit_rule_limits ()
{
char *name;
unsigned int namelen;
register struct rule *rule, *lastrule;
num_pattern_rules = max_pattern_targets = max_pattern_deps = 0;
max_pattern_dep_length = 0;
name = 0;
namelen = 0;
rule = pattern_rules;
lastrule = 0;
while (rule != 0)
{
unsigned int ndeps = 0;
register struct dep *dep;
struct rule *next = rule->next;
unsigned int ntargets;
++num_pattern_rules;
ntargets = 0;
while (rule->targets[ntargets] != 0)
++ntargets;
if (ntargets > max_pattern_targets)
max_pattern_targets = ntargets;
for (dep = rule->deps; dep != 0; dep = dep->next)
{
unsigned int len = strlen (dep->name);
#ifdef VMS
char *p = strrchr (dep->name, ']');
char *p2;
if (p == 0)
p = strrchr (dep->name, ':');
p2 = p != 0 ? strchr (dep->name, '%') : 0;
#else
char *p = strrchr (dep->name, '/');
char *p2 = p != 0 ? strchr (dep->name, '%') : 0;
#endif
ndeps++;
if (len > max_pattern_dep_length)
max_pattern_dep_length = len;
if (p != 0 && p2 > p)
{
/* There is a slash before the % in the dep name.
Extract the directory name. */
if (p == dep->name)
++p;
if (p - dep->name > namelen)
{
if (name != 0)
free (name);
namelen = p - dep->name;
name = (char *) xmalloc (namelen + 1);
}
bcopy (dep->name, name, p - dep->name);
name[p - dep->name] = '\0';
/* In the deps of an implicit rule the `changed' flag
actually indicates that the dependency is in a
nonexistent subdirectory. */
dep->changed = !dir_file_exists_p (name, "");
#ifdef VMS
if (dep->changed && strchr (name, ':') != 0)
#else
if (dep->changed && *name == '/')
#endif
{
/* The name is absolute and the directory does not exist.
This rule can never possibly match, since this dependency
can never possibly exist. So just remove the rule from
the list. */
freerule (rule, lastrule);
--num_pattern_rules;
goto end_main_loop;
}
}
else
/* This dependency does not reside in a subdirectory. */
dep->changed = 0;
}
if (ndeps > max_pattern_deps)
max_pattern_deps = ndeps;
lastrule = rule;
end_main_loop:
rule = next;
}
if (name != 0)
free (name);
}
/* Create a pattern rule from a suffix rule.
TARGET is the target suffix; SOURCE is the source suffix.
CMDS are the commands.
If TARGET is nil, it means the target pattern should be `(%.o)'.
If SOURCE is nil, it means there should be no deps. */
static void
convert_suffix_rule (target, source, cmds)
char *target, *source;
struct commands *cmds;
{
char *targname, *targpercent, *depname;
char **names, **percents;
struct dep *deps;
unsigned int len;
if (target == 0)
/* Special case: TARGET being nil means we are defining a
`.X.a' suffix rule; the target pattern is always `(%.o)'. */
{
#ifdef VMS
targname = savestring ("(%.obj)", 7);
#else
targname = savestring ("(%.o)", 5);
#endif
targpercent = targname + 1;
}
else
{
/* Construct the target name. */
len = strlen (target);
targname = xmalloc (1 + len + 1);
targname[0] = '%';
bcopy (target, targname + 1, len + 1);
targpercent = targname;
}
names = (char **) xmalloc (2 * sizeof (char *));
percents = (char **) alloca (2 * sizeof (char *));
names[0] = targname;
percents[0] = targpercent;
names[1] = percents[1] = 0;
if (source == 0)
deps = 0;
else
{
/* Construct the dependency name. */
len = strlen (source);
depname = xmalloc (1 + len + 1);
depname[0] = '%';
bcopy (source, depname + 1, len + 1);
deps = (struct dep *) xmalloc (sizeof (struct dep));
deps->next = 0;
deps->name = depname;
deps->ignore_mtime = 0;
}
create_pattern_rule (names, percents, 0, deps, cmds, 0);
}
/* Convert old-style suffix rules to pattern rules.
All rules for the suffixes on the .SUFFIXES list
are converted and added to the chain of pattern rules. */
void
convert_to_pattern ()
{
register struct dep *d, *d2;
register struct file *f;
register char *rulename;
register unsigned int slen, s2len;
/* Compute maximum length of all the suffixes. */
maxsuffix = 0;
for (d = suffix_file->deps; d != 0; d = d->next)
{
register unsigned int namelen = strlen (dep_name (d));
if (namelen > maxsuffix)
maxsuffix = namelen;
}
rulename = (char *) alloca ((maxsuffix * 2) + 1);
for (d = suffix_file->deps; d != 0; d = d->next)
{
/* Make a rule that is just the suffix, with no deps or commands.
This rule exists solely to disqualify match-anything rules. */
convert_suffix_rule (dep_name (d), (char *) 0, (struct commands *) 0);
f = d->file;
if (f->cmds != 0)
/* Record a pattern for this suffix's null-suffix rule. */
convert_suffix_rule ("", dep_name (d), f->cmds);
/* Record a pattern for each of this suffix's two-suffix rules. */
slen = strlen (dep_name (d));
bcopy (dep_name (d), rulename, slen);
for (d2 = suffix_file->deps; d2 != 0; d2 = d2->next)
{
s2len = strlen (dep_name (d2));
if (slen == s2len && streq (dep_name (d), dep_name (d2)))
continue;
bcopy (dep_name (d2), rulename + slen, s2len + 1);
f = lookup_file (rulename);
if (f == 0 || f->cmds == 0)
continue;
if (s2len == 2 && rulename[slen] == '.' && rulename[slen + 1] == 'a')
/* A suffix rule `.X.a:' generates the pattern rule `(%.o): %.X'.
It also generates a normal `%.a: %.X' rule below. */
convert_suffix_rule ((char *) 0, /* Indicates `(%.o)'. */
dep_name (d),
f->cmds);
/* The suffix rule `.X.Y:' is converted
to the pattern rule `%.Y: %.X'. */
convert_suffix_rule (dep_name (d2), dep_name (d), f->cmds);
}
}
}
/* Install the pattern rule RULE (whose fields have been filled in)
at the end of the list (so that any rules previously defined
will take precedence). If this rule duplicates a previous one
(identical target and dependencies), the old one is replaced
if OVERRIDE is nonzero, otherwise this new one is thrown out.
When an old rule is replaced, the new one is put at the end of the
list. Return nonzero if RULE is used; zero if not. */
int
new_pattern_rule (rule, override)
register struct rule *rule;
int override;
{
register struct rule *r, *lastrule;
register unsigned int i, j;
rule->in_use = 0;
rule->terminal = 0;
rule->next = 0;
/* Search for an identical rule. */
lastrule = 0;
for (r = pattern_rules; r != 0; lastrule = r, r = r->next)
for (i = 0; rule->targets[i] != 0; ++i)
{
for (j = 0; r->targets[j] != 0; ++j)
if (!streq (rule->targets[i], r->targets[j]))
break;
if (r->targets[j] == 0)
/* All the targets matched. */
{
register struct dep *d, *d2;
for (d = rule->deps, d2 = r->deps;
d != 0 && d2 != 0; d = d->next, d2 = d2->next)
if (!streq (dep_name (d), dep_name (d2)))
break;
if (d == 0 && d2 == 0)
{
/* All the dependencies matched. */
if (override)
{
/* Remove the old rule. */
freerule (r, lastrule);
/* Install the new one. */
if (pattern_rules == 0)
pattern_rules = rule;
else
last_pattern_rule->next = rule;
last_pattern_rule = rule;
/* We got one. Stop looking. */
goto matched;
}
else
{
/* The old rule stays intact. Destroy the new one. */
freerule (rule, (struct rule *) 0);
return 0;
}
}
}
}
matched:;
if (r == 0)
{
/* There was no rule to replace. */
if (pattern_rules == 0)
pattern_rules = rule;
else
last_pattern_rule->next = rule;
last_pattern_rule = rule;
}
return 1;
}
/* Install an implicit pattern rule based on the three text strings
in the structure P points to. These strings come from one of
the arrays of default implicit pattern rules.
TERMINAL specifies what the `terminal' field of the rule should be. */
void
install_pattern_rule (p, terminal)
struct pspec *p;
int terminal;
{
register struct rule *r;
char *ptr;
r = (struct rule *) xmalloc (sizeof (struct rule));
r->targets = (char **) xmalloc (2 * sizeof (char *));
r->suffixes = (char **) xmalloc (2 * sizeof (char *));
r->lens = (unsigned int *) xmalloc (2 * sizeof (unsigned int));
r->targets[1] = 0;
r->suffixes[1] = 0;
r->lens[1] = 0;
r->lens[0] = strlen (p->target);
/* These will all be string literals, but we malloc space for
them anyway because somebody might want to free them later on. */
r->targets[0] = savestring (p->target, r->lens[0]);
r->suffixes[0] = find_percent (r->targets[0]);
if (r->suffixes[0] == 0)
/* Programmer-out-to-lunch error. */
abort ();
else
++r->suffixes[0];
ptr = p->dep;
r->deps = (struct dep *) multi_glob (parse_file_seq (&ptr, '\0',
sizeof (struct dep), 1),
sizeof (struct dep));
if (new_pattern_rule (r, 0))
{
r->terminal = terminal;
r->cmds = (struct commands *) xmalloc (sizeof (struct commands));
r->cmds->fileinfo.filenm = 0;
r->cmds->fileinfo.lineno = 0;
/* These will all be string literals, but we malloc space for them
anyway because somebody might want to free them later. */
r->cmds->commands = xstrdup (p->commands);
r->cmds->command_lines = 0;
}
}
/* Free all the storage used in RULE and take it out of the
pattern_rules chain. LASTRULE is the rule whose next pointer
points to RULE. */
static void
freerule (rule, lastrule)
register struct rule *rule, *lastrule;
{
struct rule *next = rule->next;
register unsigned int i;
register struct dep *dep;
for (i = 0; rule->targets[i] != 0; ++i)
free (rule->targets[i]);
dep = rule->deps;
while (dep)
{
struct dep *t;
t = dep->next;
/* We might leak dep->name here, but I'm not sure how to fix this: I
think that pointer might be shared (e.g., in the file hash?) */
free ((char *) dep);
dep = t;
}
free ((char *) rule->targets);
free ((char *) rule->suffixes);
free ((char *) rule->lens);
/* We can't free the storage for the commands because there
are ways that they could be in more than one place:
* If the commands came from a suffix rule, they could also be in
the `struct file's for other suffix rules or plain targets given
on the same makefile line.
* If two suffixes that together make a two-suffix rule were each
given twice in the .SUFFIXES list, and in the proper order, two
identical pattern rules would be created and the second one would
be discarded here, but both would contain the same `struct commands'
pointer from the `struct file' for the suffix rule. */
free ((char *) rule);
if (pattern_rules == rule)
if (lastrule != 0)
abort ();
else
pattern_rules = next;
else if (lastrule != 0)
lastrule->next = next;
if (last_pattern_rule == rule)
last_pattern_rule = lastrule;
}
/* Create a new pattern rule with the targets in the nil-terminated
array TARGETS. If TARGET_PERCENTS is not nil, it is an array of
pointers into the elements of TARGETS, where the `%'s are.
The new rule has dependencies DEPS and commands from COMMANDS.
It is a terminal rule if TERMINAL is nonzero. This rule overrides
identical rules with different commands if OVERRIDE is nonzero.
The storage for TARGETS and its elements is used and must not be freed
until the rule is destroyed. The storage for TARGET_PERCENTS is not used;
it may be freed. */
void
create_pattern_rule (targets, target_percents,
terminal, deps, commands, override)
char **targets, **target_percents;
int terminal;
struct dep *deps;
struct commands *commands;
int override;
{
register struct rule *r = (struct rule *) xmalloc (sizeof (struct rule));
register unsigned int max_targets, i;
r->cmds = commands;
r->deps = deps;
r->targets = targets;
max_targets = 2;
r->lens = (unsigned int *) xmalloc (2 * sizeof (unsigned int));
r->suffixes = (char **) xmalloc (2 * sizeof (char *));
for (i = 0; targets[i] != 0; ++i)
{
if (i == max_targets - 1)
{
max_targets += 5;
r->lens = (unsigned int *)
xrealloc ((char *) r->lens, max_targets * sizeof (unsigned int));
r->suffixes = (char **)
xrealloc ((char *) r->suffixes, max_targets * sizeof (char *));
}
r->lens[i] = strlen (targets[i]);
r->suffixes[i] = (target_percents == 0 ? find_percent (targets[i])
: target_percents[i]) + 1;
if (r->suffixes[i] == 0)
abort ();
}
if (i < max_targets - 1)
{
r->lens = (unsigned int *) xrealloc ((char *) r->lens,
(i + 1) * sizeof (unsigned int));
r->suffixes = (char **) xrealloc ((char *) r->suffixes,
(i + 1) * sizeof (char *));
}
if (new_pattern_rule (r, override))
r->terminal = terminal;
}
/* Create a new pattern-specific variable struct. */
struct pattern_var *
create_pattern_var (target, suffix)
char *target, *suffix;
{
register struct pattern_var *p = 0;
unsigned int len = strlen(target);
/* Look to see if this pattern already exists in the list. */
for (p = pattern_vars; p != NULL; p = p->next)
if (p->len == len && !strcmp(p->target, target))
break;
if (p == 0)
{
p = (struct pattern_var *) xmalloc (sizeof (struct pattern_var));
if (last_pattern_var != 0)
last_pattern_var->next = p;
else
pattern_vars = p;
last_pattern_var = p;
p->next = 0;
p->target = target;
p->len = len;
p->suffix = suffix + 1;
p->vars = create_new_variable_set();
}
return p;
}
/* Look up a target in the pattern-specific variable list. */
struct pattern_var *
lookup_pattern_var (target)
char *target;
{
struct pattern_var *p;
unsigned int targlen = strlen(target);
for (p = pattern_vars; p != 0; p = p->next)
{
char *stem;
unsigned int stemlen;
if (p->len > targlen)
/* It can't possibly match. */
continue;
/* From the lengths of the filename and the pattern parts,
find the stem: the part of the filename that matches the %. */
stem = target + (p->suffix - p->target - 1);
stemlen = targlen - p->len + 1;
/* Compare the text in the pattern before the stem, if any. */
if (stem > target && !strneq (p->target, target, stem - target))
continue;
/* Compare the text in the pattern after the stem, if any.
We could test simply using streq, but this way we compare the
first two characters immediately. This saves time in the very
common case where the first character matches because it is a
period. */
if (*p->suffix == stem[stemlen]
&& (*p->suffix == '\0' || streq (&p->suffix[1], &stem[stemlen+1])))
break;
}
return p;
}
/* Print the data base of rules. */
static void /* Useful to call from gdb. */
print_rule (r)
struct rule *r;
{
register unsigned int i;
register struct dep *d;
for (i = 0; r->targets[i] != 0; ++i)
{
fputs (r->targets[i], stdout);
if (r->targets[i + 1] != 0)
putchar (' ');
else
putchar (':');
}
if (r->terminal)
putchar (':');
for (d = r->deps; d != 0; d = d->next)
printf (" %s", dep_name (d));
putchar ('\n');
if (r->cmds != 0)
print_commands (r->cmds);
}
void
print_rule_data_base ()
{
register unsigned int rules, terminal;
register struct rule *r;
puts (_("\n# Implicit Rules"));
rules = terminal = 0;
for (r = pattern_rules; r != 0; r = r->next)
{
++rules;
putchar ('\n');
print_rule (r);
if (r->terminal)
++terminal;
}
if (rules == 0)
puts (_("\n# No implicit rules."));
else
{
printf (_("\n# %u implicit rules, %u"), rules, terminal);
#ifndef NO_FLOAT
printf (" (%.1f%%)", (double) terminal / (double) rules * 100.0);
#else
{
int f = (terminal * 1000 + 5) / rules;
printf (" (%d.%d%%)", f/10, f%10);
}
#endif
puts (_(" terminal."));
}
if (num_pattern_rules != rules)
{
/* This can happen if a fatal error was detected while reading the
makefiles and thus count_implicit_rule_limits wasn't called yet. */
if (num_pattern_rules != 0)
fatal (NILF, _("BUG: num_pattern_rules wrong! %u != %u"),
num_pattern_rules, rules);
}
puts (_("\n# Pattern-specific variable values"));
{
struct pattern_var *p;
rules = 0;
for (p = pattern_vars; p != 0; p = p->next)
{
++rules;
printf ("\n%s :\n", p->target);
print_variable_set (p->vars->set, "# ");
}
if (rules == 0)
puts (_("\n# No pattern-specific variable values."));
else
{
printf (_("\n# %u pattern-specific variable values"), rules);
}
}
}

72
rule.h Normal file
View File

@@ -0,0 +1,72 @@
/* Definitions for using pattern rules in GNU Make.
Copyright (C) 1988, 1989, 1991, 1992, 1993 Free Software Foundation, Inc.
This file is part of GNU Make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/* Structure used for pattern rules. */
struct rule
{
struct rule *next;
char **targets; /* Targets of the rule. */
unsigned int *lens; /* Lengths of each target. */
char **suffixes; /* Suffixes (after `%') of each target. */
struct dep *deps; /* Dependencies of the rule. */
struct commands *cmds; /* Commands to execute. */
char terminal; /* If terminal (double-colon). */
char in_use; /* If in use by a parent pattern_search. */
};
struct pattern_var
{
struct pattern_var *next;
char *target;
unsigned int len;
char *suffix;
struct variable_set_list *vars;
};
/* For calling install_pattern_rule. */
struct pspec
{
char *target, *dep, *commands;
};
extern struct rule *pattern_rules;
extern struct rule *last_pattern_rule;
extern unsigned int num_pattern_rules;
extern unsigned int max_pattern_deps;
extern unsigned int max_pattern_targets;
extern unsigned int max_pattern_dep_length;
extern struct file *suffix_file;
extern unsigned int maxsuffix;
extern void install_pattern_rule PARAMS ((struct pspec *p, int terminal));
extern int new_pattern_rule PARAMS ((struct rule *rule, int override));
extern struct pattern_var *create_pattern_var PARAMS ((char *target, char *suffix));
extern struct pattern_var *lookup_pattern_var PARAMS ((char *target));
extern void count_implicit_rule_limits PARAMS ((void));
extern void convert_to_pattern PARAMS ((void));
extern void create_pattern_rule PARAMS ((char **targets,
char **target_percents, int terminal,
struct dep *deps,
struct commands *commands,
int override));

255
signame.c Normal file
View File

@@ -0,0 +1,255 @@
/* Convert between signal names and numbers.
Copyright (C) 1990,92,93,95,96,99, 2002 Free Software Foundation, Inc.
This file was part of the GNU C Library, but is now part of GNU make.
GNU Make is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Make is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Make; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "make.h"
/* If the system provides strsignal, we don't need it. */
#if !defined(HAVE_STRSIGNAL)
/* If the system provides sys_siglist, we'll use that.
Otherwise create our own.
*/
#if !defined(SYS_SIGLIST_DECLARED)
/* Some systems do not define NSIG in <signal.h>. */
#ifndef NSIG
#ifdef _NSIG
#define NSIG _NSIG
#else
#define NSIG 32
#endif
#endif
/* There is too much variation in Sys V signal numbers and names, so
we must initialize them at runtime. */
static const char *undoc;
static const char *sys_siglist[NSIG];
/* Table of abbreviations for signals. Note: A given number can
appear more than once with different abbreviations. */
#define SIG_TABLE_SIZE (NSIG*2)
typedef struct
{
int number;
const char *abbrev;
} num_abbrev;
static num_abbrev sig_table[SIG_TABLE_SIZE];
/* Number of elements of sig_table used. */
static int sig_table_nelts = 0;
/* Enter signal number NUMBER into the tables with ABBREV and NAME. */
static void
init_sig (number, abbrev, name)
int number;
const char *abbrev;
const char *name;
{
/* If this value is ever greater than NSIG it seems like it'd be a bug in
the system headers, but... better safe than sorry. We know, for
example, that this isn't always true on VMS. */
if (number >= 0 && number < NSIG)
sys_siglist[number] = name;
if (sig_table_nelts < SIG_TABLE_SIZE)
{
sig_table[sig_table_nelts].number = number;
sig_table[sig_table_nelts++].abbrev = abbrev;
}
}
static int
signame_init ()
{
int i;
undoc = xstrdup (_("unknown signal"));
/* Initialize signal names. */
for (i = 0; i < NSIG; i++)
sys_siglist[i] = undoc;
/* Initialize signal names. */
#if defined (SIGHUP)
init_sig (SIGHUP, "HUP", _("Hangup"));
#endif
#if defined (SIGINT)
init_sig (SIGINT, "INT", _("Interrupt"));
#endif
#if defined (SIGQUIT)
init_sig (SIGQUIT, "QUIT", _("Quit"));
#endif
#if defined (SIGILL)
init_sig (SIGILL, "ILL", _("Illegal Instruction"));
#endif
#if defined (SIGTRAP)
init_sig (SIGTRAP, "TRAP", _("Trace/breakpoint trap"));
#endif
/* If SIGIOT == SIGABRT, we want to print it as SIGABRT because
SIGABRT is in ANSI and POSIX.1 and SIGIOT isn't. */
#if defined (SIGABRT)
init_sig (SIGABRT, "ABRT", _("Aborted"));
#endif
#if defined (SIGIOT)
init_sig (SIGIOT, "IOT", _("IOT trap"));
#endif
#if defined (SIGEMT)
init_sig (SIGEMT, "EMT", _("EMT trap"));
#endif
#if defined (SIGFPE)
init_sig (SIGFPE, "FPE", _("Floating point exception"));
#endif
#if defined (SIGKILL)
init_sig (SIGKILL, "KILL", _("Killed"));
#endif
#if defined (SIGBUS)
init_sig (SIGBUS, "BUS", _("Bus error"));
#endif
#if defined (SIGSEGV)
init_sig (SIGSEGV, "SEGV", _("Segmentation fault"));
#endif
#if defined (SIGSYS)
init_sig (SIGSYS, "SYS", _("Bad system call"));
#endif
#if defined (SIGPIPE)
init_sig (SIGPIPE, "PIPE", _("Broken pipe"));
#endif
#if defined (SIGALRM)
init_sig (SIGALRM, "ALRM", _("Alarm clock"));
#endif
#if defined (SIGTERM)
init_sig (SIGTERM, "TERM", _("Terminated"));
#endif
#if defined (SIGUSR1)
init_sig (SIGUSR1, "USR1", _("User defined signal 1"));
#endif
#if defined (SIGUSR2)
init_sig (SIGUSR2, "USR2", _("User defined signal 2"));
#endif
/* If SIGCLD == SIGCHLD, we want to print it as SIGCHLD because that
is what is in POSIX.1. */
#if defined (SIGCHLD)
init_sig (SIGCHLD, "CHLD", _("Child exited"));
#endif
#if defined (SIGCLD)
init_sig (SIGCLD, "CLD", _("Child exited"));
#endif
#if defined (SIGPWR)
init_sig (SIGPWR, "PWR", _("Power failure"));
#endif
#if defined (SIGTSTP)
init_sig (SIGTSTP, "TSTP", _("Stopped"));
#endif
#if defined (SIGTTIN)
init_sig (SIGTTIN, "TTIN", _("Stopped (tty input)"));
#endif
#if defined (SIGTTOU)
init_sig (SIGTTOU, "TTOU", _("Stopped (tty output)"));
#endif
#if defined (SIGSTOP)
init_sig (SIGSTOP, "STOP", _("Stopped (signal)"));
#endif
#if defined (SIGXCPU)
init_sig (SIGXCPU, "XCPU", _("CPU time limit exceeded"));
#endif
#if defined (SIGXFSZ)
init_sig (SIGXFSZ, "XFSZ", _("File size limit exceeded"));
#endif
#if defined (SIGVTALRM)
init_sig (SIGVTALRM, "VTALRM", _("Virtual timer expired"));
#endif
#if defined (SIGPROF)
init_sig (SIGPROF, "PROF", _("Profiling timer expired"));
#endif
#if defined (SIGWINCH)
/* "Window size changed" might be more accurate, but even if that
is all that it means now, perhaps in the future it will be
extended to cover other kinds of window changes. */
init_sig (SIGWINCH, "WINCH", _("Window changed"));
#endif
#if defined (SIGCONT)
init_sig (SIGCONT, "CONT", _("Continued"));
#endif
#if defined (SIGURG)
init_sig (SIGURG, "URG", _("Urgent I/O condition"));
#endif
#if defined (SIGIO)
/* "I/O pending" has also been suggested. A disadvantage is
that signal only happens when the process has
asked for it, not everytime I/O is pending. Another disadvantage
is the confusion from giving it a different name than under Unix. */
init_sig (SIGIO, "IO", _("I/O possible"));
#endif
#if defined (SIGWIND)
init_sig (SIGWIND, "WIND", _("SIGWIND"));
#endif
#if defined (SIGPHONE)
init_sig (SIGPHONE, "PHONE", _("SIGPHONE"));
#endif
#if defined (SIGPOLL)
init_sig (SIGPOLL, "POLL", _("I/O possible"));
#endif
#if defined (SIGLOST)
init_sig (SIGLOST, "LOST", _("Resource lost"));
#endif
#if defined (SIGDANGER)
init_sig (SIGDANGER, "DANGER", _("Danger signal"));
#endif
#if defined (SIGINFO)
init_sig (SIGINFO, "INFO", _("Information request"));
#endif
#if defined (SIGNOFP)
init_sig (SIGNOFP, "NOFP", _("Floating point co-processor not available"));
#endif
return 1;
}
#endif /* SYS_SIGLIST_DECLARED */
char *
strsignal (signal)
int signal;
{
static char buf[] = "Signal 12345678901234567890";
#if !defined(SYS_SIGLIST_DECLARED)
static char sig_initted = 0;
if (!sig_initted)
sig_initted = signame_init ();
#endif
if (signal > 0 || signal < NSIG)
return (char *) sys_siglist[signal];
sprintf (buf, "Signal %d", signal);
return buf;
}
#endif /* HAVE_STRSIGNAL */

6
subproc.bat Normal file
View File

@@ -0,0 +1,6 @@
cd w32\subproc
set MAKE=%2
set MAKEFILE=%1
if x%2 == x set MAKE=nmake
%MAKE% /f %MAKEFILE%
cd ..\..

1
tests/.cvsignore Normal file
View File

@@ -0,0 +1 @@
work

Some files were not shown because too many files have changed in this diff Show More