SPECS: shfs.spec - nfy

arekm arekm at pld-linux.org
Sat Nov 12 02:23:50 CET 2005


Author: arekm                        Date: Sat Nov 12 01:23:50 2005 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- nfy

---- Files affected:
SPECS:
   shfs.spec (1.40 -> 1.41) 

---- Diffs:

================================================================
Index: SPECS/shfs.spec
diff -u SPECS/shfs.spec:1.40 SPECS/shfs.spec:1.41
--- SPECS/shfs.spec:1.40	Thu Sep 15 20:25:05 2005
+++ SPECS/shfs.spec	Sat Nov 12 02:23:44 2005
@@ -28,9 +28,17 @@
 BuildRequires:	rpmbuild(macros) >= 1.153
 %endif
 %{?with_dist_kernel:Requires:	kernel-fs-shfs}
+%ifarch sparc
+BuildRequires:	crosssparc64-gcc
+%endif
 Obsoletes:	shfsmount
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
+%ifarch sparc
+%define         _target_base_arch       sparc64
+%define         _target_cpu             sparc64
+%endif
+
 %description
 SHFS is a simple and easy to use Linux kernel 2.4.10+ and 2.6 module
 which allows you to mount remote filesystems using plain shell
@@ -105,7 +113,17 @@
 	install -d include/{linux,config}
 	ln -sf %{_kernelsrcdir}/config-$cfg .config
 	ln -sf %{_kernelsrcdir}/include/linux/autoconf-$cfg.h include/linux/autoconf.h
-	ln -sf %{_kernelsrcdir}/include/asm-%{_target_base_arch} include/asm
+%ifarch ppc
+        if [ -d "%{_kernelsrcdir}/include/asm-powerpc" ]; then
+                install -d include/asm
+                cp -a %{_kernelsrcdir}/include/asm-%{_target_base_arch}/* include/asm
+                cp -a %{_kernelsrcdir}/include/asm-powerpc/* include/asm
+        else
+                ln -sf %{_kernelsrcdir}/include/asm-powerpc include/asm
+        fi
+%else
+        ln -sf %{_kernelsrcdir}/include/asm-%{_target_base_arch} include/asm
+%endif
 	ln -sf %{_kernelsrcdir}/Module.symvers-$cfg Module.symvers
 	touch include/config/MARKER
 	echo "obj-m := shfs.o" > Makefile
@@ -115,6 +133,11 @@
 		RCS_FIND_IGNORE="-name '*.ko' -o" \
 		M=$PWD O=$PWD
 	%{__make} -C %{_kernelsrcdir} modules \
+%if "%{_target_base_arch}" != "%{_arch}"
+                ARCH=%{_target_base_arch} \
+                CROSS_COMPILE=%{_target_cpu}-pld-linux- \
+%endif
+                HOSTCC="%{__cc}" \
 		%{?with_verbose:V=1} \
 		M=$PWD O=$PWD
 	mv shfs.ko shfs-$cfg.ko
@@ -195,6 +218,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.41  2005/11/12 01:23:44  arekm
+- nfy
+
 Revision 1.40  2005/09/15 18:25:05  sparky
 - prepared for kernel >= 2.6.13: link Module.symvers
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SPECS/shfs.spec?r1=1.40&r2=1.41&f=u




More information about the pld-cvs-commit mailing list