Page MenuHomeFreeBSD

Add Flavor helpers for DEPRECATED and EXPIRATION_DATE
ClosedPublic

Authored by tcberner on Oct 28 2018, 7:44 PM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Mar 20, 6:35 AM
Unknown Object (File)
Dec 21 2023, 11:29 PM
Unknown Object (File)
Dec 20 2023, 6:22 AM
Unknown Object (File)
Aug 29 2023, 11:15 PM
Unknown Object (File)
Aug 29 2023, 11:12 PM
Unknown Object (File)
Aug 29 2023, 11:11 PM
Unknown Object (File)
Aug 29 2023, 11:04 PM
Unknown Object (File)
Jun 24 2023, 8:16 AM
Subscribers

Details

Summary

If a port has multiple flavors and one needs to be deprecated, one could now write

qt4_DEPRECATED=		Qt4 has been EOL since december 2015
qt4_EXPIRATION_DATE=	2019-03-15

instead of the more wordy

. if ${FLAVOR} == qt4
DEPRECATED=		Qt4 has been EOL since december 2015
EXPIRATION_DATE=	2019-03-15
. endif

@rene, this would likely require changes to your reap-scripts, as ports
could be marked deprecated as their default flavor is, but not their secondary ones.

Diff Detail

Repository
rP FreeBSD ports repository
Lint
No Lint Coverage
Unit
No Test Coverage
Build Status
Buildable 20487
Build 19918: arc lint + arc unit

Event Timeline

The wordy version in your example should be

. if ${FLAVOR} == qt4
DEPRECATED=		Qt4 has been EOL since december 2015
EXPIRATION_DATE=	2019-03-15
. endif

So without the trailing "qt4_". It looks a bit over-engineered to me, but perhaps we can save an .include somewhere.

When having Tools/scripts/rmport look for expired ports, it uses this code:

       EXPVAR=EXPIRATION_DATE
        find -H ${PORTSDIR} -mindepth 3 -maxdepth 3 -name "Makefile*" \
                |xargs grep -H  "^[^#]*${EXPVAR}"  \
(....)

So flavored expiration dates will not be found. It does evaluate EXPIRATION_DATE using make(1) when making up the commit message and adding the MOVED lines.

In D17740#379092, @rene wrote:

The wordy version in your example should be

. if ${FLAVOR} == qt4
DEPRECATED=		Qt4 has been EOL since december 2015
EXPIRATION_DATE=	2019-03-15
. endif

woops, copy & paste error, corrected.

This revision is now accepted and ready to land.Nov 10 2018, 9:59 AM
This revision was automatically updated to reflect the committed changes.