From 29b77e066a60e9b9d775bebb02f5ede502dccf3b Mon Sep 17 00:00:00 2001 From: xq2005 Date: Sun, 6 Jan 2013 03:27:26 +0000 Subject: [PATCH] build xcat-genesis on debian git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@14756 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-nbroot2/debian/rules | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/xCAT-nbroot2/debian/rules b/xCAT-nbroot2/debian/rules index 45e2be9de..64c636f39 100755 --- a/xCAT-nbroot2/debian/rules +++ b/xCAT-nbroot2/debian/rules @@ -17,7 +17,15 @@ build: mkdir -p /usr/share/dracut/modules.d/97xcat cp -r * /usr/share/dracut/modules.d/97xcat rm -rf /usr/share/dracut/modules.d/97xcat/debian - mv /usr/share/dracut/modules.d/97xcat/install.ubuntu /usr/share/dracut/modules.d/97xcat/install + version=`head -n 1 /etc/issue | awk '{print $$1}'`;if [ $$version = 'Debian' ]; then\ + mkdir -p /usr/lib/dracut/modules.d/97xcat;\ + cp -r * /usr/lib/dracut/modules.d/97xcat;\ + rm -rf /usr/lib/dracut/modules.d/97xcat/debian;\ + mv /usr/share/dracut/modules.d/97xcat/install.debian /usr/share/dracut/modules.d/97xcat/install; \ + mv /usr/lib/dracut/modules.d/97xcat/install.debian /usr/lib/dracut/modules.d/97xcat/install; \ + else\ + mv /usr/share/dracut/modules.d/97xcat/install.ubuntu /usr/share/dracut/modules.d/97xcat/install;\ + fi mkdir -p $(buildroot)/opt/xcat/share/xcat/netboot/genesis/$(DEB_BUILD_GNU_CPU)/fs dracut -m "xcat base" -f /tmp/xcatgenesis.tmp.rfs (cd $(buildroot)/opt/xcat/share/xcat/netboot/genesis/$(DEB_BUILD_GNU_CPU)/fs/ && zcat /tmp/xcatgenesis.tmp.rfs|cpio -dumi)