summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /games-rpg/eternal-lands
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'games-rpg/eternal-lands')
-rw-r--r--games-rpg/eternal-lands/Manifest3
-rw-r--r--games-rpg/eternal-lands/eternal-lands-1.9.2-r1.ebuild154
-rw-r--r--games-rpg/eternal-lands/eternal-lands-1.9.2.ebuild150
-rw-r--r--games-rpg/eternal-lands/eternal-lands-1.9.3-r1.ebuild163
-rw-r--r--games-rpg/eternal-lands/eternal-lands-1.9.3-r2.ebuild122
-rw-r--r--games-rpg/eternal-lands/eternal-lands-1.9.3.ebuild154
-rw-r--r--games-rpg/eternal-lands/files/eternal-lands-1.9.0-glext.patch11
-rw-r--r--games-rpg/eternal-lands/files/eternal-lands-1.9.1-libpng.patch23
-rw-r--r--games-rpg/eternal-lands/files/eternal-lands-1.9.2-glext.patch11
-rw-r--r--games-rpg/eternal-lands/files/eternal-lands-1.9.3-build.patch314
-rw-r--r--games-rpg/eternal-lands/files/eternal-lands-1.9.3-glbuild.patch25
-rw-r--r--games-rpg/eternal-lands/files/eternal-lands-1.9.3-minizip.patch75
-rw-r--r--games-rpg/eternal-lands/metadata.xml11
13 files changed, 1216 insertions, 0 deletions
diff --git a/games-rpg/eternal-lands/Manifest b/games-rpg/eternal-lands/Manifest
new file mode 100644
index 000000000000..f04cd7529783
--- /dev/null
+++ b/games-rpg/eternal-lands/Manifest
@@ -0,0 +1,3 @@
+DIST elc_1.9.2-20110618.tar.bz2 2164208 SHA256 0226c95dc9e0a93713d2d8efcba7f75fbb97efe9b2b4f3b527e2851db69a0fad
+DIST elc_1.9.3-20120213.tar.bz2 2401172 SHA256 b5ca11a2fc8db72003c6719ed031f9a7536865647a0278fa45ad8426ce88599e SHA512 3580d3ceb94094443ef25f6e4880c9ffe3fff256c8d8e6657b4e0683a05184da9e6a76264557d2065a8187e3d36febd9d30ff5adff83a17607b1e478be90fabc WHIRLPOOL 12461eb7c4e453c7f9e3b607ce6f0c935e78c37e04a5736dcbf59775324e9280fc7f6302792d35984a7ae21ad4e48e35854568400df279714131de4a39b0a075
+DIST eternal-lands.png 9955 SHA256 dd7d45cd9948fe7875ebd0bfcd1925d9b34e7606a223faf61d37a6dd2cd433fb SHA512 c77571c949bb43fa7f95ae58f863ed972cfc76e184de5d0fa0a3599e4f7539f6334b843233b61fc807c90ef270d87cd57494510ce559427b592d255c198729bf WHIRLPOOL 760a339efeda97dd517ebc6dc4e222a77d35fb936002ff4f3ec571b9845ba53ce677dc3ce1a2206bb49a0b33efda231f5677fff25aadb700c191d9f7e17a778f
diff --git a/games-rpg/eternal-lands/eternal-lands-1.9.2-r1.ebuild b/games-rpg/eternal-lands/eternal-lands-1.9.2-r1.ebuild
new file mode 100644
index 000000000000..6638d71fadb2
--- /dev/null
+++ b/games-rpg/eternal-lands/eternal-lands-1.9.2-r1.ebuild
@@ -0,0 +1,154 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=2
+inherit eutils flag-o-matic games
+
+DESCRIPTION="An online MMORPG written in C and SDL"
+HOMEPAGE="http://www.eternal-lands.com"
+SRC_URI="http://dev.gentoo.org/~rich0/distfiles/elc_1.9.2-20110618.tar.bz2
+ http://dev.gentoo.org/~rich0/distfiles/eternal-lands.png"
+
+LICENSE="eternal_lands"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~x86-fbsd"
+IUSE="debug doc kernel_linux"
+
+RDEPEND="x11-libs/libX11
+ x11-libs/libXau
+ x11-libs/libXdmcp
+ x11-libs/libXext
+ virtual/opengl
+ virtual/glu
+ media-libs/libsdl[X]
+ media-libs/sdl-net
+ media-libs/sdl-image
+ media-libs/openal
+ media-libs/freealut
+ media-libs/libvorbis
+ dev-libs/libxml2
+ media-libs/cal3d[-16bit-indices]
+ media-libs/libpng
+ >=games-rpg/eternal-lands-data-1.9.2"
+
+DEPEND="${RDEPEND}
+ >=app-eselect/eselect-opengl-1.0.6-r1
+ app-arch/unzip
+ doc? ( app-doc/doxygen
+ media-gfx/graphviz )"
+
+#ECVS_SERVER="cvs.elc.berlios.de:/cvsroot/elc"
+#ECVS_MODULE="elc"
+#ECVS_USER="anonymous"
+#ECVS_LOCALNAME="elc"
+#ECVS_PASS=""
+#ECVS_CVS_OPTIONS="-dP -z3"
+#ECVS_BRANCH="elc_1_8_0"
+
+#S="${WORKDIR}/${ECVS_MODULE}"
+S="${WORKDIR}/elc"
+
+src_unpack() {
+# cvs_src_unpack
+ OPTIONS="-DDATA_DIR="\\\\\"${GAMES_DATADIR}/${PN}/\\\\\"""
+ S_CLIENT="${WORKDIR}/elc"
+ BROWSER="firefox"
+ unpack ${A}
+ cd "${S}"
+}
+
+src_prepare() {
+ # Add debugging options
+ if use debug ; then
+ OPTIONS="${OPTIONS} -DMEMORY_DEBUG"
+ append-flags -ggdb
+ fi
+
+ # Clean compile flags (make Gentoo friendly)
+ sed -i \
+ -e "s@CFLAGS=\$(PLATFORM) \$(CWARN) -O0 -ggdb -pipe@CFLAGS = ${CFLAGS} ${OPTIONS} @g" \
+ -e "s@CXXFLAGS=\$(PLATFORM) \$(CXXWARN) -O0 -ggdb -pipe@CXXFLAGS = ${CXXFLAGS} ${OPTIONS} @g" \
+ -e 's/lopenal/lopenal -l alut/' \
+ Makefile.linux || die "sed failed"
+
+ sed -i \
+ -e 's/#browser/browser/g' \
+ -e "s/browser = mozilla/#browser = ${BROWSER}/g" \
+ -e "s@#data_dir = /usr/local/games/el/@#data_dir = ${GAMES_DATADIR}/${PN}/@g" \
+ el.ini || die "sed failed"
+
+ # Support BSD in the Linux makefile - it's easier
+ use kernel_linux || sed -i \
+ -e 's/^CFLAGS=.*/& -DBSD/' \
+ Makefile.linux || die "sed failed"
+
+ # Clean up library flag order for --as-needed
+# sed -i -e 's/@$(LINK) $(CFLAGS) $(LDFLAGS) -o $(EXE) $(OBJS)/@$(LINK) $(CFLAGS) -o $(EXE) $(OBJS) $(LDFLAGS)/' Makefile.linux
+
+ # Finally, update the server
+ sed -i -e '/#server_address =/ s/.*/#server_address = game.eternal-lands.com/' \
+ el.ini || die "sed failed"
+
+ sed -i -e 's:FEATURES:EL_FEATURES:' make.defaults
+ sed -i -e 's:FEATURES:EL_FEATURES:' Makefile.linux
+
+ if use debug; then
+ sed -i -e 's/#\(EL_FEATURES += MEMORY_DEBUG\)/\1/' make.defaults
+ sed -i -e 's/#\(EL_FEATURES += MEMORY_DEBUG\)/\1/' Makefile.linux
+ fi
+
+ cp Makefile.linux Makefile
+
+ epatch "${FILESDIR}/${PN}-1.9.2-glext.patch"
+# epatch "${FILESDIR}/${PN}-1.9.1-libpng.patch"
+
+# Fix for Gentoo zlib OF redefine
+
+ sed -i '1i#define OF(x) x' `find -name "*.c"` || die "sed failed"
+}
+
+src_compile() {
+ emake || die "make failed"
+
+ if use doc; then
+ emake docs || die "Failed to create documentation, try with USE=-doc"
+ mv ./docs/html/ ../client || die "Failed to move documentation directory"
+ fi
+}
+
+src_install() {
+ doicon "${DISTDIR}/eternal-lands.png" ${PN}.png
+
+ newgamesbin el.x86.linux.bin el \
+ || die "newgamesbin failed"
+ make_desktop_entry el "Eternal Lands" \
+ || die "make_desktop_entry failed"
+ insopts -m 0660
+ insinto "${GAMES_DATADIR}/${PN}"
+
+ doins -r *.ini *.txt commands.lst \
+ || die "doins failed"
+
+ if use doc ; then
+ dohtml -r client/*
+ fi
+
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+ elog "Auto Update is now enabled in Eternal Lands"
+ elog "If an update occurs then the client will suddenly exit"
+ elog "Updates only happen when the game first loads"
+ elog "Please don't report this behaviour as a bug"
+
+ # Ensure that the files are writable by the game group for auto
+ # updating.
+ chmod -R g+rw "${ROOT}/${GAMES_DATADIR}/${PN}"
+
+ # Make sure new files stay in games group
+ find "${ROOT}/${GAMES_DATADIR}/${PN}" -type d -exec chmod g+sx {} \;
+
+}
diff --git a/games-rpg/eternal-lands/eternal-lands-1.9.2.ebuild b/games-rpg/eternal-lands/eternal-lands-1.9.2.ebuild
new file mode 100644
index 000000000000..94f2b1774a37
--- /dev/null
+++ b/games-rpg/eternal-lands/eternal-lands-1.9.2.ebuild
@@ -0,0 +1,150 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=2
+inherit eutils flag-o-matic games
+
+DESCRIPTION="An online MMORPG written in C and SDL"
+HOMEPAGE="http://www.eternal-lands.com"
+SRC_URI="http://dev.gentoo.org/~rich0/distfiles/elc_1.9.2-20110618.tar.bz2
+ http://dev.gentoo.org/~rich0/distfiles/eternal-lands.png"
+
+LICENSE="eternal_lands"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~x86-fbsd"
+IUSE="debug doc kernel_linux"
+
+RDEPEND="x11-libs/libX11
+ x11-libs/libXau
+ x11-libs/libXdmcp
+ x11-libs/libXext
+ virtual/opengl
+ virtual/glu
+ media-libs/libsdl[X]
+ media-libs/sdl-net
+ media-libs/sdl-image
+ media-libs/openal
+ media-libs/freealut
+ media-libs/libvorbis
+ dev-libs/libxml2
+ media-libs/cal3d[-16bit-indices]
+ media-libs/libpng
+ >=games-rpg/eternal-lands-data-1.9.2"
+
+DEPEND="${RDEPEND}
+ >=app-eselect/eselect-opengl-1.0.6-r1
+ app-arch/unzip
+ doc? ( app-doc/doxygen
+ media-gfx/graphviz )"
+
+#ECVS_SERVER="cvs.elc.berlios.de:/cvsroot/elc"
+#ECVS_MODULE="elc"
+#ECVS_USER="anonymous"
+#ECVS_LOCALNAME="elc"
+#ECVS_PASS=""
+#ECVS_CVS_OPTIONS="-dP -z3"
+#ECVS_BRANCH="elc_1_8_0"
+
+#S="${WORKDIR}/${ECVS_MODULE}"
+S="${WORKDIR}/elc"
+
+src_unpack() {
+# cvs_src_unpack
+ OPTIONS="-DDATA_DIR="\\\\\"${GAMES_DATADIR}/${PN}/\\\\\"""
+ S_CLIENT="${WORKDIR}/elc"
+ BROWSER="firefox"
+ unpack ${A}
+ cd "${S}"
+}
+
+src_prepare() {
+ # Add debugging options
+ if use debug ; then
+ OPTIONS="${OPTIONS} -DMEMORY_DEBUG"
+ append-flags -ggdb
+ fi
+
+ # Clean compile flags (make Gentoo friendly)
+ sed -i \
+ -e "s@CFLAGS=\$(PLATFORM) \$(CWARN) -O0 -ggdb -pipe@CFLAGS = ${CFLAGS} ${OPTIONS} @g" \
+ -e "s@CXXFLAGS=\$(PLATFORM) \$(CXXWARN) -O0 -ggdb -pipe@CXXFLAGS = ${CXXFLAGS} ${OPTIONS} @g" \
+ -e 's/lopenal/lopenal -l alut/' \
+ Makefile.linux || die "sed failed"
+
+ sed -i \
+ -e 's/#browser/browser/g' \
+ -e "s/browser = mozilla/#browser = ${BROWSER}/g" \
+ -e "s@#data_dir = /usr/local/games/el/@#data_dir = ${GAMES_DATADIR}/${PN}/@g" \
+ el.ini || die "sed failed"
+
+ # Support BSD in the Linux makefile - it's easier
+ use kernel_linux || sed -i \
+ -e 's/^CFLAGS=.*/& -DBSD/' \
+ Makefile.linux || die "sed failed"
+
+ # Clean up library flag order for --as-needed
+# sed -i -e 's/@$(LINK) $(CFLAGS) $(LDFLAGS) -o $(EXE) $(OBJS)/@$(LINK) $(CFLAGS) -o $(EXE) $(OBJS) $(LDFLAGS)/' Makefile.linux
+
+ # Finally, update the server
+ sed -i -e '/#server_address =/ s/.*/#server_address = game.eternal-lands.com/' \
+ el.ini || die "sed failed"
+
+ sed -i -e 's:FEATURES:EL_FEATURES:' make.defaults
+ sed -i -e 's:FEATURES:EL_FEATURES:' Makefile.linux
+
+ if use debug; then
+ sed -i -e 's/#\(EL_FEATURES += MEMORY_DEBUG\)/\1/' make.defaults
+ sed -i -e 's/#\(EL_FEATURES += MEMORY_DEBUG\)/\1/' Makefile.linux
+ fi
+
+ cp Makefile.linux Makefile
+
+ epatch "${FILESDIR}/${PN}-1.9.2-glext.patch"
+# epatch "${FILESDIR}/${PN}-1.9.1-libpng.patch"
+}
+
+src_compile() {
+ emake || die "make failed"
+
+ if use doc; then
+ emake docs || die "Failed to create documentation, try with USE=-doc"
+ mv ./docs/html/ ../client || die "Failed to move documentation directory"
+ fi
+}
+
+src_install() {
+ doicon "${DISTDIR}/eternal-lands.png" ${PN}.png
+
+ newgamesbin el.x86.linux.bin el \
+ || die "newgamesbin failed"
+ make_desktop_entry el "Eternal Lands" \
+ || die "make_desktop_entry failed"
+ insopts -m 0660
+ insinto "${GAMES_DATADIR}/${PN}"
+
+ doins -r *.ini *.txt commands.lst \
+ || die "doins failed"
+
+ if use doc ; then
+ dohtml -r client/*
+ fi
+
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+ elog "Auto Update is now enabled in Eternal Lands"
+ elog "If an update occurs then the client will suddenly exit"
+ elog "Updates only happen when the game first loads"
+ elog "Please don't report this behaviour as a bug"
+
+ # Ensure that the files are writable by the game group for auto
+ # updating.
+ chmod -R g+rw "${ROOT}/${GAMES_DATADIR}/${PN}"
+
+ # Make sure new files stay in games group
+ find "${ROOT}/${GAMES_DATADIR}/${PN}" -type d -exec chmod g+sx {} \;
+
+}
diff --git a/games-rpg/eternal-lands/eternal-lands-1.9.3-r1.ebuild b/games-rpg/eternal-lands/eternal-lands-1.9.3-r1.ebuild
new file mode 100644
index 000000000000..8b131e9c0e7d
--- /dev/null
+++ b/games-rpg/eternal-lands/eternal-lands-1.9.3-r1.ebuild
@@ -0,0 +1,163 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=2
+inherit eutils flag-o-matic gnome2-utils games
+
+DESCRIPTION="An online MMORPG written in C and SDL"
+HOMEPAGE="http://www.eternal-lands.com"
+SRC_URI="mirror://gentoo/elc_1.9.3-20120213.tar.bz2
+ http://dev.gentoo.org/~rich0/distfiles/eternal-lands.png"
+
+LICENSE="eternal_lands"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~x86-fbsd"
+IUSE="debug doc kernel_linux"
+
+RDEPEND="x11-libs/libX11
+ x11-libs/libXau
+ x11-libs/libXdmcp
+ x11-libs/libXext
+ virtual/opengl
+ virtual/glu
+ media-libs/libsdl[X]
+ media-libs/sdl-net
+ media-libs/sdl-image
+ media-libs/openal
+ media-libs/freealut
+ media-libs/libvorbis
+ dev-libs/libxml2
+ media-libs/cal3d[-16bit-indices]
+ media-libs/libpng
+ >=games-rpg/eternal-lands-data-1.9.3"
+
+DEPEND="${RDEPEND}
+ >=app-eselect/eselect-opengl-1.0.6-r1
+ app-arch/unzip
+ doc? ( app-doc/doxygen
+ media-gfx/graphviz )"
+
+#ECVS_SERVER="cvs.elc.berlios.de:/cvsroot/elc"
+#ECVS_MODULE="elc"
+#ECVS_USER="anonymous"
+#ECVS_LOCALNAME="elc"
+#ECVS_PASS=""
+#ECVS_CVS_OPTIONS="-dP -z3"
+#ECVS_BRANCH="elc_1_8_0"
+
+#S="${WORKDIR}/${ECVS_MODULE}"
+S="${WORKDIR}/elc"
+
+src_unpack() {
+# cvs_src_unpack
+ OPTIONS="-DDATA_DIR="\\\\\"${GAMES_DATADIR}/${PN}/\\\\\"""
+ S_CLIENT="${WORKDIR}/elc"
+ BROWSER="firefox"
+ unpack ${A}
+ cd "${S}"
+}
+
+src_prepare() {
+ # Add debugging options
+ if use debug ; then
+ OPTIONS="${OPTIONS} -DMEMORY_DEBUG"
+ append-flags -ggdb
+ fi
+
+ # Clean compile flags (make Gentoo friendly)
+ sed -i \
+ -e "s@CFLAGS=\$(PLATFORM) \$(CWARN) -O0 -ggdb -pipe@CFLAGS = ${CFLAGS} ${OPTIONS} @g" \
+ -e "s@CXXFLAGS=\$(PLATFORM) \$(CXXWARN) -O0 -ggdb -pipe@CXXFLAGS = ${CXXFLAGS} ${OPTIONS} @g" \
+ -e 's/lopenal/lopenal -l alut/' \
+ Makefile.linux || die "sed failed"
+
+ sed -i \
+ -e 's/#browser/browser/g' \
+ -e "s/browser = mozilla/#browser = ${BROWSER}/g" \
+ -e "s@#data_dir = /usr/local/games/el/@#data_dir = ${GAMES_DATADIR}/${PN}/@g" \
+ el.ini || die "sed failed"
+
+ # Support BSD in the Linux makefile - it's easier
+ use kernel_linux || sed -i \
+ -e 's/^CFLAGS=.*/& -DBSD/' \
+ Makefile.linux || die "sed failed"
+
+ # Clean up library flag order for --as-needed
+# sed -i -e 's/@$(LINK) $(CFLAGS) $(LDFLAGS) -o $(EXE) $(OBJS)/@$(LINK) $(CFLAGS) -o $(EXE) $(OBJS) $(LDFLAGS)/' Makefile.linux
+
+ # Finally, update the server
+ sed -i -e '/#server_address =/ s/.*/#server_address = game.eternal-lands.com/' \
+ el.ini || die "sed failed"
+
+ sed -i -e 's:FEATURES:EL_FEATURES:' make.defaults
+ sed -i -e 's:FEATURES:EL_FEATURES:' Makefile.linux
+
+ if use debug; then
+ sed -i -e 's/#\(EL_FEATURES += MEMORY_DEBUG\)/\1/' make.defaults
+ sed -i -e 's/#\(EL_FEATURES += MEMORY_DEBUG\)/\1/' Makefile.linux
+ fi
+
+ cp Makefile.linux Makefile
+
+ epatch "${FILESDIR}/${PN}-1.9.2-glext.patch"
+# epatch "${FILESDIR}/${PN}-1.9.1-libpng.patch"
+
+# Fix for Gentoo zlib OF redefine
+
+ sed -i '1i#define OF(x) x' `find -name "*.c"` || die "sed failed"
+}
+
+src_compile() {
+ emake || die "make failed"
+
+ if use doc; then
+ emake docs || die "Failed to create documentation, try with USE=-doc"
+ mv ./docs/html/ ../client || die "Failed to move documentation directory"
+ fi
+}
+
+src_install() {
+ newicon -s 64 "${DISTDIR}/eternal-lands.png" ${PN}.png
+
+ newgamesbin el.x86.linux.bin el \
+ || die "newgamesbin failed"
+ make_desktop_entry el "Eternal Lands" \
+ || die "make_desktop_entry failed"
+ insopts -m 0660
+ insinto "${GAMES_DATADIR}/${PN}"
+
+ doins -r *.ini *.txt commands.lst \
+ || die "doins failed"
+
+ if use doc ; then
+ dohtml -r client/*
+ fi
+
+ prepgamesdirs
+}
+
+pkg_preinst() {
+ games_pkg_preinst
+ gnome2_icon_savelist
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+ gnome2_icon_cache_update
+ elog "Auto Update is now enabled in Eternal Lands"
+ elog "If an update occurs then the client will suddenly exit"
+ elog "Updates only happen when the game first loads"
+ elog "Please don't report this behaviour as a bug"
+
+ # Ensure that the files are writable by the game group for auto
+ # updating.
+ chmod -R g+rw "${ROOT}/${GAMES_DATADIR}/${PN}"
+
+ # Make sure new files stay in games group
+ find "${ROOT}/${GAMES_DATADIR}/${PN}" -type d -exec chmod g+sx {} \;
+}
+
+pkg_postrm() {
+ gnome2_icon_cache_update
+}
diff --git a/games-rpg/eternal-lands/eternal-lands-1.9.3-r2.ebuild b/games-rpg/eternal-lands/eternal-lands-1.9.3-r2.ebuild
new file mode 100644
index 000000000000..588d23fe8294
--- /dev/null
+++ b/games-rpg/eternal-lands/eternal-lands-1.9.3-r2.ebuild
@@ -0,0 +1,122 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+inherit eutils flag-o-matic gnome2-utils games
+
+DESCRIPTION="An online MMORPG written in C and SDL"
+HOMEPAGE="http://www.eternal-lands.com"
+SRC_URI="mirror://gentoo/elc_1.9.3-20120213.tar.bz2
+ http://dev.gentoo.org/~rich0/distfiles/${PN}.png"
+
+LICENSE="eternal_lands"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~x86-fbsd"
+IUSE="debug doc kernel_linux"
+
+RDEPEND="dev-libs/libxml2:=
+ media-libs/cal3d:=[-16bit-indices]
+ media-libs/freealut
+ media-libs/libpng:0=
+ media-libs/libsdl:=[X,opengl,video]
+ media-libs/libvorbis:=
+ media-libs/openal:=
+ media-libs/sdl-image:=
+ media-libs/sdl-net:=
+ >=games-rpg/eternal-lands-data-1.9.3
+ sys-libs/zlib:=[minizip]
+ virtual/glu
+ virtual/opengl
+ x11-libs/libX11:=
+ x11-libs/libXau:=
+ x11-libs/libXdmcp:=
+ x11-libs/libXext:="
+DEPEND="${RDEPEND}
+ >=app-eselect/eselect-opengl-1.0.6-r1
+ app-arch/unzip
+ virtual/pkgconfig
+ doc? ( app-doc/doxygen
+ media-gfx/graphviz )
+ media-libs/glew"
+
+S="${WORKDIR}/elc"
+
+src_prepare() {
+ local BROWSER="firefox"
+
+ sed -i \
+ -e 's/#browser/browser/g' \
+ -e "s/browser = mozilla/#browser = ${BROWSER}/g" \
+ -e "s@#data_dir = /usr/local/games/el/@#data_dir = ${GAMES_DATADIR}/${PN}/@g" \
+ el.ini || die "sed failed"
+
+ # Finally, update the server
+ sed -i -e '/#server_address =/ s/.*/#server_address = game.eternal-lands.com/' \
+ el.ini || die "sed failed"
+
+ epatch "${FILESDIR}/${PN}-1.9.3-glbuild.patch"
+ epatch "${FILESDIR}/${PN}-1.9.3-build.patch"
+ epatch "${FILESDIR}/${PN}-1.9.3-minizip.patch"
+
+ # remove bundled minizip
+ rm io/{crypt,ioapi,unzip,zip}.h || die
+ rm io/{ioapi,unzip,zip}.c || die
+
+ cp Makefile.linux Makefile
+}
+
+src_compile() {
+ emake \
+ DEBUG="$(usex debug)" \
+ BSD_KERNEL="$(usex !kernel_linux)" \
+ DATADIR="${GAMES_DATADIR}/${PN}/"
+
+ if use doc; then
+ emake docs
+ mv ./docs/html/ ../client || die "Failed to move documentation directory"
+ fi
+}
+
+src_install() {
+ dogamesbin el
+ make_desktop_entry el "Eternal Lands"
+
+ insopts -m 0660
+ insinto "${GAMES_DATADIR}/${PN}"
+
+ doins -r *.ini *.txt commands.lst
+
+ if use doc ; then
+ dohtml -r "${WORKDIR}"/client/*
+ fi
+
+ doicon -s 64 "${DISTDIR}/${PN}.png"
+
+ prepgamesdirs
+}
+
+pkg_preinst() {
+ games_pkg_preinst
+ gnome2_icon_savelist
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+ gnome2_icon_cache_update
+ elog "Auto Update is now enabled in Eternal Lands"
+ elog "If an update occurs then the client will suddenly exit"
+ elog "Updates only happen when the game first loads"
+ elog "Please don't report this behaviour as a bug"
+
+ # Ensure that the files are writable by the game group for auto
+ # updating.
+ chmod -R g+rw "${ROOT}/${GAMES_DATADIR}/${PN}"
+
+ # Make sure new files stay in games group
+ find "${ROOT}/${GAMES_DATADIR}/${PN}" -type d -exec chmod g+sx {} \;
+}
+
+pkg_postrm() {
+ gnome2_icon_cache_update
+}
diff --git a/games-rpg/eternal-lands/eternal-lands-1.9.3.ebuild b/games-rpg/eternal-lands/eternal-lands-1.9.3.ebuild
new file mode 100644
index 000000000000..cf86f7bdb3f3
--- /dev/null
+++ b/games-rpg/eternal-lands/eternal-lands-1.9.3.ebuild
@@ -0,0 +1,154 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=2
+inherit eutils flag-o-matic games
+
+DESCRIPTION="An online MMORPG written in C and SDL"
+HOMEPAGE="http://www.eternal-lands.com"
+SRC_URI="mirror://gentoo/elc_1.9.3-20120213.tar.bz2
+ http://dev.gentoo.org/~rich0/distfiles/eternal-lands.png"
+
+LICENSE="eternal_lands"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~x86-fbsd"
+IUSE="debug doc kernel_linux"
+
+RDEPEND="x11-libs/libX11
+ x11-libs/libXau
+ x11-libs/libXdmcp
+ x11-libs/libXext
+ virtual/opengl
+ virtual/glu
+ media-libs/libsdl[X]
+ media-libs/sdl-net
+ media-libs/sdl-image
+ media-libs/openal
+ media-libs/freealut
+ media-libs/libvorbis
+ dev-libs/libxml2
+ media-libs/cal3d[-16bit-indices]
+ media-libs/libpng
+ >=games-rpg/eternal-lands-data-1.9.2"
+
+DEPEND="${RDEPEND}
+ >=app-eselect/eselect-opengl-1.0.6-r1
+ app-arch/unzip
+ doc? ( app-doc/doxygen
+ media-gfx/graphviz )"
+
+#ECVS_SERVER="cvs.elc.berlios.de:/cvsroot/elc"
+#ECVS_MODULE="elc"
+#ECVS_USER="anonymous"
+#ECVS_LOCALNAME="elc"
+#ECVS_PASS=""
+#ECVS_CVS_OPTIONS="-dP -z3"
+#ECVS_BRANCH="elc_1_8_0"
+
+#S="${WORKDIR}/${ECVS_MODULE}"
+S="${WORKDIR}/elc"
+
+src_unpack() {
+# cvs_src_unpack
+ OPTIONS="-DDATA_DIR="\\\\\"${GAMES_DATADIR}/${PN}/\\\\\"""
+ S_CLIENT="${WORKDIR}/elc"
+ BROWSER="firefox"
+ unpack ${A}
+ cd "${S}"
+}
+
+src_prepare() {
+ # Add debugging options
+ if use debug ; then
+ OPTIONS="${OPTIONS} -DMEMORY_DEBUG"
+ append-flags -ggdb
+ fi
+
+ # Clean compile flags (make Gentoo friendly)
+ sed -i \
+ -e "s@CFLAGS=\$(PLATFORM) \$(CWARN) -O0 -ggdb -pipe@CFLAGS = ${CFLAGS} ${OPTIONS} @g" \
+ -e "s@CXXFLAGS=\$(PLATFORM) \$(CXXWARN) -O0 -ggdb -pipe@CXXFLAGS = ${CXXFLAGS} ${OPTIONS} @g" \
+ -e 's/lopenal/lopenal -l alut/' \
+ Makefile.linux || die "sed failed"
+
+ sed -i \
+ -e 's/#browser/browser/g' \
+ -e "s/browser = mozilla/#browser = ${BROWSER}/g" \
+ -e "s@#data_dir = /usr/local/games/el/@#data_dir = ${GAMES_DATADIR}/${PN}/@g" \
+ el.ini || die "sed failed"
+
+ # Support BSD in the Linux makefile - it's easier
+ use kernel_linux || sed -i \
+ -e 's/^CFLAGS=.*/& -DBSD/' \
+ Makefile.linux || die "sed failed"
+
+ # Clean up library flag order for --as-needed
+# sed -i -e 's/@$(LINK) $(CFLAGS) $(LDFLAGS) -o $(EXE) $(OBJS)/@$(LINK) $(CFLAGS) -o $(EXE) $(OBJS) $(LDFLAGS)/' Makefile.linux
+
+ # Finally, update the server
+ sed -i -e '/#server_address =/ s/.*/#server_address = game.eternal-lands.com/' \
+ el.ini || die "sed failed"
+
+ sed -i -e 's:FEATURES:EL_FEATURES:' make.defaults
+ sed -i -e 's:FEATURES:EL_FEATURES:' Makefile.linux
+
+ if use debug; then
+ sed -i -e 's/#\(EL_FEATURES += MEMORY_DEBUG\)/\1/' make.defaults
+ sed -i -e 's/#\(EL_FEATURES += MEMORY_DEBUG\)/\1/' Makefile.linux
+ fi
+
+ cp Makefile.linux Makefile
+
+ epatch "${FILESDIR}/${PN}-1.9.2-glext.patch"
+# epatch "${FILESDIR}/${PN}-1.9.1-libpng.patch"
+
+# Fix for Gentoo zlib OF redefine
+
+ sed -i '1i#define OF(x) x' `find -name "*.c"` || die "sed failed"
+}
+
+src_compile() {
+ emake || die "make failed"
+
+ if use doc; then
+ emake docs || die "Failed to create documentation, try with USE=-doc"
+ mv ./docs/html/ ../client || die "Failed to move documentation directory"
+ fi
+}
+
+src_install() {
+ doicon "${DISTDIR}/eternal-lands.png" ${PN}.png
+
+ newgamesbin el.x86.linux.bin el \
+ || die "newgamesbin failed"
+ make_desktop_entry el "Eternal Lands" \
+ || die "make_desktop_entry failed"
+ insopts -m 0660
+ insinto "${GAMES_DATADIR}/${PN}"
+
+ doins -r *.ini *.txt commands.lst \
+ || die "doins failed"
+
+ if use doc ; then
+ dohtml -r client/*
+ fi
+
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+ elog "Auto Update is now enabled in Eternal Lands"
+ elog "If an update occurs then the client will suddenly exit"
+ elog "Updates only happen when the game first loads"
+ elog "Please don't report this behaviour as a bug"
+
+ # Ensure that the files are writable by the game group for auto
+ # updating.
+ chmod -R g+rw "${ROOT}/${GAMES_DATADIR}/${PN}"
+
+ # Make sure new files stay in games group
+ find "${ROOT}/${GAMES_DATADIR}/${PN}" -type d -exec chmod g+sx {} \;
+
+}
diff --git a/games-rpg/eternal-lands/files/eternal-lands-1.9.0-glext.patch b/games-rpg/eternal-lands/files/eternal-lands-1.9.0-glext.patch
new file mode 100644
index 000000000000..a41db54c0f37
--- /dev/null
+++ b/games-rpg/eternal-lands/files/eternal-lands-1.9.0-glext.patch
@@ -0,0 +1,11 @@
+--- platform.h.orig 2010-02-03 13:21:41.300205559 -0500
++++ platform.h 2010-02-03 13:22:25.704049074 -0500
+@@ -79,7 +79,7 @@
+ #define GL_GLEXT_LEGACY
+ #include <GL/gl.h>
+ #include <GL/glu.h>
+- #include "glext.h"
++ #include <GL/glext.h>
+ #endif
+
+ // Inlucde the plaform specific location sound libs
diff --git a/games-rpg/eternal-lands/files/eternal-lands-1.9.1-libpng.patch b/games-rpg/eternal-lands/files/eternal-lands-1.9.1-libpng.patch
new file mode 100644
index 000000000000..953ab8ffefd7
--- /dev/null
+++ b/games-rpg/eternal-lands/files/eternal-lands-1.9.1-libpng.patch
@@ -0,0 +1,23 @@
+--- elc.orig/misc.c
++++ elc/misc.c
+@@ -311,7 +311,7 @@ int IMG_SavePNG_RW (SDL_Surface *face, S
+ }
+
+ /* Set error handling. */
+- if (setjmp(png_ptr->jmpbuf))
++ if (setjmp(png_jmpbuf(png_ptr)))
+ {
+ /* If we get here, we had a problem reading the file */
+ IMG_SetError("Error writing the PNG file");
+@@ -360,10 +360,7 @@ done:
+ if (row_pointers != NULL)
+ free (row_pointers);
+
+- if (info_ptr != NULL && info_ptr->palette != NULL)
+- free (info_ptr->palette);
+-
+- png_destroy_write_struct (&png_ptr, (png_infopp)NULL);
++ png_destroy_write_struct (&png_ptr, &info_ptr);
+
+ return result;
+ }
diff --git a/games-rpg/eternal-lands/files/eternal-lands-1.9.2-glext.patch b/games-rpg/eternal-lands/files/eternal-lands-1.9.2-glext.patch
new file mode 100644
index 000000000000..f096d2fc4253
--- /dev/null
+++ b/games-rpg/eternal-lands/files/eternal-lands-1.9.2-glext.patch
@@ -0,0 +1,11 @@
+--- platform.h.orig 2011-06-18 13:55:09.704489907 -0400
++++ platform.h 2011-06-18 13:55:41.675544567 -0400
+@@ -79,7 +79,7 @@
+ #define GL_GLEXT_LEGACY
+ #include <GL/gl.h>
+ #include <GL/glu.h>
+- #include "glext.h"
++ #include <GL/glext.h>
+ #else // BSD
+ #include <GL/gl.h>
+ #include <GL/glu.h>
diff --git a/games-rpg/eternal-lands/files/eternal-lands-1.9.3-build.patch b/games-rpg/eternal-lands/files/eternal-lands-1.9.3-build.patch
new file mode 100644
index 000000000000..989bf2700d88
--- /dev/null
+++ b/games-rpg/eternal-lands/files/eternal-lands-1.9.3-build.patch
@@ -0,0 +1,314 @@
+From: Julian Ospald <hasufell@gentoo.org>
+Date: Sun Jun 24 13:32:38 UTC 2012
+Subject: build system
+
+respect all flags
+respect compiler
+add options for DATADIR, BSD_KERNEL and DEBUG
+use proper pkgconfig calls
+remove needless build types
+rename EXE to "el"
+
+--- elc/Makefile.linux
++++ elc/Makefile.linux
+@@ -3,16 +3,54 @@
+ -include make.conf
+
+ # basic compiling and linking - rarely changed
+-OPTIONS = -DLINUX -DELC $(foreach FEATURE, $(FEATURES), -D$(FEATURE)) -D_7ZIP_ST
+-CFLAGS=$(PLATFORM) $(CWARN) -O0 -ggdb -pipe $(OPTIONS) $(shell sdl-config --cflags) $(shell xml2-config --cflags) -fno-strict-aliasing $(EXTRA_INCLUDES)
+-_CFLAGS=$(PLATFORM) -O2 -fomit-frame-pointer -ffast-math -pipe $(OPTIONS) $(shell sdl-config --cflags) $(shell xml2-config --cflags) -fno-strict-aliasing $(EXTRA_INCLUDES)
+-CXXFLAGS=$(PLATFORM) $(CXXWARN) -O0 -ggdb -pipe $(OPTIONS) $(shell sdl-config --cflags) $(shell xml2-config --cflags) -fno-strict-aliasing $(EXTRA_INCLUDES)
+-_CXXFLAGS=$(PLATFORM) -O3 -fomit-frame-pointer -ffast-math -pipe $(OPTIONS) $(shell sdl-config --cflags) $(shell xml2-config --cflags) -fno-strict-aliasing $(EXTRA_INCLUDES)
+-
+-PNG_SCREENSHOT_LIBS = -lpng
+-LDFLAGS=$(shell sdl-config --libs) $(shell xml2-config --libs) -lSDL_net -lSDL_image -lopenal $(XDIR) -lGL -lGLU -lcal3d -lm $(EXTRA_LIBS) -lz -lpng -lvorbis -lvorbisfile \
+- $(foreach FEATURE, $(FEATURES), $($(FEATURE)_LIBS))
+-_LDFLAGS=$(XDIR) -lGL -lpthread -lstdc++
++CC ?= gcc
++CXX ?= g++
++
++# some options
++DATADIR ?= /usr/share/games/eternal-lands
++
++CPPFLAGS += -DDATA_DIR=\"$(DATADIR)\" \
++ -DLINUX \
++ -DELC \
++ $(foreach FEATURE, $(EL_FEATURES), -D$(FEATURE)) \
++ -D_7ZIP_ST
++
++ifeq ($(BSD_KERNEL),yes)
++CPPFLAGS += -DBSD
++endif
++
++ifeq ($(DEBUG),yes)
++CPPFLAGS += -DMEMORY_DEBUG
++endif
++
++CFLAGS += $(shell sdl-config --cflags) \
++ $(shell xml2-config --cflags) \
++ -fno-strict-aliasing \
++ $(EXTRA_INCLUDES)
++
++CXXFLAGS += $(shell sdl-config --cflags) \
++ $(shell xml2-config --cflags) \
++ -fno-strict-aliasing \
++ $(EXTRA_INCLUDES)
++
++LIBS += $(shell pkg-config --libs x11) \
++ $(shell sdl-config --libs) \
++ $(shell xml2-config --libs) \
++ $(shell pkg-config --libs SDL_net) \
++ $(shell pkg-config --libs SDL_image) \
++ $(shell pkg-config --libs openal) \
++ $(shell pkg-config --libs freealut) \
++ $(shell pkg-config --libs gl) \
++ $(shell pkg-config --libs glu) \
++ $(shell pkg-config --libs cal3d) \
++ $(shell pkg-config --libs libpng) \
++ $(shell pkg-config --libs vorbis) \
++ $(shell pkg-config --libs vorbisfile) \
++ $(shell pkg-config --libs zlib) \
++ -lm \
++ $(EXTRA_LIBS) \
++ $(foreach FEATURE, $(EL_FEATURES), $($(FEATURE)_LIBS)) \
++ -lstdc++
+
+ # This works on Ubuntu 8.04 (LTS) at least
+ # Install these packages in addition to those required for a standard build
+@@ -59,7 +97,7 @@
+ xz/CpuArch.o xz/Delta.o xz/LzFind.o xz/Lzma2Dec.o xz/Lzma2Enc.o \
+ xz/LzmaDec.o xz/LzmaEnc.o xz/Sha256.o xz/Xz.o xz/XzCrc64.o xz/XzDec.o \
+ xz/XzEnc.o \
+- $(foreach FEATURE, $(FEATURES), $($(FEATURE)_COBJ))
++ $(foreach FEATURE, $(EL_FEATURES), $($(FEATURE)_COBJ))
+
+ CXXOBJS=actor_init.o cal3d_wrapper.o context_menu.o optimizer.o sendvideoinfo.o \
+ exceptions/extendedexception.o xml/xmlhelper.o quest_log.o \
+@@ -80,7 +118,7 @@
+ eye_candy/effect_mines.o eye_candy/effect_missile.o \
+ eye_candy/orbital_mover.o eye_candy/kepler_orbit.o \
+ eye_candy/effect_staff.o \
+- $(foreach FEATURE, $(FEATURES), $($(FEATURE)_CXXOBJ))
++ $(foreach FEATURE, $(EL_FEATURES), $($(FEATURE)_CXXOBJ))
+
+ OBJS=$(COBJS) $(CXXOBJS)
+ HEADER_DIRS = . books eye_candy io pawn fsaa engine xz
+@@ -89,24 +127,13 @@
+ DEP_FILES=$(foreach OBJ, $(COBJS), .deps/$(OBJ).P) $(foreach OBJ, $(CXXOBJS), .deps/$(OBJ).P)
+ #(shell echo $OBJ |sed s/\.o/\.P/))
+
+-EXE=el.x86.linux.bin
+-
+-ifndef CC
+-CC=gcc
+-endif
+-ifndef CXX
+-CXX=g++
+-endif
+-ifndef LINK
+-LINK=gcc
+-endif
++EXE=el
+
+ all: $(EXE)
+
+ # the compile targets
+ $(EXE): $(OBJS)
+- @echo " LINK $(EXE)"
+- @$(LINK) $(CFLAGS) -o $(EXE) $(OBJS) $(LDFLAGS)
++ $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -o $(EXE) $(OBJS) $(LIBS)
+
+ #recompile on Makefile or conf change
+ #.depend $(OBJS): Makefile.linux make.conf
+@@ -114,25 +141,19 @@
+ DEPS_MAGIC := $(shell mkdir .deps .deps/io .deps/shader .deps/eye_candy .deps/exceptions .deps/xz .deps/xml .deps/fsaa .deps/engine > /dev/null 2>&1 || :)
+
+ $(COBJS): %.o: %.c Makefile.linux make.conf
+- @echo " CC $@"
+- @if $(CC) $(CFLAGS) -MT '$@' -MD -MP -MF '.deps/$@.pp' -c $< -o $@; then \
++ @echo "$(CC) $(CFLAGS) $(CPPFLAGS) -MT '$@' -MD -MP -MF '.deps/$@.pp' -c $< -o $@"
++ @if $(CC) $(CFLAGS) $(CPPFLAGS) -MT '$@' -MD -MP -MF '.deps/$@.pp' -c $< -o $@; then \
+ mv ".deps/$@.pp" ".deps/$@.P"; \
+ else rm -f ".deps/$@.pp"; exit 1; \
+ fi
+
+ $(CXXOBJS): %.o: %.cpp Makefile.linux make.conf
+- @echo " CXX $@"
+- @if $(CXX) $(CXXFLAGS) -MT '$@' -MD -MP -MF '.deps/$@.pp' -c $< -o $@; then \
++ @echo "$(CXX) $(CXXFLAGS) $(CPPFLAGS) -MT '$@' -MD -MP -MF '.deps/$@.pp' -c $< -o $@"
++ @if $(CXX) $(CXXFLAGS) $(CPPFLAGS) -MT '$@' -MD -MP -MF '.deps/$@.pp' -c $< -o $@; then \
+ mv ".deps/$@.pp" ".deps/$@.P"; \
+ else rm -f ".deps/$@.pp"; exit 1; \
+ fi
+
+-release:
+- @$(MAKE) -f Makefile.linux 'CFLAGS=$(_CFLAGS)' 'CXXFLAGS=$(_CXXFLAGS)'
+-
+-static:
+- @$(MAKE) -f Makefile.linux 'CFLAGS=$(_CFLAGS)' 'CXXFLAGS=$(_CXXFLAGS)' 'LDFLAGS=$(_LDFLAGS)' 'OBJS=$(OBJS) $(STATICLIBS)'
+-
+ clean:
+ rm -f $(OBJS) $(EXE)
+
+@@ -140,8 +161,8 @@
+ cd docs && doxygen Doxyfile
+
+ .depend: $(foreach HEADER_DIR, $(HEADER_DIRS), $(wildcard $(HEADER_DIR)/*.h))
+- $(CC) $(CFLAGS) -MM $(patsubst %.o, %.c, $(COBJS)) >.depend
+- $(CXX) $(CXXFLAGS) -MM $(patsubst %.o, %.cpp, $(CXXOBJS)) >>.depend
++ $(CC) $(CFLAGS) $(CPPFLAGS) -MM $(patsubst %.o, %.c, $(COBJS)) >.depend
++ $(CXX) $(CXXFLAGS) $(CPPFLAGS) -MM $(patsubst %.o, %.cpp, $(CXXOBJS)) >>.depend
+
+ make.conf: make.defaults
+ @if (test -f $@ -a '$(UPDATE_CONF)' != 'yes'); \
+@@ -161,7 +182,7 @@
+ echo "\t#endinput" >> $@; \
+ echo "#endif" >> $@; \
+ echo "#define _features_included" >> $@; \
+- for feature in $(FEATURES); do \
++ for feature in $(EL_FEATURES); do \
+ echo "#define $$feature" >> $@; \
+ done
+
+--- elc/make.defaults
++++ elc/make.defaults
+@@ -1,71 +1,82 @@
+ # set this to "no" if you don't want this file to be overwritten
+ UPDATE_CONF=yes
+
++# set to 'yes' for BSD support
++BSD_KERNEL=no
++
++# set to 'yes' to enable debug support
++DEBUG=no
++
+ # tune these for your setup & compile options
+ # IMPORTANT: if you are using a linker that needs libraries in correct order, make sure you list EYE_CANDY before PNG_SCREENSHOT if you use both
+
+ ### Current release default options ###
+-FEATURES += CLUSTER_INSIDES # Group objects into separate clusters for clipping on inside maps
+-FEATURES += CUSTOM_LOOK # allows you to customize your look.
+-FEATURES += CUSTOM_UPDATE # allows autoupdating of custom look information
+-FEATURES += FUZZY_PATHS # Makes Tab Map walking not always follow exaclty the same path
+-FEATURES += NEW_SOUND # Enables extended sound effects system
+-FEATURES += PNG_SCREENSHOT # make screenshots in W3C's PNG format in game, requires libpng
+-FEATURES += TEXT_ALIASES # Text aliases
+-FEATURES += USE_INLINE # enable some optimizations to use inline functions instead of pure function calls
++EL_FEATURES += CLUSTER_INSIDES # Group objects into separate clusters for clipping on inside maps
++EL_FEATURES += CUSTOM_LOOK # allows you to customize your look.
++EL_FEATURES += CUSTOM_UPDATE # allows autoupdating of custom look information
++EL_FEATURES += FUZZY_PATHS # Makes Tab Map walking not always follow exaclty the same path
++EL_FEATURES += NEW_SOUND # Enables extended sound effects system
++EL_FEATURES += PNG_SCREENSHOT # make screenshots in W3C's PNG format in game, requires libpng
++EL_FEATURES += TEXT_ALIASES # Text aliases
++EL_FEATURES += USE_INLINE # enable some optimizations to use inline functions instead of pure function calls
+ # new for 1.9.0 release
+-FEATURES += BANDWIDTH_SAVINGS # enable bandwidth saving changes for message protocol
++EL_FEATURES += BANDWIDTH_SAVINGS # enable bandwidth saving changes for message protocol
+ # new for 1.9.2 release
+-FEATURES += ANIMATION_SCALING # Adds support for animation scaling, depending on the number of animation commands in the actor queue.
+-FEATURES += ENCYCL_NAVIGATION # Adds context menus to encyclopedia windows with search and bookmark functions
+-FEATURES += FSAA # Adds support for full screen anti-aliasing using OpenGL multisampling.
+-FEATURES += NEW_NEW_CHAR_WINDOW # Use the new character creation window; controls always on-screen
+-FEATURES += NEW_TEXTURES # Enables the new texture loading and caching system (http://www.eternal-lands.com/forum/index.php?showtopic=54756)
++EL_FEATURES += ANIMATION_SCALING # Adds support for animation scaling, depending on the number of animation commands in the actor queue.
++EL_FEATURES += ENCYCL_NAVIGATION # Adds context menus to encyclopedia windows with search and bookmark functions
++EL_FEATURES += FSAA # Adds support for full screen anti-aliasing using OpenGL multisampling.
++EL_FEATURES += NEW_NEW_CHAR_WINDOW # Use the new character creation window; controls always on-screen
++EL_FEATURES += NEW_TEXTURES # Enables the new texture loading and caching system (http://www.eternal-lands.com/forum/index.php?showtopic=54756)
+ # new for 1.9.3 release
+-FEATURES += FASTER_MAP_LOAD # Enables optimizations to speed up the process of switching between maps
+-FEATURES += FASTER_STARTUP # An attempt to reduce the startup time of EL somewhat
+-FEATURES += MIDDLE_MOUSE_PASTE # Paste using the middle mouse button from the primary buffer on X systems
++EL_FEATURES += FASTER_MAP_LOAD # Enables optimizations to speed up the process of switching between maps
++EL_FEATURES += FASTER_STARTUP # An attempt to reduce the startup time of EL somewhat
++EL_FEATURES += MIDDLE_MOUSE_PASTE # Paste using the middle mouse button from the primary buffer on X systems
+
+ ### Testing options (these options are possible for the next release and should be tested) ###
+-#FEATURES += ANTI_ALIAS # allows to enable/disable anti-aliasing in el.ini
+-#FEATURES += DYNAMIC_ANIMATIONS # (appears broken) Synchronizes animation to FPS instead of a fixed timer
+-#FEATURES += EXT_ACTOR_DICT # Removes remaining hard-coded actor def dictionaries - requires updated actor defs files (http://el.grug.redirectme.net/actor_defs.zip)
+-#FEATURES += NEW_ALPHA # (undocumented)
+-#FEATURES += USE_SIMD # Enables usage of simd instructions
++#EL_FEATURES += ANTI_ALIAS # allows to enable/disable anti-aliasing in el.ini
++#EL_FEATURES += DYNAMIC_ANIMATIONS # (appears broken) Synchronizes animation to FPS instead of a fixed timer
++#EL_FEATURES += EXT_ACTOR_DICT # Removes remaining hard-coded actor def dictionaries - requires updated actor defs files (http://el.grug.redirectme.net/actor_defs.zip)
++#EL_FEATURES += NEW_ALPHA # (undocumented)
++#EL_FEATURES += USE_SIMD # Enables usage of simd instructions
+
+ ### Machine specific options (fixes or performance enhancements) ###
+-#FEATURES += EL_BIG_ENDIAN # Enable big-endian code (automatically detected for OSX)
+-#FEATURES += NO_PF_MACRO # Use a function instead of a macro for pf_get_tile()
+-#FEATURES += SIMPLE_LOD # enable a simplistic distance culling to improve performance
++#EL_FEATURES += EL_BIG_ENDIAN # Enable big-endian code (automatically detected for OSX)
++#EL_FEATURES += NO_PF_MACRO # Use a function instead of a macro for pf_get_tile()
++#EL_FEATURES += SIMPLE_LOD # enable a simplistic distance culling to improve performance
+
+
+ ### Debug options ###
+-#FEATURES += CONTEXT_MENUS_TEST # Enable "#cmtest" command to help test/demo the context menu code
+-#FEATURES += DEBUG # (undocumented)
+-#FEATURES += DEBUG_XML # Enables missing (optional) XML string property messages
+-#FEATURES += DEBUG_POINT_PARTICLES # (undocumented)
+-#FEATURES += DEBUG_TIME # Fakes the acceleration of time for use in debugging shadows and the like.
+-#FEATURES += DEBUG_MAP_SOUND # Adds (some??) map boundary areas to tab maps and additional logging to stdout
+-#FEATURES += ECDEBUGWIN # press ctrl-alt-c to open the Eye Candy debug window: trigger most effects without casting spells or server side events
+-#FEATURES += EXTRA_DEBUG # (undocumented)
+-#FEATURES += MEMORY_DEBUG # gather information about memory allocation and freeing
+-#FEATURES += MISSILES_DEBUG # Enables debug for missiles feature. It will create a file missiles_log.txt file in your settings directory.
+-#FEATURES += MUTEX_DEBUG # (undocumented)
+-#FEATURES += OPENGL_TRACE # make far more frequent checks for OpenGL errors (requires -DDEBUG to be of any use). Will make error_log.txt a lot larger.
+-#FEATURES += TIMER_CHECK # (undocumented)
+-#FEATURES += _EXTRA_SOUND_DEBUG # Enable debug for sound effects
++#EL_FEATURES += CONTEXT_MENUS_TEST # Enable "#cmtest" command to help test/demo the context menu code
++#EL_FEATURES += DEBUG # (undocumented)
++#EL_FEATURES += DEBUG_XML # Enables missing (optional) XML string property messages
++#EL_FEATURES += DEBUG_POINT_PARTICLES # (undocumented)
++#EL_FEATURES += DEBUG_TIME # Fakes the acceleration of time for use in debugging shadows and the like.
++#EL_FEATURES += DEBUG_MAP_SOUND # Adds (some??) map boundary areas to tab maps and additional logging to stdout
++#EL_FEATURES += ECDEBUGWIN # press ctrl-alt-c to open the Eye Candy debug window: trigger most effects without casting spells or server side events
++#EL_FEATURES += EXTRA_DEBUG # (undocumented)
++
++# gather information about memory allocation and freeing
++ifeq ($(DEBUG),yes)
++EL_FEATURES += MEMORY_DEBUG
++endif
++
++#EL_FEATURES += MISSILES_DEBUG # Enables debug for missiles feature. It will create a file missiles_log.txt file in your settings directory.
++#EL_FEATURES += MUTEX_DEBUG # (undocumented)
++#EL_FEATURES += OPENGL_TRACE # make far more frequent checks for OpenGL errors (requires -DDEBUG to be of any use). Will make error_log.txt a lot larger.
++#EL_FEATURES += TIMER_CHECK # (undocumented)
++#EL_FEATURES += _EXTRA_SOUND_DEBUG # Enable debug for sound effects
+
+
+ ### Other options (Experimental, unfinished, defunct or otherwise unknown) ###
+-#FEATURES += NEW_CURSOR # New coloured cursors made by Emajekral (Experimental) Extract http://users.on.net/~gingerman/sky_cursor-textures.zip into datadir/textures/
+-#FEATURES += PAWN # Experimental, not for release, will need server support to function properly. This *will* eat your cat. You've been warned. Enables the Pawn abstract machine.
+-#FEATURES += UID # use unique ID sent from server for custom looks. (INCOMPLETE)
+-#FEATURES += USE_ACTORS_OPTIMIZER # Enables actor optimizations
+-#FEATURES += USE_BOOST
+-#FEATURES += USE_TR1 # Needs tr1 version of c++ stl, used for NEW_FILE_IO
+-#FEATURES += WRITE_XML # dangerous to use, will wipe out some XML files that are part of the main game download
+-#FEATURES += ZLIBW # Enables being able to write gzip compressed files, requires -lzlib/-lz needed for map_editor
+-#FEATURES += OLD_MISC_OBJ_DIR # if not defined, ./3dobjects/misc_objects/ paths becomes ./3dobjects/
++#EL_FEATURES += NEW_CURSOR # New coloured cursors made by Emajekral (Experimental) Extract http://users.on.net/~gingerman/sky_cursor-textures.zip into datadir/textures/
++#EL_FEATURES += PAWN # Experimental, not for release, will need server support to function properly. This *will* eat your cat. You've been warned. Enables the Pawn abstract machine.
++#EL_FEATURES += UID # use unique ID sent from server for custom looks. (INCOMPLETE)
++#EL_FEATURES += USE_ACTORS_OPTIMIZER # Enables actor optimizations
++#EL_FEATURES += USE_BOOST
++#EL_FEATURES += USE_TR1 # Needs tr1 version of c++ stl, used for NEW_FILE_IO
++#EL_FEATURES += WRITE_XML # dangerous to use, will wipe out some XML files that are part of the main game download
++#EL_FEATURES += ZLIBW # Enables being able to write gzip compressed files, requires -lzlib/-lz needed for map_editor
++#EL_FEATURES += OLD_MISC_OBJ_DIR # if not defined, ./3dobjects/misc_objects/ paths becomes ./3dobjects/
+
+
+
+@@ -86,7 +97,3 @@
+ #EXTRA_INCLUDES=-IC:\\Programme\\Dev-Cpp\\Include
+ #EXTRA_LIBS=-lz
+ #EXTRA_STATICLIBS=libs/zlib.a
+-
+-CC=gcc
+-CXX=g++
+-LINK=gcc
diff --git a/games-rpg/eternal-lands/files/eternal-lands-1.9.3-glbuild.patch b/games-rpg/eternal-lands/files/eternal-lands-1.9.3-glbuild.patch
new file mode 100644
index 000000000000..972abd9b0d2b
--- /dev/null
+++ b/games-rpg/eternal-lands/files/eternal-lands-1.9.3-glbuild.patch
@@ -0,0 +1,25 @@
+--- gl_init.c 2012-02-13 22:01:54.000000000 -0500
++++ gl_init.c 2012-12-02 18:09:41.274014922 -0500
+@@ -27,6 +27,8 @@
+ #include "fsaa/fsaa.h"
+ #endif /* FSAA */
+
++#define APIENTRY
++
+ Uint32 flags;
+
+ int window_width=640;
+--- platform.h 2012-02-13 22:01:54.000000000 -0500
++++ platform.h 2012-12-02 17:32:46.017627957 -0500
+@@ -87,9 +87,10 @@
+ #define APIENTRYP *
+ #elif !defined(BSD)
+ #define GL_GLEXT_LEGACY
++ #include <GL/glew.h>
+ #include <GL/gl.h>
+ #include <GL/glu.h>
+- #include "glext.h"
++ #include <GL/glext.h>
+ #else // BSD
+ #include <GL/gl.h>
+ #include <GL/glu.h>
diff --git a/games-rpg/eternal-lands/files/eternal-lands-1.9.3-minizip.patch b/games-rpg/eternal-lands/files/eternal-lands-1.9.3-minizip.patch
new file mode 100644
index 000000000000..9edb22254502
--- /dev/null
+++ b/games-rpg/eternal-lands/files/eternal-lands-1.9.3-minizip.patch
@@ -0,0 +1,75 @@
+From: Julian Ospald <hasufell@gentoo.org>
+Date: Sun Jun 24 16:33:08 UTC 2012
+Subject: unbundle minizip
+
+https://bugs.gentoo.org/show_bug.cgi?id=423327
+applied on top of eternal-lands-1.9.3-build.patch
+
+--- elc/new_update.c
++++ elc/new_update.c
+@@ -5,8 +5,8 @@
+ #include <string.h>
+ #include "md5.h"
+ #include "elc_private.h"
+-#include "io/zip.h"
+-#include "io/unzip.h"
++#include <zip.h>
++#include <unzip.h>
+ #include "io/ziputil.h"
+ #include "io/fileutil.h"
+ #include "io/elfilewrapper.h"
+--- elc/io/ziputil.h
++++ elc/io/ziputil.h
+@@ -8,8 +8,8 @@
+
+ #include <SDL.h>
+ #include "../md5.h"
+-#include "zip.h"
+-#include "unzip.h"
++#include <zip.h>
++#include <unzip.h>
+
+ #ifdef __cplusplus
+ extern "C"
+--- elc/io/elfilewrapper.c
++++ elc/io/elfilewrapper.c
+@@ -1,5 +1,5 @@
+ #include "elfilewrapper.h"
+-#include "unzip.h"
++#include <unzip.h>
+ #include "elpathwrapper.h"
+ #include "fileutil.h"
+ #include <sys/stat.h>
+--- elc/Makefile.linux
++++ elc/Makefile.linux
+@@ -25,11 +25,13 @@
+
+ CFLAGS += $(shell sdl-config --cflags) \
+ $(shell xml2-config --cflags) \
++ $(shell pkg-config --cflags minizip) \
+ -fno-strict-aliasing \
+ $(EXTRA_INCLUDES)
+
+ CXXFLAGS += $(shell sdl-config --cflags) \
+ $(shell xml2-config --cflags) \
++ $(shell pkg-config --cflags minizip) \
+ -fno-strict-aliasing \
+ $(EXTRA_INCLUDES)
+
+@@ -47,6 +49,7 @@
+ $(shell pkg-config --libs vorbis) \
+ $(shell pkg-config --libs vorbisfile) \
+ $(shell pkg-config --libs zlib) \
++ $(shell pkg-config --libs minizip) \
+ -lm \
+ $(EXTRA_LIBS) \
+ $(foreach FEATURE, $(EL_FEATURES), $($(FEATURE)_LIBS)) \
+@@ -80,7 +83,7 @@
+ gamewin.o gl_init.o hud.o help.o highlight.o \
+ ignore.o init.o interface.o items.o io/fileutil.o \
+ io/e3d_io.o io/elc_io.o io/map_io.o io/elpathwrapper.o io/xmlcallbacks.o \
+- io/half.o io/normal.o io/elfilewrapper.o io/unzip.o io/ioapi.o io/zip.o io/ziputil.o \
++ io/half.o io/normal.o io/elfilewrapper.o io/ziputil.o \
+ keys.o knowledge.o langselwin.o lights.o list.o load_gl_extensions.o loginwin.o loading_win.o \
+ main.o manufacture.o map.o mapwin.o memory.o \
+ md5.o mines.o minimap.o misc.o missiles.o multiplayer.o \
diff --git a/games-rpg/eternal-lands/metadata.xml b/games-rpg/eternal-lands/metadata.xml
new file mode 100644
index 000000000000..858d2d50857b
--- /dev/null
+++ b/games-rpg/eternal-lands/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>games</herd>
+<maintainer>
+ <email>rich0@gentoo.org</email>
+ <name>Richard Freeman</name>
+</maintainer>
+<longdescription>Eternal Lands is a FREE MMORPG (massively multiplayer online
+ role playing game)</longdescription>
+</pkgmetadata>