From patchwork Sun Sep 21 15:33:47 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dario Binacchi X-Patchwork-Id: 4338 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-ed1-f70.google.com (mail-ed1-f70.google.com [209.85.208.70]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id CAEAF3F18B for ; Sun, 21 Sep 2025 17:33:56 +0200 (CEST) Received: by mail-ed1-f70.google.com with SMTP id 4fb4d7f45d1cf-62f9cfb8075sf5439599a12.2 for ; Sun, 21 Sep 2025 08:33:56 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1758468836; cv=pass; d=google.com; s=arc-20240605; b=a1i4vSXyOBYSQjWewinBJ4rF+VM4fzD0KCwu2vjgGnrgsW46+h2bdfdNtFgO6ilkCC 5gEUJCXXJIpccC2dlHS4VnxbXU1ZdG8FydlqZzEyqVqtwRPpO1k8kuDVx2cVm31Rl7NJ VVh9G5c+gYMXj9o3csPCD7R1eE4TbzB6foeYAT3BoZXnHsb+EKM0gsGBKl6pKXdSH24s e2p52P6RYH3Zgxl5v5x5kniiq9Z47LuM1kFo/YEeUXkG9LwkKGMLezCTUIAVyBPV8r8y 5EX5h34Qd/jatClScDBOeZxskY0ME8J1PH/tEufzMKbemNydgvVmbeNj/0OCO5J0cp/g OD2Q== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=NoA57W40yVN/OVqDitHwgbukKel2Qs96nw3fSWUOXho=; fh=uOnRyhxi97QkogqRFKEAqm/QTFcbL8i8Bbq/VnYtzW0=; b=Tepv902Jh7znQpERtFjFHKdNEZiy0Vvj0k6GlKx7lHLf84OOoSM8xLMUdIb3IYtfY6 pPoBsieaSwJLxjTPSWHe8PYBtI1Qjc10KpTxRrMDoavZfSt+Ts2AOOHk9WpNODHV3Wg4 4L6Rg/k/82T4QXIFE0LSj3eDA8Top6SQDztOLrZpeaQRAd7FeOVhkC7grvSQ44NBjiNU 2wT+x5zi1eJVulMD9waH+kQs+8zgaFN3VZjjXNuMab7CG4Gcv+XKSv8mMiqULJdRO7az Bf2ICelLM3POTH9LqMF/P83HvapY8fsRjuIRuRWbaGwpUYJQgRQL2Zeof7QGIoXiFfQv IOYg==; darn=patchwork.amarulasolutions.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=mEdQA5bJ; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com; dara=pass header.i=@amarulasolutions.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; t=1758468836; x=1759073636; darn=patchwork.amarulasolutions.com; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:x-original-authentication-results :x-original-sender:content-transfer-encoding:mime-version:message-id :date:subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=NoA57W40yVN/OVqDitHwgbukKel2Qs96nw3fSWUOXho=; b=WYl8ciazHG9E4vSuN9yHDAb4kCCL69Zo1FgCccMyj1kcJ9fyda/UhbPRbZO6lERHUz VFI4NTL5uvEoQZgPFo5oAZXaMpNMzjIx99p+P2E706bB/BJxcaf+5V0ajMLtZIrGJv1W 3zjDMlCAF1J0Ck0aeVUXGKRFxttVEbfCKKyvc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1758468836; x=1759073636; h=list-unsubscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence :x-original-authentication-results:x-original-sender :content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-beenthere:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=NoA57W40yVN/OVqDitHwgbukKel2Qs96nw3fSWUOXho=; b=WsdhmvcKoVqko9beRUcKE5T2f/m0CwVSIbBXI2pEqvrOW/gN3og8Ju3ybwpkISBTkH fnLVSMvK4mEmOJOQZwzPlCLrCjJXarnaEZ3WqbKsD/pue8qrTwn5x8ZgiMctXVgyYPvX lbZZKP/gsT0tqLlctk8DI23oQSO9+1/Z5Cg63TuOizyH13C3l5q1AGPOtJyYSX7niCQm CFIfucbyDvBY3pRa1IK6Lsb6iBfwivzFlfeGmqi34wFWo/Ua6hjv+eBDTlXGE7LRrt3n qOPNavFevBlUhAoa26Eba+aIy5wwSznRg/VnMnpj3JCXbQQDj4f5L/DIU5R5Nb3YtHEL ZELw== X-Forwarded-Encrypted: i=2; AJvYcCW3xlxBDv4G57vMnhvUhvTbesSWYnxPNV6nIqKBTQY0OLYPMn83AOFFLJCOXS8Dfc//hWGczduv1UcbEs5J@patchwork.amarulasolutions.com X-Gm-Message-State: AOJu0YztlW8l5Ik55RDemQ2SONu3Ms5fSYk+TDWez3e7R/Yo3XMu131m EaBuguDfrqfq1HUg8eu8Ylth6T5ivEy20v2bxDM9G+auo86hW6pcbNk+oVKlM1r09hdMkQ== X-Google-Smtp-Source: AGHT+IFQKAmCHaTJ7FQ+MX++3i371sM+N+JQvKbylwA9vjcfjcBsYk9j7CFMu8L61xz1QFWE1hCFJQ== X-Received: by 2002:a05:6402:2344:b0:62f:3135:cafc with SMTP id 4fb4d7f45d1cf-62fbfeac925mr8940800a12.0.1758468836092; Sun, 21 Sep 2025 08:33:56 -0700 (PDT) X-BeenThere: linux-amarula@amarulasolutions.com; h=ARHlJd67mxsPDG5LyxzfkPLQlMb3/awLINJurZAZC3DXUrfAzQ== Received: by 2002:aa7:d653:0:b0:632:6c91:4378 with SMTP id 4fb4d7f45d1cf-6326c9149d7ls840685a12.1.-pod-prod-04-eu; Sun, 21 Sep 2025 08:33:53 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCViKbubkIoAga7yi0v4SU/ichNI0KygfOZqAzxmQY5T/ZjzZ/9Qvw74STJIoR2GrHmeWWpo14NiNqHsXJhE@amarulasolutions.com X-Received: by 2002:a17:907:6ea9:b0:b0c:6cae:51f5 with SMTP id a640c23a62f3a-b24f3e5fdb6mr1064251766b.43.1758468833513; Sun, 21 Sep 2025 08:33:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1758468833; cv=none; d=google.com; s=arc-20240605; b=XVS1pMQvTTIo5i/SSsregqCsLmbTwN5lNhMHoJdxn+ZzscdWEMybrjX5QbxT40DoUl 3Riio0E1yibBrWJfqlg5O9LY7GQJ3hK/4FiWEg4h4kEGEDS7jd86m9hJU/UQE57B5dFr 84bUPJYRS7jE73lscDPlmt6uxuA1R16JLd9gPSkQqxGLNM+yHC4wtrwBuu/ZSaOhj90G VhnLiGDbLjRhTSS71R09JMG6IQ8/yWF75ZrP6U4pkaJjAETZwJGZoU9RmeTsnNyHlwZ/ EYveKRWjMlnSCXFRBp3sonW2742wxpCHX5jC6SU6RMb8myUVkSHXllqGJhXfpY7An+QX OElw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:dkim-signature; bh=9WXjTmtIjd/oN+f+BP0pYbmG0MbtdncWyK69r+zN9Ts=; fh=LO3F6KE5y6jnmZLJ8DzHcHHouxUr5jAOqyTK41wYRGo=; b=V2pgUXjt68Emo+PtrcPdh+RQHFAmRHf7njHVfpfaZqCnLcmkt/bRnCVJKBFi/GC9FK 6QwPNZl3UMPresqdN3V8MCu36qxXh5alLK4dpN13/2nTaW5Y96RddV1lGiVKcx++H/V6 J15/WUlzF6/DNJN0nU/IIUE+kK3DzanqPO8/APnBabjUVFOWWcDTZdEHXIHKAzVE3EKx PiVr6BLID9+I5mSXVs8N+crbUg6OlUpqiKZOYrKzr2cIHa7+zc9RNJm3yLaw0M+RDvfK YpYoVuQMpv8fLNaUztR+v3+68NcMMuP5dfXsgNwKdf6CC4k78W+It9Ej0t5Fy3AMTrYH 3zdg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=mEdQA5bJ; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com; dara=pass header.i=@amarulasolutions.com Received: from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id a640c23a62f3a-b27e054f94esor138203466b.6.2025.09.21.08.33.53 for (Google Transport Security); Sun, 21 Sep 2025 08:33:53 -0700 (PDT) Received-SPF: pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) client-ip=209.85.220.41; X-Forwarded-Encrypted: i=1; AJvYcCXGwvrlCjfnYRNF7tcza6W/0RkQcY5JYRvQVH/cy2aaRePhQFb2kzX8vcc6mZuuL6axuHPYEAUpLIR+Vbj2@amarulasolutions.com X-Gm-Gg: ASbGncvQCZog08QBMuDWpApRIYdw1kc271Kp8X4CVQaIhU8KXWOl0HM+jbDQIbhUG5W gpb91973v9oeRVTIyReWcqnCWH8tJagi4LTARPjAy5WwbAljcbzel11O2mODZi/aF5iMtuIfMtP y8pqCXggEUhmRPKporqQARaHCLAp4LuFHAh9pWoyYCyzI9QuumLIIgGzXfxe5n8DaGoBPOQnS08 XjkMs/5K0XvKycvNxP68Gu3d3krljkm4NQ1V2AKQz2DtWJuxFUoR9BF377hj3O3cC31sfnFfTIx AFDBJDbSAa07Dbmi7AHQ/T0dHr41fIeiXgoGgLyfhlF6FsiNoXTU0gA2gBZcIdKMKXS6fcmccIy tYqbdmCn1WCrFgDTAgFDaYtrn1LGMP/SlmAlrDTFuP8Q+qC0NRd/IC+xzYtglteKhYUqyz48glC qMZm9nR628t/yXCAfbNTkAlgbOQPAATMNyEv1mrbJ91OUmhI1csppt/vjG2T+AQcox X-Received: by 2002:a17:907:1b0f:b0:b08:c921:1f24 with SMTP id a640c23a62f3a-b24ee03827dmr982671166b.22.1758468832748; Sun, 21 Sep 2025 08:33:52 -0700 (PDT) Received: from dario-ThinkPad-T14s-Gen-2i.homenet.telecomitalia.it (host-82-56-38-125.retail.telecomitalia.it. [82.56.38.125]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-b1fd14d5f56sm904831666b.74.2025.09.21.08.33.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 21 Sep 2025 08:33:52 -0700 (PDT) From: Dario Binacchi To: buildroot@buildroot.org Cc: Dario Binacchi , linux-amarula@amarulasolutions.com Subject: [PATCH v2 1/2] package/bc: bump to 1.08.2 Date: Sun, 21 Sep 2025 17:33:47 +0200 Message-ID: <20250921153348.2636830-1-dario.binacchi@amarulasolutions.com> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 X-Original-Sender: dario.binacchi@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=mEdQA5bJ; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com; dara=pass header.i=@amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Update patch 2 and drop patch 3 and 4 because integrated in the new version. Release notes: https://mail.gnu.org/archive/html/info-gnu/2025-01/msg00000.html https://lists.gnu.org/archive/html/info-gnu/2025-01/msg00002.html https://lists.gnu.org/archive/html/info-gnu/2025-05/msg00006.html Signed-off-by: Dario Binacchi --- Changes v1 -> v2: - Re-add and update patch 2 .checkpackageignore | 2 - ...and-write-errors-on-input-and-output.patch | 513 ++++-------------- .../0003-dc-fix-exit-code-of-q-command.patch | 46 -- package/bc/0004-no-gen-libmath.patch | 97 ---- package/bc/bc.hash | 2 +- package/bc/bc.mk | 6 +- 6 files changed, 120 insertions(+), 546 deletions(-) delete mode 100644 package/bc/0003-dc-fix-exit-code-of-q-command.patch delete mode 100644 package/bc/0004-no-gen-libmath.patch diff --git a/.checkpackageignore b/.checkpackageignore index f5e550736cf5..0cf94748c685 100644 --- a/.checkpackageignore +++ b/.checkpackageignore @@ -246,8 +246,6 @@ package/bash/0001-input.h-add-missing-include-on-stdio.h.patch lib_patch.Upstrea package/bash/0002-parse.y-fix-compilation-for-non-multibyte-builds.patch lib_patch.Upstream package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch lib_patch.Upstream package/bc/0002-notice-read-and-write-errors-on-input-and-output.patch lib_patch.Upstream -package/bc/0003-dc-fix-exit-code-of-q-command.patch lib_patch.Upstream -package/bc/0004-no-gen-libmath.patch lib_patch.Upstream package/bcache-tools/0001-Don-t-inline-crc64-for-gcc-5-compatability.patch lib_patch.Upstream package/bctoolbox/0001-Fix-Libs.private-flags-for-mbedtls.patch lib_patch.Upstream package/bcusdk/0002-eibd-fix-endless-recursion-when-using-USB-backends.patch lib_patch.Upstream diff --git a/package/bc/0002-notice-read-and-write-errors-on-input-and-output.patch b/package/bc/0002-notice-read-and-write-errors-on-input-and-output.patch index 7649ae8c4f5b..c85564764aba 100644 --- a/package/bc/0002-notice-read-and-write-errors-on-input-and-output.patch +++ b/package/bc/0002-notice-read-and-write-errors-on-input-and-output.patch @@ -1,4 +1,4 @@ -From af96fb92052c307818eefa4b687f964f1e3f542e Mon Sep 17 00:00:00 2001 +From fb6809ced7c7c062e9f754d353f6326a61aaec53 Mon Sep 17 00:00:00 2001 From: Matt Weber Date: Thu, 12 Sep 2019 15:04:35 -0500 Subject: [PATCH] notice read and write errors on input and output @@ -30,28 +30,30 @@ Signed-off-by: Bernd Kuhls [Bernd: Updated to incorporate changes by Matthias Klose on 2024-03-13 that fix Debian bug https://bugs.debian.org/1065375] +[dario: update patch for 1.08.2] +Signed-off-by: Dario Binacchi --- bc/execute.c | 10 +++++++++- bc/main.c | 3 +++ bc/sbc.y | 2 ++ bc/scan.c | 2 ++ bc/scan.l | 3 +++ - bc/util.c | 15 ++++++++++++-- - dc/dc.c | 3 +++ - dc/eval.c | 55 +++++++++++++++++++++++++++++++++++++++------------- - dc/misc.c | 1 + - dc/numeric.c | 9 +++++++++ - dc/stack.c | 11 ++++++++++- + bc/util.c | 15 +++++++++++++-- + dc/dc.c | 4 ++++ + dc/eval.c | 2 ++ + dc/misc.c | 3 +++ + dc/numeric.c | 5 +++++ + dc/stack.c | 1 + dc/string.c | 2 ++ - h/number.h | 11 +++++++---- - lib/number.c | 24 +++++++++++++++++++++++ - 14 files changed, 129 insertions(+), 22 deletions(-) + h/number.h | 10 ++++++---- + lib/number.c | 24 ++++++++++++++++++++++++ + 14 files changed, 79 insertions(+), 7 deletions(-) diff --git a/bc/execute.c b/bc/execute.c -index 256e4b7..50eac49 100644 +index e653a9d75979..3374a38e5fb6 100644 --- a/bc/execute.c +++ b/bc/execute.c -@@ -104,6 +104,7 @@ execute (void) +@@ -105,6 +105,7 @@ execute (void) } out_char ('\n'); } @@ -59,7 +61,7 @@ index 256e4b7..50eac49 100644 } #endif -@@ -224,6 +225,7 @@ execute (void) +@@ -225,6 +226,7 @@ execute (void) } } fflush (stdout); @@ -67,7 +69,7 @@ index 256e4b7..50eac49 100644 break; case 'R' : /* Return from function */ -@@ -259,6 +261,7 @@ execute (void) +@@ -260,6 +262,7 @@ execute (void) if (inst == 'W') out_char ('\n'); store_var (4); /* Special variable "last". */ fflush (stdout); @@ -75,7 +77,7 @@ index 256e4b7..50eac49 100644 pop (); break; -@@ -342,6 +345,7 @@ execute (void) +@@ -343,6 +346,7 @@ execute (void) case 'w' : /* Write a string to the output. */ while ((ch = byte(&pc)) != '"') out_schar (ch); fflush (stdout); @@ -83,7 +85,7 @@ index 256e4b7..50eac49 100644 break; case 'x' : /* Exchange Top of Stack with the one under the tos. */ -@@ -549,7 +553,10 @@ execute (void) +@@ -550,7 +554,10 @@ execute (void) { signal (SIGINT, use_quit); if (had_sigint) @@ -95,7 +97,7 @@ index 256e4b7..50eac49 100644 } } -@@ -584,6 +591,7 @@ input_char (void) +@@ -585,6 +592,7 @@ input_char (void) out_col = 0; /* Saw a new line */ } } @@ -104,10 +106,10 @@ index 256e4b7..50eac49 100644 /* Classify and preprocess the input character. */ if (isdigit(in_ch)) diff --git a/bc/main.c b/bc/main.c -index 012075c..c96207b 100644 +index b388e17b55bf..ab662dd10fc7 100644 --- a/bc/main.c +++ b/bc/main.c -@@ -353,6 +353,9 @@ use_quit (int sig) +@@ -358,6 +358,9 @@ use_quit (int sig) errno = save; #else write (1, "\n(interrupt) Exiting bc.\n", 26); @@ -118,7 +120,7 @@ index 012075c..c96207b 100644 #endif } diff --git a/bc/sbc.y b/bc/sbc.y -index 586686b..921ab1e 100644 +index 586686b4b71f..921ab1e13144 100644 --- a/bc/sbc.y +++ b/bc/sbc.y @@ -86,7 +86,9 @@ program : /* empty */ @@ -132,10 +134,10 @@ index 586686b..921ab1e 100644 } | program input_item diff --git a/bc/scan.c b/bc/scan.c -index b237f55..8dee4e9 100644 +index e208c8e7b3ba..5ac4c80fd732 100644 --- a/bc/scan.c +++ b/bc/scan.c -@@ -791,6 +791,7 @@ bcel_input (char *buf, yy_size_t *result, int max) +@@ -776,6 +776,7 @@ bcel_input (char *buf, int *result, int max) if (bcel_len != 0) history (hist, &histev, H_ENTER, bcel_line); fflush (stdout); @@ -143,7 +145,7 @@ index b237f55..8dee4e9 100644 } if (bcel_len <= max) -@@ -863,6 +864,7 @@ rl_input (char *buf, int *result, int max) +@@ -848,6 +849,7 @@ rl_input (char *buf, int *result, int max) add_history (rl_line); rl_line[rl_len-1] = '\n'; fflush (stdout); @@ -152,10 +154,10 @@ index b237f55..8dee4e9 100644 if (rl_len <= max) diff --git a/bc/scan.l b/bc/scan.l -index eb2e2dd..79186bb 100644 +index 958538d6fed0..009f8b196a5e 100644 --- a/bc/scan.l +++ b/bc/scan.l -@@ -99,6 +99,7 @@ bcel_input (char *buf, yy_size_t *result, int max) +@@ -100,6 +100,7 @@ bcel_input (char *buf, int *result, int max) if (bcel_len != 0) history (hist, &histev, H_ENTER, bcel_line); fflush (stdout); @@ -163,7 +165,7 @@ index eb2e2dd..79186bb 100644 } if (bcel_len <= max) -@@ -171,6 +172,7 @@ rl_input (char *buf, int *result, int max) +@@ -172,6 +173,7 @@ rl_input (char *buf, int *result, int max) add_history (rl_line); rl_line[rl_len-1] = '\n'; fflush (stdout); @@ -171,7 +173,7 @@ index eb2e2dd..79186bb 100644 } if (rl_len <= max) -@@ -295,6 +297,7 @@ limits return(Limits); +@@ -296,6 +298,7 @@ limits return(Limits); if (c == EOF) { fprintf (stderr,"EOF encountered in a comment.\n"); @@ -180,10 +182,10 @@ index eb2e2dd..79186bb 100644 } } diff --git a/bc/util.c b/bc/util.c -index 8eba093..cacd796 100644 +index 7abc2a0af309..ce7cc404fb0b 100644 --- a/bc/util.c +++ b/bc/util.c -@@ -247,9 +247,10 @@ init_gen (void) +@@ -248,9 +248,10 @@ init_gen (void) continue_label = 0; next_label = 1; out_count = 2; @@ -196,7 +198,7 @@ index 8eba093..cacd796 100644 init_load (); had_error = FALSE; did_gen = FALSE; -@@ -272,6 +273,7 @@ generate (const char *str) +@@ -273,6 +274,7 @@ generate (const char *str) printf ("\n"); out_count = 0; } @@ -204,7 +206,7 @@ index 8eba093..cacd796 100644 } else load_code (str); -@@ -289,6 +291,7 @@ run_code(void) +@@ -290,6 +292,7 @@ run_code(void) if (compile_only) { printf ("@r\n"); @@ -212,7 +214,7 @@ index 8eba093..cacd796 100644 out_count = 0; } else -@@ -326,6 +329,7 @@ out_char (int ch) +@@ -327,6 +330,7 @@ out_char (int ch) } putchar (ch); } @@ -220,7 +222,7 @@ index 8eba093..cacd796 100644 } /* Output routines: Write a character CH to the standard output. -@@ -355,6 +359,7 @@ out_schar (int ch) +@@ -356,6 +360,7 @@ out_schar (int ch) } putchar (ch); } @@ -228,7 +230,7 @@ index 8eba093..cacd796 100644 } -@@ -639,6 +644,7 @@ limits(void) +@@ -640,6 +645,7 @@ limits(void) #ifdef OLD_EQ_OP printf ("Old assignment operatiors are valid. (=-, =+, ...)\n"); #endif @@ -236,7 +238,7 @@ index 8eba093..cacd796 100644 } /* bc_malloc will check the return value so all other places do not -@@ -703,6 +709,7 @@ yyerror (str, va_alist) +@@ -704,6 +710,7 @@ yyerror (str, va_alist) fprintf (stderr,"%s %d: ",name,line_no); vfprintf (stderr, str, args); fprintf (stderr, "\n"); @@ -244,7 +246,7 @@ index 8eba093..cacd796 100644 had_error = TRUE; va_end (args); } -@@ -743,6 +750,7 @@ ct_warn (mesg, va_alist) +@@ -744,6 +751,7 @@ ct_warn (mesg, va_alist) fprintf (stderr,"%s %d: Error: ",name,line_no); vfprintf (stderr, mesg, args); fprintf (stderr, "\n"); @@ -252,7 +254,7 @@ index 8eba093..cacd796 100644 had_error = TRUE; } else -@@ -755,6 +763,7 @@ ct_warn (mesg, va_alist) +@@ -756,6 +764,7 @@ ct_warn (mesg, va_alist) fprintf (stderr,"%s %d: (Warning) ",name,line_no); vfprintf (stderr, mesg, args); fprintf (stderr, "\n"); @@ -260,7 +262,7 @@ index 8eba093..cacd796 100644 } va_end (args); } -@@ -789,6 +798,7 @@ rt_error (mesg, va_alist) +@@ -790,6 +799,7 @@ rt_error (mesg, va_alist) va_end (args); fprintf (stderr, "\n"); @@ -268,7 +270,7 @@ index 8eba093..cacd796 100644 runtime_error = TRUE; } -@@ -823,6 +833,7 @@ rt_warn (const char *mesg) +@@ -824,6 +834,7 @@ rt_warn (const char *mesg) va_end (args); fprintf (stderr, "\n"); @@ -277,26 +279,26 @@ index 8eba093..cacd796 100644 /* bc_exit: Make sure to reset the edit state. */ diff --git a/dc/dc.c b/dc/dc.c -index 6a2bb26..ccdb1c2 100644 +index 92a843cbdcdc..c5ea5753c91e 100644 --- a/dc/dc.c +++ b/dc/dc.c -@@ -45,6 +45,7 @@ - #include +@@ -36,6 +36,7 @@ + #endif + #include "../h/getopt.h" #include "dc.h" - #include "dc-proto.h" -+#include "number.h" ++#include "../h/number.h" - #ifndef EXIT_SUCCESS /* C89 */ - # define EXIT_SUCCESS 0 -@@ -59,6 +59,7 @@ static void - bug_report_info DC_DECLVOID() + const char *progname; /* basename of program invocation */ + unsigned int max_recursion_depth=0; +@@ -44,6 +45,7 @@ static void + bug_report_info(void) { printf("Email bug reports to: bug-dc@gnu.org .\n"); + checkferror_output(stdout); } static void -@@ -69,6 +70,7 @@ show_version DC_DECLVOID() +@@ -54,6 +56,7 @@ show_version(void) This is free software; see the source for copying conditions. There is NO\n\ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE,\n\ to the extent permitted by law.\n", DC_COPYRIGHT); @@ -304,243 +306,54 @@ index 6a2bb26..ccdb1c2 100644 } /* your generic usage function */ -@@ -85,6 +87,7 @@ Usage: %s [OPTION] [file ...]\n\ +@@ -71,6 +74,7 @@ Usage: %s [OPTION] [file ...]\n\ \n\ ", progname); bug_report_info(); + checkferror_output(f); } - /* returns a pointer to one past the last occurance of c in s, + /* returns a pointer to one past the last occurrence of c in s, diff --git a/dc/eval.c b/dc/eval.c -index 05a3d9e..6c54e61 100644 +index 30d0a20381d1..26e6d21256f9 100644 --- a/dc/eval.c +++ b/dc/eval.c -@@ -41,6 +41,7 @@ +@@ -33,6 +33,7 @@ + # include /* isatty */ #endif #include "dc.h" - #include "dc-proto.h" -+#include "number.h" - - typedef enum {DC_FALSE, DC_TRUE} dc_boolean; - -@@ -97,12 +97,15 @@ static int input_pushback; - static int - input_fil DC_DECLVOID() - { -+ int c; - if (input_pushback != EOF){ -- int c = input_pushback; -+ c = input_pushback; - input_pushback = EOF; - return c; - } -- return getc(input_fil_fp); -+ c = getc(input_fil_fp); -+ checkferror_input(input_fil_fp); -+ return c; - } - - /* passed as an argument to dc_getnum */ -@@ -301,11 +304,13 @@ dc_func DC_DECLARG((c, peekc, negcmp)) - tmpint = dc_num2int(datum.v.number, DC_TOSS); - if (2 <= tmpint && tmpint <= DC_IBASE_MAX) - dc_ibase = tmpint; -- else -+ else { - fprintf(stderr, - "%s: input base must be a number \ - between 2 and %d (inclusive)\n", - progname, DC_IBASE_MAX); -+ checkferror_output(stderr); -+ } - } - break; - case 'k': /* set scale to value on top of stack */ -@@ -313,11 +318,12 @@ between 2 and %d (inclusive)\n", - tmpint = -1; - if (datum.dc_type == DC_NUMBER) - tmpint = dc_num2int(datum.v.number, DC_TOSS); -- if ( ! (tmpint >= 0) ) -+ if ( ! (tmpint >= 0) ) { - fprintf(stderr, - "%s: scale must be a nonnegative number\n", - progname); -- else -+ checkferror_output(stderr); -+ } else - dc_scale = tmpint; - } - break; -@@ -341,11 +347,12 @@ between 2 and %d (inclusive)\n", - tmpint = 0; - if (datum.dc_type == DC_NUMBER) - tmpint = dc_num2int(datum.v.number, DC_TOSS); -- if ( ! (tmpint > 1) ) -+ if ( ! (tmpint > 1) ) { - fprintf(stderr, - "%s: output base must be a number greater than 1\n", - progname); -- else -+ checkferror_output(stderr); -+ } else - dc_obase = tmpint; - } - break; -@@ -378,6 +385,7 @@ between 2 and %d (inclusive)\n", - fprintf(stderr, - "%s: square root of nonnumeric attempted\n", - progname); -+ checkferror_output(stderr); - }else if (dc_sqrt(datum.v.number, dc_scale, &tmpnum) == DC_SUCCESS){ - dc_free_num(&datum.v.number); - datum.v.number = tmpnum; -@@ -424,6 +432,7 @@ between 2 and %d (inclusive)\n", - dc_garbage("at top of stack", -1); - } - fflush(stdout); -+ checkferror_output(stdout); - break; - case 'Q': /* quit out of top-of-stack nested evals; - * pops value from stack; -@@ -440,6 +449,7 @@ between 2 and %d (inclusive)\n", - fprintf(stderr, - "%s: Q command requires a number >= 1\n", - progname); -+ checkferror_output(stderr); - } - break; - case 'R': /* pop a value off of the evaluation stack,; -@@ -483,11 +493,12 @@ between 2 and %d (inclusive)\n", - if (datum.dc_type == DC_NUMBER) - tmpint = dc_num2int(datum.v.number, DC_TOSS); - if (dc_pop(&datum) == DC_SUCCESS){ -- if (tmpint < 0) -+ if (tmpint < 0) { - fprintf(stderr, - "%s: array index must be a nonnegative integer\n", - progname); -- else -+ checkferror_output(stderr); -+ } else - dc_array_set(peekc, tmpint, datum); - } - } -@@ -499,18 +510,21 @@ between 2 and %d (inclusive)\n", - tmpint = -1; - if (datum.dc_type == DC_NUMBER) - tmpint = dc_num2int(datum.v.number, DC_TOSS); -- if (tmpint < 0) -+ if (tmpint < 0) { - fprintf(stderr, - "%s: array index must be a nonnegative integer\n", - progname); -- else -+ checkferror_output(stderr); -+ } else - dc_push(dc_array_get(peekc, tmpint)); - } - return DC_EATONE; - - default: /* What did that user mean? */ - fprintf(stderr, "%s: ", progname); -+ checkferror_output(stderr); - dc_show_id(stdout, c, " unimplemented\n"); -+ checkferror_output(stdout); - break; - } - return DC_OKAY; -@@ -538,6 +552,7 @@ evalstr DC_DECLARG((string)) - fprintf(stderr, - "%s: eval called with non-string argument\n", - progname); -+ checkferror_output(stderr); - return DC_OKAY; - } - interrupt_seen = 0; -@@ -635,6 +650,7 @@ evalstr DC_DECLARG((string)) - return DC_FAIL; - } - fprintf(stderr, "%s: unexpected EOS\n", progname); ++#include "../h/number.h" + + typedef enum { + DC_OKAY, //no further intervention needed for this command +@@ -421,6 +422,7 @@ dc_nextcmd(void) + || tmpint < 2 || DC_IBASE_MAX < tmpint) { + fprintf(stderr, "%s: input base must be a number " + "between 2 and %d (inclusive)\n", progname, DC_IBASE_MAX); + checkferror_output(stderr); - return DC_OKAY; - } - } -@@ -692,6 +708,7 @@ dc_evalfile DC_DECLARG((fp)) - stdin_lookahead = EOF; - for (c=getc(fp); c!=EOF; c=peekc){ - peekc = getc(fp); -+ checkferror_input(stdin); - /* - * The following if() is the only place where ``stdin_lookahead'' - * might be set to other than EOF: -@@ -717,24 +734,30 @@ dc_evalfile DC_DECLARG((fp)) - signal(SIGINT, sigint_handler); - switch (dc_func(c, peekc, negcmp)){ - case DC_OKAY: -- if (stdin_lookahead != peekc && fp == stdin) -+ if (stdin_lookahead != peekc && fp == stdin) { - peekc = getc(fp); -+ checkferror_input(stdin); -+ } - break; - case DC_EATONE: - peekc = getc(fp); -+ checkferror_input(fp); break; - case DC_EVALREG: - /*commands which send us here shall guarantee that peekc!=EOF*/ - c = peekc; - peekc = getc(fp); -+ checkferror_input(fp); - stdin_lookahead = peekc; - if (dc_register_get(c, &datum) != DC_SUCCESS) - break; - dc_push(datum); - /*@fallthrough@*/ - case DC_EVALTOS: -- if (stdin_lookahead != peekc && fp == stdin) -+ if (stdin_lookahead != peekc && fp == stdin) { - peekc = getc(fp); -+ checkferror_input(stdin); -+ } - if (dc_pop(&datum) == DC_SUCCESS){ - if (datum.dc_type == DC_NUMBER){ - dc_push(datum); -@@ -744,6 +767,7 @@ dc_evalfile DC_DECLARG((fp)) - goto reset_and_exit_quit; - fprintf(stderr, "%s: Q command argument exceeded \ - string execution depth\n", progname); -+ checkferror_output(stderr); - } - }else{ - dc_garbage("at top of stack", -1); -@@ -756,8 +780,11 @@ string execution depth\n", progname); - fprintf(stderr, - "%s: Q command argument exceeded string execution depth\n", - progname); -- if (stdin_lookahead != peekc && fp == stdin) -+ checkferror_output(stderr); -+ if (stdin_lookahead != peekc && fp == stdin) { - peekc = getc(fp); -+ checkferror_input(stdin); -+ } - break; - - case DC_INT: + } + dc_discard_TOS(); diff --git a/dc/misc.c b/dc/misc.c -index cd23602..cd910b8 100644 +index e64f62aca1e9..17e337792a84 100644 --- a/dc/misc.c +++ b/dc/misc.c -@@ -47,6 +47,7 @@ - #include +@@ -31,12 +31,14 @@ + #include #include "dc.h" - #include "dc-proto.h" -+#include "number.h" + #include "../config.h" ++#include "../h/number.h" - #ifndef EXIT_FAILURE /* C89 */ - # define EXIT_FAILURE 1 -@@ -89,6 +89,7 @@ dc_show_id DC_DECLARG((fp, id, suffix)) + /* print a simple warning message */ + void + dc_warn(const char *msg) + { + fprintf(stderr, "%s: %s\n", progname, msg); ++ checkferror_output(stderr); + } + + /* print an "out of memory" diagnostic and exit program */ +@@ -71,6 +73,7 @@ dc_show_id(FILE *fp, int id, const char *suffix) fprintf(fp, "'%c' (%#o)%s", (unsigned int) id, id, suffix); else fprintf(fp, "%#o%s", (unsigned int) id, suffix); @@ -549,42 +362,10 @@ index cd23602..cd910b8 100644 diff --git a/dc/numeric.c b/dc/numeric.c -index 37759de..60cfb85 100644 +index 556c5bd6478f..887688b0d64f 100644 --- a/dc/numeric.c +++ b/dc/numeric.c -@@ -133,6 +133,7 @@ dc_div DC_DECLARG((a, b, kscale, result)) - bc_init_num(CastNumPtr(result)); - if (bc_divide(CastNum(a), CastNum(b), CastNumPtr(result), kscale)){ - fprintf(stderr, "%s: divide by zero\n", progname); -+ checkferror_output(stderr); - return DC_DOMAIN_ERROR; - } - return DC_SUCCESS; -@@ -155,6 +156,7 @@ dc_divrem DC_DECLARG((a, b, kscale, quotient, remainder)) - if (bc_divmod(CastNum(a), CastNum(b), - CastNumPtr(quotient), CastNumPtr(remainder), kscale)){ - fprintf(stderr, "%s: divide by zero\n", progname); -+ checkferror_output(stderr); - return DC_DOMAIN_ERROR; - } - return DC_SUCCESS; -@@ -173,6 +175,7 @@ dc_rem DC_DECLARG((a, b, kscale, result)) - bc_init_num(CastNumPtr(result)); - if (bc_modulo(CastNum(a), CastNum(b), CastNumPtr(result), kscale)){ - fprintf(stderr, "%s: remainder by zero\n", progname); -+ checkferror_output(stderr); - return DC_DOMAIN_ERROR; - } - return DC_SUCCESS; -@@ -225,6 +228,7 @@ dc_sqrt DC_DECLARG((value, kscale, result)) - tmp = bc_copy_num(CastNum(value)); - if (!bc_sqrt(&tmp, kscale)){ - fprintf(stderr, "%s: square root of negative number\n", progname); -+ checkferror_output(stderr); - bc_free_num(&tmp); - return DC_DOMAIN_ERROR; - } -@@ -470,6 +474,7 @@ dc_dump_num DC_DECLARG((dcvalue, discard_p)) +@@ -408,6 +408,7 @@ dc_dump_num(dc_num dcvalue) for (cur=top_of_stack; cur; cur=next) { putchar(cur->digit); @@ -592,7 +373,7 @@ index 37759de..60cfb85 100644 next = cur->link; free(cur); } -@@ -587,6 +592,8 @@ out_char (ch) +@@ -493,6 +494,8 @@ out_char (int ch) out_col = 1; } putchar(ch); @@ -601,119 +382,56 @@ index 37759de..60cfb85 100644 } } -@@ -626,6 +633,7 @@ rt_error (mesg, va_alist) - vfprintf (stderr, mesg, args); - va_end (args); - fprintf (stderr, "\n"); +@@ -516,6 +519,7 @@ rt_error(const char *mesg, ...) + vfprintf(stderr, mesg, args); + va_end(args); + fprintf(stderr, "\n"); + checkferror_output(stderr); } -@@ -659,6 +667,7 @@ rt_warn (mesg, va_alist) - vfprintf (stderr, mesg, args); - va_end (args); - fprintf (stderr, "\n"); +@@ -533,6 +537,7 @@ rt_warn(const char *mesg, ...) + vfprintf(stderr, mesg, args); + va_end(args); + fprintf(stderr, "\n"); + checkferror_output(stderr); } diff --git a/dc/stack.c b/dc/stack.c -index 49422df..174411d 100644 +index 35f8ee7cc876..2c69828dad87 100644 --- a/dc/stack.c +++ b/dc/stack.c -@@ -33,9 +33,13 @@ - #include "dc.h" - #include "dc-proto.h" - #include "dc-regdef.h" -+#include "number.h" - - /* an oft-used error message: */ --#define Empty_Stack fprintf(stderr, "%s: stack empty\n", progname) -+#define Empty_Stack do{ \ -+ fprintf(stderr, "%s: stack empty\n", progname); \ -+ checkferror_output(stderr); \ -+ }while(0) - - - /* simple linked-list implementation suffices: */ -@@ -91,6 +94,7 @@ dc_binop DC_DECLARG((op, kscale)) - if (dc_stack->value.dc_type!=DC_NUMBER - || dc_stack->link->value.dc_type!=DC_NUMBER){ - fprintf(stderr, "%s: non-numeric value\n", progname); -+ checkferror_output(stderr); - return; - } - (void)dc_pop(&b); -@@ -131,6 +135,7 @@ dc_binop2 DC_DECLARG((op, kscale)) - if (dc_stack->value.dc_type!=DC_NUMBER - || dc_stack->link->value.dc_type!=DC_NUMBER){ - fprintf(stderr, "%s: non-numeric value\n", progname); -+ checkferror_output(stderr); - return; - } - (void)dc_pop(&b); -@@ -169,6 +174,7 @@ dc_cmpop DC_DECLVOID() - if (dc_stack->value.dc_type!=DC_NUMBER - || dc_stack->link->value.dc_type!=DC_NUMBER){ - fprintf(stderr, "%s: non-numeric value\n", progname); -+ checkferror_output(stderr); - return 0; - } - (void)dc_pop(&b); -@@ -206,6 +212,7 @@ dc_triop DC_DECLARG((op, kscale)) - || dc_stack->link->value.dc_type!=DC_NUMBER - || dc_stack->link->link->value.dc_type!=DC_NUMBER){ - fprintf(stderr, "%s: non-numeric value\n", progname); -+ checkferror_output(stderr); - return; - } - (void)dc_pop(&c); -@@ -327,6 +334,7 @@ dc_register_get DC_DECLARG((regid, result)) - *result = dc_int2data(0); - }else if (r->value.dc_type==DC_UNINITIALIZED){ - fprintf(stderr, "%s: BUG: register ", progname); -+ checkferror_output(stderr); - dc_show_id(stderr, regid, " exists but is uninitialized?\n"); - return DC_FAIL; - }else{ -@@ -402,6 +410,7 @@ dc_register_pop DC_DECLARG((stackid, result)) +@@ -388,6 +388,7 @@ dc_register_pop(int stackid, dc_data *result) r = dc_register[stackid]; - if (r==NULL || r->value.dc_type==DC_UNINITIALIZED){ + if (!r || r->value.dc_type==DC_UNINITIALIZED){ fprintf(stderr, "%s: stack register ", progname); + checkferror_output(stderr); dc_show_id(stderr, stackid, " is empty\n"); return DC_FAIL; } diff --git a/dc/string.c b/dc/string.c -index dee9169..389d899 100644 +index 41b578c130d2..e46b35215d3e 100644 --- a/dc/string.c +++ b/dc/string.c -@@ -45,6 +45,7 @@ - #endif - #include "dc.h" - #include "dc-proto.h" -+#include "number.h" - - /* here is the completion of the dc_string type: */ - struct dc_string { -@@ -94,6 +94,7 @@ dc_out_str DC_DECLARG((value, discard_flag)) - dc_discard discard_flag DC_DECLEND +@@ -71,6 +71,7 @@ void + dc_out_str(dc_str value, dc_discard discard_flag) { fwrite(value->s_ptr, value->s_len, sizeof *value->s_ptr, stdout); -+ checkferror_output(stdout); ++ checkferror_output(stdout); if (discard_flag == DC_TOSS) dc_free_str(&value); } -@@ -169,6 +170,7 @@ dc_readstring DC_DECLARG((fp, ldelim, rdelim)) +@@ -155,6 +156,7 @@ dc_readstring(int (*input)(void), int ldelim, int rdelim, const char *augment) } *p++ = c; } -+ checkferror_input(fp); - return dc_makestring(line_buf, (size_t)(p-line_buf)); - } - ++ + if (c==EOF && p==line_buf) + return dc_makestring(NULL, 0, NULL); + return dc_makestring(line_buf, (size_t)(p-line_buf), augment); diff --git a/h/number.h b/h/number.h -index abf6332..1983ab4 100644 +index b2d9f9eae46a..f6fc880de920 100644 --- a/h/number.h +++ b/h/number.h @@ -23,10 +23,10 @@ @@ -731,19 +449,20 @@ index abf6332..1983ab4 100644 *************************************************************************/ #ifndef _NUMBER_H_ -@@ -140,4 +140,7 @@ void bc_out_num (bc_num num, int o_base, void (* out_char)(int), - int leading_zero); - +@@ -142,6 +142,8 @@ void bc_out_num (bc_num num, int o_base, void (* out_char)(int), void bc_out_long (long val, int size, int space, void (*out_char)(int)); -+ + + +void checkferror_input (FILE*); +void checkferror_output (FILE*); - #endif + + /* function prototypes for callbacks from the library which + * need to be provided by the application diff --git a/lib/number.c b/lib/number.c -index f394e92..80b33e3 100644 +index f84f4fc87336..9d4553a14b37 100644 --- a/lib/number.c +++ b/lib/number.c -@@ -1713,6 +1713,7 @@ static void +@@ -1714,6 +1714,7 @@ static void out_char (int c) { putchar(c); @@ -751,7 +470,7 @@ index f394e92..80b33e3 100644 } -@@ -1721,6 +1722,7 @@ pn (bc_num num) +@@ -1722,6 +1723,7 @@ pn (bc_num num) { bc_out_num (num, 10, out_char, 0); out_char ('\n'); @@ -759,7 +478,7 @@ index f394e92..80b33e3 100644 } -@@ -1732,6 +1734,28 @@ pv (char *name, unsigned char *num, int len) +@@ -1733,6 +1735,28 @@ pv (char *name, unsigned char *num, int len) printf ("%s=", name); for (i=0; i -Date: Thu, 27 Jun 2019 13:10:47 +0800 -Subject: [PATCH] dc: fix exit code of q command - -The exit code for "echo q | dc" is 1 for dc-1.4.1; -while the exit code for "echo q | dc" is 0 for dc-1.4. - -Here is the answer from ken@gnu.org: -dc-1.4 was right. There was a rewrite of a chunk of code for 1.4.1 to -fix a corner case in the Q command, and somehow the placement of the -clean-up label for the 'q' command got misplaced on the error-handling -branch instead of the clean-exit branch. The patch below fixes this -(it is committed for whenever the next bc/dc release gets made). - -Thanks for the report, - --Ken Pizzini - -Upstream: -https://git.yoctoproject.org/cgit.cgi/poky/plain/meta/recipes-extended/bc/bc/0001-dc-fix-exit-code-of-q-command.patch - -Signed-off-by: Li Zhou -Signed-off-by: Matthew Weber ---- - dc/eval.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/dc/eval.c b/dc/eval.c -index 6c54e61..9c28f18 100644 ---- a/dc/eval.c -+++ b/dc/eval.c -@@ -841,10 +841,10 @@ error_fail: - fprintf(stderr, "%s: ", progname); - perror("error reading input"); - return DC_FAIL; --reset_and_exit_quit: - reset_and_exit_fail: - signal(SIGINT, sigint_default); - return DC_FAIL; -+reset_and_exit_quit: - reset_and_exit_success: - signal(SIGINT, sigint_default); - return DC_SUCCESS; --- -2.17.1 - diff --git a/package/bc/0004-no-gen-libmath.patch b/package/bc/0004-no-gen-libmath.patch deleted file mode 100644 index 15b7b9e5a8a8..000000000000 --- a/package/bc/0004-no-gen-libmath.patch +++ /dev/null @@ -1,97 +0,0 @@ -From a543af443c5f86b24ca89a994b75b6ef4751ac66 Mon Sep 17 00:00:00 2001 -From: Matt Weber -Date: Thu, 12 Sep 2019 15:12:40 -0500 -Subject: [PATCH] no gen libmath - -These rules are not cross-friendly so delete them. libmath has been -generated offline and included as part of this patch as the fbc tool -used to generate that header is assuming the cross architecture and -can't execute. - -Upstream: -https://git.yoctoproject.org/cgit.cgi/poky/plain/meta/recipes-extended/bc/bc/no-gen-libmath.patch -https://git.yoctoproject.org/cgit.cgi/poky/plain/meta/recipes-extended/bc/bc/libmath.h - -[Reformatted to GIT for 1.0.7.1 by Matt W] -Signed-off-by: Ross Burton -Signed-off-by: Matthew Weber ---- - bc/Makefile.am | 8 -------- - bc/libmath.h | 46 ++++++++++++++++++++++++++++++++++++++++++++++ - 2 files changed, 46 insertions(+), 8 deletions(-) - create mode 100644 bc/libmath.h - -diff --git a/bc/Makefile.am b/bc/Makefile.am -index d9d412e..f244241 100644 ---- a/bc/Makefile.am -+++ b/bc/Makefile.am -@@ -31,14 +31,6 @@ global.o: libmath.h - - fbcOBJ = main.o bc.o scan.o execute.o load.o storage.o util.o warranty.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 -- $(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 - sbc.o: sbc.c -diff --git a/bc/libmath.h b/bc/libmath.h -new file mode 100644 -index 0000000..63e1acb ---- /dev/null -+++ b/bc/libmath.h -@@ -0,0 +1,46 @@ -+{"@iK20:s2:p@r", -+"@iF1,5.6,7,8,9,10,11,12,13,14,15[l0:KA:#Z1:l0:s7:pKA:s0:pl5:C1,0:", -+"s14:pl7:s0:pl14:RN1:l5:0Z4:l10:1+s10:pl5:K2:/s5:pl2:", -+"1+s2:pJ3:N4:l13:s2:p1l5:+s14:pl5:s6:p1s8:pK2:s11:pN6:1B7:J5:N8:", -+"l11:i11:pJ6:N7:l6:l5:*s6:l8:l11:*s8:/s9:pl9:0=Z9:l10:0>Z10:N11:", -+"l10:d10:Z12:l14:l14:*s14:pJ11:N12:N10:l15:s2:pl12:Z13:1l14:/R", -+"N13:l14:1/RN9:l14:l9:+s14:pJ8:N5:0R]@r", -+"@iF2,5.7,9,10,11,12,13,14,15[l0:KA:#Z1:l0:s7:pKA:s0:pl5:C2,0:", -+"s14:pl7:s0:pl14:RN1:l5:0{Z2:1K10:l2:^-1/RN2:l2:s15:pK6:l2:+s2:", -+"pK2:s10:p0s11:pN3:l5:K2:}Z4:l10:K2:*s10:pl5:cRs5:pJ3:N4:N5:l5:", -+"K.5:{Z6:l10:K2:*s10:pl5:cRs5:pJ5:N6:l5:1-l5:1+/s13:s14:pl13:l13:", -+"*s12:pK3:s11:pN8:1B9:J7:N10:l11:K2:+s11:pJ8:N9:l13:l12:*s13:l11:", -+"/s9:pl9:0=Z11:l10:l14:*s14:pl15:s2:pl14:1/RN11:l14:l9:+s14:pJ10:N7:", -+"0R]@r", -+"@iF3,5.7,9,11,12,13,16,14,15[l0:KA:#Z1:l0:s7:pKA:s0:pl5:C3,0:", -+"s14:pl7:s0:pl14:RN1:l2:s15:pK1.1:l15:*K2:+s2:p1C4,0:s14:pl5:0", -+"Z11:l15:K5:+s2:pK.2:C4,0:s6:pN11:", -+"l15:K3:+s2:pN12:l5:K.2:>Z13:l10:1+s10:pl5:K.2:-1l5:K.2:*+/s5:", -+"pJ12:N13:l5:s13:s14:pl5:nl5:*s16:pK3:s11:pN15:1B16:J14:N17:l11:", -+"K2:+s11:pJ15:N16:l13:l16:*s13:l11:/s9:pl9:0=Z18:l15:s2:pl10:l6:", -+"*l14:+l12:/RN18:l14:l9:+s14:pJ17:N14:0R]@r", -+"@iF6,13,5.6,7,8,9,10,11,12,16,14,15[l0:KA:#Z1:l0:s7:pKA:s0:pl13:", -+"l5:C6,00:s14:pl7:s0:pl14:RN1:l2:s15:p0s2:pl13:1/s13:pl13:0