Lines 1-21
Link Here
|
1 |
# Copyright 1999-2005 Gentoo Foundation |
1 |
# Copyright 1999-2005 Gentoo Foundation |
2 |
# Distributed under the terms of the GNU General Public License v2 |
2 |
# Distributed under the terms of the GNU General Public License v2 |
3 |
# $Header: /var/cvsroot/gentoo-x86/games-rpg/eternal-lands/eternal-lands-1.0.1.ebuild,v 1.2 2005/06/09 01:08:50 mr_bones_ Exp $ |
3 |
# $Header: /var/cvsroot/gentoo-x86/games-rpg/eternal-lands/eternal-lands-1.1.0-r1.ebuild,v 1.2 2005/06/09 01:08:50 mr_bones_ Exp $ |
4 |
|
4 |
|
5 |
inherit games |
5 |
inherit games |
6 |
|
6 |
|
7 |
TMP_PV=${PV%_p*} |
7 |
TMP_PV=${PV%_p*} |
8 |
DESCRIPTION="An online MMORPG written in C and SDL" |
8 |
DESCRIPTION="An online MMORPG written in C and SDL" |
9 |
HOMEPAGE="http://www.eternal-lands.com" |
9 |
HOMEPAGE="http://www.eternal-lands.com" |
10 |
SRC_URI="http://el.tfm.ro/el_${TMP_PV//.}.zip |
10 |
SRC_URI="http://el.tfm.ro/el_${TMP_PV//.}-t1.zip |
11 |
ftp://ftp.berlios.de/pub/elc/elc_${PV//.}.tgz |
11 |
ftp://ftp.berlios.de/pub/elc/elc_${TMP_PV//.}.tgz |
12 |
mapeditor? ( ftp://ftp.berlios.de/pub/elc/mapedit_${PV//.}.tgz ) |
12 |
mapeditor? ( ftp://ftp.berlios.de/pub/elc/mapedit_${TMP_PV//.}.tgz ) |
13 |
!nomusic? ( http://el.tfm.ro/el_music_${PV//.}.zip )" |
13 |
!nomusic? ( http://el.tfm.ro/el_music_101.zip )" |
14 |
|
14 |
|
15 |
LICENSE="eternal_lands" |
15 |
LICENSE="eternal_lands" |
16 |
SLOT="0" |
16 |
SLOT="0" |
17 |
KEYWORDS="~amd64 ~x86" |
17 |
KEYWORDS="~amd64 ~x86" |
18 |
IUSE="doc nomusic mapeditor" |
18 |
IUSE="doc nomusic mapeditor netthread" |
19 |
|
19 |
|
20 |
RDEPEND="virtual/x11 |
20 |
RDEPEND="virtual/x11 |
21 |
virtual/opengl |
21 |
virtual/opengl |
Lines 24-30
Link Here
|
24 |
>media-libs/openal-20020127 |
24 |
>media-libs/openal-20020127 |
25 |
media-libs/libvorbis |
25 |
media-libs/libvorbis |
26 |
>=dev-libs/libxml2-2.6.7 |
26 |
>=dev-libs/libxml2-2.6.7 |
27 |
mapeditor? ( <x11-libs/gtk+-1.3 )" |
27 |
=media-libs/cal3d-0.10.0 |
|
|
28 |
>=media-libs/libpng-1.2.8 |
29 |
mapeditor? (>=x11-libs/gtk+-2.4)" |
28 |
|
30 |
|
29 |
DEPEND="${RDEPEND} |
31 |
DEPEND="${RDEPEND} |
30 |
app-arch/unzip |
32 |
app-arch/unzip |
Lines 32-52
Link Here
|
32 |
>=media-gfx/graphviz-1.10 )" |
34 |
>=media-gfx/graphviz-1.10 )" |
33 |
|
35 |
|
34 |
src_unpack() { |
36 |
src_unpack() { |
35 |
OPTIONS="OPTIONS=-DDATA_DIR="\\\\\"${GAMES_DATADIR}/${PN}/\\\\\"" " |
37 |
OPTIONS="OPTIONS=-DDATA_DIR="\\\\\"${GAMES_DATADIR}/${PN}/\\\\\""" |
36 |
S_CLIENT="${WORKDIR}/elc" |
38 |
S_CLIENT="${WORKDIR}/elc" |
37 |
S_MAPEDITOR="${WORKDIR}/map_editor" |
39 |
S_MAPEDITOR="${WORKDIR}/map_editor" |
|
|
40 |
BROWSER="mozilla" |
38 |
|
41 |
|
39 |
unpack ${A} |
42 |
unpack ${A} |
40 |
use amd64 && OPTIONS="${OPTIONS} -DX86_64" |
43 |
use amd64 && OPTIONS="${OPTIONS} -DX86_64" |
|
|
44 |
use netthread && OPTIONS="${OPTIONS} -DNETWORK_THREAD" |
41 |
cd "${S_CLIENT}" |
45 |
cd "${S_CLIENT}" |
42 |
sed \ |
46 |
sed \ |
43 |
-e "s@CFLAGS=\$(PLATFORM) -Wall -O -Werror -ggdb -pipe @CFLAGS=${CFLAGS} @g" \ |
47 |
-e "s@CFLAGS=\$(PLATFORM) \$(CWARN) -O -ggdb -pipe@CFLAGS=${CFLAGS} @g"\ |
|
|
48 |
-e "s@CXXFLAGS=\$(PLATFORM) \$(CXXWARN) -O -ggdb -pipe@CXXFLAGS=${CXXFLAGS} @g"\ |
44 |
-e "s@OPTIONS=@${OPTIONS} @g" \ |
49 |
-e "s@OPTIONS=@${OPTIONS} @g" \ |
45 |
Makefile.linux > Makefile \ |
50 |
Makefile.linux > Makefile \ |
46 |
|| die "sed failed" |
51 |
|| die "sed failed" |
47 |
sed \ |
52 |
sed \ |
48 |
-e 's/#browser/browser/g' \ |
53 |
-e 's/#browser/browser/g' \ |
49 |
-e 's/browser = mozilla/#browser = mozilla/g' \ |
54 |
-e "s/browser = mozilla/#browser = ${BROWSER}/g" \ |
50 |
-e "s@#data_dir = /usr/local/games/el/@#data_dir = ${GAMES_DATADIR}/${PN}/@g" \ |
55 |
-e "s@#data_dir = /usr/local/games/el/@#data_dir = ${GAMES_DATADIR}/${PN}/@g" \ |
51 |
el.ini > ../el.ini \ |
56 |
el.ini > ../el.ini \ |
52 |
|| die "sed failed" |
57 |
|| die "sed failed" |
Lines 65-71
Link Here
|
65 |
fi |
70 |
fi |
66 |
cd ${WORKDIR} |
71 |
cd ${WORKDIR} |
67 |
cp license.txt EULA || die "cp failed" |
72 |
cp license.txt EULA || die "cp failed" |
68 |
cp changes.txt ChangeLog || die "cp failed" |
73 |
cp -r ${S_CLIENT}/languages . |
69 |
} |
74 |
} |
70 |
|
75 |
|
71 |
src_compile() { |
76 |
src_compile() { |
Lines 73-79
Link Here
|
73 |
emake || die "emake failed" |
78 |
emake || die "emake failed" |
74 |
cp el.x86.linux.bin ../el.x86.linux.bin || die "cp failed" |
79 |
cp el.x86.linux.bin ../el.x86.linux.bin || die "cp failed" |
75 |
if use doc; then |
80 |
if use doc; then |
76 |
emake docs || die "Failed to create documentation, try with USE=-docs" |
81 |
emake docs || die "Failed to create documentation, try with USE=-doc" |
77 |
mv ./docs/html/ ../client || die "Failed to move documentation directory" |
82 |
mv ./docs/html/ ../client || die "Failed to move documentation directory" |
78 |
fi |
83 |
fi |
79 |
if use mapeditor; then |
84 |
if use mapeditor; then |
Lines 85-110
Link Here
|
85 |
|
90 |
|
86 |
src_install () { |
91 |
src_install () { |
87 |
cd "${WORKDIR}" |
92 |
cd "${WORKDIR}" |
|
|
93 |
|
88 |
newgamesbin el.x86.linux.bin el || die "newgamesbin failed" |
94 |
newgamesbin el.x86.linux.bin el || die "newgamesbin failed" |
89 |
if use mapeditor; then |
95 |
if use mapeditor; then |
90 |
newgamesbin mapedit.x86.linux.bin el-mapedit \ |
96 |
newgamesbin mapedit.x86.linux.bin el-mapedit \ |
91 |
|| die "newgamesbin failed" |
97 |
|| die "newgamesbin failed" |
92 |
fi |
98 |
fi |
93 |
|
99 |
|
94 |
dodoc ChangeLog EULA |
100 |
doicon el_icon.png || die "doicon failed" |
|
|
101 |
|
102 |
dodoc EULA |
95 |
insinto "${GAMES_DATADIR}/${PN}" |
103 |
insinto "${GAMES_DATADIR}/${PN}" |
96 |
doins *.ini entrable.lst harvestable.lst el_icon.png icon.bmp \ |
104 |
|
97 |
global_filters.txt local_ignores.txt e3dlist.txt \ |
105 |
doins *.ini entrable.lst harvestable.lst \ |
|
|
106 |
global_filters.txt e3dlist.txt \ |
98 |
|| die "doins failed" |
107 |
|| die "doins failed" |
99 |
|
108 |
|
100 |
if use mapeditor; then |
109 |
if use mapeditor; then |
|
|
110 |
cp -r mapeditor ${D}/${GAMES_DATADIR}/${PN} || die "copy failed" |
101 |
doins browser.lst || die "doins failed" |
111 |
doins browser.lst || die "doins failed" |
102 |
fi |
112 |
fi |
103 |
|
113 |
|
104 |
cp -R 2dobjects 3dobjects languages maps md2 particles sound textures tiles \ |
114 |
cp -R 2dobjects 3dobjects languages maps particles sound textures tiles\ |
|
|
115 |
meshes animations actor_defs books skeletons\ |
105 |
"${D}/${GAMES_DATADIR}/${PN}" \ |
116 |
"${D}/${GAMES_DATADIR}/${PN}" \ |
106 |
|| die "copy failed" |
117 |
|| die "copy failed" |
107 |
|
118 |
|
108 |
if ! use nomusic; then |
119 |
if ! use nomusic; then |
109 |
cp -R music "${D}/${GAMES_DATADIR}/${PN}" || die "cp failed" |
120 |
cp -R music "${D}/${GAMES_DATADIR}/${PN}" || die "cp failed" |
110 |
fi |
121 |
fi |
Lines 116-121
Link Here
|
116 |
dohtml "${WORKDIR}/mapeditor.html" |
127 |
dohtml "${WORKDIR}/mapeditor.html" |
117 |
dohtml -r "${WORKDIR}/mapeditor" |
128 |
dohtml -r "${WORKDIR}/mapeditor" |
118 |
fi |
129 |
fi |
|
|
130 |
|
131 |
make_desktop_entry el "Eternal Lands" el_icon.png Game |
132 |
use mapeditor && \ |
133 |
make_desktop_entry el-mapedit "Map editor" el_icon.png Game |
134 |
|
119 |
prepgamesdirs |
135 |
prepgamesdirs |
120 |
} |
136 |
} |
121 |
|
137 |
|
Lines 123-130
Link Here
|
123 |
games_pkg_postinst |
139 |
games_pkg_postinst |
124 |
echo |
140 |
echo |
125 |
einfo "To run the game: el" |
141 |
einfo "To run the game: el" |
126 |
einfo "Copy ${GAMES_DATADIR}/${PN}/el.ini to ~/.elc/" |
|
|
127 |
einfo "to make per-user changes." |
128 |
echo |
142 |
echo |
129 |
if use mapeditor; then |
143 |
if use mapeditor; then |
130 |
einfo "To use the map editor: el-mapedit" |
144 |
einfo "To use the map editor: el-mapedit" |