Skip to contentSkip to conversation

package/bc: bump to 1.07.1

PATCH New Matt Weber 3 participants 9 messages Sep 12, 2019 – Sep 13, 2019

lore
Share & tools
lore

Matt Weber

author
#0 lore raw

PATCH 1/1 package/bc: bump to 1.07.1

* Added license hash files
* Updated site to new GNU location
* Reconfig required to use newer automake
* Dropped patch for 01_array_initialize.patch as it was fixed in the latest
* Refactored patches for makeinfo variable and write io errs
* Added new dc fix exit code patch from Debian sid
* Added new libmath offline gen cross-compile patch from Yocto

---
 ...01-bc-use-MAKEINFO-variable-for-docs.patch |  34 ++
 ...nd-write-errors-on-input-and-output.patch} | 350 ++++++++++--------
 .../0003-dc-fix-exit-code-of-q-command.patch  |  46 +++
 package/bc/0004-no-gen-libmath.patch          |  97 +++++
 package/bc/01_array_initialize.patch          |  20 -
 package/bc/03_use_appropiate_makeinfo.patch   |  17 -
 package/bc/bc.hash                            |   4 +-
 package/bc/bc.mk                              |   9 +-
 8 files changed, 384 insertions(+), 193 deletions(-)
 create mode 100644 package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch
 rename package/bc/{02_notice_read_write_errors.patch => 0002-notice-read-and-write-errors-on-input-and-output.patch} (63%)
 create mode 100644 package/bc/0003-dc-fix-exit-code-of-q-command.patch
 create mode 100644 package/bc/0004-no-gen-libmath.patch
 delete mode 100644 package/bc/01_array_initialize.patch
 delete mode 100644 package/bc/03_use_appropiate_makeinfo.patch
package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch new file +34 -0
new file mode 100644
index 0000000000..6f82e9f82e
@@ -0,0 +1,34 @@
+From 66d30778ec5bf98dbd106a3287d17fe0b5123490 Mon Sep 17 00:00:00 2001
+From: Matt Weber <[email protected]>
+Date: Wed, 11 Sep 2019 21:57:35 -0500
+Subject: [PATCH] bc: use MAKEINFO variable for docs
+
+Use the appropiate MAKEINFO variable rather than the hardcoded makeinfo
+command directly, otherwise missing logic never works.
+
+Fixes:
+http://autobuild.buildroot.net/results/b0b/b0b9dced0014a5a8026fa972f95085e8bd16a07b/
+
+[Recreated for 1.0.7.1 by Matt W]
+Signed-off-by: Gustavo Zacarias <[email protected]>
+Signed-off-by: Matthew Weber <[email protected]>
+---
+ doc/Makefile.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/doc/Makefile.in b/doc/Makefile.in
+index 55aa316..2ca37ff 100644
+--- a/doc/Makefile.in
++++ b/doc/Makefile.in
+@@ -214,7 +214,7 @@ LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
+ LIBOBJS = @LIBOBJS@
+ LIBS = @LIBS@
+ LTLIBOBJS = @LTLIBOBJS@
+-MAKEINFO = makeinfo --no-split
++MAKEINFO = @MAKEINFO@ --no-split
+ MKDIR_P = @MKDIR_P@
+ OBJEXT = @OBJEXT@
+ PACKAGE = @PACKAGE@
+-- 
+2.17.1
+
package/bc/0002-notice-read-and-write-errors-on-input-and-output.patch renamed from package/bc/02_notice_read_write_errors.patch +198 -152

756 lines not on this page · raw message

package/bc/0003-dc-fix-exit-code-of-q-command.patch new file +46 -0

46 lines not on this page · raw message

package/bc/0004-no-gen-libmath.patch new file +97 -0

97 lines not on this page · raw message

