Skip to contentSkip to conversation

make deb-pkg: optionally use fakeroot

BUG/PATCH Matthias Lederhofer 2 participants 3 messages Sep 8, 2006 – Sep 9, 2006 Kbuild

lore
Share & tools
lore
#0 lore raw

Problem: deb-pkg needs root privileges or fakeroot but git-diff-index does not work correctly with fakeroot. Perhaps this variable should have another name and be added to the other package targets too.

---
 scripts/package/Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
scripts/package/Makefile +1 -1
index 7c434e0..d77e21a 100644
@@ -72,7 +72,7 @@ # Deb target
 # ---------------------------------------------------------------------------
 deb-pkg: FORCE
 	$(MAKE) KBUILD_SRC=
-	$(CONFIG_SHELL) $(srctree)/scripts/package/builddeb
+	$(FAKEROOT) $(CONFIG_SHELL) $(srctree)/scripts/package/builddeb
 
 clean-dirs += $(objtree)/debian/
 
Signature · 1 line
1.4.2.g0ea2
#1 lore raw

scripts/package/Makefile # Deb target · line 75

Quoted 11 lines
scripts/package/Makefile +0 -0
index 7c434e0..d77e21a 100644
@@ -72,7 +72,7 @@ # Deb target
 # ---------------------------------------------------------------------------

deb-pkg: FORCE

	$(MAKE) KBUILD_SRC=
scripts/package/Makefile +1 -1
-	$(CONFIG_SHELL) $(srctree)/scripts/package/builddeb
+	$(FAKEROOT) $(CONFIG_SHELL) $(srctree)/scripts/package/builddeb

Why are distribution-specific things/objects/targets even included?

Jan Engelhardt

#2 lore raw
In reply to Matthias Lederhofer
Quoted 3 lines · Matthias Lederhofer

Problem: deb-pkg needs root privileges or fakeroot but git-diff-index does not work correctly with fakeroot. Perhaps this variable should have another name and be added to the other package targets too.

<gitster> So "fakeroot -u" (Use the real ownership of files previously
unknown to fakeroot instead of pretending they are owned by root:root.) would be a good workaround.
<gitster> Eh, not a workaround but probably that is the right thing to do.

This solves the problem, just ignore the patch.