Commit graph

26 commits

Author SHA1 Message Date
Paul Smith
fda00f88d3 Add test suite support to Windows
* main.c (main): Sanitize program name detection on Windows.
* makeint.h: 'program' is a const string on all platforms now.
* tests/run_make_tests.bat: Windows bat file to invoke tests
* tests/test_driver.pl: Obtain system-specific error messages.
(get_osname): Compute the $port_type here.  Add more $osname checks
for different Windows Perl ports.
(_run_command): Rewrite the timeout capability to work properly
with Windows.  Don't use Perl fork/exec; instead use system(1,...)
which allows a more reliable/proper kill operation.
Also, allow options to be given as a list instead of a string, to
allow more complex quoting of command-line arguments.
* tests/run_make_tests.pl (run_make_with_options): Allow options
to be provided as a list in addition to a simple string.
(set_more_defaults): Write sample makefiles and run make on them
instead of trying to run echo and invoking make with -f-, to avoid
relying on shell and echo to get basic configuration values.  Also
create a $sh_name variable instead of hard-coding /bin/sh.
* tests/scripts/features/archives: Skip on Windows.
* tests/scripts/features/escape: Use list method for passing options.
* tests/scripts/features/include: Use system-specific error messages.
* tests/scripts/features/output-sync: "Command not found" errors
generate very different / odd output on Windows.  This needs to be
addressed but for now disable these tests on Windows.
* tests/scripts/functions/abspath: Disable on Windows.
* tests/scripts/functions/file: Use system-specific error messages.
* tests/scripts/functions/shell: "Command not found" errors generate
very different / odd output on Windows.  This needs to be addressed
but for now disable these tests on Windows.
* tests/scripts/misc/close_stdout: Disable on Windows.
* tests/scripts/options/dash-k: Use system-specific error messages.
* tests/scripts/options/dash-l: Disable on Windows.
* tests/scripts/options/eval: Use list method for passing options.
* tests/scripts/options/general: Skip some non-portable tests.
* tests/scripts/targets/ONESHELL: Skip some non-portable tests.
* tests/scripts/targets/POSIX: Skip some non-portable tests.
* tests/scripts/variables/MAKEFILES: Skip some non-portable tests.
* tests/scripts/variables/SHELL: Use a makefile not -f- for testing.
2017-06-04 18:37:20 -04:00
Paul Smith
45bf0e3a67 Portability changes for the test suite.
* tests/test_driver.pl: Save error strings for later comparison.
* tests/run_make_tests.pl: Create portable commands for later use.
* tests/*: Use these new variables.
2016-12-26 09:01:59 -05:00
Paul Smith
ef6c059e1e * DELETE_ON_ERROR: [SV 48061] Use "exit 1" for portability.
Reported by Joel Fredrikson <Joel.Fredrikson@it.uu.se>
2016-05-31 03:17:26 -04:00
Paul Smith
b4682cb479 * job.c (child_error): Combine file info with error message.
* tests/scripts/...: Update error message matches.
2016-03-20 14:23:22 -04:00
Paul Smith
42745a900f * implicit.c (pattern_search): [SV 43677] Mark files secondary.
In order to fix SV 12267 we were marking the prerequisites of
implicit (pattern) targets that existed elsewhere in the makefile
as precious to keep them from being deleted as intermediate files.
However this also keeps them from being deleted on error.  Instead
mark them as secondary.
* tests/scripts/targets/DELETE_ON_ERROR: Test DELETE_ON_ERROR.
2015-07-13 00:51:35 -04:00
Paul Smith
d0944ee2e8 Solaris /bin/sh can't handle multiple options ("-e -c"). 2013-09-30 00:12:18 -04:00
Paul Smith
30b2e4207d When .POSIX: is specified use POSIX-standard macro values by default. 2012-09-09 19:19:15 +00:00
Paul Smith
23c2b99e9d Convert all "`'" quotes to "''" per new GNU Coding Standard guidelines.
Fixes Savannah bug #34530.
2012-03-04 00:24:20 +00:00
Paul Smith
405c89ba1e Ensure that .ONESHELL works with .SHELLFLAGS options containing whitespace.
See Savannah bug #35397.
2012-03-03 22:56:20 +00:00
Paul Smith
3057357c0a Add prerequisites to ensure ordering of results. 2011-12-10 17:13:14 +00:00
Paul Smith
a86d1693ba Bump the version to 3.82.90.
Fix some doc bugs.
Implement the --trace flag.
Show filename/linenumber on error.
2010-08-29 23:05:26 +00:00
Paul Smith
95f1a32d27 Release GNU make 3.82
- Update tests for Solaris bizarre-ness
- Update files for release
2010-07-28 05:39:50 +00:00
Paul Smith
fba20a776d - Many fixup patches from Savannah.
- Fix the test suite on Solaris (from Boris)
- Update the manual for .ONESHELL
2010-07-19 07:10:53 +00:00
Paul Smith
bbe7b86718 Forgot to add the ONESHELL regression tests. 2010-07-12 05:29:25 +00:00
Paul Smith
c7b469f0f3 - Enhance .POSIX to set -e when invoking shells, as demanded by a
backward-incompatible change in the 2008 POSIX specification.
- Add the .SHELLFLAGS variable so people can choose their own shell flags.
- Add tests for this.
- Add documentation for this.
2010-07-06 06:37:42 +00:00
Paul Smith
19b6504f8a Incorporate Icarus Sparry's fix for 3330 and 15919, and test cases.
One of our translations disappeared from the translations site so remove it.

The fdl.texi file was changed to not contain any @node entries, so add some
around it in make.texi.
2007-08-15 13:53:53 +00:00
Paul Smith
4bd6db9df1 Update the make.1 man page.
Use rm -f instead of rm in the test scripts.  Fixes bug #15085.
2005-12-13 14:44:17 +00:00
Paul Smith
3daf8df6ee Fix some Savannah bugs.
Updates to docs (still need more work here) and NEWS file.
New language.
2005-04-08 12:51:20 +00:00
Paul Smith
08c8105c54 Various enhancements
- OS/2 Patches
  - OpenVMS updates
  - Sanitize the handling of -include/sinclude with and without -k
  - Fix the setting of $< for order-only rules.
2004-05-16 19:16:52 +00:00
Paul Smith
652234e967 Fix bug #2515: the .SECONDARY target with no prerequisites wasn't
behaving properly (if you listed prerequisites it worked properly).
2003-03-28 06:31:44 +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
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
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
90f23f1ea6 * Updates for VMS, Windows, and DOS ports.
* Clean up some warnings.
2000-02-05 07:50:47 +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
0d366b6682 * Added the test suite to the main distribution. 1999-09-14 02:03:19 +00:00