1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-04 01:48:54 +00:00
freebsd-ports/Mk/Uses/fmake.mk
Baptiste Daroussin 4698330b90 Add a new USES: fmake
This uses will allow to build ports using the legacy FreeBSD make, for ports
not compatible with bmake
2013-06-20 09:48:08 +00:00

40 lines
1003 B
Makefile

# $FreeBSD$
#
# Provide support to use the legacy FreeBSD make
#
# MAINTAINER: portmgr@FreeBSD.org
#
# Feature: fmake
# Usage: USES=fmake
#
.if !defined(_INCLUDE_USES_FMAKE_MK)
_INCLUDE_USES_FMAKE_MK= yes
.if defined(fmake_ARGS)
IGNORE= Incorrect 'USES+= fmake:${fmake_ARGS}' fmake takes no arguments
.endif
.if defined(.PARSEDIR)
FMAKE= ${LOCALBASE}/bin/fmake
BUILD_DEPENDS+= ${FMAKE}:${PORTSDIR}/devel/fmake
CONFIGURE_ENV+= MAKE=${FMAKE}
.if !target(do-build)
do-build:
@set -e ; (cd ${BUILD_WRKSRC}; if ! ${SETENV} ${MAKE_ENV} ${FMAKE} ${MAKE_FLAGS} ${MAKEFILE} ${_MAKE_JOBS} ${MAKE_ARGS} ${ALL_TARGET}; then \
if [ -n "${BUILD_FAIL_MESSAGE}" ] ; then \
${ECHO_MSG} "===> Compilation failed unexpectedly."; \
(${ECHO_CMD} ${BUILD_FAIL_MESSAGE}) | ${FMT} 75 79 ; \
fi; \
${FALSE}; \
fi)
.endif
.if !target(do-install)
do-install:
@set -e ; (cd ${INSTALL_WRKSRC} && ${SETENV} ${MAKE_ENV} ${FMAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} ${INSTALL_TARGET})
.endif
.endif
.endif