From e1157dcec4087620c1bb915ddbc244a2349d013b Mon Sep 17 00:00:00 2001 From: Ed Maste Date: Mon, 25 Feb 2019 18:22:20 +0000 Subject: [PATCH] Make libifconfig INTERNALLIB Instead of PRIVATELIB + NO_PIC. This avoids the need for the wlandebug PIE special case added in r344211, and provides a stronger guarantee against 3rd party software coming to depend on the API or ABI. If / when we declare the API/ABI to be stable we can make it a normal library. Discussed with: bapt Sponsored by: The FreeBSD Foundation --- ObsoleteFiles.inc | 3 +++ lib/libifconfig/Makefile | 4 +--- share/mk/bsd.libnames.mk | 1 - share/mk/src.libnames.mk | 5 ++++- sys/sys/capability.h | 6 +++--- 5 files changed, 11 insertions(+), 8 deletions(-) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index 1cdb447200a3..39eba5af6d4c 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -38,6 +38,9 @@ # xargs -n1 | sort | uniq -d; # done +# 20190222: libifconfig made INTERNALLIB +OLD_FILES+=/usr/lib/libprivateifconfig.a +OLD_FILES+=/usr/lib/libprivateifconfig_p.a # 20190131: pfil(9) changed OLD_FILES+=usr/share/man/man9/pfil_hook_get.9 OLD_FILES+=usr/share/man/man9/pfil_rlock.9 diff --git a/lib/libifconfig/Makefile b/lib/libifconfig/Makefile index 94bd3ac5eb86..9ec235a076c4 100644 --- a/lib/libifconfig/Makefile +++ b/lib/libifconfig/Makefile @@ -2,9 +2,7 @@ PACKAGE= lib${LIB} LIB= ifconfig -PRIVATELIB= true -# Don't build shared library, for now. -NO_PIC= +INTERNALLIB= true SHLIBDIR?= /lib SHLIB_MAJOR= 1 diff --git a/share/mk/bsd.libnames.mk b/share/mk/bsd.libnames.mk index bb6861ba74fc..b2675fce7cf3 100644 --- a/share/mk/bsd.libnames.mk +++ b/share/mk/bsd.libnames.mk @@ -80,7 +80,6 @@ LIBIBMAD?= ${LIBDESTDIR}${LIBDIR_BASE}/libibmad.a LIBIBNETDISC?= ${LIBDESTDIR}${LIBDIR_BASE}/libibnetdisc.a LIBIBUMAD?= ${LIBDESTDIR}${LIBDIR_BASE}/libibumad.a LIBIBVERBS?= ${LIBDESTDIR}${LIBDIR_BASE}/libibverbs.a -LIBIFCONFIG?= ${LIBDESTDIR}${LIBDIR_BASE}/libifconfig.a LIBIPSEC?= ${LIBDESTDIR}${LIBDIR_BASE}/libipsec.a LIBIPT?= ${LIBDESTDIR}${LIBDIR_BASE}/libipt.a LIBJAIL?= ${LIBDESTDIR}${LIBDIR_BASE}/libjail.a diff --git a/share/mk/src.libnames.mk b/share/mk/src.libnames.mk index daf420fb377a..99ae9f7114e2 100644 --- a/share/mk/src.libnames.mk +++ b/share/mk/src.libnames.mk @@ -20,7 +20,6 @@ _PRIVATELIBS= \ event \ heimipcc \ heimipcs \ - ifconfig \ ldns \ sqlite3 \ ssh \ @@ -35,6 +34,7 @@ _INTERNALLIBS= \ cron \ elftc \ fifolog \ + ifconfig \ ipf \ lpr \ netbsd \ @@ -450,6 +450,9 @@ LIBVERS?= ${LIBVERSDIR}/libvers${PIE_SUFFIX}.a LIBSLDIR= ${OBJTOP}/kerberos5/lib/libsl LIBSL?= ${LIBSLDIR}/libsl${PIE_SUFFIX}.a +LIBIFCONFIGDIR= ${OBJTOP}/lib/libifconfig +LIBIFCONFIG?= ${LIBIFCONFIGDIR}/libifconfig${PIE_SUFFIX}.a + LIBIPFDIR= ${OBJTOP}/sbin/ipf/libipf LIBIPF?= ${LIBIPFDIR}/libipf${PIE_SUFFIX}.a diff --git a/sys/sys/capability.h b/sys/sys/capability.h index 39195e034c56..6c3bae746dbb 100644 --- a/sys/sys/capability.h +++ b/sys/sys/capability.h @@ -35,13 +35,13 @@ * Historically, the key userspace and kernel Capsicum definitions were found * in this file. However, it conflicted with POSIX.1e's capability.h, so has * been renamed capsicum.h. The file remains for backwards compatibility - * reasons as a nested include. It is expected to be removed before - * FreeBSD 13. + * reasons as a nested include. It will be removed on March 31, 2019 and will + * not be in FreeBSD 13. */ #ifndef _SYS_CAPABILITY_H_ #define _SYS_CAPABILITY_H_ -#warning this file includes which is deprecated +#warning this file includes , to be removed on March 31, 2019. #include #endif /* !_SYS_CAPABILITY_H_ */