commit: 9a523f187eb159ba514ac94ade360f25b7e68225
Author: David Seifert gentoo org>
AuthorDate: Fri Dec 30 07:33:50 2016 +
Commit: David Seifert gentoo org>
CommitDate: Fri Dec 30 07:35:23 2016 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9a523f18
games-arcade/tuxdash: Fix building with GCC 6
Gentoo-bug: 600084
* EAPI=6
* Remove games.eclass
Package-Manager: Portage-2.3.3, Repoman-2.3.1
.../files/tuxdash-0.8-fix-build-system.patch | 11 +++
.../tuxdash/files/tuxdash-0.8-fix-c++14.patch | 101 +
.../tuxdash/files/tuxdash-0.8-fix-paths.patch | 45 +
games-arcade/tuxdash/tuxdash-0.8-r1.ebuild | 48 ++
4 files changed, 205 insertions(+)
diff --git a/games-arcade/tuxdash/files/tuxdash-0.8-fix-build-system.patch
b/games-arcade/tuxdash/files/tuxdash-0.8-fix-build-system.patch
new file mode 100644
index ..9f861d9
--- /dev/null
+++ b/games-arcade/tuxdash/files/tuxdash-0.8-fix-build-system.patch
@@ -0,0 +1,11 @@
+Fix build system to honour all user variables.
+
+--- a/src/Makefile
b/src/Makefile
+@@ -1,4 +1,4 @@
+ all:
+- g++ main.cpp -Wall `/usr/bin/sdl-config --libs --cflags` -lSDL_ttf -o
../TuxDash
++ $(CXX) main.cpp $(LDFLAGS) $(CXXFLAGS) $(CPPFLAGS) `/usr/bin/sdl-config
--libs --cflags` -lSDL_ttf -o ../tuxdash
+ static:
+- g++ -static main.cpp -Wall `/usr/bin/sdl-config --cflags --static-libs`
-lSDL_ttf -lfreetype -lz -o ../TuxDash
++ $(CXX) -static main.cpp $(LDFLAGS) $(CXXFLAGS) $(CPPFLAGS)
`/usr/bin/sdl-config --cflags --static-libs` -lSDL_ttf -lfreetype -lz -o
../tuxdash
diff --git a/games-arcade/tuxdash/files/tuxdash-0.8-fix-c++14.patch
b/games-arcade/tuxdash/files/tuxdash-0.8-fix-c++14.patch
new file mode 100644
index ..b37f456
--- /dev/null
+++ b/games-arcade/tuxdash/files/tuxdash-0.8-fix-c++14.patch
@@ -0,0 +1,101 @@
+Modernise C++ to avoid errors in C++14 mode.
+See also: https://bugs.gentoo.org/show_bug.cgi?id=600084
+
+--- a/src/main.cpp
b/src/main.cpp
+@@ -66,7 +66,7 @@
+
+ void writeconfig(const map& game_map) {
+ ofstream config((ostring)TuxHomeDirectory + "/config"); // open config
file
+- if(config == NULL) {// error check
++ if(!config) { // error check
+ cout << "Warning: Couldn't write to file " <<
(ostring)TuxHomeDirectory + "/config" << endl;
+ return;
+ }
+@@ -124,7 +124,7 @@
+
+ void readconfig(class map& game_map) {
+ ifstream config((ostring)TuxHomeDirectory + "/config"); // open config
file
+- if(config==0) { // error check
++ if(!config) { // error check
+ cout << "Warning: Couldn't find configuration file " <<
(ostring)TuxHomeDirectory + "/config" << ". Using default values." << endl;
+ return;
+ }
+--- a/src/map.cpp
b/src/map.cpp
+@@ -346,13 +346,13 @@
+ cout << "-- copy map --" << endl; // print status message
+ ifstream in_file(path); // open source file
+
+- if(in_file == 0) { // error checking
++ if(!in_file) { // error checking
+ cout << "Couldn't open sourcefile \"" << filename << "\"" <<
endl;
+ cout << endl << "-- error in copymap --" << endl;
+ return 1;
+ }
+
+- if(out_file == 0) { // error checking
++ if(!out_file) { // error checking
+ cout << "Couldn't open target file \"" << temp_path << "\" for
writing " << endl;
+ cout << endl << "-- error in copymap --" << endl;
+ return 1;
+@@ -390,7 +390,7 @@
+ path = mapfolder;
+ path += filename;
+ file.open(path);// open file
+- if(file == NULL) {
++ if(!file) {
+ cout << "map::savemap : error while saving map to file
'" << path << "'" << endl;
+ return 1;
+ }
+@@ -402,7 +402,7 @@
+ path = savefolder;
+ path += filename;
+ file.open(path);// open file
+- if(file == NULL) {
++ if(!file) {
+ cout << "map::savemap : error while saving game to file
'" << path << "'" << endl;
+ return 1;
+ }
+--- a/src/menu.cpp
b/src/menu.cpp
+@@ -119,7 +119,7 @@
+
+ // add a selection box
+
+-class element* menu_mgm::add_box(int x, int y, const ostring& text, const
ostring& value, bool selectable, int size, int xgroup, int ygroup, int max, int
width, int height, unsigned char r, unsigned char g, unsigned char b, int
value_type, bool dependency, char* depend) {
++class element* menu_mgm::add_box(int x, int y, const ostring& text, const
ostring& value, bool selectable, int size, int xgroup, int ygroup, int max, int
width, int height, unsigned char r, unsigned char g, unsigned char b, int
value_type, bool dependency, const char* depend) {
+