Bug 226618

Summary: [PATCH]: devel/subversion Add freebsd flavor with FREEBSD_TEMPLATE enabled
Product: Ports & Packages Reporter: Craig Leres <leres>
Component: Individual Port(s)Assignee: Lev A. Serebryakov <lev>
Status: New ---    
Severity: Affects Only Me Flags: bugzilla: maintainer-feedback? (lev)
Priority: ---    
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
patch
none
poudriere build log (with default options)
none
poudriere build log (freebsd flavor)
none
revised patch
none
revised patch leres: maintainer-approval?

Description Craig Leres freebsd_committer 2018-03-14 22:04:32 UTC
In my environment I was building two subversion packages with and without the FREEBSD_TEMPLATE option. This allowed me to install the FREEBSD_TEMPLATE version on the system I do FreeBSD work on and the version without on the other systems and avoid confusing my end users with the various FreeBSD specific fields. I did this by creating a local slave port:

    # @(#) $Id: Makefile 4 2017-09-10 17:41:11Z leres $ (LBL)

    PKGNAMESUFFIX=              -freebsd

    CONFLICTS_INSTALL=  ${PORTNAME}-[0-9]*

    OPTIONS_SLAVE=              FREEBSD_TEMPLATE

    MASTERDIR=          /usr/ports/devel/subversion

    .include "${MASTERDIR}/Makefile"

This worked great until yesterday when something changed:

    [00:00:03] Error: MOVED: devel/subversion-freebsd 2011-10-16 Merged with devel/subversion

The attached patch adds a freebsd FLAVOR to the subversion port. I'm not sure if using OPTIONS_SLAVE is 100% correct but I couldn't quite figure out how OPTIONS_SLAVE works. Setting OPTIONS_EXCLUDE to FREEBSD_TEMPLATE worked as expected but setting OPTIONS_SET_FORCE did not.

Assuming we can converge on a reasonable version I'm happy to commit this with maintainer approval.
Comment 1 Craig Leres freebsd_committer 2018-03-14 22:05:04 UTC
Created attachment 191506 [details]
patch
Comment 2 Craig Leres freebsd_committer 2018-03-14 22:10:51 UTC
Created attachment 191507 [details]
poudriere build log (with default options)
Comment 3 Craig Leres freebsd_committer 2018-03-14 22:11:54 UTC
Created attachment 191508 [details]
poudriere build log (freebsd flavor)
Comment 4 Craig Leres freebsd_committer 2018-03-20 23:12:33 UTC
Created attachment 191676 [details]
revised patch

freebsd_OPTIONS_SLAVE doesn't actually do anything...
Comment 5 Lev A. Serebryakov freebsd_committer 2018-04-20 15:54:41 UTC
Default build contains FREEBSD_TEMPLATE. Should it be disabled by default?
Comment 6 Craig Leres freebsd_committer 2018-04-20 17:46:43 UTC
Created attachment 192686 [details]
revised patch

Of course you're right; I didn't notice because I have FREEBSD_TEMPLATE disabled... Here's an updated patch.
Comment 7 Mathieu Arnold freebsd_committer 2018-10-10 22:23:01 UTC
Mmmmm, I would rather it be reversed, the default "subversion" package stays as it is with FREEBSD_TEMPLATE, and another flavor with another package name is without it.
Comment 8 Mathieu Arnold freebsd_committer 2018-10-10 22:23:54 UTC
I'm saying this because many ports depend on subversion, and pkg's dependencies are not clever enough to see that the different flavors both provide subversion with slightly different features.