u-boot-asahi: tweak LICENSE file generation

- use head(1) instead of cat so that there's a header between the
parts from separate source license files

- assemble the LICENSE file in do-build instead of fake so this can
be used as a :build target in apple-firmware.
This commit is contained in:
sthen 2023-01-21 09:36:20 +00:00
parent d45fb08779
commit cea81fcea8
1 changed files with 4 additions and 4 deletions

View File

@ -6,7 +6,7 @@ VERSION= 2022.07-3
GH_ACCOUNT= AsahiLinux
GH_PROJECT= u-boot
GH_TAGNAME= asahi-v${VERSION}
REVISION= 2
REVISION= 3
PKGNAME= u-boot-asahi-${VERSION:S/-/./g}
@ -30,7 +30,8 @@ FILES=\
u-boot \
u-boot.bin \
u-boot-nodtb.bin \
u-boot.dtb
u-boot.dtb \
LICENSE
LICENSE_FILES= \
Licenses/*.txt \
@ -44,13 +45,12 @@ do-build:
cd ${WRKSRC} && \
${SETENV} ${MAKE_ENV} ${MAKE_PROGRAM} ${MAKE_FLAGS} \
O="build/" -f ${MAKE_FILE} ${ALL_TARGET}
cd ${WRKSRC} && head -99999 ${LICENSE_FILES} > build/LICENSE
do-install:
${INSTALL_DATA_DIR} ${PREFIX}/share/u-boot/apple_m1/dts
cd ${WRKSRC}/build && \
${INSTALL_DATA} ${FILES} ${PREFIX}/share/u-boot/apple_m1/ && \
${INSTALL_DATA} arch/arm/dts/*.dtb ${PREFIX}/share/u-boot/apple_m1/dts/
cd ${WRKSRC} && for f in ${LICENSE_FILES}; do \
(cat "$${f}"; echo) >> ${PREFIX}/share/u-boot/apple_m1/LICENSE; done
.include <bsd.port.mk>