Date: Sat, 31 Jul 2021 08:07:42 -0600 From: Warner Losh <imp@bsdimp.com> To: Kristof Provost <kp@freebsd.org> Cc: Warner Losh <imp@freebsd.org>, src-committers <src-committers@freebsd.org>, "<dev-commits-src-all@freebsd.org>" <dev-commits-src-all@freebsd.org>, dev-commits-src-branches@freebsd.org Subject: Re: git: 6edf5082bab7 - stable/12 - one-true-awk: import 20210221 (1e4bc42c53a1) which fixes a number of bugs Message-ID: <CANCZdfp96v_oinwe75-LVsn3Y0Y%2Bn5Q=BSLWHwfk5xJ4KW%2BekQ@mail.gmail.com> In-Reply-To: <4AD3AB8C-A960-43BE-A89B-5D9C4CD077DD@FreeBSD.org> References: <202107101712.16AHCwoE088447@gitrepo.freebsd.org> <4AD3AB8C-A960-43BE-A89B-5D9C4CD077DD@FreeBSD.org>
index | next in thread | previous in thread | raw e-mail
On Sat, Jul 31, 2021 at 3:11 AM Kristof Provost <kp@freebsd.org> wrote: > Hi Warner, > > On 10 Jul 2021, at 19:12, Warner Losh wrote: > > The branch stable/12 has been updated by imp: > > URL: > https://cgit.FreeBSD.org/src/commit/?id=6edf5082bab71cf923efff9f18e38efe5b83b0ec > > commit 6edf5082bab71cf923efff9f18e38efe5b83b0ec > Author: Warner Losh <imp@FreeBSD.org> > AuthorDate: 2021-07-07 23:30:35 +0000 > Commit: Warner Losh <imp@FreeBSD.org> > CommitDate: 2021-07-10 17:11:15 +0000 > > one-true-awk: import 20210221 (1e4bc42c53a1) which fixes a number of bugs > > Import the latest bsd-features branch of the one-true-awk upstream: > > o Move to bison for $YACC > o Set close-on-exec flag for file and pipe redirects that aren't std* > o lots of little fixes to modernize ocde base > o free sval member before setting it > o fix a bug where a{0,3} could match aaaa > o pull in systime and strftime from NetBSD awk > o pull in fixes from {Net,Free,Open}BSD (normalized our code with them) > o add BSD extensions and, or, xor, compl, lsheift, rshift (mostly a nop) > > Also revert a few of the trivial FreeBSD changes that were done slightly > differently in the upstreaming process. Also, our PR database may have > been mined by upstream for these fixes, and Mikolaj Golub may deserve > credit for some of the fixes in this update. > > Suggested by: Mikolaj Golub <to.my.trociny@gmail.com> > PR: 143363,143365,143368,143369,143373,143375,214782 > Sponsored by: Netflix > > (cherry picked from commit f39dd6a9784467f0db5886012b3f4b13899be6b8) > > I *think* this is the relevant commit, but I’m not 100% sure. > > Anyway, I’ve recently started seeing issues building pfSense for aarch64. > I’ve finally narrowed it down, and replicated the problem on base FreeBSD > (stable/12, but I assume other branches are affected too). > > It fails to build proctab.c. This file is generated by maketab, a tool > built as part of the build process. In my case this tool is built for > aarch64, which makes executing it on amd64 less successful than we’d like. > > This only happens when building with META_MODE though. I do not understand > the build system sufficiently to debug why. Hopefully you’ll have a better > idea. > Generally I do, but this one is a bit weird. Also, the amount of context you've included omits the actual error :( Though I'm guessing it's wrong arch for the build tool... I rarely use meta mode, and understand it not at all, but awk follows the same patterns as /bin/sh and /bin/csh does. Warner This triggers the build failure: > > % cat /usr/src/src_env.conf > WITH_META_MODE=yes > % env SRC_ENV_CONF=/usr/src/src_env.conf TARGET_ARCH=aarch64 make -j 8 buildworld > > … > --- proctab.c --- > *** [proctab.c] Error code 255 > > make[4]: stopped in /usr/src/usr.bin/awk > .ERROR_TARGET='proctab.c' > .ERROR_META_FILE='/usr/obj/usr/src/arm64.aarch64/usr.bin/awk/proctab.c.meta' > .MAKE.LEVEL='4' > MAKEFILE='' > .MAKE.MODE='meta missing-filemon=yes missing-meta=yes silent=yes verbose' > _ERROR_CMD='./maketab awkgram.h > proctab.c;' > .CURDIR='/usr/src/usr.bin/awk' > .MAKE='make' > .OBJDIR='/usr/obj/usr/src/arm64.aarch64/usr.bin/awk' > .TARGETS='all' > DESTDIR='/usr/obj/usr/src/arm64.aarch64/tmp' > LD_LIBRARY_PATH='' > MACHINE='arm64' > MACHINE_ARCH='aarch64' > MAKEOBJDIRPREFIX='' > MAKESYSPATH='/usr/src/share/mk' > MAKE_VERSION='20200710' > > Further up in the build output: > > --- maketab --- > cc -target aarch64-unknown-freebsd12.2 --sysroot=/usr/obj/usr/src/arm64.aarch64/tmp -B/usr/obj/usr/src/arm64.aarch64/tmp/usr/bin -O2 -pipe -fno-common -DHAS_ISBLANK -I. -I/usr/src/contrib/one-true-awk -DFOPEN_MAX=64 -g -std=gnu99 -Wno-format-zero-length -fstack-protector-strong -Wsystem-headers -Werror -Wno-pointer-sign -Wno-empty-body -Wno-string-plus-int -Wno-unused-const-variable -Wno-tautological-compare -Wno-unused-value -Wno-parentheses-equality -Wno-unused-function -Wno-enum-conversion -Wno-unused-local-typedef -Wno-address-of-packed-member -Wno-switch -Wno-switch-enum -Wno-knr-promoted-parameter -Wno-parentheses -Qunused-arguments /usr/src/contrib/one-true-awk/maketab.c -o maketab > > Without META_MODE maketab is built as an amd64 binary, and the entire > build succeeds. > > Best regards, > Kristof >help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CANCZdfp96v_oinwe75-LVsn3Y0Y%2Bn5Q=BSLWHwfk5xJ4KW%2BekQ>
