Changeset View
Changeset View
Standalone View
Standalone View
sysutils/uefi-edk2-bhyve-csm/Makefile
# $FreeBSD$ | # $FreeBSD$ | ||||
PKGNAMESUFFIX= -csm | PORTNAME= uefi-edk2-bhyve-csm | ||||
DISTVERSIONPREFIX= v | |||||
DISTVERSION= 0.2 | |||||
PORTREVISION= 2 | |||||
PORTEPOCH= 1 | |||||
CATEGORIES= sysutils | |||||
COMMENT= UEFI-EDK2 firmware for bhyve with CSM | MAINTAINER= bcran@FreeBSD.org | ||||
COMMENT= UEFI EDK2 firmware for bhyve with CSM (16-bit BIOS) | |||||
woodsb02: The ? is not required if there is no master/slave ports relationship | |||||
MASTERDIR= ${.CURDIR}/../uefi-edk2-bhyve | LICENSE= BSD2CLAUSE | ||||
WITH_CSM= yes | ONLY_FOR_ARCHS= amd64 | ||||
.include "${MASTERDIR}/Makefile" | BUILD_DEPENDS= bash:shells/bash \ | ||||
nasm:devel/nasm \ | |||||
${PYTHON_LIBDIR}/lib-dynload/_sqlite3.so:databases/py-sqlite3@${PY_FLAVOR} | |||||
USES= gmake \ | |||||
python:2.7,build | |||||
USE_GCC= 4.8 | |||||
USE_GITHUB= yes | |||||
GH_ACCOUNT= freebsd | |||||
GH_PROJECT= uefi-edk2 | |||||
GH_TAGNAME= aa8d718 | |||||
PLIST_FILES= ${PREFIX}/share/uefi-firmware/BHYVE_UEFI_CSM.fd | |||||
OPTIONS_DEFINE= DEBUG | |||||
DEBUG_VARS= uefi_target=DEBUG | |||||
DEBUG_VARS_OFF= uefi_target=RELEASE | |||||
MAKE_ARGS+= AS=${LOCALBASE}/bin/as \ | |||||
AR=${LOCALBASE}/bin/ar \ | |||||
LD=${LOCALBASE}/bin/ld \ | |||||
OBJCOPY=${LOCALBASE}/bin/objcopy \ | |||||
CC=${LOCALBASE}/bin/gcc48 \ | |||||
CXX=${LOCALBASE}/bin/g++48 | |||||
BUILD_ARGS=-DDEBUG_ON_SERIAL_PORT=TRUE -D FD_SIZE_2MB -DCSM_ENABLE=TRUE | |||||
post-extract: | |||||
Done Inline ActionsThis is no loner required, since the only things requiring it were the if defined(WITH_CSM) statements, which are now removed. woodsb02: This is no loner required, since the only things requiring it were the if defined(WITH_CSM)… | |||||
@${REINPLACE_CMD} -e 's|python|${PYTHON_CMD}|' ${WRKSRC}/BaseTools/Tests/GNUmakefile \ | |||||
${WRKSRC}/BaseTools/BinWrappers/PosixLike/* | |||||
Done Inline ActionsGiven this is no longer wrapped in an if statement, this can just be moved to the BUILD_ARGS list 2 lines above. woodsb02: Given this is no longer wrapped in an if statement, this can just be moved to the BUILD_ARGS… | |||||
do-build: | |||||
unset ARCH; unset MAKEFLAGS; ${MAKE_CMD} ${MAKE_ARGS} -C ${BUILD_WRKSRC}/BaseTools | |||||
${MKDIR} ${BUILD_WRKSRC}/Build; | |||||
${LN} -sf ${LOCALBASE}/bin/gcc48 ${BUILD_WRKSRC}/Build/gcc | |||||
${LN} -sf ${LOCALBASE}/bin/ld ${BUILD_WRKSRC}/Build/ld | |||||
${LN} -sf ${LOCALBASE}/bin/gmake ${BUILD_WRKSRC}/Build/make | |||||
${LN} -sf ${LOCALBASE}/bin/ar ${BUILD_WRKSRC}/Build/ar | |||||
${LN} -sf ${LOCALBASE}/bin/objcopy ${BUILD_WRKSRC}/Build/objcopy | |||||
${LN} -sf ${LOCALBASE}/bin/nasm ${BUILD_WRKSRC}/Build/nasm | |||||
bash -c " \ | |||||
cd ${BUILD_WRKSRC}; \ | |||||
source edksetup.sh;\ | |||||
unset ARCH; unset MAKEFLAGS; \ | |||||
${MAKE_CMD} ${MAKE_ARGS} GCC48_BIN=${BUILD_WRKSRC}/Build/ -C ${BUILD_WRKSRC}/BhyvePkg/Csm/BhyveCsm16/" | |||||
woodsb02Unsubmitted Not Done Inline ActionsThe second indent here should be using a tab rather than spaces woodsb02: The second indent here should be using a tab rather than spaces | |||||
bash -c " \ | |||||
cd ${BUILD_WRKSRC}; \ | |||||
source edksetup.sh;\ | |||||
unset ARCH; unset MAKEFLAGS; \ | |||||
export GCC48_BIN=${BUILD_WRKSRC}/Build/; \ | |||||
build -t GCC48 -a X64 -b ${UEFI_TARGET} -p BhyvePkg/BhyvePkgX64.dsc ${BUILD_ARGS} \ | |||||
" | |||||
do-install: | |||||
${MKDIR} ${STAGEDIR}${PREFIX}/share/uefi-firmware/ | |||||
${INSTALL} ${BUILD_WRKSRC}/Build/BhyveX64/${UEFI_TARGET}_GCC48/FV/BHYVE.fd \ | |||||
${STAGEDIR}${PREFIX}/share/uefi-firmware/BHYVE_UEFI_CSM.fd | |||||
.include <bsd.port.mk> |
The ? is not required if there is no master/slave ports relationship