package/bc/01_array_initialize.patch deleted +0 -20
deleted file mode 100644
index 9520d824af..0000000000
@@ -1,20 +0,0 @@
-Description: Fix array initialization bug
-Author: Phil Nelson
-Origin: upstream
-Bug-Debian: http://bugs.debian.org/586969
-Bug-Debian: http://bugs.debian.org/671513
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
-Index: bc/bc/storage.c
-===================================================================
---- bc.orig/bc/storage.c	2013-06-02 20:34:09.401273864 -0400
-+++ bc/bc/storage.c	2013-06-02 20:34:11.000000000 -0400
-@@ -179,7 +179,7 @@
- 
- 
-   /* Initialize the new elements. */
--  for (; indx < v_count; indx++)
-+  for (; indx < a_count; indx++)
-     arrays[indx] = NULL;
- 
-   /* Free the old elements. */
package/bc/03_use_appropiate_makeinfo.patch deleted +0 -17
deleted file mode 100644
index e6f9262b09..0000000000
@@ -1,17 +0,0 @@
-Use the appropiate MAKEINFO variable rather than the hardcoded makeinfo
-command directly, otherwise missing logic never works.
-
-Signed-off-by: Gustavo Zacarias <[email protected]>
-
-diff -Nura bc-1.06.95.orig/doc/Makefile.in bc-1.06.95/doc/Makefile.in
---- bc-1.06.95.orig/doc/Makefile.in	2015-06-13 09:39:46.946620294 -0300
-+++ bc-1.06.95/doc/Makefile.in	2015-06-13 09:40:10.019407630 -0300
-@@ -96,7 +96,7 @@
- LIBOBJS = @LIBOBJS@
- LIBS = @LIBS@
- LTLIBOBJS = @LTLIBOBJS@
--MAKEINFO = makeinfo --no-split
-+MAKEINFO = @MAKEINFO@ --no-split
- OBJEXT = @OBJEXT@
- PACKAGE = @PACKAGE@
- PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
package/bc/bc.hash +3 -1
index 5f1ed63536..6feca831d2 100644
@@ -1,2 +1,4 @@
 # Locally calculated
-sha256 7ee4abbcfac03d8a6e1a8a3440558a3d239d6b858585063e745c760957725ecc  bc-1.06.95.tar.bz2
+sha256	62adfca89b0a1c0164c2cdca59ca210c1d44c3ffc46daf9931cf4942664cb02a  bc-1.07.1.tar.gz
+sha256	8ceb4b9ee5adedde47b31e975c1d90c73ad27b6b165a1dcd80c7c545eb65b903  COPYING
+sha256	a853c2ffec17057872340eee242ae4d96cbf2b520ae27d903e1b2fef1a5f9d1c  COPYING.LIB
package/bc/bc.mk +6 -3
index ee0e43848b..afca0e8300 100644
@@ -4,11 +4,14 @@
 #
 ################################################################################
 
-BC_VERSION = 1.06.95
-BC_SOURCE = bc-$(BC_VERSION).tar.bz2
-BC_SITE = http://alpha.gnu.org/gnu/bc
+BC_VERSION = 1.07.1
+BC_SOURCE = bc-$(BC_VERSION).tar.gz
+BC_SITE = http://ftp.gnu.org/gnu/bc
 BC_DEPENDENCIES = host-flex
 BC_LICENSE = GPL-2.0+, LGPL-2.1+
 BC_LICENSE_FILES = COPYING COPYING.LIB
 
+# Need to reconf to fix automake-1.14: command not found
+BC_AUTORECONF = YES
+
 $(eval $(autotools-package))
Signature · 1 line
2.17.1
#1 lore raw

PATCH 1/1 package/bc: bump to 1.07.1

Hello Matt,

Quoted 10 lines · On Thu, 12 Sep 2019 15:50:57 -0500 Matt Weber…

* Added license hash files
* Updated site to new GNU location
* Reconfig required to use newer automake
* Dropped patch for 01_array_initialize.patch as it was fixed in the latest
* Refactored patches for makeinfo variable and write io errs
* Added new dc fix exit code patch from Debian sid
* Added new libmath offline gen cross-compile patch from Yocto

Do you know what is the upstream status for the different patches we had and that are still needed ?

Quoted 13 lines
package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch new file +7 -0
new file mode 100644
index 0000000000..6f82e9f82e
@@ -0,0 +1,34 @@
+From 66d30778ec5bf98dbd106a3287d17fe0b5123490 Mon Sep 17 00:00:00 2001
+From: Matt Weber <[email protected]>
+Date: Wed, 11 Sep 2019 21:57:35 -0500
+Subject: [PATCH] bc: use MAKEINFO variable for docs
+
+Use the appropiate MAKEINFO variable rather than the hardcoded makeinfo
+command directly, otherwise missing logic never works.

package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch line 17

