ports/58853: bsd.port.mk - MASTER_SITE_SUBDIR grouping disentangling is broken

Edwin Groothuis edwin at mavetju.org
Mon Nov 3 02:40:14 UTC 2003


>Number:         58853
>Category:       ports
>Synopsis:       bsd.port.mk - MASTER_SITE_SUBDIR grouping disentangling is broken
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Nov 02 18:40:12 PST 2003
>Closed-Date:
>Last-Modified:
>Originator:     Edwin Groothuis
>Release:        FreeBSD 4.8-RELEASE i386
>Organization:
-
>Environment:
System: FreeBSD k7.mavetju 4.8-RELEASE FreeBSD 4.8-RELEASE #0: Sun Aug 17 16:04:25 EST 2003 edwin at k7.mavetju:/usr/src/sys/compile/k7 i386

>Description:

See the makefile of net/pppoa:
    MASTER_SITES=           http://download.ethomson.com/download/ \
			    ${MASTER_SITE_SOURCEFORGE}
    MASTER_SITE_SUBDIR=     speedtouch
    DISTFILES=              ${SPEEDTOUCH}.tar.bz2 ${ALCATELDRIVER}

The output of "make all-fetchlist" is (amongst others)
    http://us.dl.sourceforge.net/speedtouch/speedtouch-1.2-beta2.tar.bz2

To disentangle the two distfiles and the two master_sites, use this:
    MASTER_SITES=           http://download.ethomson.com/download/:mngt \
			    ${MASTER_SITE_SOURCEFORGE:S/$/:src/}
    MASTER_SITE_SUBDIR=     speedtouch:src
    DISTFILES=              ${SPEEDTOUCH}.tar.bz2:src ${ALCATELDRIVER}:mngt

The output of "make all-fetchlist" is (amongst others)
    http://us.dl.sourceforge.net/speedtouch-1.2-beta2.tar.bz2

Note the lack of /speedtouch/ in the URL.

According to bsd.port.mk, version 1.468, around line 1917:
    .for _S in ${MASTER_SITE_SUBDIR}
    _S_TEMP=    ${_S:S/^${_S:C@/:[^/:]+$@/@}//:S/^://}
    .   if !empty(_S_TEMP)

The value of _S_TEMP is properly filled after the call. But the
call to empty() treats it as an empty variable.

>How-To-Repeat:

See example in description.

>Fix:

Try a different kind of voodoo? (that's a joke)
>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list