diff --git a/lib/libc/amd64/sys/amd64_get_fsbase.c b/lib/libc/amd64/sys/amd64_get_fsbase.c --- a/lib/libc/amd64/sys/amd64_get_fsbase.c +++ b/lib/libc/amd64/sys/amd64_get_fsbase.c @@ -33,9 +33,8 @@ #include __FBSDID("$FreeBSD$"); -#define IN_RTLD 1 +#define _WANT_P_OSREL #include -#undef IN_RTLD #include #include #include diff --git a/lib/libc/amd64/sys/amd64_get_gsbase.c b/lib/libc/amd64/sys/amd64_get_gsbase.c --- a/lib/libc/amd64/sys/amd64_get_gsbase.c +++ b/lib/libc/amd64/sys/amd64_get_gsbase.c @@ -33,9 +33,8 @@ #include __FBSDID("$FreeBSD$"); -#define IN_RTLD 1 +#define _WANT_P_OSREL #include -#undef IN_RTLD #include #include #include diff --git a/lib/libc/amd64/sys/amd64_set_fsbase.c b/lib/libc/amd64/sys/amd64_set_fsbase.c --- a/lib/libc/amd64/sys/amd64_set_fsbase.c +++ b/lib/libc/amd64/sys/amd64_set_fsbase.c @@ -33,9 +33,8 @@ #include __FBSDID("$FreeBSD$"); -#define IN_RTLD 1 +#define _WANT_P_OSREL #include -#undef IN_RTLD #include #include #include diff --git a/lib/libc/amd64/sys/amd64_set_gsbase.c b/lib/libc/amd64/sys/amd64_set_gsbase.c --- a/lib/libc/amd64/sys/amd64_set_gsbase.c +++ b/lib/libc/amd64/sys/amd64_set_gsbase.c @@ -33,9 +33,8 @@ #include __FBSDID("$FreeBSD$"); -#define IN_RTLD 1 +#define _WANT_P_OSREL #include -#undef IN_RTLD #include #include #include diff --git a/libexec/rtld-elf/amd64/reloc.c b/libexec/rtld-elf/amd64/reloc.c --- a/libexec/rtld-elf/amd64/reloc.c +++ b/libexec/rtld-elf/amd64/reloc.c @@ -33,6 +33,7 @@ * John Polstra . */ +#define _WANT_P_OSREL #include #include #include diff --git a/libexec/rtld-elf/map_object.c b/libexec/rtld-elf/map_object.c --- a/libexec/rtld-elf/map_object.c +++ b/libexec/rtld-elf/map_object.c @@ -27,6 +27,7 @@ * $FreeBSD$ */ +#define _WANT_P_OSREL #include #include #include diff --git a/sbin/fsck_ffs/main.c b/sbin/fsck_ffs/main.c --- a/sbin/fsck_ffs/main.c +++ b/sbin/fsck_ffs/main.c @@ -43,7 +43,7 @@ #include __FBSDID("$FreeBSD$"); -#define IN_RTLD /* So we pickup the P_OSREL defines */ +#define _WANT_P_OSREL #include #include #include diff --git a/sbin/newfs/mkfs.c b/sbin/newfs/mkfs.c --- a/sbin/newfs/mkfs.c +++ b/sbin/newfs/mkfs.c @@ -46,7 +46,7 @@ #include __FBSDID("$FreeBSD$"); -#define IN_RTLD /* So we pickup the P_OSREL defines */ +#define _WANT_P_OSREL #include #include #include diff --git a/sys/sys/param.h b/sys/sys/param.h --- a/sys/sys/param.h +++ b/sys/sys/param.h @@ -94,7 +94,7 @@ #undef __FreeBSD_kernel__ #define __FreeBSD_kernel__ -#if defined(_KERNEL) || defined(IN_RTLD) +#if defined(_KERNEL) || defined(_WANT_P_OSREL) #define P_OSREL_SIGWAIT 700000 #define P_OSREL_SIGSEGV 700004 #define P_OSREL_MAP_ANON 800104