From owner-freebsd-arch@FreeBSD.ORG Fri Apr 17 17:25:38 2015 Return-Path: Delivered-To: arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 459E5863 for ; Fri, 17 Apr 2015 17:25:38 +0000 (UTC) Received: from mail-pd0-f175.google.com (mail-pd0-f175.google.com [209.85.192.175]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 16D76E1 for ; Fri, 17 Apr 2015 17:25:37 +0000 (UTC) Received: by pdea3 with SMTP id a3so134326027pde.3 for ; Fri, 17 Apr 2015 10:25:36 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:subject:mime-version:content-type:from :in-reply-to:date:cc:message-id:references:to; bh=YKtclGdlY8wcPftkGypxrxurCB2s9LyVFOxVXdnZLGk=; b=IMDzMY4ZkcsnuCGkiy4hTnd9weM+GlUXYEWdNsc1rFnTM1KIcgsytaoxgywZOzaWGL GdAsnmSHgBxtZArncCEvwz066kWQKNx6bDBRpv3byXTmQaRw3BNfW0Rt7T5E1XxoUtnT waoSrd4GhYoSFB8Ud4nLoZhGWeb2msFjaKx2ajoBTktIwS2HeCVN3dtnFdpr1EK9jpnH v/Cp0s2TAbGL1+3UYYQ0lEJxjj5WtzklGr3MsWM3GV/caIiRANrezJc2neOqsoouU3R8 dEEE85WxMXwAfWzznrCq94TGyVXu2erHijYxZKCaoSYc8Gn/gvh3QG3VxHlZQgLHAayb hdVA== X-Gm-Message-State: ALoCoQlk/a7UCfFFP6ddOqA7oCaFDOCZFuTvDT/4vJxIhMo2qbKYRNvOpPASmPNIPoDA4aLnvY/Y X-Received: by 10.66.217.129 with SMTP id oy1mr7308930pac.82.1429291536805; Fri, 17 Apr 2015 10:25:36 -0700 (PDT) Received: from [10.64.24.57] ([69.53.236.236]) by mx.google.com with ESMTPSA id dp7sm10732763pdb.10.2015.04.17.10.25.34 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 17 Apr 2015 10:25:35 -0700 (PDT) Sender: Warner Losh Subject: Re: Removal of the 6.x kernel compat code from libc Mime-Version: 1.0 (Mac OS X Mail 8.2 \(2098\)) Content-Type: multipart/signed; boundary="Apple-Mail=_0E8BBBDD-29F4-4683-9A0C-E6C7B6D00DBC"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail 2.5b6 From: Warner Losh In-Reply-To: <2754569.tvBmmIXdDx@overcee.wemm.org> Date: Fri, 17 Apr 2015 11:25:32 -0600 Cc: John Baldwin , Oliver Pinter , Konstantin Belousov , "freebsd-arch@freebsd.org" , Stefan Esser , freebsd-arch@freebsd.org Message-Id: References: <20150417075942.GI2390@kib.kiev.ua> <5531059F.4060500@freebsd.org> <14081053.n6WdaDRXXc@ralph.baldwin.cx> <2754569.tvBmmIXdDx@overcee.wemm.org> To: Peter Wemm X-Mailer: Apple Mail (2.2098) X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 Apr 2015 17:25:38 -0000 --Apple-Mail=_0E8BBBDD-29F4-4683-9A0C-E6C7B6D00DBC Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Apr 17, 2015, at 11:10 AM, Peter Wemm wrote: >=20 > On Friday, April 17, 2015 09:28:24 AM John Baldwin wrote: >> On Friday, April 17, 2015 03:07:43 PM Stefan Esser wrote: >>> Could we get rid of check_utility_compat(3) on that occasion? >>>=20 >>> It is only used (AFAIK) to select FreeBSD-4 compatible behaviour of >>> expr(1), which can also be selected with option "-e" and env = variable >>> COMPAT_EXPR. >>>=20 >>> I doubt that anybody relies on non-POSIX behaviour that has been >>> deprecated for some 15 years ... >>>=20 >>> We'll need to preserve a stub function for check_utility_compat(3), >>> I'm afraid, but I think we can remove the environment variable and >>> the actual checking for a sym-link named = "/etc/compat-FreeBSD-4-util" >>> at startup of expr. (I bet, nobody even knew that the behaviour of >>> expr could be changed with above sym-link ...) >>>=20 >>> If there is consensus, I could prepare a patch to remove the check >>> and to update the man-page for expr (just for -CURRENT, no MFC). >>=20 >> I would not be surprised if Y!BSD depends on this and uses it in 11 = FWIW. :) >=20 > I'm sorry to say, but yes. We do actually us this on 10.x and 11.x at = work, > although it's worse than you can imagine. I just did a quick diff and = I see: >=20 > =3D=3D=3D=3D //depot/vendor/FreeBSD/stable/10/bin/expr/expr.y#2 = (text+ko) - > //depot/yahoo/ybsd_10/src/bin/expr/expr.y#3 (text+ko) =3D=3D=3D=3D = content > @@ -270,6 +270,8 @@ > int c; >=20 > setlocale(LC_ALL, ""); > + if (getenv("NO_EXPR_COMPAT") =3D=3D NULL) > + setenv("EXPR_COMPAT", "1", 1); > if (getenv("EXPR_COMPAT") !=3D NULL > || check_utility_compat("expr")) { > av =3D argv + 1; >=20 > I'm not going to do an annotate to see who did that.. However, we can > maintain patches locally if needed. >=20 > I'm not even sure *why* its there. I might have removed the code that > depended on it. Let me do some research. With a bit of luck, it = might be > academic for us now. For some reason, I=E2=80=99m happier you said you were using the expr = hack rather than running new libc on ancient kernels=E2=80=A6 Both fill me with = horror, but I guess the expr one is less horrific somehow... Warner --Apple-Mail=_0E8BBBDD-29F4-4683-9A0C-E6C7B6D00DBC Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJVMUINAAoJEGwc0Sh9sBEAPFMQAOmK33qnVYMBOfaZd5JTgMjw D/aIEfnXisSFEGnhPQk7hfwYsjbhE+21ExPiHzzD6PRX9J6JGdvlihO0Ax3Zfpx5 Zker1VYIF0KQn9V0lz6jjbDJvYgMQ3OsDBXd5OqlUq8JlYOXMtRGV+qFG4iYY31Q gb8rOVRqkZcUhJdplwryEh+K4feZkyJEIoAIvn0+7l3Ry3o+qUVvoNyL1nxqxM11 CjPkQMao7GMf5YRXOUJWAhqcojlbfNtFl8GSGOHStJIBHSaFnbcJsZ3+z87flXrc bEIj7v20elpVZDmML3QCayKM47KSYbFpyI+J5R4a9m7Up00zunSizxi/RA/X6V9M DCePJMSCCNDAEh9XUyxMpPdG8RA3ASjS7WGFAVdtRGrwvGpH8Y8IslsbSVWZgMep 0Ka8I8oc+2pk7z0OSyxFE2ftEDowsgXkd6WDvwX6oWT7jW//v2awFG/F5MjDw1o7 aX0cK27knQ7V3R07QMW7bzTuSzzhqnSEnYkp0nfVC0bRwCX7WsbYcyYZp3qK81Sl 0Dls0GE1sc0gpNblL8wuLRIphvsw9uubWZI/FOl64sV31Feqry9VxaKkHdmRNSUJ cymJ8+REwpwlE+lnqQnsCNOaqY6w9g0nAvfLlBbQN9Cpk/g75hAkVtQ6eV+aKzN+ drVtbeeFrQnTFvQFW6HW =RpUA -----END PGP SIGNATURE----- --Apple-Mail=_0E8BBBDD-29F4-4683-9A0C-E6C7B6D00DBC--