1 |
commit: 72aa2845bba14a3291d5c73d178278a448e11d7f |
2 |
Author: Sam James <sam <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Jan 6 23:06:22 2022 +0000 |
4 |
Commit: Sam James <sam <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Jan 6 23:06:32 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=72aa2845 |
7 |
|
8 |
games-strategy/endless-sky: initial import (restore at 0.9.14) |
9 |
|
10 |
Closes: https://bugs.gentoo.org/735542 |
11 |
Signed-off-by: Sam James <sam <AT> gentoo.org> |
12 |
|
13 |
games-strategy/endless-sky/Manifest | 1 + |
14 |
.../endless-sky/endless-sky-0.9.14.ebuild | 59 ++++++++++++++++++++++ |
15 |
.../files/endless-sky-0.9.14-no-games-path.patch | 42 +++++++++++++++ |
16 |
.../files/endless-sky-0.9.14-respect-cflags.patch | 20 ++++++++ |
17 |
games-strategy/endless-sky/metadata.xml | 16 ++++++ |
18 |
5 files changed, 138 insertions(+) |
19 |
|
20 |
diff --git a/games-strategy/endless-sky/Manifest b/games-strategy/endless-sky/Manifest |
21 |
new file mode 100644 |
22 |
index 000000000000..75a855912828 |
23 |
--- /dev/null |
24 |
+++ b/games-strategy/endless-sky/Manifest |
25 |
@@ -0,0 +1 @@ |
26 |
+DIST endless-sky-0.9.14.tar.gz 124358153 BLAKE2B 5845c3b595f0feba7fc5f6ce1ead88b34e9426c3db53cf013fc67f9197d2cabad8fae39056fa6f4d6da76fceb43a9709397b95daba855d1b1ebf3c25a04ba007 SHA512 861fddc8e2f167d335247f3ce1efb59bb4a5951cb0aa5e4a10517fded096db7e69ac17cf0e813f2a1ec040bef57c5d6b6e8e90d952debc9b2caa38d1fb91abe5 |
27 |
|
28 |
diff --git a/games-strategy/endless-sky/endless-sky-0.9.14.ebuild b/games-strategy/endless-sky/endless-sky-0.9.14.ebuild |
29 |
new file mode 100644 |
30 |
index 000000000000..f0f7509aa8a8 |
31 |
--- /dev/null |
32 |
+++ b/games-strategy/endless-sky/endless-sky-0.9.14.ebuild |
33 |
@@ -0,0 +1,59 @@ |
34 |
+# Copyright 1999-2022 Gentoo Authors |
35 |
+# Distributed under the terms of the GNU General Public License v2 |
36 |
+ |
37 |
+EAPI=7 |
38 |
+ |
39 |
+PYTHON_COMPAT=( python3_{8,9,10} ) |
40 |
+inherit python-any-r1 scons-utils toolchain-funcs xdg |
41 |
+ |
42 |
+DESCRIPTION="Space exploration, trading & combat in the tradition of Terminal Velocity" |
43 |
+HOMEPAGE="https://endless-sky.github.io" |
44 |
+SRC_URI="https://github.com/endless-sky/endless-sky/archive/v${PV}.tar.gz -> ${P}.tar.gz" |
45 |
+ |
46 |
+LICENSE="CC-BY-SA-4.0 CC-BY-SA-3.0 GPL-3+ public-domain" |
47 |
+SLOT="0" |
48 |
+KEYWORDS="~amd64 ~x86" |
49 |
+ |
50 |
+# Needs work; doesn't link against SDL 2 |
51 |
+RESTRICT="test" |
52 |
+ |
53 |
+RDEPEND="media-libs/glew:0= |
54 |
+ media-libs/libsdl2 |
55 |
+ media-libs/libjpeg-turbo:= |
56 |
+ media-libs/libmad |
57 |
+ media-libs/libpng:= |
58 |
+ media-libs/openal |
59 |
+ virtual/opengl" |
60 |
+DEPEND="${RDEPEND}" |
61 |
+ |
62 |
+PATCHES=( |
63 |
+ "${FILESDIR}"/${PN}-0.9.14-respect-cflags.patch |
64 |
+ "${FILESDIR}"/${PN}-0.9.14-no-games-path.patch |
65 |
+) |
66 |
+ |
67 |
+src_compile() { |
68 |
+ tc-export CXX |
69 |
+ |
70 |
+ escons |
71 |
+} |
72 |
+ |
73 |
+src_test() { |
74 |
+ escons test |
75 |
+} |
76 |
+ |
77 |
+src_install() { |
78 |
+ escons PREFIX="${ED}"/usr/ install |
79 |
+} |
80 |
+ |
81 |
+pkg_postinst() { |
82 |
+ xdg_pkg_postinst |
83 |
+ |
84 |
+ einfo "Endless Sky provides high-res sprites for high-dpi screens." |
85 |
+ einfo "If you want to use them, download" |
86 |
+ einfo |
87 |
+ einfo " https://github.com/endless-sky/endless-sky-high-dpi/releases" |
88 |
+ einfo |
89 |
+ einfo "and extract it to ~/.local/share/endless-sky/plugins/." |
90 |
+ einfo |
91 |
+ einfo "Enjoy." |
92 |
+} |
93 |
|
94 |
diff --git a/games-strategy/endless-sky/files/endless-sky-0.9.14-no-games-path.patch b/games-strategy/endless-sky/files/endless-sky-0.9.14-no-games-path.patch |
95 |
new file mode 100644 |
96 |
index 000000000000..bdec820de1e1 |
97 |
--- /dev/null |
98 |
+++ b/games-strategy/endless-sky/files/endless-sky-0.9.14-no-games-path.patch |
99 |
@@ -0,0 +1,42 @@ |
100 |
+https://src.fedoraproject.org/rpms/endless-sky/raw/rawhide/f/endless-sky-0.9.13-remove-games-path.patch |
101 |
+--- a/SConstruct |
102 |
++++ b/SConstruct |
103 |
+@@ -191,11 +191,11 @@ |
104 |
+ RecursiveInstall(env, pathjoin(target, name), node.abspath) |
105 |
+ else: |
106 |
+ env.Install(target, node) |
107 |
+-RecursiveInstall(env, "$DESTDIR$PREFIX/share/games/endless-sky/data", "data") |
108 |
+-RecursiveInstall(env, "$DESTDIR$PREFIX/share/games/endless-sky/images", "images") |
109 |
+-RecursiveInstall(env, "$DESTDIR$PREFIX/share/games/endless-sky/sounds", "sounds") |
110 |
+-env.Install("$DESTDIR$PREFIX/share/games/endless-sky", "credits.txt") |
111 |
+-env.Install("$DESTDIR$PREFIX/share/games/endless-sky", "keys.txt") |
112 |
++RecursiveInstall(env, "$DESTDIR$PREFIX/share/endless-sky/data", "data") |
113 |
++RecursiveInstall(env, "$DESTDIR$PREFIX/share/endless-sky/images", "images") |
114 |
++RecursiveInstall(env, "$DESTDIR$PREFIX/share/endless-sky/sounds", "sounds") |
115 |
++env.Install("$DESTDIR$PREFIX/share/endless-sky", "credits.txt") |
116 |
++env.Install("$DESTDIR$PREFIX/share/endless-sky", "keys.txt") |
117 |
+ |
118 |
+ # Make the word "install" in the command line do an installation. |
119 |
+ env.Alias("install", "$DESTDIR$PREFIX") |
120 |
+--- a/SConstruct |
121 |
++++ b/SConstruct |
122 |
+@@ -142,7 +142,7 @@ |
123 |
+ |
124 |
+ |
125 |
+ # Install the binary: |
126 |
+-env.Install("$DESTDIR$PREFIX/games", sky) |
127 |
++env.Install("$DESTDIR$PREFIX/bin", sky) |
128 |
+ |
129 |
+ # Install the desktop file: |
130 |
+ env.Install("$DESTDIR$PREFIX/share/applications", "endless-sky.desktop") |
131 |
+--- a/source/Files.cpp |
132 |
++++ b/source/Files.cpp |
133 |
+@@ -119,7 +119,7 @@ |
134 |
+ // the executable, but are under the same prefix (/usr or /usr/local). |
135 |
+ static const string LOCAL_PATH = "/usr/local/"; |
136 |
+ static const string STANDARD_PATH = "/usr/"; |
137 |
+- static const string RESOURCE_PATH = "share/games/endless-sky/"; |
138 |
++ static const string RESOURCE_PATH = "share/endless-sky/"; |
139 |
+ if(!resources.compare(0, LOCAL_PATH.length(), LOCAL_PATH)) |
140 |
+ resources = LOCAL_PATH + RESOURCE_PATH; |
141 |
+ else if(!resources.compare(0, STANDARD_PATH.length(), STANDARD_PATH)) |
142 |
|
143 |
diff --git a/games-strategy/endless-sky/files/endless-sky-0.9.14-respect-cflags.patch b/games-strategy/endless-sky/files/endless-sky-0.9.14-respect-cflags.patch |
144 |
new file mode 100644 |
145 |
index 000000000000..8bea82409af0 |
146 |
--- /dev/null |
147 |
+++ b/games-strategy/endless-sky/files/endless-sky-0.9.14-respect-cflags.patch |
148 |
@@ -0,0 +1,20 @@ |
149 |
+https://src.fedoraproject.org/rpms/endless-sky/raw/rawhide/f/endless-sky-0.9.14-remove-additional-ccflags.patch |
150 |
+--- a/SConstruct |
151 |
++++ b/SConstruct |
152 |
+@@ -46,15 +46,7 @@ |
153 |
+ # $ CXXFLAGS=-msse3 scons |
154 |
+ # $ CXXFLAGS=-march=native scons |
155 |
+ # or modify the `flags` variable: |
156 |
+-flags = ["-std=c++11", "-Wall", "-Werror", "-Wold-style-cast"] |
157 |
+-if env["mode"] != "debug": |
158 |
+- flags += ["-O3", "-flto"] |
159 |
+- env.Append(LINKFLAGS = ["-O3", "-flto"]) |
160 |
+-if env["mode"] == "debug": |
161 |
+- flags += ["-g"] |
162 |
+-elif env["mode"] == "profile": |
163 |
+- flags += ["-pg"] |
164 |
+- env.Append(LINKFLAGS = ["-pg"]) |
165 |
++flags = ["-std=c++11"] |
166 |
+ env.Append(CCFLAGS = flags) |
167 |
+ |
168 |
+ # Always use `ar` to create the symbol table, and don't use ranlib at all, since it fails to preserve |
169 |
|
170 |
diff --git a/games-strategy/endless-sky/metadata.xml b/games-strategy/endless-sky/metadata.xml |
171 |
new file mode 100644 |
172 |
index 000000000000..6f9e5ee62db4 |
173 |
--- /dev/null |
174 |
+++ b/games-strategy/endless-sky/metadata.xml |
175 |
@@ -0,0 +1,16 @@ |
176 |
+<?xml version='1.0' encoding='UTF-8'?> |
177 |
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> |
178 |
+<pkgmetadata> |
179 |
+ <maintainer type="project"> |
180 |
+ <email>games@g.o</email> |
181 |
+ <name>Gentoo Games</name> |
182 |
+ </maintainer> |
183 |
+ <longdescription> |
184 |
+ Explore other star systems. Earn money by trading, carrying passengers, or completing missions. |
185 |
+ Use your earnings to buy a better ship or to upgrade the weapons and engines on your current one. Blow up pirates. |
186 |
+ Take sides in a civil war. Or leave human space behind and hope to find some friendly aliens whose culture is more civilized than your own... |
187 |
+ </longdescription> |
188 |
+ <upstream> |
189 |
+ <remote-id type="github">endless-sky/endless-sky</remote-id> |
190 |
+ </upstream> |
191 |
+</pkgmetadata> |