Quoted 10 lines
package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch new file +10 -0
+
+Fixes:
+http://autobuild.buildroot.net/results/b0b/b0b9dced0014a5a8026fa972f95085e8bd16a07b/
+
+[Recreated for 1.0.7.1 by Matt W]
+Signed-off-by: Gustavo Zacarias <[email protected]>
+Signed-off-by: Matthew Weber <[email protected]>
+---
+ doc/Makefile.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)

This patch is useless, because it modifies Makefile.in, but you have AUTORECONF = YES, so Makefile.in will be regenerated from Makefile.am.

package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch line 22

Quoted 5 lines
package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch new file +5 -0
+[Reformatted to GIT for 1.0.7.1 by Matt W]
+Signed-off-by: Ross Burton <[email protected]>
+Signed-off-by: Matthew Weber <[email protected]>
+---
+ bc/Makefile.am |  8 --------

You're modifying Makefile.am here.

package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch line 24

Quoted 2 lines
package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch new file +2 -0
+# Need to reconf to fix automake-1.14: command not found
+BC_AUTORECONF = YES

And so the reason for the autoreconf = yes is not "automake: command not found", it's because you're patching Makefile.am, so it is newer than the corresponding Makefile.in, and consequently, the autotools machinery tries to regenerate it by calling automake. So the comment here should be the usual:

# We're patching Makefile.am

or, the file name of the patch touching Makefile.am.

Thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
#2 lore raw

PATCH 1/1 package/bc: bump to 1.07.1

Thomas,

Quoted 15 lines · Thomas Petazzoni

Hello Matt,

Quoted 9 lines · On Thu, 12 Sep 2019 15:50:57 -0500 Matt Weber…

* Added license hash files
* Updated site to new GNU location
* Reconfig required to use newer automake
* Dropped patch for 01_array_initialize.patch as it was fixed in the latest
* Refactored patches for makeinfo variable and write io errs
* Added new dc fix exit code patch from Debian sid
* Added new libmath offline gen cross-compile patch from Yocto

Quoted 4 lines
Quoted 1 line

Do you know what is the upstream status for the different patches we had and that are still needed ?

For the patches that were kept in this bump, they were all still
pending and on the debian / yocto distro patch lists. I wasn't able
to find any upstream submissions. Are patches against gnu tools like bc done directly to the maintainer ( Phil Nelson <[email protected]>)? I could definitely send them out to him if that makes sense.

Quoted 19 lines
Quoted 19 lines
package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch new file +12 -0
new file mode 100644
index 0000000000..6f82e9f82e
@@ -0,0 +1,34 @@
+From 66d30778ec5bf98dbd106a3287d17fe0b5123490 Mon Sep 17 00:00:00 2001
+From: Matt Weber <[email protected]>
+Date: Wed, 11 Sep 2019 21:57:35 -0500
+Subject: [PATCH] bc: use MAKEINFO variable for docs
+
+Use the appropiate MAKEINFO variable rather than the hardcoded makeinfo
+command directly, otherwise missing logic never works.
+
+Fixes:
+http://autobuild.buildroot.net/results/b0b/b0b9dced0014a5a8026fa972f95085e8bd16a07b/
+
+[Recreated for 1.0.7.1 by Matt W]
Quoted 9 lines

package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch line 17

Quoted 5 lines
package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch new file +5 -0
+Signed-off-by: Gustavo Zacarias <[email protected]>
+Signed-off-by: Matthew Weber <[email protected]>
+---
+ doc/Makefile.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)

This patch is useless, because it modifies Makefile.in, but you have AUTORECONF = YES, so Makefile.in will be regenerated from Makefile.am.

Oops, true and it isn't easy to test on my system. When recreating I definitely did use the wrong file.

Quoted 17 lines

package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch line 22

Quoted 5 lines
package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch new file +5 -0
+[Reformatted to GIT for 1.0.7.1 by Matt W]
+Signed-off-by: Ross Burton <[email protected]>
+Signed-off-by: Matthew Weber <[email protected]>
+---
+ bc/Makefile.am |  8 --------

You're modifying Makefile.am here.

package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch line 24

Quoted 2 lines
package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch new file +2 -0
+# Need to reconf to fix automake-1.14: command not found
+BC_AUTORECONF = YES

