From owner-dev-commits-src-branches@freebsd.org Sat Jul 31 14:20:50 2021 Return-Path: Delivered-To: dev-commits-src-branches@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id AC33265EE45 for ; Sat, 31 Jul 2021 14:20:50 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qk1-x72d.google.com (mail-qk1-x72d.google.com [IPv6:2607:f8b0:4864:20::72d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4GcRJK4Vpqz4cJ4 for ; Sat, 31 Jul 2021 14:20:49 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qk1-x72d.google.com with SMTP id t66so12407132qkb.0 for ; Sat, 31 Jul 2021 07:20:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=uGCstSf2y6eKOGdrS6H9f/Q8TVOlsjqs1IjZT7v2xuw=; b=TVkxIKsDZi7NiL/7RQyoosEYd/XqFnjyA0POn3Ts5xwzoBA4AKYuHImjml3qxDoibU 1ppKP9UIOG+jNEH9kcYVSU6LojwIuIEGrSnN48fvF9vgLbl0JsfbaEkc+8HI60FYn9j+ jNMkirdS1G1RiwQGn95xM6sNDSZkb1M42i8plnqXzIaWxZIlJ231CkOE+Slm+LS3l7/n xaB3Aqji9iJcKoEjjNFLPnYKb/M+funplyM2tlbZCX7vJgy56wgxvDJ8ZryV3fumtMWu XW9nwD87yTRFIF5oVZ/I7/DBmq8ML5m3dutrqbzRoxLgqoVJykIQILikkD8CSg3K4fyh Cmqg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=uGCstSf2y6eKOGdrS6H9f/Q8TVOlsjqs1IjZT7v2xuw=; b=pDqS65GxgJp5/vr0XDBralCI6mMa/a3qUTp7ak8noRihtRHIhFRFuDL7bs0Jve+PIV i6k6CyuarT/PiOcSXFJsyXDsh/+KIZ4z6pBDmGF1oXNw5Y8YALjX5nQgeAj5BkaYOGvt PMhvpka4kW2sYto4/T/zHYHrELzjROl5gh/FF8w94Bh73AclfvoRHAPFjlpgx/EIJiCr 8yj9q/5Fg8XI1oQD1h4qJFx8PE/eybaH54YQ1R93LXWRS3UhEf/Ym+asNvAz7xJ2NfIF Kfp6uWkobAvZ1Jdc6x5XiMa4NfMlFZnF2xDj1FMgiZoyuriRMTQnwmyk2tapQmldOlHE k/gQ== X-Gm-Message-State: AOAM530IJ8RUdPpSiI+9TSCDWBGQ9mmSNS/smwaFrfPezsnvJ62uhrVe oYPh0GDDFJ2ES67pd4Znf9+MFXuKwvGVUaa8sJ5JlA== X-Google-Smtp-Source: ABdhPJxGlDp12C8kJwMVi6AIn4b3NDGGn0vqb5OBt+/QxsQ2EA8caFLWlmznFvsgBvMRxNUS96vcaWyUxnIMZLrNZ6M= X-Received: by 2002:a37:e4f:: with SMTP id 76mr7063468qko.44.1627741249050; Sat, 31 Jul 2021 07:20:49 -0700 (PDT) MIME-Version: 1.0 References: <202107101712.16AHCwoE088447@gitrepo.freebsd.org> <4AD3AB8C-A960-43BE-A89B-5D9C4CD077DD@FreeBSD.org> In-Reply-To: From: Warner Losh Date: Sat, 31 Jul 2021 08:20:39 -0600 Message-ID: Subject: Re: git: 6edf5082bab7 - stable/12 - one-true-awk: import 20210221 (1e4bc42c53a1) which fixes a number of bugs To: Kristof Provost Cc: Warner Losh , src-committers , "" , dev-commits-src-branches@freebsd.org X-Rspamd-Queue-Id: 4GcRJK4Vpqz4cJ4 X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20150623.gappssmtp.com header.s=20150623 header.b=TVkxIKsD; dmarc=none; spf=none (mx1.freebsd.org: domain of wlosh@bsdimp.com has no SPF policy when checking 2607:f8b0:4864:20::72d) smtp.mailfrom=wlosh@bsdimp.com X-Spamd-Result: default: False [-2.99 / 15.00]; RCVD_TLS_ALL(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20150623.gappssmtp.com:s=20150623]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[dev-commits-src-branches@freebsd.org]; DMARC_NA(0.00)[bsdimp.com]; RCPT_COUNT_FIVE(0.00)[5]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[bsdimp-com.20150623.gappssmtp.com:+]; NEURAL_HAM_SHORT(-0.99)[-0.988]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::72d:from]; R_SPF_NA(0.00)[no SPF record]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; MIME_TRACE(0.00)[0:+,1:+,2:~]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; MAILMAN_DEST(0.00)[dev-commits-src-branches]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.34 X-BeenThere: dev-commits-src-branches@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commits to the stable branches of the FreeBSD src repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 31 Jul 2021 14:20:50 -0000 On Sat, Jul 31, 2021 at 8:07 AM Warner Losh wrote: > > > On Sat, Jul 31, 2021 at 3:11 AM Kristof Provost 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=3D6edf5082bab71cf923efff9f18e38e= fe5b83b0ec >> >> commit 6edf5082bab71cf923efff9f18e38efe5b83b0ec >> Author: Warner Losh >> AuthorDate: 2021-07-07 23:30:35 +0000 >> Commit: Warner Losh >> CommitDate: 2021-07-10 17:11:15 +0000 >> >> one-true-awk: import 20210221 (1e4bc42c53a1) which fixes a number of bug= s >> >> 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 >> 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=E2=80=99m not 100% sure. >> >> Anyway, I=E2=80=99ve recently started seeing issues building pfSense for= aarch64. >> I=E2=80=99ve finally narrowed it down, and replicated the problem on bas= e 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=E2=80= =99d like. >> >> This only happens when building with META_MODE though. I do not >> understand the build system sufficiently to debug why. Hopefully you=E2= =80=99ll >> 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 > [[ stupid gmail ]] I've just pushed removal of proctab.c. That may fix this, though I'm not hopeful. I've rarely used metamode, and not for quite some time, but this an extra file that would confuse things so that maketab might not be built during build-tools and instead is built later. Please give that a try, and I'll start a meta build, but that takes a while, not least because I have to re-leran how to do that :) I've also noticed a few things I can do to cleanup the main build to eliminate the awkward symlinks, but I'll do those separately. Warner > Warner > > This triggers the build failure: >> >> % cat /usr/src/src_env.conf >> WITH_META_MODE=3Dyes >> % env SRC_ENV_CONF=3D/usr/src/src_env.conf TARGET_ARCH=3Daarch64 make -j= 8 buildworld >> >> =E2=80=A6 >> --- proctab.c --- >> *** [proctab.c] Error code 255 >> >> make[4]: stopped in /usr/src/usr.bin/awk >> .ERROR_TARGET=3D'proctab.c' >> .ERROR_META_FILE=3D'/usr/obj/usr/src/arm64.aarch64/usr.bin/awk/proctab.c= .meta' >> .MAKE.LEVEL=3D'4' >> MAKEFILE=3D'' >> .MAKE.MODE=3D'meta missing-filemon=3Dyes missing-meta=3Dyes silent=3Dyes= verbose' >> _ERROR_CMD=3D'./maketab awkgram.h > proctab.c;' >> .CURDIR=3D'/usr/src/usr.bin/awk' >> .MAKE=3D'make' >> .OBJDIR=3D'/usr/obj/usr/src/arm64.aarch64/usr.bin/awk' >> .TARGETS=3D'all' >> DESTDIR=3D'/usr/obj/usr/src/arm64.aarch64/tmp' >> LD_LIBRARY_PATH=3D'' >> MACHINE=3D'arm64' >> MACHINE_ARCH=3D'aarch64' >> MAKEOBJDIRPREFIX=3D'' >> MAKESYSPATH=3D'/usr/src/share/mk' >> MAKE_VERSION=3D'20200710' >> >> Further up in the build output: >> >> --- maketab --- >> cc -target aarch64-unknown-freebsd12.2 --sysroot=3D/usr/obj/usr/src/arm6= 4.aarch64/tmp -B/usr/obj/usr/src/arm64.aarch64/tmp/usr/bin -O2 -pipe -fno-c= ommon -DHAS_ISBLANK -I. -I/usr/src/contrib/one-true-awk -DFOPEN_MAX=3D64 = -g -std=3Dgnu99 -Wno-format-zero-length -fstack-protector-strong -Wsystem-h= eaders -Werror -Wno-pointer-sign -Wno-empty-body -Wno-string-plus-int -Wno-= unused-const-variable -Wno-tautological-compare -Wno-unused-value -Wno-pare= ntheses-equality -Wno-unused-function -Wno-enum-conversion -Wno-unused-loca= l-typedef -Wno-address-of-packed-member -Wno-switch -Wno-switch-enum -Wno-k= nr-promoted-parameter -Wno-parentheses -Qunused-arguments /usr/src/cont= rib/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 >> >