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)
Sat, Dec 21, 4:24 PM
Unknown Object (File)
Sat, Dec 21, 4:00 PM
Unknown Object (File)
Nov 25 2024, 8:33 AM
Unknown Object (File)
Nov 23 2024, 7:41 PM
Unknown Object (File)
Nov 23 2024, 2:26 PM
Unknown Object (File)
Nov 21 2024, 7:24 AM
Unknown Object (File)
Nov 19 2024, 11:52 PM
Unknown Object (File)
Nov 9 2024, 2:09 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
Lint Not Applicable
Unit
Tests Not Applicable

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.