pkgsrc-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: mk.conf error from pkg_chk (Was: openjdk21 build errors)
Am 28.01.2025 um 08:35 schrieb Mayuresh:
> On Mon, Jan 27, 2025 at 06:28:57PM +0100, Roland Illig wrote:
>> Since pkg_chk is a shell program, you can get an execution trace by running:
>
> I ran it as:
>
> sh -xe /usr/pkg/sbin/pkg_chk -Brnv
>
> I find this line intriguing:
>
> 190 eval $(printf "BSD_PKG_MK=1\n.PHONY: x\nx:\n\t@echo $1="'$'"{$1}\n" | ${MAKE} -f - -f $MAKECONF x)
I consider this line a clear bug.
The file mk/bsd.prefs.mk documents at the top that some variables are
always defined when mk.conf is included. And even though OPSYS is not
in that list, MACHINE_PLATFORM contains it, and it is defined
unconditionally above the point where mk.conf is included, so OPSYS
should be seen as guaranteed to be defined as well.
Same for the variables OBJECT_FMT, NATIVE_OBJECT_FMT.
I don't know pkg_chk, but maybe its maintainer David Brownlee can help
out here by ensuring that mk.conf is only ever included in an
environment that offers the same guarantees as pkgsrc itself.
Roland
Home |
Main Index |
Thread Index |
Old Index