summaryrefslogtreecommitdiff
path: root/games/HeroesOfMightAndMagic
diff options
context:
space:
mode:
authorPav Lucistnik <pav@FreeBSD.org>2003-12-04 10:29:39 +0000
committerPav Lucistnik <pav@FreeBSD.org>2003-12-04 10:29:39 +0000
commit9c1d6cb1f7360b18c5670cc6a68f94acee11edad (patch)
tree486c056aff03672d225995339163bce0334cc18a /games/HeroesOfMightAndMagic
parentAdd CONFLICTS (diff)
- Move plist creation to build target
PR: ports/59681 Submitted by: Simun Mikecin <sime@logos.hr> Approved by: maintainer Approved by: adamw (mentor)
Notes
Notes: svn path=/head/; revision=94940
Diffstat (limited to 'games/HeroesOfMightAndMagic')
-rw-r--r--games/HeroesOfMightAndMagic/scripts/configure35
-rw-r--r--games/HeroesOfMightAndMagic/scripts/do-install13
2 files changed, 36 insertions, 12 deletions
diff --git a/games/HeroesOfMightAndMagic/scripts/configure b/games/HeroesOfMightAndMagic/scripts/configure
index b23b90c2e439..159db7c06d48 100644
--- a/games/HeroesOfMightAndMagic/scripts/configure
+++ b/games/HeroesOfMightAndMagic/scripts/configure
@@ -53,4 +53,39 @@ echo MUSIC=$answ >> $F
yesno NO "Do you want to install Videos (137 MB) "
echo VIDEOS=$answ >> $F
+. $F
+
+cat ${PKGDIR}/files/pkg-plist.base > ${PLIST}
+
+# Scenario files
+if [ $SCENARIO = YES ]; then
+ cat ${PKGDIR}/files/pkg-plist.scenario >> ${PLIST}
+else
+ echo ${GAMESUBDIR}/maps >> ${PLIST}
+fi
+
+# Neither sound nor Music, make the whole data tree a link
+if [ $GRAPHIC = NO -a $MUSIC = NO ]; then
+ echo ${GAMESUBDIR}/data/video >> ${PLIST}
+else
+ cat ${PKGDIR}/files/pkg-plist.video >> ${PLIST}
+fi
+
+# Videos
+if [ $VIDEOS = YES ]; then
+ cat ${PKGDIR}/files/pkg-plist.video >> ${PLIST}
+fi
+
+
+
+# Music
+if [ $MUSIC = YES ]; then
+ cat ${PKGDIR}/files/pkg-plist.music >> ${PLIST}
+else
+ echo ${GAMESUBDIR}/mp3 >> ${PLIST}
+fi
+
+echo @dirrm ${GAMESUBDIR}/data >> ${PLIST}
+echo @dirrm ${GAMESUBDIR} >> ${PLIST}
+
exit 0
diff --git a/games/HeroesOfMightAndMagic/scripts/do-install b/games/HeroesOfMightAndMagic/scripts/do-install
index 7b17e5a55ce3..489da4882cc7 100644
--- a/games/HeroesOfMightAndMagic/scripts/do-install
+++ b/games/HeroesOfMightAndMagic/scripts/do-install
@@ -21,11 +21,11 @@ ${INSTALL_DATA} ${CD}/icon.bmp ${CD}/icon.xpm ${GAMEDIR}
# INSTALL_PROGRAM (its parameter -s) currupts the file. Using cp.
cp ${CD}/bin/x86/heroes3 ${GAMEDIR}
+chmod 755 ${GAMEDIR}/heroes3
brandelf -t Linux ${GAMEDIR}/heroes3
ln -sf ${GAMEDIR}/heroes3 ${LOCALBASE}/bin/heroes3
touch ${GAMEDIR}/data/hiscore.dat
chmod 666 ${GAMEDIR}/data/hiscore.dat
-cat ${PKGDIR}/files/pkg-plist.base > ${PLIST}
# Basis packet
if [ $BASIC = YES ]; then
@@ -43,18 +43,13 @@ if [ $SCENARIO = YES ]; then
echo Installing Scenarios
mkdir -p ${GAMEDIR}/maps
${INSTALL_DATA} ${CD}/maps/* ${GAMEDIR}/maps
- cat ${PKGDIR}/files/pkg-plist.scenario >> ${PLIST}
else
ln -sf ${CD}/maps ${GAMEDIR}/maps
- echo ${GAMESUBDIR}/maps >> ${PLIST}
fi
# Neither sound nor Music, make the whole data tree a link
if [ $GRAPHIC = NO -a $MUSIC = NO ]; then
ln -sf ${CD}/data/video ${GAMEDIR}/data/video
- echo ${GAMESUBDIR}/data/video >> ${PLIST}
-else
- cat ${PKGDIR}/files/pkg-plist.video >> ${PLIST}
fi
# Graphics (recommended)
@@ -77,7 +72,6 @@ if [ $VIDEOS = YES ]; then
echo Installing Videos
mkdir -p ${GAMEDIR}/data/video
${INSTALL_DATA} ${CD}/data/video/*.mpg ${GAMEDIR}/data/video
- cat ${PKGDIR}/files/pkg-plist.video >> ${PLIST}
elif [ $GRAPHIC = YES ]; then
# Music is installed, so create links
cd $CD/data/video
@@ -92,15 +86,10 @@ if [ $MUSIC = YES ]; then
echo Installing Music
mkdir -p ${GAMEDIR}/mp3
${INSTALL_DATA} ${CD}/mp3/* ${GAMEDIR}/mp3
- cat ${PKGDIR}/files/pkg-plist.music >> ${PLIST}
else
ln -sf ${CD}/mp3 ${GAMEDIR}/mp3
- echo ${GAMESUBDIR}/mp3 >> ${PLIST}
fi
- echo @dirrm ${GAMESUBDIR}/data >> ${PLIST}
- echo @dirrm ${GAMESUBDIR} >> ${PLIST}
-
# Goodbye message
if [ $BASIC = YES -a $GRAPHIC = YES ]; then
echo