From owner-dev-commits-src-main@freebsd.org Mon Apr 12 14:40:13 2021 Return-Path: Delivered-To: dev-commits-src-main@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 70F835D336A for ; Mon, 12 Apr 2021 14:40:13 +0000 (UTC) (envelope-from shawn.webb@hardenedbsd.org) 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 4FJrxT2MkNz4Y2M for ; Mon, 12 Apr 2021 14:40:13 +0000 (UTC) (envelope-from shawn.webb@hardenedbsd.org) Received: by mail-qk1-x72d.google.com with SMTP id e13so4042133qkl.6 for ; Mon, 12 Apr 2021 07:40:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hardenedbsd.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=WRhPPlXE3j24G44OrhsC2zxrW7JrqVqPGVR/33728/M=; b=krSHQ/0/tGnZ834CWNauStP9Hlz6r9RdQPg1qRJKS665LJErYr/nGUR71QenVo/+lZ uDkGVdqIXDR6lGQtBrZ0omi8Py0wuUoEZEbD89E3XZ8mqE/3AHBJ6F4+qdlXLJ3wHSd2 oVaoz564oo+rIheLrc02+BOgAWMyhbtoq9hPREu/WIlDw6ks3TE2dDGGVo5cFK5RvznL 91+hM2ir9+eLGjH0kylKJQV0BzZyaUMW3uyHccyjKPCWO0EUcyW3XhvxURII3UnqT0FJ 3N46OaRtufjT7Xgs1yIP0Cb52pK9U9QR6PS1gNokIXjxrz0C+AKCSDepfOA1fANFkGYz k+uA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=WRhPPlXE3j24G44OrhsC2zxrW7JrqVqPGVR/33728/M=; b=HGDF7RPHRx1sBY7TT5J7dygWBOuoz6syyTglaAiJ/JKCzmHLil6yT3LZC/PF/gj800 1i9/0iv8uzRJRWF9e+M51GZvQsvUD+l92Y/fnivCPmTHIOyCdZBOLbbFEISrCgJGZ7ym 6P9bRhAq7VQk/tPx59Q09hWBMqSpgTGnjGU+zESRmb6DdwNU/fngINTGgwR/4vsWUG9F 5+hiU7uqIevjpapdXordM0U/fqjxiGOHYkT/hDxQyFIH0U2RV9XNSDMbqUxb7pT3tNI3 VTUCY6kYzCnyLaCw8VX4QPONcZti6xPICMKZThVSIuw84S7yJUsgdqJMtukuuu8IBaps KdAg== X-Gm-Message-State: AOAM530aFs+uYXf0v4s50BHpSzg9Tt57LwVeTPqS4zmgSoX//LxK6oaA 1sjKJ4JKBTQGMMJj7bqDSZAvug== X-Google-Smtp-Source: ABdhPJwgZzCGhd8TuPX67upCfMelSYHlz+lhmrOIHNKIQZ/lChQaPbNmgwmjeZJ2+1sPZ0HzTarvqw== X-Received: by 2002:a05:620a:a89:: with SMTP id v9mr10091211qkg.279.1618238411935; Mon, 12 Apr 2021 07:40:11 -0700 (PDT) Received: from mutt-hbsd (pool-100-16-222-53.bltmmd.fios.verizon.net. [100.16.222.53]) by smtp.gmail.com with ESMTPSA id l17sm7601037qtk.60.2021.04.12.07.40.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 Apr 2021 07:40:11 -0700 (PDT) Date: Mon, 12 Apr 2021 10:40:10 -0400 From: Shawn Webb To: Kristof Provost Cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 0dd13c77432a - main - libnv: Build PIC Message-ID: <20210412144010.lcv7swa5ob3eql6m@mutt-hbsd> X-Operating-System: FreeBSD mutt-hbsd 14.0-CURRENT-HBSD FreeBSD 14.0-CURRENT-HBSD X-PGP-Key: https://git.hardenedbsd.org/hardenedbsd/pubkeys/-/blob/master/Shawn_Webb/03A4CBEBB82EA5A67D9F3853FF2E67A277F8E1FA.pub.asc References: <202104100916.13A9GMOp069019@gitrepo.freebsd.org> <20210410152754.4isx26qyvz6k3qbo@mutt-hbsd> <98C59789-AF1F-4B88-B814-F0BD359A06BD@FreeBSD.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="og47aeiobytpupsd" Content-Disposition: inline In-Reply-To: <98C59789-AF1F-4B88-B814-F0BD359A06BD@FreeBSD.org> X-Rspamd-Queue-Id: 4FJrxT2MkNz4Y2M X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-BeenThere: dev-commits-src-main@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commit messages for the main branch of the src repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Apr 2021 14:40:13 -0000 --og47aeiobytpupsd Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Apr 12, 2021 at 01:39:50PM +0200, Kristof Provost wrote: > On 10 Apr 2021, at 17:27, Shawn Webb wrote: > > On Sat, Apr 10, 2021 at 09:16:22AM +0000, Kristof Provost wrote: > > > The branch main has been updated by kp: > > >=20 > > > URL: https://cgit.FreeBSD.org/src/commit/?id=3D0dd13c77432ade1ae94c96= 61cbad5537e3e6ab1d > > >=20 > > > commit 0dd13c77432ade1ae94c9661cbad5537e3e6ab1d > > > Author: Kristof Provost > > > AuthorDate: 2021-04-02 15:06:02 +0000 > > > Commit: Kristof Provost > > > CommitDate: 2021-04-10 09:16:01 +0000 > > >=20 > > > libnv: Build PIC > > >=20 > > > Build libnv as position independent code so we can use it from > > > shared > > > libraries. > > >=20 > > > MFC after: 4 weeks > > > Sponsored by: Rubicon Communications, LLC ("Netgate") > > > Differential Revision: https://reviews.freebsd.org/D29561 > > > --- > > > lib/libnv/Makefile | 1 + > > > 1 file changed, 1 insertion(+) > > >=20 > > > diff --git a/lib/libnv/Makefile b/lib/libnv/Makefile > > > index b13758931c4e..854cd2c7f3f3 100644 > > > --- a/lib/libnv/Makefile > > > +++ b/lib/libnv/Makefile > > > @@ -10,6 +10,7 @@ SHLIB_MAJOR=3D 0 > > >=20 > > > .PATH: ${SRCTOP}/sys/contrib/libnv ${SRCTOP}/sys/sys > > > CFLAGS+=3D-I${.CURDIR} > > > +CFLAGS+=3D-fPIC > >=20 > > Wouldn't the better fix be renaming LIB to SHLIB like every other PIC > > lib? > >=20 > Ed pointed me at INSTALL_PIC_ARCHIVE. I=E2=80=99m also pondering just mak= ing > libpfctl a .so, which should also fix the issue this addresses. >=20 > The complication is that libpfctl is currently a .a, and can be used in a > shared library itself (for bsnmp), so it has to be - and use - PIC. Out of curiosity, is there a reason not to have the shared library depend on libnv as a shared library? Thanks, --=20 Shawn Webb Cofounder / Security Engineer HardenedBSD https://git.hardenedbsd.org/hardenedbsd/pubkeys/-/raw/master/Shawn_Webb/03A= 4CBEBB82EA5A67D9F3853FF2E67A277F8E1FA.pub.asc --og47aeiobytpupsd Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEA6TL67gupaZ9nzhT/y5nonf44foFAmB0W8gACgkQ/y5nonf4 4fp6fRAAmKuDEACIDiwZBulIBiSRtEJaXkXl53gmferwb+XV+rLGXzCP1W1hB3tD 7ZeFhs6Egvc83FDvDsk9JT4MYr6OKyLa7J31sDCY4hSGWXNxtBYJQnnlVjcSKvrp noWeP75dZ9NM+X0+GlxuE8NVOxPbLqrHmFo0iKMG0GqWo/R41vwytqvkUgP7jMPs lnK60Wk7iJJX8mI6I7DUqwN54D9468Kr6Or89hPVRZ37tZpTbaGKvy/KTCoxZImw /AgfG58dp8FylwxbfhY3TO6qc3cMu8OeMQ0l8rX+TK2nj7nvmhq4Pl2L6021xW+I IoHkj1Mk5fgFatFhZm7JNdvWf1XC9bHRNXMHsRFeiMi6LLwMJA+SL96lO7J3Ptty 910SJ1b+thh2Toaq+s1prbf19GJliHH7iCuvyCgvjoAIHHhCIyZy45SkztStY52r EhTAosfXMdruV57AKZypsAXm6Tkl52U6bsYJMmIkGmIWGKb731dalWz0nyeSS28M LLnvNbeR91tzHOgdfSywBqnaaGpHiZPYQBBMkmxnxIPtst0nKIezxA/zg2AZy5MO pfR1PpDQU+LC4i7VjHdjlLTWa5CuNdtQVkc6GTe0QrUtINtEGm2mBsqlKMg5p8pd t58l2bYUj5feJJ6jiktgvabTZVu/lkXBAHISawOFrNi/A9a6Tqg= =ddtq -----END PGP SIGNATURE----- --og47aeiobytpupsd--