Re: [Cbe-oss-dev] LIO Target iSCSI/SE PS3-Linux / FC8 builds

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Nicholas A. Bellinger <nab@...>
Cc: <cbe-oss-dev@...>, linux-scsi <linux-scsi@...>, LKML <linux-kernel@...>, Open iSCSI <open-iscsi@...>
Date: Monday, February 4, 2008 - 12:44 pm

Hi Nicholas,

thanks for your quick reply.

Am Montag 04 Februar 2008 16:52:40 schrieb Nicholas A. Bellinger:

Yes, this works. The arch detection is a little ugly. I wonder why it is 
necessary at all.


I don't think, that it is useful to provide a kernel module rpm - kernels are 
changing to fast ;-) Better go for dkms ...

Anyway, heres a quick ugly fix for the ARCH detection code, tested on ps3.

Thanks

Marc


--- ostype.pm.orig      2008-02-04 17:02:48.000000000 +0100
+++ ostype.pm   2008-02-04 17:37:19.000000000 +0100
@@ -33,14 +33,10 @@

     if ($rval->{ARCH} eq "")
     {
-       my $uname = `file $root/bin/ls`;
-       $uname =~ s/\n+//g;
-
-       $rval->{ARCH}="x86_64" if ($uname =~ /64.*(AMD|Intel)/);
-       $rval->{ARCH}="i386" if ($uname =~ /32.*(AMD|Intel)/);
-       $rval->{ARCH}="ppc" if ($uname =~ /32.*(PowerPC)/);
-       $rval->{ARCH}="ppc64" if ($uname =~ /64.*(PowerPC)/);
-       $rval->{ARCH}="alpha" if ($uname =~ /64.*(Alpha)/);
+       my $uname = `uname -r`;
+       $uname =~ s/\n//g;
+       $rval->{ARCH} = readlink "/lib/modules/$uname/build/include/asm";
+       $rval->{ARCH} =~ s/asm\-(.*)/\1/g;
     }
     if ($rval->{ARCH} eq "")
     {






-- 
	"We do not want war."
		 Lord Arthur Ponsonby, "Falsehood in Wartime: Propaganda Lies of the First 
World War", 1928
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [Cbe-oss-dev] LIO Target iSCSI/SE PS3-Linux / FC8 builds, Nicholas A. Bellinger, (Mon Feb 4, 11:52 am)
Re: [Cbe-oss-dev] LIO Target iSCSI/SE PS3-Linux / FC8 builds, Marc Dietrich, (Mon Feb 4, 12:44 pm)
Re: [Cbe-oss-dev] LIO Target iSCSI/SE PS3-Linux / FC8 builds, Nicholas A. Bellinger, (Mon Feb 4, 12:03 pm)