From nobody Fri Oct 17 06:46:16 2025 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4cnwMX2zvjz6ClLH; Fri, 17 Oct 2025 06:46:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cnwMX2F4Gz3bs9; Fri, 17 Oct 2025 06:46:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1760683576; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=x+4+w6bWxWJ1OSvGcHREkhYRa5HqawCIX+fwgWqrVRI=; b=QBFjf8GhaLrWR28tg2f2dC7yY9GDoA5PyhfKcGAnBDDX7gEaxAlyQn19u4XAxJRJDDZNOG 2RNlYNZcDuCx6hHbfryaps4TWXlhgQSeHBBNJkAgYPAKUSsPdN8A8xA+eGmVP+tYATc5Hx /5A8hfVQ0hB7xIUsBMLlom5l1RvzaYOxgRPwjym2sCQGIFFzpJOJGhbrGEWlFSwQGzT96S IPGZIY+sO9+/skJLCJD+/XcWCSLlvLk0FdQ+a0YtHwFwpY3+5Ti72kD/7aZ2Uje9jKgTdj VvwA/JXd8Ja6xUcbw1uMBGOTCApg4DgpVJfm5TAs6xV+z1jtusUhs7LFHRVMGw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1760683576; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=x+4+w6bWxWJ1OSvGcHREkhYRa5HqawCIX+fwgWqrVRI=; b=NiSczLmj5IGa5OVv1uExNLZx491HLGCHUyq/VM/ZJ456I1/+bcATXHGC4Nl0Sf1rMyj53/ X5uTjo+Ewkx6VCd1+w23GvpL+8Y6UfuF197woQYDa/iEL+ksdaU6LBuIN19fVrB3HJpsoy YqJQw5hLvfm+8HFwNhpFmK2fpqrmNbTyJkZ40C0HVIRkzzXrL+lxrhpVdkfsWeoprQyB0p Bi78FYg9+sEzqyTGBQxvelvOFZhF30TBwff8IOfQV7aJ/SKOELna9bkMhHPGitmuNdHijJ WEU2ZpndlOD6Tcc9tGlobEdMKWqu/0pc1eWvlzXcFc6ykJyoDctlzZhd7GkVOA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1760683576; a=rsa-sha256; cv=none; b=lm29PsD/Z+YVouUQVU4hKjMfBdQKH7W53nagVQbx/1FMukrns0vVR/CLbZDTniQeJn4H/Y SioZIHe9R3Y9wDBTatooVqXJhMQ+IwptvYfnq8MuD9guqw3D+xB8jw0Vigopoz4fTVvf/m yJYgXQOJsZl1BaQmEvtMBjfzu7a/3EMYPVBXSU2AH0KkLnhbU/o6H82/8ckfV8NWkCr98R SAHd5XHWXZ0JKCznOEJ4QGy+wuOGugSWeeCJL3PWRShq0/4jtzXcrQ+y0BO03jTwIpmTwn cKjKDJUBDpYYA5XV/f+tRlUoDMZcumKfr2jHC1AKqY3XIONayDDb73Bq08/csg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4cnwMX1rQZzkZr; Fri, 17 Oct 2025 06:46:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 59H6kGCc022965; Fri, 17 Oct 2025 06:46:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 59H6kG0S022962; Fri, 17 Oct 2025 06:46:16 GMT (envelope-from git) Date: Fri, 17 Oct 2025 06:46:16 GMT Message-Id: <202510170646.59H6kG0S022962@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Enji Cooper Subject: git: 97388e7215e0 - main - OpenSSL: install .pc files from the exporters subdir List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: ngie X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 97388e7215e080f2cb9fd446f4be4e46a9aeb114 Auto-Submitted: auto-generated The branch main has been updated by ngie: URL: https://cgit.FreeBSD.org/src/commit/?id=97388e7215e080f2cb9fd446f4be4e46a9aeb114 commit 97388e7215e080f2cb9fd446f4be4e46a9aeb114 Author: Enji Cooper AuthorDate: 2025-10-11 20:47:20 +0000 Commit: Enji Cooper CommitDate: 2025-10-17 06:42:13 +0000 OpenSSL: install .pc files from the exporters subdir The .pc files generated in the root directory are used as part of the build; they should never be installed. Use the versions from the exporters subdirectory--which should be installed--as the .pc files which are distributed with FreeBSD. This avoids the need for "fixing up" these files after the fact (see `crypto/openssl/BSDmakefile` for more details as part of this change). Garbage collect `secure/lib/libcrypto/Makefile.version`, et al, as they're orphaned files. They were technically unused prior to this change as the vendor process properly embeds the version numbers in various files, but this commit formalizes the removal. This correction/clarification on the .pc files will be made in an upcoming release of OpenSSL [1]. References: 1. https://github.com/openssl/openssl/issues/28803 Suggested by: Richard Levitte (OpenSSL project) MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D53043 --- crypto/openssl/BSDmakefile | 20 -------------------- .../openssl/freebsd/dump_version_from_configdata.pl | 21 --------------------- secure/lib/libcrypto/Makefile.inc | 12 +++--------- secure/lib/libcrypto/Makefile.version | 2 -- 4 files changed, 3 insertions(+), 52 deletions(-) diff --git a/crypto/openssl/BSDmakefile b/crypto/openssl/BSDmakefile index d260808ffac3..a45dc2b532f3 100644 --- a/crypto/openssl/BSDmakefile +++ b/crypto/openssl/BSDmakefile @@ -48,32 +48,12 @@ configure: enable-sctp \ --openssldir=etc \ --prefix=/usr) - @echo "Building configdata.pm for later use." - @(cd ${.CURDIR} && \ - ${SETENVI} ${WRK_ENV} ${GMAKE} -j ${.MAKE.JOBS} configdata.pm) - - @echo "Populating Makefile.version with release information" - @(cd ${LCRYPTO_SRC} && ${SETENVI} ${WRK_ENV} ${PERL} \ - ${LCRYPTO_SRC}/freebsd/dump_version_from_configdata.pl > \ - ${SRCTOP}/secure/lib/libcrypto/Makefile.version) all: patch @echo "==> Building generated files (headers, manpages, etc)" @(cd ${.CURDIR} && \ ${SETENVI} ${WRK_ENV} ${GMAKE} -j ${.MAKE.JOBS} build_all_generated) - # 1. Fix --prefix. - # a. Not sure why --prefix isn't honored properly, even though it's - # passed to Configure; the files might be getting rebuilt - # post-Configure, somehow. - # 2. Remove duplicate path in CFLAGS. - # 3. Remove duplicate path in includedir(s). - @echo "==> Fixing pkgconfig files" - @find . -name \*.pc -print -exec sed -i '' -E \ - -e 's,^prefix=.+,prefix=/usr,' \ - -e 's,[[:space:]]+(\-I)?\$\{prefix\}/\./include[[:space:]]*,,g' \ - {} + - @echo "==> Cleaning / rebuilding ASM" @(cd ${SRCTOP}/secure/lib/libcrypto && \ ${SETENVI} ${WRK_ENV} ${MAKE} cleanasm && \ diff --git a/crypto/openssl/freebsd/dump_version_from_configdata.pl b/crypto/openssl/freebsd/dump_version_from_configdata.pl deleted file mode 100644 index b6137718ba54..000000000000 --- a/crypto/openssl/freebsd/dump_version_from_configdata.pl +++ /dev/null @@ -1,21 +0,0 @@ -#!/usr/bin/env perl -# -# This dumps out the values needed to generate manpages and other artifacts -# which include the release version/date. -# -# See also: `secure/lib/libcrypto/Makefile.version`. - -use Cwd qw(realpath); -use File::Basename qw(dirname); -use Time::Piece; - -use lib dirname(dirname(realpath($0))); - -use configdata qw(%config); - -$OPENSSL_DATE = Time::Piece->strptime($config{"release_date"}, "%d %b %Y")->strftime("%Y-%m-%d"); - -$OPENSSL_VER = "$config{'major'}.$config{'minor'}.$config{'patch'}"; - -print("OPENSSL_VER=\t${OPENSSL_VER}\n"); -print("OPENSSL_DATE=\t${OPENSSL_DATE}\n"); diff --git a/secure/lib/libcrypto/Makefile.inc b/secure/lib/libcrypto/Makefile.inc index 4d5e9c68a1fe..5b281166df61 100644 --- a/secure/lib/libcrypto/Makefile.inc +++ b/secure/lib/libcrypto/Makefile.inc @@ -3,9 +3,6 @@ PACKAGE= openssl LIB_PACKAGE= -# OpenSSL version used for manual page generation -.include "Makefile.version" - LCRYPTO_SRC= ${SRCTOP}/crypto/openssl LCRYPTO_DOC= ${LCRYPTO_SRC}/doc @@ -15,10 +12,7 @@ CFLAGS+= -I${LCRYPTO_SRC}/providers/common/include CFLAGS+= -I${LCRYPTO_SRC}/providers/fips/include CFLAGS+= -I${LCRYPTO_SRC}/providers/implementations/include -.include "Makefile.common" +.SUFFIXES: .pc +.PATH.pc: ${LCRYPTO_SRC}/exporters -.for pcfile in ${PCFILES} -${pcfile}: ${pcfile}.in - sed -e 's,@openssl_ver@,${OPENSSL_VER},g' ${.ALLSRC} > ${.TARGET} -.endfor -CLEANFILES+= ${PCFILES} +.include "Makefile.common" diff --git a/secure/lib/libcrypto/Makefile.version b/secure/lib/libcrypto/Makefile.version deleted file mode 100644 index 81636b8adfe8..000000000000 --- a/secure/lib/libcrypto/Makefile.version +++ /dev/null @@ -1,2 +0,0 @@ -OPENSSL_VER= 3.5.4 -OPENSSL_DATE= 2025-09-30