From patchwork Thu Jun 5 05:08:54 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andy Tai X-Patchwork-Id: 43021 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id BAC3727BC49; Thu, 5 Jun 2025 06:10:21 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-6.4 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL,RCVD_IN_VALIDITY_SAFE, SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 91EFF27BC4A for ; Thu, 5 Jun 2025 06:10:18 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1uN2rh-0004FE-90; Thu, 05 Jun 2025 01:10:09 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1uN2re-0004DO-Qr for guix-patches@gnu.org; Thu, 05 Jun 2025 01:10:06 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1uN2re-00023B-7v for guix-patches@gnu.org; Thu, 05 Jun 2025 01:10:06 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:From:To:In-Reply-To:References:Subject; bh=pxQLfBkTCG0sW+QKuMoX0lWJuirSKUMl2w6RpI7Ldhw=; b=MgDwuTTiljiP3OViO+YMMs1866BHE2Tw6p7TMf/4Dzl+BfOQFpncpd9T4yHu3qdcViCpHWY2uZ6CXpPU0W4XcRlyq2PM/8TsZY2ZsvWopYboyLpyeT3ZFjmbzsgZbLVYtD9PT6o7qhQ5MxPiI9kAVr87/m3/iBbJPB3xKFrCvPU6Da8+gJ3H0ZrO7BJwmPDBFzar+DKQVNCWiqT7iErFRHMuxm5Z6L2rnscPIG13ayk6UEVCjyIcdhr06jAVucaH2ilJqQI1K+JnpRS6VvinATy/pTzjsdNyuSQD09lIckyfD3NUPKsgj9Zk/ynRQEXpDGCpS01A6AhhtTT5vnxiGw==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1uN2rb-00047n-3g; Thu, 05 Jun 2025 01:10:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#75274] [PATCH core-packages-team v4] gnu: bc: Update to 1.08.2. References: In-Reply-To: Resent-From: Andy Tai Original-Sender: "Debbugs-submit" Resent-CC: andreas@enge.fr, bavier@posteo.net, sharlatanus@gmail.com, guix-patches@gnu.org Resent-Date: Thu, 05 Jun 2025 05:10:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 75274 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 75274@debbugs.gnu.org, andreas@enge.fr, sharlatanus@gmail.com, bavier@posteo.net Cc: Andy Tai , Andreas Enge , Eric Bavier , Sharlatan Hellseher X-Debbugs-Original-Xcc: Andreas Enge , Eric Bavier , Sharlatan Hellseher Received: via spool by 75274-submit@debbugs.gnu.org id=B75274.174910015415409 (code B ref 75274); Thu, 05 Jun 2025 05:10:02 +0000 Received: (at 75274) by debbugs.gnu.org; 5 Jun 2025 05:09:14 +0000 Received: from localhost ([127.0.0.1]:57120 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1uN2qn-00040N-0v for submit@debbugs.gnu.org; Thu, 05 Jun 2025 01:09:14 -0400 Received: from mail-pf1-x42c.google.com ([2607:f8b0:4864:20::42c]:60728) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1uN2qf-0003yO-34 for 75274@debbugs.gnu.org; Thu, 05 Jun 2025 01:09:10 -0400 Received: by mail-pf1-x42c.google.com with SMTP id d2e1a72fcca58-742af848148so411198b3a.1 for <75274@debbugs.gnu.org>; Wed, 04 Jun 2025 22:09:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1749100138; x=1749704938; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:sender:from:to:cc:subject:date:message-id:reply-to; bh=pxQLfBkTCG0sW+QKuMoX0lWJuirSKUMl2w6RpI7Ldhw=; b=R68ttZVEs1VrTj2wMSoLeH5Idqz32xmTExsSSIEtott3+x8O5gDK2eagMN56DC/bRL 9Clfg+4AwpMwfvgtZ2AKkZHKbzvjEU7YFzWRyy+VsqPNgAfBpQ429b6I6g3M3EaI/gRA 6JFOS2s4+faE39sdS04/UvjnJxO9/LSBSBAdlbzo1IZfn/MRODAIyhbYArZpBixHPVUh PsLcxtbEBwYgvqZGen0g/kse/9AKWkbEWWZII0E90e1e4Gu7YsohzIEgvxyJ7mmUxSw4 5NmUgKTZP0ZyMB1mgbu1kvTF+ji9cxTcSiWPxygGe7jb7k7QZZbITBHUS2Gu1tKu1vyi Eg3Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1749100138; x=1749704938; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:sender:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=pxQLfBkTCG0sW+QKuMoX0lWJuirSKUMl2w6RpI7Ldhw=; b=pxN0+h5z9PMihoXrPBVPI4xa2WFk25VF0MtdJun/qm1ydukI544GSQ+NEIOGv3kvQr vD0VO2neS1Fnvn3K9gaB84TnnPJ99YNWm0mp8CuIjgfNwb47Um1yuKZPKRXScE7mmY9P q+cgfNsRC8BSQb21Etd3qylbjXPTbCppxg0vVjFMKbfAKdpwAvZkZIr1EBagG23DDiJF PLWId4SHADFct+bhtuHxZxHNi9uzYy/zv5P6t2/GGClT5Tim/xLId5DNAYjPyrhedrI1 QBHSDXF4ejBTN9W0CUjZZeiicDq2Qc0HA57yRg5HQVc6eCSSjcUYJlCZQoQV2+Hqt509 pjzw== X-Gm-Message-State: AOJu0YzayBqms+EoIkZJ/6QG9hYQyW7tVEQhg8p1ItZRIGvZId6TCyB3 UPgwkRpMmwC8ePTGGrjRRsG5jy6js/g2DncrBD6cMb/b2Ndj1NjQa9hG3RCBBBGJ X-Gm-Gg: ASbGncsjfP/bpaq8rrbVj3yp5zf+98LWV/D++WQq/6iyGvXyyGs8ZvMVB3fxSdxMuHA 663D/Qn6QwJEXURkvy+rkiTkgb1R2pMYh2ciizlup9QZLG7taLA7NAAhM5AOXGGCOc7m9ROeE6o 1kvbgAl3ITGdepii6PmAQQUcYkeNsTVTdksysoIgsXw1oxSNQdXnAa8Pb1OMNvjyTdADmreFlJg xiEUr8EReA5jSiQY4YgSeFx5OfnBF9BJP48bLqWHAVQNOLkcJwr4/Ua6wAvSzks2pAr5NnVkAHL dipYIiB+W2v8hFePLMXgAwg9hq4RCgMdJT6vQVgwe1+dM+w= X-Google-Smtp-Source: AGHT+IHOcrOSEf7lv7YE2F17Gm12/yzL/zJyemx3ze0OU9t9xj4NOXSqVGr7+klLK5JkDcH0sa/Z6g== X-Received: by 2002:a05:6a21:9991:b0:216:19c1:1f5d with SMTP id adf61e73a8af0-21d22bcdeddmr8034601637.3.1749100138255; Wed, 04 Jun 2025 22:08:58 -0700 (PDT) Received: from DEskMiniX300.. ([172.98.218.160]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-747afe96825sm12029317b3a.36.2025.06.04.22.08.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 04 Jun 2025 22:08:57 -0700 (PDT) From: Andy Tai Date: Wed, 4 Jun 2025 22:08:54 -0700 Message-ID: <3add1cfe16d0775a0d5a2f70c34a95abb45279b6.1749099968.git.atai@atai.org> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/algebra.scm (bc): Update to 1.08.2. [source](origin): Remove patch. * gnu/packages/patches/bc-fix-cross-compilation.patch: Delete. * gnu/local.mk: Unregister deleted file. Change-Id: Iada592d2deeeec91f875306a0fb6f8c4056ccfad --- gnu/local.mk | 1 - gnu/packages/algebra.scm | 9 +- .../patches/bc-fix-cross-compilation.patch | 189 ------------------ 3 files changed, 4 insertions(+), 195 deletions(-) delete mode 100644 gnu/packages/patches/bc-fix-cross-compilation.patch base-commit: c06805c59fce8ff951fe9e24029daa41caf07de9 diff --git a/gnu/local.mk b/gnu/local.mk index 0d9711b866..c95555c257 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1039,7 +1039,6 @@ dist_patch_DATA = \ %D%/packages/patches/bash-linux-pgrp-pipe.patch \ %D%/packages/patches/bastet-change-source-of-unordered_set.patch \ %D%/packages/patches/bazaar-CVE-2017-14176.patch \ - %D%/packages/patches/bc-fix-cross-compilation.patch \ %D%/packages/patches/bdb-5.3-atomics-on-gcc-9.patch \ %D%/packages/patches/biboumi-cmake-ignore-git.patch \ %D%/packages/patches/brightnessctl-elogind-support.patch \ diff --git a/gnu/packages/algebra.scm b/gnu/packages/algebra.scm index 41401ff2a7..c1ba022d41 100644 --- a/gnu/packages/algebra.scm +++ b/gnu/packages/algebra.scm @@ -714,19 +714,18 @@ (define-public gmp-ecm (define-public bc (package (name "bc") - (version "1.07.1") + (version "1.08.2") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/bc/bc-" version ".tar.gz")) (sha256 (base32 - "0amh9ik44jfg66csyvf4zz1l878c4755kjndq9j0270akflgrbb2")) - (patches (search-patches "bc-fix-cross-compilation.patch")))) + "11jzg23ks39k58bnb5y55wxqqz6h534ys5900hz6axcp8bn0yixf")))) (build-system gnu-build-system) (native-inputs (list automake autoconf ed flex readline texinfo)) (inputs - (list readline)) + (list readline ncurses)) (arguments '(#:configure-flags (list "--with-readline") @@ -742,7 +741,7 @@ (define-public bc an interactive environment for evaluating mathematical statements. Its syntax is similar to that of C, so basic usage is familiar. It also includes \"dc\", a reverse-polish calculator.") - (license license:gpl2+))) + (license license:gpl3+))) ;; The original kiss-fft does not have a complete build system and does not ;; build any shared libraries. This is a fork used by Extempore. diff --git a/gnu/packages/patches/bc-fix-cross-compilation.patch b/gnu/packages/patches/bc-fix-cross-compilation.patch deleted file mode 100644 index 04f2c92abf..0000000000 --- a/gnu/packages/patches/bc-fix-cross-compilation.patch +++ /dev/null @@ -1,189 +0,0 @@ -Patch adapted from Nix. -Upstream-status: Submitted to bug-bc@gnu.org. - -diff --git a/bc/Makefile.am b/bc/Makefile.am -index d9d412e..13f2b1e 100644 ---- a/bc/Makefile.am -+++ b/bc/Makefile.am -@@ -8,7 +8,7 @@ EXTRA_DIST = bc.h bcdefs.h const.h fix-libmath_h global.h libmath.b proto.h \ - sbc.y - noinst_HEADERS = libmath.h - --DISTCLEANFILES = sbc sbc.c sbc.h libmath.h -+DISTCLEANFILES = fbc sbc sbc.c sbc.h libmath.h - - MAINTAINERCLEANFILES = Makefile.in bc.c bc.h scan.c \ - bc.y bcdefs.h const.h execute.c fix-libmath_h \ -@@ -17,6 +17,7 @@ MAINTAINERCLEANFILES = Makefile.in bc.c bc.h scan.c \ - - AM_CPPFLAGS = -I$(srcdir) -I$(srcdir)/../h - LIBBC = ../lib/libbc.a -+LIBBC_HOST = ../lib/libbc_host.a - LIBL = @LEXLIB@ - LDADD = $(LIBBC) $(LIBL) @READLINELIB@ - -@@ -29,15 +30,22 @@ $(PROGRAMS): libmath.h $(LIBBC) - scan.o: bc.h - global.o: libmath.h - --fbcOBJ = main.o bc.o scan.o execute.o load.o storage.o util.o warranty.o -+%.o_host: CC := $(CC_FOR_BUILD) -+%.o_host: %.c -+ $(COMPILE) -c -o $@ $< - --libmath.h: libmath.b $(fbcOBJ) $(LIBBC) -- echo '{0}' > libmath.h -- $(MAKE) global.o -- $(LINK) -o fbc $(fbcOBJ) global.o $(LIBBC) $(LIBL) $(READLINELIB) $(LIBS) -- ./fbc -c $(srcdir)/libmath.b libmath.h -+fbcOBJ = $(addsuffix _host,\ -+ main.o bc.o scan.o execute.o load.o storage.o util.o warranty.o) -+ -+global_host.c: global.c -+ sed 's/#include "libmath.h"/{0}/' $< > $@ -+ -+fbc: $(fbcOBJ) global_host.o_host $(LIBBC_HOST) $(LIBS) -+ $(CC_FOR_BUILD) $(LIBL) $(READLINELIB) -o $@ $^ -+ -+libmath.h: libmath.b fbc $(LIBBC_HOST) -+ ./fbc -c $(srcdir)/libmath.b < /dev/null > libmath.h - $(srcdir)/fix-libmath_h -- rm -f ./fbc ./global.o - - sbcOBJ = main.o sbc.o scan.o execute.o global.o load.o storage.o util.o \ - warranty.o -diff --git a/configure.ac b/configure.ac -index fc74573..5cabb73 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -20,6 +20,7 @@ m4_define([dc_version], 1.4.1) - - AC_INIT([bc],[bc_version]) - AC_CONFIG_SRCDIR(doc/bc.1) -+AC_CONFIG_MACRO_DIR([m4]) - AM_INIT_AUTOMAKE([dist-bzip2]) - AC_CONFIG_HEADERS(config.h) - -@@ -35,6 +36,7 @@ AC_DEFINE([DC_COPYRIGHT], - [Define the dc copyright line.]) - - AC_PROG_CC -+AX_CC_FOR_BUILD - AC_USE_SYSTEM_EXTENSIONS - - AM_PROG_LEX -diff --git a/lib/Makefile.am b/lib/Makefile.am -index ec4bf59..24c9f42 100644 ---- a/lib/Makefile.am -+++ b/lib/Makefile.am -@@ -1,5 +1,5 @@ - ## Process this file with automake to produce Makefile.in --noinst_LIBRARIES = libbc.a -+noinst_LIBRARIES = libbc.a libbc_host.a - - AM_CPPFLAGS = -I. -I.. -I$(srcdir)/../h - -@@ -7,8 +7,6 @@ libbc_a_SOURCES = getopt.c getopt1.c vfprintf.c number.c - - DEFS = @DEFS@ $(DEFSADD) - --AM_CFLAGS = @CFLAGS@ -- - MAINTAINERCLEANFILES = Makefile.in number.c - CLEANFILES = testmul specialnumber muldigits.h - -@@ -24,3 +22,11 @@ testmul: testmul.o number.o - - specialnumber: newnumber.o - cp newnumber.o number.o -+ -+%.o_host: CC := $(CC_FOR_BUILD) -+%.o_host : %.c -+ $(COMPILE) -c -o $@ $< -+ -+libbc_host.a : $(addsuffix _host,$(libbc_a_OBJECTS)) -+ ar cru $@ $+ -+ ranlib $@ -diff --git a/m4/cc_for_build.m4 b/m4/cc_for_build.m4 -new file mode 100644 -index 0000000..c62ffad ---- /dev/null -+++ b/m4/cc_for_build.m4 -@@ -0,0 +1,77 @@ -+# =========================================================================== -+# https://www.gnu.org/software/autoconf-archive/ax_cc_for_build.html -+# =========================================================================== -+# -+# SYNOPSIS -+# -+# AX_CC_FOR_BUILD -+# -+# DESCRIPTION -+# -+# Find a build-time compiler. Sets CC_FOR_BUILD and EXEEXT_FOR_BUILD. -+# -+# LICENSE -+# -+# Copyright (c) 2010 Reuben Thomas -+# Copyright (c) 1999 Richard Henderson -+# -+# This program is free software: you can redistribute it and/or modify it -+# under the terms of the GNU General Public License as published by the -+# Free Software Foundation, either version 3 of the License, or (at your -+# option) any later version. -+# -+# This program is distributed in the hope that it will be useful, but -+# WITHOUT ANY WARRANTY; without even the implied warranty of -+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General -+# Public License for more details. -+# -+# You should have received a copy of the GNU General Public License along -+# with this program. If not, see . -+# -+# As a special exception, the respective Autoconf Macro's copyright owner -+# gives unlimited permission to copy, distribute and modify the configure -+# scripts that are the output of Autoconf when processing the Macro. You -+# need not follow the terms of the GNU General Public License when using -+# or distributing such scripts, even though portions of the text of the -+# Macro appear in them. The GNU General Public License (GPL) does govern -+# all other use of the material that constitutes the Autoconf Macro. -+# -+# This special exception to the GPL applies to versions of the Autoconf -+# Macro released by the Autoconf Archive. When you make and distribute a -+# modified version of the Autoconf Macro, you may extend this special -+# exception to the GPL to apply to your modified version as well. -+ -+#serial 3 -+ -+dnl Get a default for CC_FOR_BUILD to put into Makefile. -+AC_DEFUN([AX_CC_FOR_BUILD], -+[# Put a plausible default for CC_FOR_BUILD in Makefile. -+if test -z "$CC_FOR_BUILD"; then -+ if test "x$cross_compiling" = "xno"; then -+ CC_FOR_BUILD='$(CC)' -+ else -+ CC_FOR_BUILD=gcc -+ fi -+fi -+AC_SUBST(CC_FOR_BUILD) -+# Also set EXEEXT_FOR_BUILD. -+if test "x$cross_compiling" = "xno"; then -+ EXEEXT_FOR_BUILD='$(EXEEXT)' -+else -+ AC_CACHE_CHECK([for build system executable suffix], bfd_cv_build_exeext, -+ [rm -f conftest* -+ echo 'int main () { return 0; }' > conftest.c -+ bfd_cv_build_exeext= -+ ${CC_FOR_BUILD} -o conftest conftest.c 1>&5 2>&5 -+ for file in conftest.*; do -+ case $file in -+ *.c | *.o | *.obj | *.ilk | *.pdb) ;; -+ *) bfd_cv_build_exeext=`echo $file | sed -e s/conftest//` ;; -+ esac -+ done -+ rm -f conftest* -+ test x"${bfd_cv_build_exeext}" = x && bfd_cv_build_exeext=no]) -+ EXEEXT_FOR_BUILD="" -+ test x"${bfd_cv_build_exeext}" != xno && EXEEXT_FOR_BUILD=${bfd_cv_build_exeext} -+fi -+AC_SUBST(EXEEXT_FOR_BUILD)])dnl