the build step. Catches things like binutils which do a bunch of configures
on the build step and lose possibly. Fixes issues from PR#29197 for lex
not being picked up here.
so generated objects vs listed objects in make line up and dependcies happen
correctly. Found because libiberty (on this binutils import) was leaving
all objects as ./object.o and make wasn't picking up correct depends on
config.h as a result.
gets built and installed in a hp700 distribution.
TODO
- merge with hp300
- pick a preferred method for dealing with the elf headers.
hp700-mkboot and prep-mkbootimage (bintuils) vs mips-elf2ecoff and
tools/installboot
this is not currently being used and should be replaced with
HAVE_STRUCT_STATVFS_F_IOSIZE, but that will be done separately.
This commit should be able to be safely pulled up to
the netbsd-2-0 branch to address PR toolchain/26415
So, don't wrap definitions in it, and instead check for it and #error out
if it somehow leaks into scope.
Tested a complete build to sets on x86 from a clean source tree.
- Protect dirfd() macro so that we don't re-define it.
These changes make my build proceed further.
The problem is that automatically generated files, might include system
files before they include anything else (for example our yacc skeleton
includes <stdlib.h> before it does anything else). This foils the scheme
of defining _POSIX_SOURCE and friends so that _NETBSD_SOURCE does not
get defined; in fact, we include many files with _NETBSD_SOURCE defined,
enough to cause confusion in compat_defs.h which tries to re-define things.
exposed all the time, but routines which use it do not. Otherwise callers
of strtouq will lose.
XXX: Need to come back through here and clean up the configure tests better
for this
_NETBSD_SOURCE as this makes cross building from older/newer versions of
NetBSD harder, not easier (and also makes the resulting tools 'different')
Wrap all required code with the inclusion of nbtool_config.h, attempt to
only use POSIX code in all places (or when reasonable test w. configure and
provide definitions: ala u_int, etc).
Reviewed by lukem. Tested on FreeBSD 4.9, Redhat Linux ES3, NetBSD 1.6.2 x86
NetBSD current (x86 and amd64) and Solaris 9.
Fixes PR's: PR#17762 PR#25944
sure to use _POSIX_C_SOURCE and undef _NETBSD_SOURCE so the myriad of NetBSD
extentions don't get pulled into scope (and likely conflict at some point
with branched code trying to build on -current due to drift). Fixes PR#25533
XXX: The entire process here is just wacky and the entire cross tools process
needed to be reviewed to build clean w. just _POSIX_C_SOURCE or the equiv
set on NetBSD hosts or this will lose again somewhere..
no dependencies are known in advance. So a simple 'build.sh -r -u' will
often lose and end up with a TOOLDIR without a toolchain, groff, etc. Fix
by forcing .install_done to always run.
Instead of adding MAKE_BOOTSTRAP for hosted environments, i.e., when
you want things simple, instead add MAKE_NATIVE to get those hugely
important features like __RCSID().
Also, get rid of a now-unneeded -I.
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.
Fix the behaviour of native and tools gcc when MKPIC=no is specified for
platforms that mknative has determined support shared libraries.
XXX distrib/sets/sets.subr doesn't support MKPIC=no