FreeBSD Bugzilla – Attachment 153787 Details for
Bug 198279
[bsd.lib.mk] Patch to stop world killing jails via failing install -fschg libc.so.7
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
bsd.lib.mk.chflags.REL=ALL.diff to stop make world killing jails
bsd.lib.mk.chflags.REL=ALL.diff (text/plain), 2.59 KB, created by
jhs
on 2015-03-04 15:59:01 UTC
(
hide
)
Description:
bsd.lib.mk.chflags.REL=ALL.diff to stop make world killing jails
Filename:
MIME Type:
Creator:
jhs
Created:
2015-03-04 15:59:01 UTC
Size:
2.59 KB
patch
obsolete
>http://berklix.com/~jhs/src/bsd/fixes/freebsd/src/gen/share/mk/bsd.lib.mk.chflags.REL=ALL.diff > >Jails are lethaly killed by make world, unless /etc/make.conf contains this: > NO_FSCHG="yes" > # Avoid bsd.lib.mk 'INSTALLFLAGS+= -fschg' killing FreeBSD jails, > # deleting /lib/libc.so.7 via 'cd /usr/src/lib/csu/amd64 ; make install' > >Killing: > uname -a > FreeBSD land.berklix.org 10.1-RELEASE-p6 FreeBSD 10.1-RELEASE-p6 #0: Tue Feb 24 19:00:21 UTC 2015 root@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64 > > cd /usr/src; make install > ===> lib/libc (install) > install -s -o root -g wheel -m 444 -fschg -S libc.so.7 /lib > install: /lib/libc.so.7: chflags: Operation not permitted > *** Error code 71 > >Recovery: > /rescue/cp /usr/obj/usr/src/lib/libc/libc.so.7 /lib/ > >man install falsely claims: -S Safe copy, But is broken by -fschg ! > >Solutions: >- Disable chflags in bsd.lib.mk & bsd.lib.mk. Patches appended. >- Or Extend bsd.lib.mk & bsd.lib.mk to be conditional on jail detection. (**) >- Or Fix install to not break with chflags (**) >(**) Last 2 should be done by those who want to keep Chflags in FreeBSD, > not me, I've used Unix since 1978, but find chflags a Wart best removed. > >I discovered this on 8.2-RELEASE 18 Jun 2013, & just got bitten again on >10.1-RELEASE-p6, (as my jail's make.conf lost its NO_FSCHG="yes"). > >*** 10.1-RELEASE-p6/src/share/mk/bsd.lib.mk Wed Mar 4 14:27:16 2015 >--- new-generic/src/share/mk/bsd.lib.mk Wed Mar 4 14:33:48 2015 >*************** >*** 284,291 **** > > .if defined(PRECIOUSLIB) > .if !defined(NO_FSCHG) >! SHLINSTALLFLAGS+= -fschg > .endif > SHLINSTALLFLAGS+= -S > .endif >--- 284,290 ---- > > .if defined(PRECIOUSLIB) > .if !defined(NO_FSCHG) >! # SHLINSTALLFLAGS+= -fschg >! # Explanation: http://berklix.com/~jhs/src/bsd/fixes/freebsd/src/gen/share/mk/bsd.lib.mk.chflags.REL=ALL.diff > .endif > SHLINSTALLFLAGS+= -S > .endif >*************** >*** 356,362 **** > ${INSTALL_SYMLINK} ${_SHLIBDIRPREFIX}${_SHLIBDIR}/${SHLIB_NAME} \ > ${DESTDIR}${_LIBDIR}/${SHLIB_LINK} > .if exists(${DESTDIR}${_LIBDIR}/${SHLIB_NAME}) >! -chflags noschg ${DESTDIR}${_LIBDIR}/${SHLIB_NAME} > rm -f ${DESTDIR}${_LIBDIR}/${SHLIB_NAME} > .endif > .endif >--- 356,364 ---- > ${INSTALL_SYMLINK} ${_SHLIBDIRPREFIX}${_SHLIBDIR}/${SHLIB_NAME} \ > ${DESTDIR}${_LIBDIR}/${SHLIB_LINK} > .if exists(${DESTDIR}${_LIBDIR}/${SHLIB_NAME}) >! # -chflags noschg ${DESTDIR}${_LIBDIR}/${SHLIB_NAME} >! # Chflags wont actually kill the system here, but chflags is dirty. >! @echo "Skipping -chflags noschg ${DESTDIR}${_LIBDIR}/${SHLIB_NAME}" > rm -f ${DESTDIR}${_LIBDIR}/${SHLIB_NAME} > .endif > .endif
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 198279
: 153787