Created attachment 191597 [details] make -d d config in /usr/ports When I try to configure www/firefox in poudriere I get make: "/usr/local/poudriere/ports/local/Mk/bsd.gecko.mk" line 392: Malformed conditional (${MOZILLA_VER:R:R} >= 56 && (${ARCH:Maarch64} || ${MACHINE_CPU:Msse2})) make: Fatal errors encountered -- cannot continue make: stopped in /usr/local/poudriere/ports/local/www/firefox This error doesn't occur when doing `make config` directly in /usr/ports Here's my investigation: - MACHINE_CPU is empty - MACHINE_CPU is set inside bsd.cpu.mk based on MACHINE_CPUARCH - MACHINE_CPUARCH is empty - `make -C /usr/local/poudriere/ports/local/www/firefox config` does not include bsd.cpu.mk - `make -C /usr/ports/www/firefox config` does include bsd.cpu.mk - poudriere config loads *.mk from `/usr/local/share/mk` instead of `/usr/share/mk` (I have bmake installed) I attach logs from executing make -d d config locally and in poudriere
Created attachment 191598 [details] make -d d config in poudriere ports
Which ARCH and which OSVERSION ?
OSVERSION: 1101001 ARCH: amd64 for both local system and poudriere jail
Is there any progress in solving this issue?
(In reply to serpent7776 from comment #0) > - MACHINE_CPUARCH is empty [...] > - poudriere config loads *.mk from `/usr/local/share/mk` instead of `/usr/share/mk` (I have bmake installed) I can't reproduce. Handing over to poudriere maintainer to investigate.
Please clarify what 'make config in poudriere' means? Are you talking about 'poudriere options', or 'poudriere testport -i', or 'poudriere jail -s' and jexecing into the jail first? Does your host have a /usr/bin/bmake? Is that a copy of the port version from /usr/local/bin/bmake? That may cause the problem.
by `make -d d config` in poudriere I mean `poudriere jail -s` and then jexecing into the jail. I have no /usr/bin/bmake on my system. I had /usr/local/bin/bmake instaled from 'devel/bmake' port and this casused this error - when I deleted bmake port everything worked as should.
(In reply to serpent7776 from comment #7) > by `make -d d config` in poudriere I mean `poudriere jail -s` and then > jexecing into the jail. > > I have no /usr/bin/bmake on my system. > I had /usr/local/bin/bmake instaled from 'devel/bmake' port and this casused > this error - when I deleted bmake port everything worked as should. Try 'which make'... The only way this happens for me is if I run 'bmake'. # echo $PATH /sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:/root/bin # which make /usr/bin/make # which bmake /usr/local/bin/bmake Either way this is not a firefox nor a poudriere problem. You're installing packages and doing things in a poudriere jail that are outside of the intended use. You likely have a modified PATH or alias or symlink.
`which make` tells /usr/bin/make as expected. I don't think anything I did was outside of the intended use: all I did was: - install bmake (on the host) - run poudriere options www/firefox And that failed, because incorrect file being loaded. jexecing into jail was only to try to investigate the issue. Have also not found anything in PATH or an alias that could cause this. Anyway I will try to investigate this further.
I can reproduce this error on clean virtualbox images for 11.1-RELEASE and 11.2-RELEASE steps to reproduce: - bootstrap pkg - `pkg install poudriere` - `poudriere ports -c` - `poudriere jail -c -j test -v 11.1-RELEASE` for 11.1-RELEASE image `poudriere jail -c -j test -v 11.2-RELEASE` for 11.2-RELEASE image - `poudriere options www/firefox` - this works fine - shows firefox options - Ctrl-C to cancel options - `pkg install bmake` - `poudriere options www/firefox` - this fails
I can reproduce this issue outside of poudriere jail on 11.2-RELEASE: - install bmake package - `ln -s /usr/ports /usr/local/ports` - `make -C /usr/local/ports/www/firefox config` make: "/usr/ports/Mk/bsd.gecko.mk" line 405: Malformed conditional (${MOZILLA_VER:R:R} >= 56 && (${ARCH:Maarch64} || ${MACHINE_CPU:Msse2})) make: Fatal errors encountered -- cannot continue make: stopped in /usr/local/ports/www/firefox This error does not occur when calling `make -C /usr/ports/www/firefox config` I assumme this is a `/usr/bin/make` issue - for some reason when executing Makefile that lives under `/usr/local` bmake's `*.mk` files are sourced instead of `*.mk` from `/usr/share/mk`.
Created attachment 198861 [details] `truss make -C config` output when bmake is not installed
Created attachment 198862 [details] `truss make -C config` output when bmake is installed
I've found cause of this behaviour comparing `truss make -C /usr/local/ports/www/firefox config` output. When `make` searches for `sys.mk` file, it starts in current directory and tries in parents if failed. So it searches for sys.mk in the following directories: /usr/local/ports/www/firefox/share/mk /usr/local/ports/www/share/mk /usr/local/ports/share/mk /usr/local/share/mk /usr/share/mk If bmake is not installed `sys.mk` exists only in `/usr/share/mk` so it gets loaded and everuthing is ok. If bmake is installed however `/usr/local/share/mk` contains bmake's sys.mk and this gets loaded instead of `/usr/share/mk/sys.mk`. So is this searching for `sys.mk` is required at all?