And so the reason for the autoreconf = yes is not "automake: command not found", it's because you're patching Makefile.am, so it is newer than the corresponding Makefile.in, and consequently, the autotools machinery tries to regenerate it by calling automake. So the comment here should be the usual:

Quoted 3 lines

# We're patching Makefile.am

or, the file name of the patch touching Makefile.am.

True, I'll update the comment.

Thanks for the review and I'll work on spinning a v2 this afternoon.

Matt

#3 lore raw

PATCH 1/1 package/bc: bump to 1.07.1

Hello Matt,

Quoted 6 lines · On Fri, 13 Sep 2019 13:14:10 -0500 Matthew Weber <[email protected]>…

For the patches that were kept in this bump, they were all still
pending and on the debian / yocto distro patch lists. I wasn't able
to find any upstream submissions. Are patches against gnu tools like bc done directly to the maintainer ( Phil Nelson <[email protected]>)? I could definitely send them out to him if that makes sense.

Yes, I already contributed a patch to bc a while ago, and indeed, I sent it directly to the upstream author. Interestingly, the patch and discussion I had were precisely about libmath being re-generated, and that was last year.

He had sent me some test versions of bc 1.07.2 which should have fixed the problem, but I never took the time to reply it seems :-/

These projects with no mailing list, bug tracker or public version control system are really difficult to work with :-/

Best regards,

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
#4 lore raw

PATCH 1/1 package/bc: bump to 1.07.1

Hello Matt,

Quoted 2 lines · On Fri, 13 Sep 2019 20:31:45 +0200 Thomas Petazzoni…

He had sent me some test versions of bc 1.07.2 which should have fixed the problem, but I never took the time to reply it seems :-/

I correct this: the discussion was two years ago, it seems like I did provide some feedback and then in March 2018, I pinged the bc maintainer. See:

===========

From: Phil Nelson <[email protected]>
To: Thomas Petazzoni <[email protected]>
Subject: Re: Please provide feedback: bc 1.07+ not building with Yocto project tools (libmath.h related)
Date: Fri, 23 Mar 2018 15:21:58 -0700
User-Agent: KMail/1.9.10

Quoted 3 lines · On Friday 23 March 2018 15:05:24 you wrote:

I still don't see bc 1.07.2 at http://ftp.gnu.org/gnu/bc/. Do you think you will have the time to push out this release in the near future ?

I will put it on the list for next week. Sorry I haven't done this yet.

--Phil

Signature · 14 lines
Phil Nelson

===========

As you can see, we're another year later, and bc 1.07.2 is still not
released it seems.

Best regards,

Thomas
-- 
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
#5 lore raw

Thomas,

Quoted 6 lines · Thomas Petazzoni

Hello Matt,

On Fri, 13 Sep 2019 20:31:45 +0200
Thomas Petazzoni <[email protected]> wrote:

Quoted 6 lines
Quoted 2 lines

He had sent me some test versions of bc 1.07.2 which should have fixed the problem, but I never took the time to reply it seems :-/

I correct this: the discussion was two years ago, it seems like I did provide some feedback and then in March 2018, I pinged the bc maintainer. See:

Ah ok, so it looks like your discussion was around 1.07.1. Should I
maybe give it another try with our current set of patches that are aligned with Debian?

I noticed your email was with respect to the libmath.h generation issues, were you just pointing those out to the maintainer or was there a better patch then the removal changes Yocto proposed?

Regards,
Matt

#6 lore raw

Hello,

Quoted 7 lines · On Fri, 13 Sep 2019 13:40:00 -0500 Matthew Weber <[email protected]>…

Ah ok, so it looks like your discussion was around 1.07.1. Should I
maybe give it another try with our current set of patches that are aligned with Debian?

I noticed your email was with respect to the libmath.h generation issues, were you just pointing those out to the maintainer or was there a better patch then the removal changes Yocto proposed?

I think it was the Yocto change that was proposed:

====
From: Thomas Petazzoni <[email protected]>
To: Phil Nelson <[email protected]>
Cc: Jose Lamego <[email protected]>, Vincent.Riera at imgtec.com, ken at gnu.org
Subject: Re: Please provide feedback: bc 1.07+ not building with Yocto project tools (libmath.h related)
Date: Wed, 23 Aug 2017 15:18:10 +0200
X-Mailer: Claws Mail 3.14.1 (GTK+ 2.24.31; x86_64-redhat-linux-gnu)
Organization: Free Electrons

