There's two variables added to Makefile.crunch:
SMALLPROG If 1, add SMALLPROG=1 to CRUNCHENV. [default: 1]
This can be used by various Makefiles to
determine if a `small' version of the program
is required.
SMALLPROG_INET6 If 1 and SMALLPROG == 1, add SMALLPROG_INET6=1
to CRUNCHENV. [default: 0]
This can be used by various Makefiles to
determine if the `small' version has INET6
support enabled.
Only enable SMALLPROG_INET6 for programs on the ramdisks that have INET6 in
the appropriate kernel, and cleanup INET6 setting.
(Note: this means that sysinst won't get INET6 support if the kernel
it's running on doesn't have it).
This change saves a fair bit of space on various install images
(including i386 ramdisk-{ps2,small,tiny}) that didn't have INET6 in
the kernel but were unconditionally getting INET6 support in their tools.
- build (mdset/nm/strip) into ${filename} as one rule, and move ${filename}.gz
into separate rule
- rename MDSET.${filename}.nosymbols -> MDSET_NOSYMBOLS.${filename}
- rename MDSET.${filename}.post -> MDSET_POST.${filename}, and don't do
suffix handling here
- rework suffix handling:
- rename MDSET.${filename}.suffixes -> MDSET_SUFFIXES.${filename},
and change from list of suffixes to list of "suffix cmdtobuildsuffix",
where cmdtobuildsuffix is the name of the variable containing the
command to build ${filename}.${suffix} (available as "${.TARGET}").
- for each ${filename}.${suffix}, depend upon ${filename} and use
${cmdtobuildsuffix} to create the former.
- add separate ${filename}.${suffix}.gz rule
- mipsco & pmax: rename "install.gz" to "netbsd-INSTALL.gz", for
consistency and so the target to build the mdset kernel doesn't get
confused with general "install" target
- move guts of distrib/Makefile.inc to distrib/common/Makefile.distrib
(fixes problem caused by implicit include of ../Makefile.inc in certain
submake conditions triggered by makefiles not yet in tree)
- removed mkdir of ${RELEASEDIR}/*; rely upon "snap_pre" target of
etc/Makefile to create all the release directories
- renamed RELINSTALL to RELEASE_INSTALL
- renamed FLOPPYINSTDIR to FLOPPY_RELEASEDIR
- renamed MDSETDIR to MDSET_RELEASEDIR
- removed ITARGET
- move release target from top level to appropriate subdirectory
- ensure release target has correct depends
- replace miniroot's IMAGE_MD_POST with common/Makefile.image IMAGEPOSTBUILD
- Makefile.image: add realall: ${IMAGE}
otherwise, libc.a and other objects which was not compiled with -xgot
won't link. (in general, you can't mix -xgot and no -xgot binaries.)
current GOT size is 0000f618 (see below).
10 .got 0000f618 10010460 10010460 0026c460 2**4
CONTENTS, ALLOC, LOAD, DATA
symbols into locals, but relocs are left in place (rather than attempting
to resolve-in-place with "ld -r", even with "-Bsymbolic").
Standard MIPS code will generate CALL16 relocs for function calls, but
the linker forbids such relocs from being used to call local symbols (such
as those turned "local" by objcopy). So, rather than battle the toolchain
uphill, work around it for the moment by forcing 32-bit GOT references with
the assembler option "-xgot".
This will be fixed in a more clean manner in the future.
replace
TARGETS = KERNEL IMAGE [...]
with
MDTARGETS = KERNEL IMAGE FILENAME [...]
If FILENAME is "-", use "netbsd.${KERNEL}" as the target filename
The rest:
Update for new MDTARGETS syntax. In some cases, the kernel
name from the "old" method will be used to override the default.
dependent files:
- Use infrastructure from distrib/common to build file system images with
crunchgen-ed programs from a list file.
- Non root ("UNPRIVED") builds from a read-only source tree are possible,
as makefs(8) replaces vnconfig(8)/vnd use, devices are generated using
common/makedev2spec.awk, etc.
- Cross builds should be possible, except that some ports need cross-compile
host tool versions of installboot and any appropriate host disk labelling
tools.
XXX: pmax, sparc and vax need fixing for this!
- This code has NOT YET BEEN TESTED on most of the ports.
It should work, but it is extremely likely that the file system
parameters may need tweaking to get things to fit.
See MAKEFS_FLAGS in sparc/miniroot/Makefile.inc for an example.
If assistance is required, please ask!
files have copyright held by people in addition to myself. (I did the
original work, they copied it, enhanced it, and added their copyright
to the derivative work.) Their approval has been given re: the license
change.