Skip to content

Commit 48db661

Browse files
cpackham-atlnzmshych
authored andcommitted
crosstool-NG: Add upstream patch to allow building with docker
crosstool-NG wants to know the username but it isn't critical. Bring in an upstream patch that allows using docker containers started with the -u option to provide a numeric UID. Upstream commit crosstool-ng/crosstool-ng@aa6a6c3a Change-Id: I04f598ec48cbbd045dea5e523530abed47174de7 Signed-off-by: Chris Packham <[email protected]> Signed-off-by: Michael Shych <[email protected]>
1 parent 6cfbd01 commit 48db661

File tree

2 files changed

+27
-1
lines changed

2 files changed

+27
-1
lines changed
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
From aa6a6c3a34b3e2c5b094855e8d2b57a698457561 Mon Sep 17 00:00:00 2001
2+
From: Quentin Boswank <[email protected]>
3+
Date: Mon, 5 Feb 2024 16:20:18 +0100
4+
Subject: [PATCH] Ignore a bad id command to allow docker
5+
6+
Signed-off-by: Quentin Boswank <[email protected]>
7+
---
8+
scripts/crosstool-NG.sh | 2 +-
9+
1 file changed, 1 insertion(+), 1 deletion(-)
10+
11+
diff --git a/scripts/crosstool-NG.sh b/scripts/crosstool-NG.sh
12+
index 08dbf0de..900dcb18 100644
13+
--- a/scripts/crosstool-NG.sh
14+
+++ b/scripts/crosstool-NG.sh
15+
@@ -264,7 +264,7 @@ fi
16+
17+
# Good, now grab a bit of informations on the system we're being run on,
18+
# just in case something goes awok, and it's not our fault:
19+
-CT_SYS_USER=$(id -un)
20+
+CT_SYS_USER=$(id -un 2>/dev/null || echo "unknown")
21+
CT_SYS_HOSTNAME=$(hostname -f 2>/dev/null || true)
22+
# Hmmm. Some non-DHCP-enabled machines do not have an FQDN... Fall back to node name.
23+
CT_SYS_HOSTNAME="${CT_SYS_HOSTNAME:-$(uname -n)}"
24+
--
25+
2.50.1
26+

patches/crosstool-NG/series

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# Previous patches not applied on new revisions.
22
#allow-patching-custom-kernel-tarballs.patch
3-
3+
Ignore-a-bad-id-command-to-allow-docker.patch
44

0 commit comments

Comments
 (0)