]> git.draconx.ca Git - gentoo-draconx.git/blob - games-engines/onscripter-en/onscripter-en-20110930-r1.ebuild
games-engines/onscripter-en: Update to work with latest gentoo repo.
[gentoo-draconx.git] / games-engines / onscripter-en / onscripter-en-20110930-r1.ebuild
1 # Copyright © 2015, 2021 Nick Bowler
2 # License GPLv3+: GNU General Public License version 3 or any later version.
3 # This is free software: you are free to change and redistribute it.
4 # There is NO WARRANTY, to the extent permitted by law.
5
6 EAPI=7
7
8 DESCRIPTION="English-language fork of ONScripter: a free clone of NScripter"
9 HOMEPAGE="http://unclemion.com/dev/projects/onscripter-en"
10
11 # This package has a hard dep on SDL_ttf-2.0.10, fonts do not work with
12 # 2.0.11.  Download that release specifically.
13 SRC_URI="https://web.archive.org/web/20150801182531/http://unclemion.com/dev/attachments/download/36/$P-src.tar.bz2
14         https://www.libsdl.org/projects/SDL_ttf/release/SDL_ttf-2.0.10.tar.gz
15         "
16
17 LICENSE="GPL-2+ ZLIB"
18 SLOT="0"
19 KEYWORDS="~amd64"
20
21 BDEPEND="app-arch/bzip2
22         virtual/pkgconfig"
23 DEPEND="media-libs/libsdl
24         media-libs/sdl-mixer[vorbis]
25         media-libs/sdl-image
26         media-libs/smpeg
27         media-libs/freetype:2
28         x11-libs/libXt"
29 RDEPEND=$DEPEND
30
31 PATCHES=(
32         "$FILESDIR/$P-fix-configure.patch"
33         "$FILESDIR/$PN-respect-CXXFLAGS.patch"
34 )
35
36 src_configure() {
37         local pkgconfig=`command -v pkg-config`
38
39         einfo "Configuring SDL_ttf $pkgconfig"
40         cd "$WORKDIR/SDL_ttf-2.0.10" || die
41         econf --prefix="$S/onscrlib" --libdir='${prefix}/lib' \
42                 --enable-static --disable-shared \
43                 FREETYPE_CONFIG="$pkgconfig freetype2"
44
45         einfo "Configuring $PN"
46         cd "$S" || die
47         econf --unsupported-compiler \
48                 --onscrlib-path="$S" --with-internal-sdl-ttf
49 }
50
51 src_compile() {
52         einfo "Building SDL_ttf"
53         cd "$WORKDIR/SDL_ttf-2.0.10" || die
54         emake noinst_PROGRAMS= install
55
56         einfo "Building $PN"
57         cd "$S" || die
58         default
59 }
60
61 src_install() {
62         dodoc README
63         dobin onscripter-en
64 }