diff --git a/sys/boot/common/bootstrap.h b/sys/boot/common/bootstrap.h index 7f011c736238..4c92ba860ad9 100644 --- a/sys/boot/common/bootstrap.h +++ b/sys/boot/common/bootstrap.h @@ -327,4 +327,10 @@ void dev_cleanup(void); time_t time(time_t *tloc); +#ifndef CTASSERT /* Allow lint to override */ +#define CTASSERT(x) _CTASSERT(x, __LINE__) +#define _CTASSERT(x, y) __CTASSERT(x, y) +#define __CTASSERT(x, y) typedef char __assert ## y[(x) ? 1 : -1] +#endif + #endif /* !_BOOTSTRAP_H_ */ diff --git a/sys/boot/i386/efi/reloc.c b/sys/boot/i386/efi/reloc.c index 24eed0aaab4b..96f9241a6e49 100644 --- a/sys/boot/i386/efi/reloc.c +++ b/sys/boot/i386/efi/reloc.c @@ -30,16 +30,7 @@ __FBSDID("$FreeBSD$"); #include #include #include - -/* - * XXX: we can't include sys/systm.h. - */ -#ifndef CTASSERT /* Allow lint to override */ -#define CTASSERT(x) _CTASSERT(x, __LINE__) -#define _CTASSERT(x, y) __CTASSERT(x, y) -#define __CTASSERT(x, y) typedef char __assert ## y[(x) ? 1 : -1] -#endif - +#include /* * A simple relocator for IA32 EFI binaries. diff --git a/sys/boot/sparc64/loader/main.c b/sys/boot/sparc64/loader/main.c index dbbf08dc1466..cb0dda2f490b 100644 --- a/sys/boot/sparc64/loader/main.c +++ b/sys/boot/sparc64/loader/main.c @@ -74,12 +74,6 @@ __FBSDID("$FreeBSD$"); #include "libofw.h" #include "dev_net.h" -#ifndef CTASSERT -#define CTASSERT(x) _CTASSERT(x, __LINE__) -#define _CTASSERT(x, y) __CTASSERT(x, y) -#define __CTASSERT(x, y) typedef char __assert ## y[(x) ? 1 : -1] -#endif - extern char bootprog_name[], bootprog_rev[], bootprog_date[], bootprog_maker[]; enum {