Page MenuHomeFreeBSD

Eliminate duplicate `afterinstallconfigs` target
AcceptedPublic

Authored by ngie on May 21 2019, 4:52 AM.

Details

Reviewers
brd
bapt
Summary

Define separate dependent targets which afterinstallconfigs relies on, in
order to modify ${DESTDIR}/etc/master.passwd and
${DESTDIR}/etc/nsswitch.conf.

Mark these targets .PHONY, since they manipulate configurations on the fly and
the generation logic isn't 100% defined in terms of the source files/logic,
and is variable, based on MK_foo flags.

Test Plan

Before:

$ (cd lib/libc; make buildenv)
[Creating objdir /usr/obj/home/ngie/svn/freebsd/base/projects/runtime-coverage-v2/amd64.amd64/lib/libc...]
make: "/home/ngie/svn/freebsd/base/projects/runtime-coverage-v2/lib/libc/net/Makefile.inc" line 130: warning: duplicate script for target "afterinstallconfig" ignored
make: "/home/ngie/svn/freebsd/base/projects/runtime-coverage-v2/lib/libc/gen/Makefile.inc" line 552: warning: using previous script for "afterinstallconfig" defined here
$

After:

$ (cd lib/libc; make buildenv)
Entering world for amd64:amd64
$

Diff Detail

Repository
rS FreeBSD src repository
Lint
Lint OK
Unit
No Unit Test Coverage
Build Status
Buildable 24347
Build 23169: arc lint + arc unit

Event Timeline

ngie created this revision.May 21 2019, 4:52 AM
ngie added a comment.Thu, Sep 19, 4:18 PM

Still an issue:

$ (cd ~/svn/freebsd/base/head/; svnversion; make -C lib/libc buildenv)
352519
make: "/home/ngie/svn/freebsd/base/head/lib/libc/net/Makefile.inc" line 130: warning: duplicate script for target "afterinstallconfig" ignored
make: "/home/ngie/svn/freebsd/base/head/lib/libc/gen/Makefile.inc" line 554: warning: using previous script for "afterinstallconfig" defined here
Entering world for amd64:amd64
ngie added a reviewer: bapt.Thu, Sep 19, 4:19 PM
brd accepted this revision.Thu, Sep 19, 6:55 PM

Thanks, sorry I missed the notification about this review before.

This revision is now accepted and ready to land.Thu, Sep 19, 6:55 PM