summaryrefslogtreecommitdiff
path: root/commands.c
AgeCommit message (Collapse)AuthorFilesLines
2013-05-03Fix interfacing with and remaking dynamic objects on MS-Windows.Eli Zaretskii1-0/+8
load.c (load_object, load_file): Accept an additional argument DLP and return in it a pointer that can be used to unload the dynamic object. read.c (eval): Call load_file with an additional argument, and record the pointer returned there in the 'struct file' object of dynamic objects in that object's 'struct file'. commands.c (execute_file_commands): Unload dynamic objects before remaking them, to avoid failure to remake if the OS doesn't allow overwriting objects that are in use. filedef.h (struct file): New member dlopen_ptr. gnumake.h (GMK_EXPORT): Define to dllexport/dllimport decorations for Windows and to nothing on other platforms. (gmk_eval, gmk_expand, gmk_add_function): Add GMK_EXPORT qualifier to prototypes. makeint.h (MAIN): Define before including gnumake.h, to give correct dllexport decorations to exported functions. (load_file): Adjust prototype. loadapi.c: Don't include gnumake.h, since makeint.h already includes it, and takes care of defining MAIN before doing so. build_w32.bat (LinkGCC): Produce an import library for functions exported by Make for loadable dynamic objects. w32/compat/posixfcn.c (dlclose): New function. w32/include/dlfcn.h (dlclose): Add prototype. scripts/features/load: Fix signatures of testload_gmk_setup and explicit_setup, to bring them in line with the documentation.
2013-01-20Rename the make.h file to makeint.h for internal use only.Paul Smith1-1/+1
2012-03-05Simplify copyrights using ranges of years.Paul Smith1-3/+1
The new GNU Maintainer's Manual allows the use of year ranges in certain situations; take advantage of this simplification.
2012-03-04Convert all "`'" quotes to "''" per new GNU Coding Standard guidelines.Paul Smith1-10/+10
Fixes Savannah bug #34530.
2012-01-16Update copyright notices.Paul Smith1-3/+3
2010-11-06Improve backslash/newline handling to adhere to POSIX requirements.Paul Smith1-4/+13
2010-07-13Update copyrights for 2010.Paul Smith1-2/+2
2010-07-12Add the beginning of the .ONESHELL special feature.Paul Smith1-37/+54
Original patch by David Boyce. Modified by Paul Smith.
2009-10-25Update copyright years.Paul Smith1-2/+2
2009-10-25Various simple code cleanups.Paul Smith1-4/+6
2009-10-07Minor fix and code rework.Boris Kolpackov1-12/+13
2009-10-06Fix savannah bug 25780. Optimize things a bit.Boris Kolpackov1-20/+72
2009-09-24- Rework secondary expansion so we only defer it if there's a possibilityPaul Smith1-5/+10
it might be needed: for most situations we parse prereqs immediately as we used to. Reduces memory usage. - Fixes Savannah bug #18622.
2009-09-16- Add xcalloc() and call itPaul Smith1-1/+1
- Fix memory errors found by valgrind - Remove multi_glob() and empower parse_file_seq() to do its job: the goal here is to remove the confusing reverse/re-reverse we do on the file lists: needed for future fixes. - Add a prefix arg to parse_file_seq() - Make concat() variadic so it can take arbitrary #'s of strings
2009-06-13- Fix Savannah bug 17825Paul Smith1-1/+1
- Fix Savannah bug 21231
2009-05-24Found this change in an old CVS workspace: rewrite savestring() to thePaul Smith1-1/+1
more standard xstrndup().
2007-11-04New special variable: .RECIPEPREFIXPaul Smith1-6/+3
Allows the user to reset the prefix character for introducing recipe lines from the default (tab) to any other single character, and back again. Also, reworked the manual to consistently use the word "recipe" to describe the set of commands we use to update a target, instead of the various phrases used in the past: "commands", "command lines", "command scripts", etc.
2007-07-04* Update to GPLv3Paul Smith1-4/+4
* Update copyright to 2007 * Fix download URL for translation files (thanks to Thiemo Seufer)
2007-03-20This is a major update, which switches virtually every allocated-but-not-freedPaul Smith1-2/+2
string into the strcache. As a side-effect, many more structure members and function arguments can/should be declared const. As mentioned in the changelog, unfortunately measurement shows that this change does not yet reduce memory. The problem is with secondary expansion: because of this we store all the prerequisites in the string cache twice. First we store the prerequisite string after initial expansion but before secondary expansion, then we store each individual file after secondary expansion and expand_deps(). I plan to change expand_deps() to be callable in either context (eval or snap_deps) then have non-second-expansion targets call expand_deps() during eval, so that we only need to store that dependency list once.
2006-11-18Fix from Eli for incorrect value of $(MAKE) on Cygwin.Paul Smith1-25/+28
A few changes from char* to void* where appropriate, and removing of unnecessary casts. Much more work on const-ifying the codebase. This round involves some code changes to make it correct. NOTE!! There will almost certainly be problems on the non-POSIX ports that will need to be addressed after the const changes are finished: they will need to be const-ified properly and there may need to be some changes to allocate memory, etc. as well. The next (last?) big push for this, still to come, is const-ifying the filenames in struct file, struct dep, etc. This will allow us to store file names in the string cache and finally resolve Savannah bug #15182 (make uses too much memory), among other advantages.
2006-04-09Another round of cleanups:Paul Smith1-16/+13
- Add more warnings. - Rename variables that mask out-scope vars with the same name. - Remove all casts of return values from xmalloc, xrealloc, and alloca. - Remove casts of the first argument to xrealloc. - Convert all bcopy/bzero/bcmp invocations to use memcp/memmove/memset/memcmp.
2006-04-07Code cleanup: Remove all references to PARAMS() & ansi2knr.Paul Smith1-2/+2
2006-02-20- Memory cleanups, found with valgrind.Paul Smith1-3/+3
- Fix handling of special targets like .SUFFIX for VMS insensitive targets. - Don't make temporary batch files for -n. Make sure batch files are created in text mode.
2006-02-11Last of the copyright updates.Paul Smith1-1/+2
2006-02-11Update copyright and license notices on all files.Paul Smith1-13/+11
Added new file strcache.c to various non-UNIX makefiles and build scripts.
2005-08-08- Fixed a bug reported by Michael Matz regarding handling of parallelPaul Smith1-2/+30
jobs after a failed job. - Enhancements to WINDOWS32 code from Eli Zaretskii. - Add Microsoft Project files from J. Grant.
2005-03-04- Missing docs for $|Paul Smith1-0/+5
- Update NEWS and AUTHORS files. - Fix support request #103195. - Apply patch #3679 - Fix handling of sys_siglist in autoconf/etc.
2005-02-27Implementation of the second expansion in explicitBoris Kolpackov1-1/+1
rules, static pattern rules and implicit rules.
2004-09-21Remove sindex() and replace with strstr().Paul Smith1-7/+5
Windows: allow users to set SHELL to cmd.exe and have it behave as if no UNIX shell were found.
2004-05-16Various enhancementsPaul Smith1-3/+9
- OS/2 Patches - OpenVMS updates - Sanitize the handling of -include/sinclude with and without -k - Fix the setting of $< for order-only rules.
2004-02-24Many compiler warning cleanups.Paul Smith1-1/+1
Small fixes for W32 (from Jonathan Grant <jg-make@jguk.org>) Maintainer enhancements to clean up the tree.
2003-01-30Portability fix for glob.h building in FreeBSD ports system.Paul Smith1-1/+3
Implement a fix for bug # 2169: too many OSs, even major OSs like Solaris, don't properly implement SA_RESTART: important system calls like stat() can still fail when SA_RESTART is set. So, forget the BROKEN_RESTART config check and get rid of atomic_stat() and atomic_readdir(), and implement permanent wrappers for EINTR checking on various system calls (stat(), fstat(), opendir(), and readdir() so far).
2002-10-14Convert the source code to use ANSI C style function definitions andPaul Smith1-15/+7
enable the automake ansi2knr capability. Right now this doesn't quite build using a K&R compiler because of a problem with the loadavg test program, but the rest of the code works. I'm asking the automake list about this problem.
2002-10-13Fix bug#1379: don't use alloca() where it could overrun the stack size.Paul Smith1-6/+15
Implemented enhancement #1391: allow "export" in target-specific variable definitions. Change the Info name of the "Automatic" node to "Automatic Variables". Add text clarifying the scope of automatic variables to that section.
2002-09-12Fixups for the release. One bug fix, some automake complaint fixes,Paul Smith1-1/+1
and a function return type fix for older systems.
2002-07-09Documentation and tests for order-only prerequisites.Paul Smith1-1/+1
Add a new test suite for automatic variables.
2002-07-08Various cleanups reported by people using the alpha release.Paul Smith1-46/+65
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.
2001-05-21Some VMS fixes sent by John Fowler.Paul Smith1-1/+1
Fix: make flags on some lines of define/endef don't affect other lines
2000-06-13* Some timestamp fixes from Paul Eggert.Paul Smith1-2/+5
* Fix compilation on Linux; use libintl.h and not gettext.h when using the system gettext.
2000-06-07* Lots of bug fixes and cleanup; new i18n files, etc.Paul Smith1-1/+1
2000-02-05* Fix PR/1407.Paul Smith1-2/+2
* Keep filename/lineno information for variables, for debugging.
1999-10-15* Fix PR/1394.Paul Smith1-8/+8
* Apply changes from Paul Eggert. * Many other cleanups (index/rindex --> strchr/strrchr, etc.)
1999-10-13* Fix PR/1379: -n/-q behaves correctly when all commands are recursive.Paul Smith1-84/+86
1999-07-28* Add gettext macros to start i18n support.Paul Smith1-8/+8
1999-07-21* Add configure option to enable dmalloc library.Paul Smith1-1/+1
* Various code cleanups.
1999-07-20* Fix memory leaks, fd leaks, and some long-standing bugs recognizing whenPaul Smith1-0/+1
targets need to have their modtimes rechecked (-n, etc.)
1999-06-14* Various bug fixes.Paul Smith1-1/+1
1999-03-05* Update FSF address info in copyright notices.Paul Smith1-1/+2
* 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.
1998-10-03Checkpoint changes. Bug fixes, mostly.Paul Smith1-8/+9
1997-08-27Updates for GNU make 3.75.92.Paul Smith1-1/+1