Re: git: 0983bbffe275 - main - devel/rubygem-oj: Fix build

From: Matthias Fechner <idefix_at_fechner.net>
Date: Mon, 06 Feb 2023 10:34:33 UTC
Am 27.01.2023 um 12:17 schrieb Yasuhiro Kimura:
> Unfortunately build still fails after this commit.
> "${INSTALL_DATA} -d" creates directory with 0644 and it result in
> failing to copy header files with 'permission denied'. Attached patch
> fixes it. It uses "${INSTALL} -d" instead. So directory is created
> with 0755 and now header files are copied successfully.
>
>  From 3a01bac7a4793cc191bc605fbb81b0380ab26959 Mon Sep 17 00:00:00 2001
> From: Yasuhiro Kimura <yasu@FreeBSD.org>
> Date: Fri, 27 Jan 2023 18:41:22 +0900
> Subject: [PATCH] devel/rubygem-oj: Create directoy with proper mode
>
> "${INSTALL_DATA} -d" creates directory with 0644 and it result in
> failing to copy header files with 'permission denied'. So use
> "${INSTALL} -d" instead.It creates directory with 0755 and header
> files are copied successfully.
>
> Fixes:		0983bbffe275
> ---
>   devel/rubygem-oj/Makefile | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/devel/rubygem-oj/Makefile b/devel/rubygem-oj/Makefile
> index 374e6a43edc7..367164535c29 100644
> --- a/devel/rubygem-oj/Makefile
> +++ b/devel/rubygem-oj/Makefile
> @@ -1,6 +1,6 @@
>   PORTNAME=	oj
>   PORTVERSION=	3.13.23
> -PORTREVISION=	2
> +PORTREVISION=	3
>   CATEGORIES=	devel rubygems
>   MASTER_SITES=	RG
>   
> @@ -16,7 +16,7 @@ USES=		gem
>   # TODO: find a better way to do this
>   # Copy all header file, as it is required by rubygem-oj-introspect
>   post-install:
> -	${INSTALL_DATA} -d ${STAGEDIR}${PREFIX}/${GEMS_DIR}/${PORTNAME}-${PORTVERSION}/ext/oj
> +	${INSTALL} -d ${STAGEDIR}${PREFIX}/${GEMS_DIR}/${PORTNAME}-${PORTVERSION}/ext/oj
>   	cd ${WRKSRC}/ext/oj && ${FIND} * -name "*.h" -type f -exec ${INSTALL_DATA} {} "${STAGEDIR}${PREFIX}/${GEMS_DIR}/${PORTNAME}-${PORTVERSION}/ext/oj/{}" \;
>   
>   .include <bsd.port.mk>

thanks for your patch.
I committed it, so it should now also be fixed for NONE-ROOT builds.

Gruß
Matthias

-- 

"Programming today is a race between software engineers striving to
build bigger and better idiot-proof programs, and the universe trying to
produce bigger and better idiots. So far, the universe is winning." --
Rich Cook