Whamcloud - gitweb
Branch: b_cray-1_4_2
authorgreen <green>
Tue, 31 May 2005 20:25:50 +0000 (20:25 +0000)
committergreen <green>
Tue, 31 May 2005 20:25:50 +0000 (20:25 +0000)
If liblustre was built, add liblustre.{a,so} to the lustre package

build/lustre.spec.in

index 2c41cf0..0f827d5 100644 (file)
@@ -104,7 +104,7 @@ rm -f lustre-source
 ln -s $RPM_BUILD_ROOT/usr/src lustre-source
 make distdir distdir=lustre-source/lustre-%{version}
 
-%files
+cat >lustre.files <<EOF
 %attr(-, root, root) /sbin/mount.lustre
 %attr(-, root, root) /usr/sbin/*
 %attr(-, root, root) /usr/bin/*
@@ -125,6 +125,13 @@ make distdir distdir=lustre-source/lustre-%{version}
 %attr(-, root, root) /etc/openldap/schema/lustre.schema
 %attr(-, root, root) /usr/share/lustre/lustre2ldif.xsl
 %attr(-, root, root) /usr/share/lustre/top.ldif
+EOF
+if [ -f $RPM_BUILD_ROOT/usr/lib/liblustre.so ] ; then
+  echo '%attr(-, root, root) %{_libdir}/liblustre.a' >>lustre.files
+  echo '%attr(-, root, root) %{_libdir}/liblustre.so' >>lustre.files
+fi
+
+%files -f lustre.files
 
 %files modules
 %attr(-, root, root) %doc COPYING