blob: 2c29c8b5c266aa86173979f79930949389dfb80f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
|
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
PYTHON_COMPAT=( python2_7 )
inherit cmake-utils python-single-r1 xdg
DESCRIPTION="A free turn-based space empire and galactic conquest game"
HOMEPAGE="https://www.freeorion.org"
if [[ ${PV} == 9999 ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/freeorion/freeorion.git"
else
KEYWORDS="~amd64"
if [[ ${PV} = *_p* ]]; then
COMMIT="2a49c05796f1c92b96ce9b2aeaf0124fc8be7a77"
SRC_URI="https://github.com/${PN}/${PN}/archive/${COMMIT}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${PN}-${COMMIT}"
else
SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV/_/-}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${PN}-${PV/_/-}"
fi
fi
LICENSE="GPL-2 LGPL-2.1 CC-BY-SA-3.0"
SLOT="0"
IUSE="dedicated"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
BDEPEND="
virtual/pkgconfig
"
RDEPEND="
>=dev-libs/boost-1.58:=[python,threads,${PYTHON_USEDEP}]
!dedicated? (
media-libs/freealut
>=media-libs/freetype-2.5.5
media-libs/glew:=
>=media-libs/libogg-1.1.3
media-libs/libpng:0=
media-libs/libsdl2[X,opengl,video]
>=media-libs/libvorbis-1.1.2
media-libs/openal
sci-physics/bullet
virtual/opengl
)
sys-libs/zlib
"
DEPEND="${RDEPEND}
${PYTHON_DEPS}
"
pkg_setup() {
# build system is using FindPythonLibs.cmake which needs python:2
python-single-r1_pkg_setup
}
src_prepare() {
sed -e "s/-O3//" -i CMakeLists.txt || die
cmake-utils_src_prepare
}
src_configure() {
local mycmakeargs=(
-DCMAKE_BUILD_TYPE=Release
-DCMAKE_SKIP_RPATH=ON
-DBUILD_HEADLESS="$(usex dedicated)"
)
cmake-utils_src_configure
}
src_install() {
cmake-utils_src_install
newenvd "${FILESDIR}/${PN}.envd" 99${PN}
}
|