Commit Graph

31 Commits

Author SHA1 Message Date
christos 5c5210c091 Like the non-host mkdep don't print ./foo.h as a dependency, but simplify
it to foo.h. This was causing problems with:

.y.h: ${.TARGET:.h=.c}

where .h was ./cgram.h and the source became ./cgram.c confusing for example
/usr/src/tools/lint1 because make had both cgram.c and ./cgram.c in the list
of sources, trying to build both of them in parallel thinking that they were
different files. Since the regular mkdep does not produce such dependencies,
the regular build does not suffer from this issue.
2015-05-12 00:04:34 +00:00
joerg 6bc52dcb42 Preserve -std=* options as they may change the dependency list. 2013-09-02 08:37:11 +00:00
uwe a94dff73a7 Some shells have ((expr)) syntax for arithmetic. Add space between
parens of nested (compound-list)s to unconfuse them.

Fixes PR toolchain/47695
2013-03-27 01:03:39 +00:00
christos 0cbc48b3cf Put back error checking in a simpler form thanks to uwe 2013-03-16 02:51:56 +00:00
joerg 8f7ae0d2ba Revert 1.25 and 1.26: Breaks build on !NetBSD 2013-03-14 14:55:35 +00:00
christos 93b2a5c31b re-directing once is good enough. 2013-03-12 01:55:33 +00:00
christos 621c21b80f Perform shell fd gymnastics to capture the error in the pipeline and exit. 2013-03-12 01:52:20 +00:00
christos e2a59201c6 account for -vi 2013-03-05 03:06:21 +00:00
christos 5641345b31 forgetting to shift turns this into a cpu burner. 2012-12-09 23:53:39 +00:00
christos 810857e2ff ignore --sysroot=/ 2012-12-09 23:42:16 +00:00
jmmv cdcce7d462 Add a new "-P prefix" option to mkdep(1).
This option prepends the string given in prefix to every target
filename.  This is useful for programs that have source files in
multiple subdirectories and a single Makefile that references all of
them explicitly (without using the VPATH functionality because there
can be files with the same name in each subdirectory).
2012-08-26 22:37:19 +00:00
wiz 4cbd24b23f dependant -> dependent 2011-06-30 20:09:15 +00:00
christos 0c40d420be recognize isysroot 2010-11-14 15:18:24 +00:00
joerg 637b0cffec Rewrite argument processing to deal with spaces and other meta
characters in options. This was exposed by the "NetBSD 5.99" argument of
mandoc.
2010-02-20 15:04:03 +00:00
jmmv 899297d564 Treat -cxx-isystem as -isystem-cxx. Not really required by our code, but
I discovered this while trying to add a host tool written in C++.
2007-07-09 15:27:10 +00:00
jwise c21f37fb93 On second thought, we can't just pass through -isystem-cxx, we have to
change it to -isystem.  With this change, I can now make depend a simple c++
stl-using host program.
2005-09-01 21:51:11 +00:00
jwise 97ec3a6bc9 Recognize -isystem-cxx as well as -isystem, making this more usable for c++
host progs.
2005-09-01 21:17:31 +00:00
dsl 8d259d44d9 Fix the processing of '-s .lo\ .ln' (etc).
This means that the tools now have correct dependencies (xxx.lo: ... instead
of xxx.o: ...) and in particular causes the pax to be built with consistent
headers.
There could also be other lossage on update builds of tools.
2004-03-27 18:36:23 +00:00
dsl 9a8804be3a Make command line parser getopt() compatible (allow host-mkdep -aq -s.o.lo ...)
Don't use shell builtin because we need to know the values of OPTIND (etc)
in what is usually an error path.
2003-12-07 20:19:15 +00:00
dsl 7037826394 Let -- be used to separate mkdep options from cc options 2003-11-11 10:50:02 +00:00
dsl 198a6cd602 Make this support the same new options as recently added to the mkdep program. 2003-11-10 17:57:43 +00:00
christos a3d7c5fa32 No sources == error again. 2003-06-11 13:20:38 +00:00
christos 2a8b4af820 for now, make the fact that no sources were specified a warning. 2003-06-10 21:34:02 +00:00
christos b09683b289 Do -isystem differently. 2003-06-10 20:40:39 +00:00
christos 1c6e138be1 understand -isystem too if compiler gcc/g++ 2003-06-10 19:51:45 +00:00
christos 33113de8c0 - shift; shift -> shift 2
- understand and do something reasonable with -nostdinc*
2003-06-06 17:33:32 +00:00
thorpej acd9c2da10 Allow "-no-cpp-precomp", which disables use of pre-compiled headers
on Mac OS X.
2003-03-13 04:40:45 +00:00
thorpej a25cf0dfe0 Patch host-mkdep with the working host shell. 2002-09-15 17:23:01 +00:00
thorpej 5aa3fde6fa Delete a few things that appear in gcc 3.x's CPP output. 2002-09-13 03:41:54 +00:00
tv 0c41d3705e Ensure a space after # or #line so we don't pick up stray #pragmas and
so forth in the .depend file.
2002-01-28 19:26:35 +00:00
tv 5457974230 Move host-mkdep to its own directory. Create and install it before
everything else.  Now it's possible for the target mkdep to build and
install like "normal" host-tools do; should remove the function decl
warnings reported by greywolf@starwolf.com on current-users.
2002-01-10 17:04:20 +00:00