diff options
author | Paul Smith <psmith@gnu.org> | 2006-11-18 20:53:44 +0000 |
---|---|---|
committer | Paul Smith <psmith@gnu.org> | 2006-11-18 20:53:44 +0000 |
commit | e4da30858037b431880263676e8f90b1f8412a38 (patch) | |
tree | 2605109d089f52e373bd976391dca85774ae3b21 /read.c | |
parent | 7595f38f62afa7ac3451018d865fb251e3ce91c3 (diff) | |
download | gunmake-e4da30858037b431880263676e8f90b1f8412a38.tar.gz |
Fix from Eli for incorrect value of $(MAKE) on Cygwin.
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.
Diffstat (limited to 'read.c')
-rw-r--r-- | read.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -527,7 +527,7 @@ eval (struct ebuffer *ebuf, int set_default) /* Check for a shell command line first. If it is not one, we can stop treating tab specially. */ - if (line[0] == '\t') + if (line[0] == cmd_prefix) { if (no_targets) /* Ignore the commands in a rule with no targets. */ @@ -848,7 +848,7 @@ eval (struct ebuffer *ebuf, int set_default) /* This line starts with a tab but was not caught above because there was no preceding target, and the line might have been usable as a variable definition. But now we know it is definitely lossage. */ - if (line[0] == '\t') + if (line[0] == cmd_prefix) fatal(fstart, _("commands commence before first target")); /* This line describes some target files. This is complicated by @@ -1351,7 +1351,7 @@ do_define (char *name, unsigned int namelen, another define, or ends one. */ /* Stop if we find an 'endef' */ - if (line[0] != '\t') + if (line[0] != cmd_prefix) { p = next_token (line); len = strlen (p); @@ -2223,7 +2223,7 @@ find_char_unquote (char *string, int stop1, int stop2, int blank, return 0; } -/* Search PATTERN for an unquoted %. */ +/* Search PATTERN for an unquoted % and handle quoting. */ char * find_percent (char *pattern) |