From patchwork Mon Aug 17 19:27:12 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vincent Fazio X-Patchwork-Id: 1346482 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=busybox.net (client-ip=140.211.166.133; helo=hemlock.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=xes-inc.com Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4BVkZy1f4Dz9sTK for ; Tue, 18 Aug 2020 05:27:38 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 848FC878CE; Mon, 17 Aug 2020 19:27:36 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id bPAvpizPEr1P; Mon, 17 Aug 2020 19:27:36 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by hemlock.osuosl.org (Postfix) with ESMTP id E04F3878E5; Mon, 17 Aug 2020 19:27:35 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 0C4821BF28F for ; Mon, 17 Aug 2020 19:27:35 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 014DF20361 for ; Mon, 17 Aug 2020 19:27:35 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id U-77I6C+uyln for ; Mon, 17 Aug 2020 19:27:32 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail.xes-mad.com (xes-mad.com [162.248.234.2]) by silver.osuosl.org (Postfix) with ESMTPS id CBD09204E4 for ; Mon, 17 Aug 2020 19:27:32 +0000 (UTC) Received: from vfazio1.xes-mad.com (vfazio1.xes-mad.com [10.52.16.140]) by mail.xes-mad.com (Postfix) with ESMTP id A4FE321355; Mon, 17 Aug 2020 14:27:31 -0500 (CDT) From: Vincent Fazio To: buildroot@buildroot.org Date: Mon, 17 Aug 2020 14:27:12 -0500 Message-Id: <20200817192712.32481-1-vfazio@xes-inc.com> X-Mailer: git-send-email 2.28.0 MIME-Version: 1.0 Subject: [Buildroot] [PATCH 1/1] package/ibm-sw-tpm2: fix glibc build errors X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Philippe Reynes , Vincent Fazio Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" From: Vincent Fazio In order to not have to define all architecture bitness variants in src/LibSupport.h to conditionally define RADIX_BITS, a patch was created to depend on LONG_BIT being defined via limits.h For glibc, LONG_BIT is behind a _XOPEN_SOURCE define guard so patch the makefile to define this macro as well as _DEFAULT_SOURCE. Defining _XOPEN_SOURCE requires _DEFAULT_SOURCE to be explicitly defined for builds to succeed as it is no longer impliclty defined when _XOPEN_SOURCE is defined. Fixes: http://autobuild.buildroot.net/results/bc145dd23c80a0660300766d0c114a00ed2e52b6/ http://autobuild.buildroot.net/results/1d84e70c30d4d0719274aa4f3edc01772beb24a3/ Fixes: 19bd089004 ("package/ibm-sw-tpm2: fix patch to address musl builds") Signed-off-by: Vincent Fazio --- package/ibm-sw-tpm2/0002-Add-required-defines.patch | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 package/ibm-sw-tpm2/0002-Add-required-defines.patch diff --git a/package/ibm-sw-tpm2/0002-Add-required-defines.patch b/package/ibm-sw-tpm2/0002-Add-required-defines.patch new file mode 100644 index 0000000000..c9e2f19bd2 --- /dev/null +++ b/package/ibm-sw-tpm2/0002-Add-required-defines.patch @@ -0,0 +1,11 @@ +--- a/src/makefile ++++ b/src/makefile +@@ -46,6 +46,8 @@ CCFLAGS = -Wall \ + -c -ggdb -O0 \ + -DTPM_POSIX \ + -D_POSIX_ \ ++ -D_DEFAULT_SOURCE \ ++ -D_XOPEN_SOURCE \ + -DTPM_NUVOTON + + # add this line for big endian platforms