diff options
| author | tsutsui <tsutsui@NetBSD.org> | 2014-11-24 08:08:23 +0000 |
|---|---|---|
| committer | tsutsui <tsutsui@NetBSD.org> | 2014-11-24 08:08:23 +0000 |
| commit | d4d60b3e17b8dc707bcdcce99a6bd851cfbf4c78 (patch) | |
| tree | b2b3a4e5f180f7a60bb4841603e5977f7b4765ef /sys/arch/atari | |
| parent | bd718c5b7d724fd57dcafa686c87f2b346745271 (diff) | |
Disable "OS bootversion check" on crunched binaries for installation media.
This oscheck() function seems implemented to check compatibility
between bootloaders and /netbsd kernel, but checking /netbsd using kvm(3)
doesn't make sense on installation or even future cross builds, and
probably we will never bump bootloader version without compatibility
per recent 14 years history.
This works around overflow of 1440KB 2HD sysinst.fs, and would also be
worth to pullup to netbsd-7.
Diffstat (limited to 'sys/arch/atari')
| -rw-r--r-- | sys/arch/atari/stand/installboot/Makefile | 5 | ||||
| -rw-r--r-- | sys/arch/atari/stand/installboot/installboot.c | 8 |
2 files changed, 11 insertions, 2 deletions
diff --git a/sys/arch/atari/stand/installboot/Makefile b/sys/arch/atari/stand/installboot/Makefile index b73f58445c3..ac678f6a441 100644 --- a/sys/arch/atari/stand/installboot/Makefile +++ b/sys/arch/atari/stand/installboot/Makefile @@ -1,11 +1,14 @@ -# $NetBSD: Makefile,v 1.7 2014/11/24 07:52:04 tsutsui Exp $ +# $NetBSD: Makefile,v 1.8 2014/11/24 08:08:23 tsutsui Exp $ WARNS= 4 PROG= installboot NOMAN= # defined SRCS= installboot.c disklabel.c BINDIR= /usr/mdec +.ifndef SMALLPROG +CPPFLAGS+= -DCHECK_OS_BOOTVERSION LDADD= -lkvm +.endif # XXX needs proper struct or union to calculate boot sector uint16_t cksums CFLAGS+= -fno-strict-aliasing diff --git a/sys/arch/atari/stand/installboot/installboot.c b/sys/arch/atari/stand/installboot/installboot.c index b5f6b5f92b6..cce3dfb26ea 100644 --- a/sys/arch/atari/stand/installboot/installboot.c +++ b/sys/arch/atari/stand/installboot/installboot.c @@ -1,4 +1,4 @@ -/* $NetBSD: installboot.c,v 1.33 2014/11/24 07:34:45 tsutsui Exp $ */ +/* $NetBSD: installboot.c,v 1.34 2014/11/24 08:08:23 tsutsui Exp $ */ /* * Copyright (c) 1995 Waldi Ravens @@ -54,7 +54,9 @@ #include "installboot.h" static void usage(void); +#ifdef CHECK_OS_BOOTVERSION static void oscheck(void); +#endif static u_int abcksum(void *); static void setNVpref(void); static void setIDEpar(u_int8_t *, size_t); @@ -99,8 +101,10 @@ main(int argc, char *argv[]) char *devchr; int fd, c; +#ifdef CHECK_OS_BOOTVERSION /* check OS bootversion */ oscheck(); +#endif /* parse options */ while ((c = getopt(argc, argv, "Nmt:u:v")) != -1) { @@ -177,6 +181,7 @@ main(int argc, char *argv[]) return(EXIT_SUCCESS); } +#ifdef CHECK_OS_BOOTVERSION static void oscheck(void) { @@ -208,6 +213,7 @@ oscheck(void) errx(EXIT_FAILURE, "Kern bootversion: %d, expected: %d", kvers, BOOTVERSION); } +#endif static void install_fd(char *devnm, struct disklabel *label) |
