Skip to contentSkip to conversation

package/libnss: fix build failure with make 4.3.91

PATCH Applied Giulio Benetti 3 participants 3 messages Nov 17, 2022 – Nov 21, 2022

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/libnss: fix build failure with make 4.3.91

Make 4.3.91 doesn't allow to safely override Simple Expanded Variables, so let's add a patch pending upstream[0] to make those variable Conditional Expanded.

[0]: https://bugzilla.mozilla.org/show_bug.cgi?id=1801182

Fixes:
http://autobuild.buildroot.net/results/1074143dbea60567cd83be0a23f7c0214d470de9/

---
 ...w-overriding-OS_ARCH-OS_TEST-and-OS_.patch | 45 +++++++++++++++++++
 1 file changed, 45 insertions(+)
 create mode 100644 package/libnss/0001-Bug-1801182-Allow-overriding-OS_ARCH-OS_TEST-and-OS_.patch
package/libnss/0001-Bug-1801182-Allow-overriding-OS_ARCH-OS_TEST-and-OS_.patch new file +45 -0
new file mode 100644
index 0000000000..7b3abea307
@@ -0,0 +1,45 @@
+From a1a5f3afea2ee59bdbb7a74eb2d7f82b635dbd1a Mon Sep 17 00:00:00 2001
+From: Giulio Benetti <[email protected]>
+Date: Thu, 17 Nov 2022 20:38:48 +0100
+Subject: [PATCH] Bug 1801182 - Allow overriding OS_ARCH, OS_TEST and
+ OS_RELEASE in Makefile
+
+Starting from Make 4.3.91 simple expanded variables can't be safely
+overriden via command line anymore, so let's use conditional expanded
+variables to override OS_ARCH, OS_TEST and OS_RELEASE.
+
+Signed-off-by: Giulio Benetti <[email protected]>
+[Upstream status: https://bugzilla.mozilla.org/show_bug.cgi?id=1801182]
+---
+ nss/coreconf/arch.mk | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/nss/coreconf/arch.mk b/nss/coreconf/arch.mk
+index 17e9faeac..85aac9341 100644
+--- a/nss/coreconf/arch.mk
++++ b/nss/coreconf/arch.mk
+@@ -20,17 +20,17 @@
+ # Macros for getting the OS architecture
+ #
+ 
+-OS_ARCH := $(subst /,_,$(shell uname -s))
++OS_ARCH ?= $(subst /,_,$(shell uname -s))
+ 
+ #
+ # Attempt to differentiate between sparc and x86 Solaris
+ #
+ 
+-OS_TEST := $(shell uname -m)
++OS_TEST ?= $(shell uname -m)
+ ifeq ($(OS_TEST),i86pc)
+-    OS_RELEASE := $(shell uname -r)_$(OS_TEST)
++    OS_RELEASE ?= $(shell uname -r)_$(OS_TEST)
+ else
+-    OS_RELEASE := $(shell uname -r)
++    OS_RELEASE ?= $(shell uname -r)
+ endif
+ 
+ 
+-- 
+2.34.1
+
Signature · 6 lines
2.34.1

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Tested-by on v1 1/1
#1 lore raw
Quoted 11 lines · Giulio Benetti

Make 4.3.91 doesn't allow to safely override Simple Expanded Variables, so let's add a patch pending upstream[0] to make those variable Conditional Expanded.

[0]: https://bugzilla.mozilla.org/show_bug.cgi?id=1801182

Fixes:
http://autobuild.buildroot.net/results/1074143dbea60567cd83be0a23f7c0214d470de9/

Quoted 59 lines
---
 ...w-overriding-OS_ARCH-OS_TEST-and-OS_.patch | 45 +++++++++++++++++++
 1 file changed, 45 insertions(+)
 create mode 100644 package/libnss/0001-Bug-1801182-Allow-overriding-OS_ARCH-OS_TEST-and-OS_.patch
package/libnss/0001-Bug-1801182-Allow-overriding-OS_ARCH-OS_TEST-and-OS_.patch new file +45 -1
new file mode 100644
index 0000000000..7b3abea307
@@ -0,0 +1,45 @@
+From a1a5f3afea2ee59bdbb7a74eb2d7f82b635dbd1a Mon Sep 17 00:00:00 2001
+From: Giulio Benetti <[email protected]>
+Date: Thu, 17 Nov 2022 20:38:48 +0100
+Subject: [PATCH] Bug 1801182 - Allow overriding OS_ARCH, OS_TEST and
+ OS_RELEASE in Makefile
+
+Starting from Make 4.3.91 simple expanded variables can't be safely
+overriden via command line anymore, so let's use conditional expanded
+variables to override OS_ARCH, OS_TEST and OS_RELEASE.
+
+Signed-off-by: Giulio Benetti <[email protected]>
+[Upstream status: https://bugzilla.mozilla.org/show_bug.cgi?id=1801182]
+---
+ nss/coreconf/arch.mk | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/nss/coreconf/arch.mk b/nss/coreconf/arch.mk
+index 17e9faeac..85aac9341 100644
+--- a/nss/coreconf/arch.mk
++++ b/nss/coreconf/arch.mk
+@@ -20,17 +20,17 @@
+ # Macros for getting the OS architecture
+ #
+
+-OS_ARCH := $(subst /,_,$(shell uname -s))
++OS_ARCH ?= $(subst /,_,$(shell uname -s))
+
+ #
+ # Attempt to differentiate between sparc and x86 Solaris
+ #
+
+-OS_TEST := $(shell uname -m)
++OS_TEST ?= $(shell uname -m)
+ ifeq ($(OS_TEST),i86pc)
+-    OS_RELEASE := $(shell uname -r)_$(OS_TEST)
++    OS_RELEASE ?= $(shell uname -r)_$(OS_TEST)
+ else
+-    OS_RELEASE := $(shell uname -r)
++    OS_RELEASE ?= $(shell uname -r)
+ endif
+
+
+--
+2.34.1
+
--

2.34.1

Quoted 4 lines

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot

#2 lore raw
In reply to Giulio Benetti
Quoted 6 lines · On Thu, 17 Nov 2022 20:45:05 +0100 Giulio Benetti…

Make 4.3.91 doesn't allow to safely override Simple Expanded Variables, so let's add a patch pending upstream[0] to make those variable Conditional Expanded.

[0]: https://bugzilla.mozilla.org/show_bug.cgi?id=1801182

Quoted 8 lines

Fixes:
http://autobuild.buildroot.net/results/1074143dbea60567cd83be0a23f7c0214d470de9/

---
 ...w-overriding-OS_ARCH-OS_TEST-and-OS_.patch | 45 +++++++++++++++++++
 1 file changed, 45 insertions(+)
 create mode 100644 package/libnss/0001-Bug-1801182-Allow-overriding-OS_ARCH-OS_TEST-and-OS_.patch

Applied to master, thanks.

Thomas

Signature · 7 lines
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot