On Thu, 11 Jun 2026 12:41:48 +0200,
Stuart Henderson <[email protected]> wrote:
> 
> On 2026/06/11 11:47, Kirill A. Korinsky wrote:
> > ports@,
> > 
> > I'd like to add small port which packs pnor.BOOTKERNEL needed to boot
> > qemu-system-ppc64 with something that can run OpenBSD/powerpc64
> 
> I don't really like EXTRACT_ONLY= when the main distfile can be handled
> by standard infrastructure, so I'd prefer it with the diff below, but
> won't insist.
>
> ok
> 
> --- Makefile.orig     Thu Jun 11 11:39:45 2026
> +++ Makefile  Thu Jun 11 11:24:21 2026
> @@ -8,7 +8,6 @@ CATEGORIES=   sysutils
>  HOMEPAGE=    https://wiki.raptorcs.com/wiki/Talos_II/Firmware
>  SITES=               https://wiki.raptorcs.com/w/images/6/61/
>  EXTRACT_SUFX=        .tar
> -EXTRACT_ONLY=
>  
>  # pnor.BOOTKERNEL: Linux kernel (GPL-2.0) with Buildroot/Skiroot
>  # initramfs containing GPL/LGPL/BSD/MIT/ISC licensed components.
> @@ -24,10 +23,9 @@ PNOR_BZ2=  shell_upgrade/talos-ii-v${V}.pnor.bz2
>  PNOR=                ${WRKSRC}/talos-ii-v${V}.pnor
>  BOOTKERNEL=  ${WRKSRC}/pnor.BOOTKERNEL
>  
> +WRKDIST=     ${WRKDIR}
> +
>  post-extract:
> -     ${INSTALL_DATA_DIR} ${WRKSRC}
> -     cd ${WRKSRC} && \
> -         ${TAR} -xf ${FULLDISTDIR}/${DISTNAME}${EXTRACT_SUFX} -- ${PNOR_BZ2}
>       ${LOCALBASE}/bin/bzip2 -dc ${WRKSRC}/${PNOR_BZ2} > ${PNOR}
>  
>  do-build:
> 
> 

This way it won't make clean as:

===>  Cleaning for talos-ii-pnor-bootkernel-2.10
rm: 
/build/pobj/talos-ii-pnor-bootkernel-2.10/shell_upgrade/talos-ii-v2.10.pnor.bz2:
 Permission denied
rm: /build/pobj/talos-ii-pnor-bootkernel-2.10/shell_upgrade: Directory not empty
rm: 
/build/pobj/talos-ii-pnor-bootkernel-2.10/web_ipmi_upgrade/talos-ii-v2.01.pnor.squashfs.tar:
 Permission denied
rm: /build/pobj/talos-ii-pnor-bootkernel-2.10/web_ipmi_upgrade: Directory not 
empty
rm: /build/pobj/talos-ii-pnor-bootkernel-2.10: Directory not empty
*** Error 1 in . (/usr/ports/infrastructure/mk/bsd.port.mk:3409 
'_internal-clean': @if [ -e /build/pobj/talos-ii-pnor-bootkernel-2.10 ]; the...)

the issue that Talos-ii-pnor-v2.10-bundle.tar contains two folders inside,
and I haven't found a way to fix make clean without this "manual hack"

Any idea?

-- 
wbr, Kirill

Reply via email to