Wrong BUILD_DEPENDS behaviour
Alex Dupre
sysadmin at alexdupre.com
Sun May 25 04:12:33 PDT 2003
The bsd.port.mk file says:
# BUILD_DEPENDS - A list of "path:dir[:target]" tuples of other ports this
# package depends to build (between the "extract" and
# "build" stages, inclusive).
For me this means extract, patch, configure and build stages.
But later in the makefile we find:
_EXTRACT_SEQ= extract-message checksum extract-depends pre-extract \
pre-extract-script do-extract \
post-extract post-extract-script
[no build-depends]
_PATCH_SEQ= patch-message patch-depends pre-patch pre-patch-script \
do-patch post-patch post-patch-script
[no build-depends]
_CONFIGURE_SEQ= build-depends lib-depends misc-depends configure-message \
patch-libtool pre-configure pre-configure-script \
do-configure post-configure post-configure-script
[build-depends appears in configure stage]
_BUILD_SEQ= build-message pre-build pre-build-script do-build \
post-build post-build-script
[no build-depends]
There is clearly something wrong IMHO...and this issue is exploited for
example with the USE_REINPLACE knob.
if defined(USE_REINPLACE)
REINPLACE_ARGS?= -i.bak
.if ${OSVERSION} < 460101 || ( ${OSVERSION} >= 500000 && ${OSVERSION} < 500036 )
BUILD_DEPENDS+= ${LOCALBASE}/bin/sed_inplace:${PORTSDIR}/textproc/sed_inplace
REINPLACE_CMD?= ${LOCALBASE}/bin/sed_inplace ${REINPLACE_ARGS}
.else
REINPLACE_CMD?= ${SED} ${REINPLACE_ARGS}
.endif
.endif
Consider a fresh FreeBSD installation that requires the sed_inplace port
and a port who define USE_REINPLACE to sed something in the post-patch
stage. The sed_inplace port will not be installed before the configure
stage and the build will fail in patch stage.
--
Alex Dupre sysadmin at alexdupre.com
http://www.alexdupre.com/ alex at sm.FreeBSD.org
Today's excuse: Standing room only on the bus.
More information about the freebsd-ports
mailing list