Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 4 Jun 2026 19:49:38 +0000
From:      Shawn Webb <shawn.webb@hardenedbsd.org>
To:        Dag-Erling =?utf-8?B?U23DuHJncmF2?= <des@FreeBSD.org>
Cc:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org,  dev-commits-src-main@FreeBSD.org
Subject:   Re: git: eb3a0a74a069 - main - libarchive: Clean up the build configuration
Message-ID:  <3pdazz27eqlfeclrop6e6eotyrq2nltofy36nxbzq5tj2nrk6b@7notz67ugzfl>
In-Reply-To: <6a2179d9.33381.266325aa@gitrepo.freebsd.org>

index | next in thread | previous in thread | raw e-mail

[-- Attachment #1 --]
On Thu, Jun 04, 2026 at 01:12:57PM +0000, Dag-Erling Smørgrav wrote:
> The branch main has been updated by des:
> 
> URL: https://cgit.FreeBSD.org/src/commit/?id=eb3a0a74a069d0f294e1596504676459282bb308
> 
> commit eb3a0a74a069d0f294e1596504676459282bb308
> Author:     Dag-Erling Smørgrav <des@FreeBSD.org>
> AuthorDate: 2026-06-04 13:12:23 +0000
> Commit:     Dag-Erling Smørgrav <des@FreeBSD.org>
> CommitDate: 2026-06-04 13:12:23 +0000
> 
>     libarchive: Clean up the build configuration
>     
>     * Move settings duplicated in libarchive, bsdcat, bsdcpio, bsdtar, and
>       bsdunzip into libarchive's Makefile.inc.
>     
>     * Drop some CFLAGS that merely duplicated some of the contents of our
>       platform configuration header.
>     
>     MFC after:      1 week
>     Reviewed by:    mm
>     Differential Revision:  https://reviews.freebsd.org/D57307
> ---
>  lib/libarchive/Makefile       |  7 ++-----
>  lib/libarchive/Makefile.inc   | 16 +++++++++++-----
>  lib/libarchive/tests/Makefile |  8 ++++----
>  usr.bin/bsdcat/Makefile       | 17 ++++++-----------
>  usr.bin/bsdcat/tests/Makefile | 15 +++++++--------
>  usr.bin/cpio/Makefile         | 18 +++++-------------
>  usr.bin/cpio/tests/Makefile   | 15 +++++++--------
>  usr.bin/tar/Makefile          | 13 +++----------
>  usr.bin/tar/tests/Makefile    | 13 +++++++------
>  usr.bin/unzip/Makefile        | 14 ++++----------
>  usr.bin/unzip/tests/Makefile  | 13 +++++++------
>  11 files changed, 63 insertions(+), 86 deletions(-)
> 
> diff --git a/lib/libarchive/Makefile b/lib/libarchive/Makefile
> index 4e32dcf72341..c4b4bc67ba33 100644
> --- a/lib/libarchive/Makefile
> +++ b/lib/libarchive/Makefile
> @@ -1,7 +1,8 @@
>  .include <src.opts.mk>
>  
> +.include "Makefile.inc"
> +
>  PACKAGE=lib${LIB}
> -_LIBARCHIVEDIR=	${SRCTOP}/contrib/libarchive
>  
>  LIB=	archive
>  
> @@ -9,10 +10,6 @@ LIB=	archive
>  # It has no real relation to the libarchive version number.
>  SHLIB_MAJOR= 7
>  
> -CFLAGS+=	-I${.OBJDIR}
> -CFLAGS+=	-I${SRCTOP}/sys/contrib/zstd/lib
> -.include "Makefile.inc"
> -
>  .if ${MACHINE_ARCH:Marm*} != "" || ${MACHINE_ARCH:Mpowerpc*} != ""
>  NO_WCAST_ALIGN=	yes
>  .if ${MACHINE_ARCH:M*64*} == ""
> diff --git a/lib/libarchive/Makefile.inc b/lib/libarchive/Makefile.inc
> index 755a39ec01e8..33ab0085367f 100644
> --- a/lib/libarchive/Makefile.inc
> +++ b/lib/libarchive/Makefile.inc
> @@ -2,11 +2,17 @@
>  # them in sync we can get run-time crashes while running tests due to mismatches
>  # between structures such as archive_md5_ctx, etc.
>  
> -LIBADD=	z bz2 lzma bsdxml zstd
> -CFLAGS+=	-DHAVE_BZLIB_H=1 -DHAVE_LIBLZMA=1 -DHAVE_LZMA_H=1 \
> -		-DHAVE_ZSTD_H=1 -DHAVE_LIBZSTD=1 -DHAVE_ZSTD_compressStream=1 \
> -		-DHAVE_SYSCONF=1
> -CFLAGS+=	-DPLATFORM_CONFIG_H=\"${.CURDIR}/config_freebsd.h\"
> +_LIBARCHIVEDIR=	${SRCTOP}/contrib/libarchive
> +LIBARCHIVE_VERSION_ONLY_STRING!= \
> +	sed -n '/define.*ARCHIVE_VERSION_ONLY_STRING/{s,[^0-9.],,gp;q;}' \
> +	    ${LIBARCHIVEDIR}/libarchive/archive.h

Hey Dag-Erling,

This seems to have created a new warning during buildworld:

==== BEGIN BUILD LOG ====
===> lib/libarchive (all)
sed: /libarchive/archive.h: No such file or directory
make[5]: /usr/src/lib/libarchive/Makefile.inc:6: warning: Command "sed -n '/define.*ARCHIVE_VERSION_ONLY_STRING/{s,[^0-9.],,gp;q;}'  /libarchive/archive.h" exited with status 1
==== END BUILD LOG ====

Thanks,

-- 
Shawn Webb
Cofounder / Security Engineer
HardenedBSD

Signal Username:  shawn_webb.74
Tor-ified Signal: +1 (719) 756-1197 / activist_opsec.27
https://git.hardenedbsd.org/hardenedbsd/pubkeys/-/raw/master/Shawn_Webb/03A4CBEBB82EA5A67D9F3853FF2E67A277F8E1FA.pub.asc

[-- Attachment #2 --]
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEA6TL67gupaZ9nzhT/y5nonf44foFAmoh1ssACgkQ/y5nonf4
4fqjbQ/9GSxJmeBn+BPIocCjZJ3AhyxQ1qqQ9/35K9qFe9IOAgvvj8Bi6nkaslkH
IBebleF6CR0KqSzeRpaTeDsecym08sCV/2TacFi8yzzbeRD6j7mxc7OnRqUV7TmG
mFmAfNtnnHUsRKP8u3XLgu0it39oO0Q74BMiG2HKeWeFfR4VyMus2nF7BVXcNEnS
JKodf4g305w7SfmTIq+FfoLdetmEViPNywni9AurIYzbAyz01Mn1NOkSkvl/aDtk
ceNPMfVw8QlCc+RPSIUd791Pvo4DU+0GXtfJSL4IO1zqnBWYRC8/0358lIKb7OLx
CAGglcnJV4t8sCnhj8f3Ilzl8pq2mgBNRkDGOXUabElrN0JV8vM7pCBnFDq6pF2I
cpny/g9YfllDtQnhC5i2L2N1vLwoKEaMjY9gof5R5aTuQXW6iHje5i8pQ3fc9/t2
+jibhXHkpsGGLNUbhdeJzR1Y5NdENwFWLcxAGxe0hw41pcecgV37nkn4y7OeaBlv
/AMs4fEXFW2Jox2HGLhcq0kWklLwgqDIaDZ/7SbpJwizlFoKOsINydb1QF4j01bd
w28z7exd1bUvJ57R43E0NIFUIYhkZtQnpWhMjg4jQr+vhc1B5fpupZ8U0g3VJZn4
ZgwxTzKR61wBwmrKBVxRSkhJCt1b28gwcKqfIamy5/xdcNwewQc=
=zYF0
-----END PGP SIGNATURE-----
home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3pdazz27eqlfeclrop6e6eotyrq2nltofy36nxbzq5tj2nrk6b>