Page MenuHomeFreeBSD

bsd.{files,conf}.mk: remove some complicated logic
Needs ReviewPublic

Authored by kevans on Apr 3 2020, 1:16 AM.
Tags
None
Referenced Files
Unknown Object (File)
Dec 20 2023, 8:25 AM
Unknown Object (File)
Dec 8 2023, 5:17 AM
Unknown Object (File)
Oct 18 2023, 1:20 AM
Unknown Object (File)
Jul 29 2023, 4:14 AM
Unknown Object (File)
Jul 2 2023, 3:43 PM
Unknown Object (File)
Apr 8 2023, 12:43 AM
Unknown Object (File)
Mar 22 2023, 7:31 AM
Subscribers

Details

Reviewers
sjg
bdrewery
brd
Summary

The current version is kind of funky, and I can't quite decipher what the intention is. A block shortly above sets up _${group}DIR_${file} to where we should be installing this specific file to, defaulting to ${group}DIR and expanding as needed.

This block ends up clobbering where we should be installing files to, in cases like this (contrived, similar to real use):

FILES+=	foo bar
FILESDIR_foo=	/tmp
FILESDIR_bar=	/tmp

.include <bsd.prog.mk>

An execution of this reveals that it figures out that foo is supposed to be in /tmp. but it screws up bar and this logic decides that it's supposed to go in FILESDIR instead of the clearly specified /tmp.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 30254

Event Timeline

These files became far more complicated recently I think perhaps as a consequence of moving etc/ files all over the place, and then needing to make them install to the right place.
Since that need is? going away, perhaps the complexity can too.

In D24270#534256, @sjg wrote:

These files became far more complicated recently I think perhaps as a consequence of moving etc/ files all over the place, and then needing to make them install to the right place.
Since that need is? going away, perhaps the complexity can too.

I think the complexity is going to have to stay, but it'd perhaps be a good idea to make a pass through and see if we can streamline it/comment it any more. This in particular addresses the need to install multiple groups of CONFS or FILES into different directories, which is likely going to be necessary no matter how the restoration of etc/ project goes.