Re: git: 73922d6b363a - main - net-mgmt/librenms: Fix start on FreeBSD 14/nginx
Date: Sun, 08 Oct 2023 16:47:09 UTC
08.10.2023 19:32, Sergey A. Osokin пишет:
> On Sun, Oct 08, 2023 at 12:16:59PM -0400, Dan Langille wrote:
>> On Sun, Oct 8, 2023, at 10:54 AM, Sergey A. Osokin wrote:
>>>> +- base = ("/usr/bin/env", "php")
>>>> ++ base = ("/usr/local/bin/php",)
>>> Would that be better to use %%PREFIX%% in a patch and substitute
>>> that with a value of the ${LOCALBASE} variable in a post-patch
>>> phase?
>> This is a great idea. I know the port is already doing this for other locations
>> in the code. There are other patches which need this adjustment as well.
>>
>> post-patch:
>> ${REINPLACE_CMD} 's|%%LOCALBASE%%|${LOCALBASE}|g' ${WRKSRC}/LibreNMS/Validations/Php.php
>> + ${REINPLACE_CMD} 's|%%LOCALBASE%%|${LOCALBASE}|g' ${WRKSRC}/LibreNMS/__init__.py
>> + ${REINPLACE_CMD} 's|%%LOCALBASE%%|${LOCALBASE}|g' ${WRKSRC}/LibreNMS/wrapper.py
>> ${REINPLACE_CMD} 's|%%LOCALBASE%%|${LOCALBASE}|g' ${WRKSRC}/LibreNMS/Util/Version.php
> sed(1) supports multiple files as arguments, so I'd prefer to see more
> compact version (not tested), i.e.:
>
> ${REINPLACE_CMD} 's|%%LOCALBASE%%|${LOCALBASE}|g' \
> ${WRKSRC}/LibreNMS/Validations/Php.php \
> ${WRKSRC}/LibreNMS/__init__.py \
> ${WRKSRC}/LibreNMS/wrapper.py \
> ${WRKSRC}/LibreNMS/Util/Version.php \
> ...
>
> Thank you.
${REINPLACE_CMD} -e 's|%%LOCALBASE%%|${LOCALBASE}|g' \
-e ${WRKSRC}/LibreNMS/Validations/Php.php \
-e ${WRKSRC}/LibreNMS/__init__.py \
-e ${WRKSRC}/LibreNMS/wrapper.py \
-e ${WRKSRC}/LibreNMS/Util/Version.php \
--
Best regards,
Vladimir Druzenko