[PATCH 1/3] setarch changes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Aug 27, 2007 at 03:54:55PM +0200, Karel Zak wrote:
>  I'm going to release a stable util-linux-ng 2.13 in next 10 hours --
>  you have the last opportunity to submit a patch / updated PO files /
>  bug report.

I just walked through the complete debian diff, which now has 3 changes
that I think make sense for 2.13.  Here they are in 3 messages.

lamont
>From bc12d4e4a6c395c7eaed7f0bb28ffe42de161bb6 Mon Sep 17 00:00:00 2001
From: LaMont Jones <lamont@xxxxxxxxxxxx>
Date: Mon, 27 Aug 2007 09:50:46 -0600
Subject: [PATCH] Finish adding parisc support to setarch, and replace Debian's linux32

The original setarch/parisc patch was missing some code.

Debian had a pre-existing linux{32,64} command which supported only --3gb
and --4gb.  Adding support for those options allows setarch to replace that
package.

Signed-off-by: LaMont Jones <lamont@xxxxxxxxxxxx>
---
 configure.ac          |    1 +
 sys-utils/Makefile.am |    4 ++++
 sys-utils/setarch.c   |    7 ++++++-
 3 files changed, 11 insertions(+), 1 deletions(-)

diff --git a/configure.ac b/configure.ac
index 00157e2..cfc2179 100644
--- a/configure.ac
+++ b/configure.ac
@@ -253,6 +253,7 @@ UTIL_SET_ARCH(SPARC, sparc*)
 UTIL_SET_ARCH(PPC, ppc*|powerpc*)
 UTIL_SET_ARCH(M68K, m68*)
 UTIL_SET_ARCH(MIPS, mips*)
+UTIL_SET_ARCH(HPPA, hppa*)
 
 AC_ARG_ENABLE([arch],
   AS_HELP_STRING([--enable-arch], [do build arch]),
diff --git a/sys-utils/Makefile.am b/sys-utils/Makefile.am
index 6fc60aa..cf6d87e 100644
--- a/sys-utils/Makefile.am
+++ b/sys-utils/Makefile.am
@@ -65,6 +65,9 @@ endif
 if ARCH_IA64
 SETARCH_LINKS += i386 ia64
 endif
+if ARCH_HPPA
+SETARCH_LINKS += parisc parisc64
+endif
 
 install-exec-hook:
 	for I in $(RDEV_LINKS); do \
@@ -72,4 +75,5 @@ install-exec-hook:
 	done
 	for I in $(SETARCH_LINKS); do \
 		cd $(DESTDIR)$(usrbinexecdir) && ln -sf setarch $$I ; \
+		cd $(DESTDIR)$(man8dir) && ln -sf ../man8/setarch.8 $${I}.8; \
 	done
diff --git a/sys-utils/setarch.c b/sys-utils/setarch.c
index d0cfe22..6b695ae 100644
--- a/sys-utils/setarch.c
+++ b/sys-utils/setarch.c
@@ -122,7 +122,7 @@ int set_arch(const char *pers, unsigned long options)
     {PER_LINUX, "ia64", "ia64"},
 #endif
 #if defined(__hppa__)
-    {PER_LINUX, "parisc", "parisc"},
+    {PER_LINUX32, "parisc", "parisc"},
     {PER_LINUX, "parisc64", "parisc64"},
 #endif
 #if defined(__s390x__) || defined(__s390__)
@@ -211,6 +211,11 @@ int main(int argc, char *argv[])
     if (!strcmp(arg, "--help"))
       show_help();
 
+    if (!strcmp(arg, "--3gb"))
+      arg="-3";
+    else if (!strcmp(arg, "--4gb"))
+      continue;		/* just ignore this one */
+
     for (n = 1; arg[n]; n++) {
       int f;
 
-- 
1.5.2.3


[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux