From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id kSamCftFdF+xWwAA0tVLHw (envelope-from ) for ; Wed, 30 Sep 2020 08:46:51 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id 0HYOBftFdF8idAAAbx9fmQ (envelope-from ) for ; Wed, 30 Sep 2020 08:46:51 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id B3859940430 for ; Wed, 30 Sep 2020 08:46:50 +0000 (UTC) Received: from localhost ([::1]:34900 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kNXlB-0005DT-Nl for larch@yhetil.org; Wed, 30 Sep 2020 04:46:49 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:53184) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kNXkR-0005Ac-Pb for guix-patches@gnu.org; Wed, 30 Sep 2020 04:46:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:46544) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kNXkR-0008EV-Gh for guix-patches@gnu.org; Wed, 30 Sep 2020 04:46:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kNXkR-0005Gp-Eq for guix-patches@gnu.org; Wed, 30 Sep 2020 04:46:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#43591] [PATCH core-updates v2 2/5] build-system/gnu: Explicity declare the _FILE_OFFSET_BITS we want. Resent-From: Danny Milosavljevic Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 30 Sep 2020 08:46:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 43591 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 43591@debbugs.gnu.org Cc: Danny Milosavljevic Received: via spool by 43591-submit@debbugs.gnu.org id=B43591.160145556120205 (code B ref 43591); Wed, 30 Sep 2020 08:46:03 +0000 Received: (at 43591) by debbugs.gnu.org; 30 Sep 2020 08:46:01 +0000 Received: from localhost ([127.0.0.1]:58083 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kNXkO-0005Fi-UX for submit@debbugs.gnu.org; Wed, 30 Sep 2020 04:46:01 -0400 Received: from dd26836.kasserver.com ([85.13.145.193]:33118) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kNXkL-0005En-8F for 43591@debbugs.gnu.org; Wed, 30 Sep 2020 04:45:58 -0400 Received: from dayas.lan (80-110-126-103.cgn.dynamic.surfer.at [80.110.126.103]) by dd26836.kasserver.com (Postfix) with ESMTPSA id 365DD336344D; Wed, 30 Sep 2020 10:45:56 +0200 (CEST) From: Danny Milosavljevic Date: Wed, 30 Sep 2020 10:45:09 +0200 Message-Id: <20200930084512.31738-3-dannym@scratchpost.org> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200930084512.31738-1-dannym@scratchpost.org> References: <20200924141211.21649-1-dannym@scratchpost.org> <20200930084512.31738-1-dannym@scratchpost.org> MIME-Version: 1.0 Tags: patch Content-Transfer-Encoding: 8bit X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -1.7 (-) X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Spam-Score: 3.99 X-TUID: x/uOKudim8hb * guix/build/gnu-build-system.scm (set-FILE-OFFSET-BITS): New procedure. (%standard-phases): Add it. --- guix/build/gnu-build-system.scm | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/guix/build/gnu-build-system.scm b/guix/build/gnu-build-system.scm index d3347c9518..1a1c4627ab 100644 --- a/guix/build/gnu-build-system.scm +++ b/guix/build/gnu-build-system.scm @@ -60,6 +60,17 @@ See https://reproducible-builds.org/specs/source-date-epoch/." (setenv "SOURCE_DATE_EPOCH" "1") #t) +(define* (set-FILE-OFFSET-BITS #:rest _) + "Define '_FILE_OFFSET_BITS' using the C preprocessor. +This ensures that 32 bit and 64 bit user space both can handle results +returned from a 64 bit kernel. +See https://bugzilla.kernel.org/show_bug.cgi?id=205957." + ;; Setting CFLAGS here makes packages not default CFLAGS. + ;; Since glibc (and probably other packages) don't like being built without optimization, enable optimization here. + (setenv "CFLAGS" "-D_FILE_OFFSET_BITS=64 -g -O2") + (setenv "CXXFLAGS" "-D_FILE_OFFSET_BITS=64 -g -O2") + #t) + (define (first-subdirectory directory) "Return the file name of the first sub-directory of DIRECTORY." (match (scandir directory @@ -803,7 +814,7 @@ which cannot be found~%" ;; Standard build phases, as a list of symbol/procedure pairs. (let-syntax ((phases (syntax-rules () ((_ p ...) `((p . ,p) ...))))) - (phases set-SOURCE-DATE-EPOCH set-paths install-locale unpack + (phases set-SOURCE-DATE-EPOCH set-FILE-OFFSET-BITS set-paths install-locale unpack bootstrap patch-usr-bin-file patch-source-shebangs configure patch-generated-file-shebangs