aboutsummaryrefslogtreecommitdiff
path: root/games/einstein
diff options
context:
space:
mode:
authorDmitry Marakasov <amdmi3@FreeBSD.org>2018-06-24 18:28:00 +0000
committerDmitry Marakasov <amdmi3@FreeBSD.org>2018-06-24 18:28:00 +0000
commit235c15a80a6d018c98c0222f70b5946dc2e85b0a (patch)
tree679422e82c4cf36af17d4b90474529dc9db46942 /games/einstein
parent02cd77c8b7cc689e7ae852d384e0bcfd7a5e84e6 (diff)
downloadports-235c15a80a6d018c98c0222f70b5946dc2e85b0a.tar.gz
ports-235c15a80a6d018c98c0222f70b5946dc2e85b0a.zip
Notes
Diffstat (limited to 'games/einstein')
-rw-r--r--games/einstein/Makefile8
-rw-r--r--games/einstein/files/patch-Makefile37
-rw-r--r--games/einstein/files/patch-convert.h4
-rw-r--r--games/einstein/files/patch-formatter.cpp12
-rw-r--r--games/einstein/files/patch-random.cpp4
-rw-r--r--games/einstein/files/patch-unicode.cpp4
-rw-r--r--games/einstein/files/patch-utils.cpp6
7 files changed, 42 insertions, 33 deletions
diff --git a/games/einstein/Makefile b/games/einstein/Makefile
index 9aadff8262b9..a20d6df816fa 100644
--- a/games/einstein/Makefile
+++ b/games/einstein/Makefile
@@ -14,14 +14,12 @@ COMMENT= Remake of old DOS game Sherlock, which was inspired by Albert Einstein'
LICENSE= GPLv2+ # (now dead) website mentions GPL
+LIB_DEPENDS= libfreetype.so:print/freetype2
+
USE_SDL= sdl ttf mixer
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}
-post-patch:
- @${REINPLACE_CMD} \
- -e "s,@@STAGEDIR@@,${STAGEDIR}," \
- -e "s,@@PREFIX@@,${PREFIX}," \
- ${WRKSRC}/Makefile
+CXXFLAGS+= -Wno-c++11-narrowing
post-install:
@${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/einstein
diff --git a/games/einstein/files/patch-Makefile b/games/einstein/files/patch-Makefile
index 34eaa292e5e1..6f2f1dec75e0 100644
--- a/games/einstein/files/patch-Makefile
+++ b/games/einstein/files/patch-Makefile
@@ -1,34 +1,45 @@
---- Makefile.orig Mon Sep 26 07:20:30 2005
-+++ Makefile Thu Oct 13 08:35:14 2005
-@@ -5,7 +5,7 @@
+--- Makefile.orig 2005-09-25 21:20:30 UTC
++++ Makefile
+@@ -5,7 +5,6 @@
########################################
# installation prefix
-PREFIX=/usr/local
-+PREFIX=@@PREFIX@@
########################################
#
-@@ -16,8 +16,8 @@
- OPTIMIZE=#-O6 -march=pentium4 -mfpmath=sse -fomit-frame-pointer -funroll-loops
- PROFILER=#-pg
- DEBUG=#-ggdb
+@@ -13,11 +12,8 @@ PREFIX=/usr/local
+ #
+ ########################################
+
+-OPTIMIZE=#-O6 -march=pentium4 -mfpmath=sse -fomit-frame-pointer -funroll-loops
+-PROFILER=#-pg
+-DEBUG=#-ggdb
-CXXFLAGS=-pipe -Wall $(OPTIMIZE) $(DEBUG) `sdl-config --cflags` -DPREFIX=L\"$(PREFIX)\" $(PROFILER)
-LNFLAGS=-pipe -lSDL_ttf -lfreetype `sdl-config --libs` -lz -lSDL_mixer $(PROFILER)
-+CXXFLAGS=-pipe -Wall $(OPTIMIZE) $(DEBUG) `${SDL_CONFIG} --cflags` -DPREFIX=L\"$(PREFIX)\" $(PROFILER)
-+LNFLAGS=-pipe -lSDL_ttf -lfreetype `${SDL_CONFIG} --libs` -lz -lSDL_mixer $(PROFILER)
++CXXFLAGS+=-Wall `${SDL_CONFIG} --cflags` -DPREFIX=L\"$(PREFIX)\"
++LDFLAGS+=-lSDL_ttf -lfreetype `${SDL_CONFIG} --libs` -lz -lSDL_mixer
INSTALL=install
TARGET=einstein
-@@ -61,8 +61,9 @@
+@@ -49,7 +45,7 @@ all: $(TARGET)
+
+
+ $(TARGET): $(OBJECTS)
+- $(CXX) $(LNFLAGS) $(OBJECTS) -o $(TARGET)
++ $(CXX) $(LDFLAGS) $(OBJECTS) -o $(TARGET)
+
+ clean:
+ rm -f $(OBJECTS) core* *core $(TARGET) *~
+@@ -61,8 +57,9 @@ run: $(TARGET)
./$(TARGET)
install: $(TARGET)
- $(INSTALL) -s -D $(TARGET) $(PREFIX)/bin/$(TARGET)
- $(INSTALL) -D einstein.res $(PREFIX)/share/einstein/res/einstein.res
-+ $(INSTALL) $(TARGET) $(DESTDIR)$(PREFIX)/bin/$(TARGET)
++ $(BSD_INSTALL_PROGRAM) $(TARGET) $(DESTDIR)$(PREFIX)/bin/$(TARGET)
+ mkdir -p $(DESTDIR)$(PREFIX)/share/einstein/res/
-+ $(INSTALL) einstein.res $(DESTDIR)$(PREFIX)/share/einstein/res/einstein.res
++ $(BSD_INSTALL_DATA) einstein.res $(DESTDIR)$(PREFIX)/share/einstein/res/einstein.res
# DO NOT DELETE THIS LINE -- make depend depends on it.
diff --git a/games/einstein/files/patch-convert.h b/games/einstein/files/patch-convert.h
index ec77561fe4ec..6c6db56236ac 100644
--- a/games/einstein/files/patch-convert.h
+++ b/games/einstein/files/patch-convert.h
@@ -1,5 +1,5 @@
---- convert.h.orig 2005-08-14 06:40:58.000000000 +0400
-+++ convert.h 2015-03-27 02:57:05.826432000 +0300
+--- convert.h.orig 2005-08-14 02:40:58 UTC
++++ convert.h
@@ -5,6 +5,7 @@
#include <iostream>
#include <sstream>
diff --git a/games/einstein/files/patch-formatter.cpp b/games/einstein/files/patch-formatter.cpp
index 0507fbd646a2..af837ff6d189 100644
--- a/games/einstein/files/patch-formatter.cpp
+++ b/games/einstein/files/patch-formatter.cpp
@@ -1,7 +1,6 @@
-diff -urN einstein-2.0.orig/formatter.cpp einstein-2.0/formatter.cpp
---- formatter.cpp 2005-08-13 22:40:58.000000000 -0400
-+++ formatter.cpp 2006-08-15 11:18:28.000000000 -0400
-@@ -58,7 +58,7 @@
+--- formatter.cpp.orig 2005-08-14 02:40:58 UTC
++++ formatter.cpp
+@@ -58,7 +58,7 @@ Formatter::Formatter(unsigned char *data
if ((c.type == INT_ARG) || (c.type == STRING_ARG) ||
(c.type == FLOAT_ARG) || (c.type == DOUBLE_ARG))
{
@@ -10,7 +9,7 @@ diff -urN einstein-2.0.orig/formatter.cpp einstein-2.0/formatter.cpp
args[no - 1] = c.type;
}
}
-@@ -123,7 +123,7 @@
+@@ -123,7 +123,7 @@ class StrArgValue: public ArgValue
std::wstring Formatter::format(std::vector<ArgValue*> &argValues) const
{
std::wstring s;
@@ -19,7 +18,7 @@ diff -urN einstein-2.0.orig/formatter.cpp einstein-2.0/formatter.cpp
for (int i = 0; i < commandsCnt; i++) {
Command *cmd = &commands[i];
-@@ -135,8 +135,8 @@
+@@ -135,8 +135,8 @@ std::wstring Formatter::format(std::vect
case STRING_ARG:
case INT_ARG:
@@ -29,3 +28,4 @@ diff -urN einstein-2.0.orig/formatter.cpp einstein-2.0/formatter.cpp
+ if (no < (long int)argValues.size())
s += argValues[no]->format(cmd);
break;
+
diff --git a/games/einstein/files/patch-random.cpp b/games/einstein/files/patch-random.cpp
index 7fa9f193e251..bcc6d7eb1762 100644
--- a/games/einstein/files/patch-random.cpp
+++ b/games/einstein/files/patch-random.cpp
@@ -1,8 +1,8 @@
---- random.cpp.orig
+--- random.cpp.orig 2005-08-14 02:40:58 UTC
+++ random.cpp
@@ -1,3 +1,5 @@
+#include "sys/time.h"
+
#include "random.h"
#include "utils.h"
-
+
diff --git a/games/einstein/files/patch-unicode.cpp b/games/einstein/files/patch-unicode.cpp
index 5e7081d18573..c968129726a3 100644
--- a/games/einstein/files/patch-unicode.cpp
+++ b/games/einstein/files/patch-unicode.cpp
@@ -1,5 +1,5 @@
---- unicode.cpp.orig 2005-08-14 06:40:58.000000000 +0400
-+++ unicode.cpp 2015-03-27 02:57:47.513365000 +0300
+--- unicode.cpp.orig 2005-08-14 02:40:58 UTC
++++ unicode.cpp
@@ -1,5 +1,6 @@
#include <wchar.h>
#include <stdlib.h>
diff --git a/games/einstein/files/patch-utils.cpp b/games/einstein/files/patch-utils.cpp
index ec46747b98aa..6b3b21c87e80 100644
--- a/games/einstein/files/patch-utils.cpp
+++ b/games/einstein/files/patch-utils.cpp
@@ -1,6 +1,6 @@
---- utils.cpp.orig Tue Feb 1 08:23:17 2005
-+++ utils.cpp Tue Feb 1 08:23:27 2005
-@@ -9,6 +9,7 @@
+--- utils.cpp.orig 2005-08-23 21:26:23 UTC
++++ utils.cpp
+@@ -11,6 +11,7 @@
//#endif
#include <fstream>