Hello,

Quoted 7 lines · Phil Nelson
Quoted 4 lines · On Tuesday 18 July 2017 10:06:09 Jose Lamego wrote:

Hi Phil,

I just learned that Vincent, Thomas and others (cc'ed) have found the same issues as the Yocto team when trying to update bc recipe.

How does that attached version work?

This version works fine in the context of Buildroot, i.e it does not have additional dependencies that are annoying to provide.

When do you think you could release this updated version?

Thanks a lot!

Thomas

Signature · 14 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
===

I have uploaded at https://bootlin.com/~thomas/bc-1.07.2.tar.gz the
tarball that the maintainer gave me back then as a preview for 1.07.2
which was apparently never released.

Thomas
-- 
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
#7 lore raw

PATCH 1/1 package/bc: bump to 1.07.1

In reply to Matthew Weber

Thomas,

Quoted 61 lines · Matthew Weber

Thomas,

Quoted 15 lines · Thomas Petazzoni

Hello Matt,

Quoted 9 lines · On Thu, 12 Sep 2019 15:50:57 -0500 Matt Weber…

* Added license hash files
* Updated site to new GNU location
* Reconfig required to use newer automake
* Dropped patch for 01_array_initialize.patch as it was fixed in the latest
* Refactored patches for makeinfo variable and write io errs
* Added new dc fix exit code patch from Debian sid
* Added new libmath offline gen cross-compile patch from Yocto

Quoted 4 lines
Quoted 1 line

Do you know what is the upstream status for the different patches we had and that are still needed ?

For the patches that were kept in this bump, they were all still
pending and on the debian / yocto distro patch lists. I wasn't able
to find any upstream submissions. Are patches against gnu tools like bc done directly to the maintainer ( Phil Nelson <[email protected]>)? I could definitely send them out to him if that makes sense.

Quoted 19 lines
Quoted 19 lines
package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch new file +12 -0
new file mode 100644
index 0000000000..6f82e9f82e
@@ -0,0 +1,34 @@
+From 66d30778ec5bf98dbd106a3287d17fe0b5123490 Mon Sep 17 00:00:00 2001
+From: Matt Weber <[email protected]>
+Date: Wed, 11 Sep 2019 21:57:35 -0500
+Subject: [PATCH] bc: use MAKEINFO variable for docs
+
+Use the appropiate MAKEINFO variable rather than the hardcoded makeinfo
+command directly, otherwise missing logic never works.
+
+Fixes:
+http://autobuild.buildroot.net/results/b0b/b0b9dced0014a5a8026fa972f95085e8bd16a07b/
+
+[Recreated for 1.0.7.1 by Matt W]
Quoted 9 lines

package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch line 17

Quoted 5 lines
package/bc/0001-bc-use-MAKEINFO-variable-for-docs.patch new file +5 -0
+Signed-off-by: Gustavo Zacarias <[email protected]>
+Signed-off-by: Matthew Weber <[email protected]>
+---
+ doc/Makefile.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)

This patch is useless, because it modifies Makefile.in, but you have AUTORECONF = YES, so Makefile.in will be regenerated from Makefile.am.

Quoted 2 lines

Oops, true and it isn't easy to test on my system. When recreating I definitely did use the wrong file.

Now I see what happened, I took Gustavo's original which was against the Makefile.in.

I see that Makefile.am has a hardcoded
MAKEINFO = makeinfo --no-split

What would you propose I do? I can see if instead I could set it to the following which should also work, or I can just drop this patch and see if it is still a corner case that a autobuilder finds.... MAKEINFO = @MAKEINFO@ --no-split

Matt

#8 lore raw

PATCH 1/1 package/bc: bump to 1.07.1

Quoted 10 lines · On Fri, 13 Sep 2019 13:34:01 -0500 Matthew Weber <[email protected]>…

Now I see what happened, I took Gustavo's original which was against the Makefile.in.

I see that Makefile.am has a hardcoded
MAKEINFO = makeinfo --no-split

What would you propose I do? I can see if instead I could set it to the following which should also work, or I can just drop this patch and see if it is still a corner case that a autobuilder finds.... MAKEINFO = @MAKEINFO@ --no-split

Using @MAKEINFO@ in the Makefile.am seems like the right thing to do. It could even be sent upstream.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com