From nobody Tue Jan 04 21:13:43 2022 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 EE359192E41F; Tue, 4 Jan 2022 21:13:43 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4JT52H4sWNz4X8k; Tue, 4 Jan 2022 21:13:43 +0000 (UTC) (envelope-from git@FreeBSD.org) 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 86DBE1FDD1; Tue, 4 Jan 2022 21:13:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 204LDhF6081281; Tue, 4 Jan 2022 21:13:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 204LDhsA081279; Tue, 4 Jan 2022 21:13:43 GMT (envelope-from git) Date: Tue, 4 Jan 2022 21:13:43 GMT Message-Id: <202201042113.204LDhsA081279@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: f3d7ace4b235 - main - file: Turns out we need xlocal.h protection 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: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f3d7ace4b235422e5ccff0315f2965ac935241d8 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1641330823; 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=yVWLNDQx00SS/+aPWUffCY2OqalIhgX8zPNzBxNKC8Y=; b=QOKTNBHCi679OyxOaCFe6EUr9omFLQ/CNIltMKBsljpOUrxVhtB6gAV6noj6Gn9oZOOegw h+X5EX7CLRBzn/P8Go7JpiFqdqRycz5J8LEXQoyDLTNuAHa/bfu6Ouig8gV8HHpDvzT3uK C2LPC2CqIl33EBSdHzTh0f24BSNcsT9/mmhziLwRE7A/iHJdmkTJ9MHYPf91W0p2XjtnPZ M2rRTV22klYhcR/8Hkb4b++bG6RWlx0M99I7FwLwRL4kNSFiAedbEKEdp8xBpId+wvR4RQ HFV1QqW71NGfTZ/vQIWA2+SJgKJVkeAfwvD7DpQikLvtlMY5vouGR7XwU4THgw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1641330823; a=rsa-sha256; cv=none; b=re55ea0uZ+JY/D8WeZIVg8JJXErdmFPCzDQTx78CmCCgfDuMyHO5s4yOnAcoKOFu9rtWp6 vMFf3qBSXqM4cNW+mSnRTg+EfOKmNM5Wv8HH86pnYxd6dj019Pts6Dv/kSB4L7C/i3ru1B z++EAMmUGnKz990Oxh8YiKXR5l+A7Uufj7F4zP3SFLgfN1WtX0P6U3gtaKSaWqu6GZ7gqX DZPiGsbuFpco6EIprKWpAlYQD7beYalkMvdAru/w+Q7ZjiYJZwRX/Qh507Jnx5M7pjY/+U oat+exnX7o+gJYRAhjdVYQ2eEs87wR3hbfYelXY3rAclWiEinIkMyxrN++xORw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=f3d7ace4b235422e5ccff0315f2965ac935241d8 commit f3d7ace4b235422e5ccff0315f2965ac935241d8 Author: Warner Losh AuthorDate: 2022-01-04 21:12:44 +0000 Commit: Warner Losh CommitDate: 2022-01-04 21:12:59 +0000 file: Turns out we need xlocal.h protection It turns out that we still need xlocal.h protection for when we're cross building on Linux. Linux doesn't have this file, but os/x does. Before, we'd assume we didn't have it, like old FreeBSD, when cross compiling. After the latest update, all that code was removed so cross compiling needs to be handled separaetly. Do so by defining HAVE_XLOCALE_H only when we're not building on linux. This allows us to build the mkmagic build tool needed to build file(1). Sponsored by: Netflix Reviewed by: jrtc27 Differential Revision: https://reviews.freebsd.org/D33741 --- lib/libmagic/config.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/libmagic/config.h b/lib/libmagic/config.h index 816087e19b5d..35d090dd48b9 100644 --- a/lib/libmagic/config.h +++ b/lib/libmagic/config.h @@ -254,7 +254,9 @@ #define HAVE_WORKING_VFORK 1 /* Define to 1 if you have the header file. */ +#ifndef __linux__ /* Cross building tools build with glibc on linux */ #define HAVE_XLOCALE_H 1 +#endif /* Define to 1 if you have the header file. */ #define HAVE_ZLIB_H 1