1 |
#!/bin/sh |
2 |
|
3 |
[ -d cdrom.image ] || (echo "No cdrom.image directory?"; exit 1) |
4 |
|
5 |
distname='SME Server' |
6 |
distrel=7 |
7 |
distvers=$(basename $(pwd)) |
8 |
distarch=$(uname -i) |
9 |
|
10 |
PYTHONPATH=/usr/lib/anaconda/ /usr/lib/anaconda-runtime/genhdlist \ |
11 |
--withnumbers \ |
12 |
$(pwd)/cdrom.image/ |
13 |
|
14 |
PYTHONPATH=/usr/lib/anaconda/ /usr/lib/anaconda-runtime/pkgorder \ |
15 |
$(pwd)/cdrom.image \ |
16 |
$distarch > pkgorder |
17 |
|
18 |
for PKG in /releases/$distrel/smeextras/$distarch/RPMS/*.rpm |
19 |
do |
20 |
PKGFILE=$(basename $PKG) |
21 |
if [ ! -f $(pwd)/cdrom.image/SME/$PKGFILE ] |
22 |
then |
23 |
ln -sf $PKG $(pwd)/cdrom.image/CentOS/RPMS/ |
24 |
fi |
25 |
done |
26 |
|
27 |
PYTHONPATH=/usr/lib/anaconda/ sudo /usr/lib/anaconda-runtime/buildinstall \ |
28 |
--product "$distname" \ |
29 |
--version "$distrel.0" \ |
30 |
--release "$distname" \ |
31 |
--pkgorder pkgorder \ |
32 |
$(pwd)/cdrom.image/ |
33 |
|
34 |
# Remove previous linked files |
35 |
find $(pwd)/cdrom.image/CentOS/RPMS/ -type l | xargs rm -f |
36 |
|
37 |
# Copy updated isolinux files |
38 |
sudo cp -f /builds/isolinux/* $(pwd)/cdrom.image/isolinux/ |
39 |
|
40 |
sed -i 's@1,2,3@1@' $(pwd)/cdrom.image/.discinfo |
41 |
|
42 |
sudo chown -R buildcvs:developers $(pwd)/cdrom.image/ |
43 |
sudo chmod -R g+w $(pwd)/cdrom.image/ |
44 |
|
45 |
echo "You now need to run /builds/bin/build_ISO as non-root" |
46 |
|
47 |
# That's it. |