mirror of
https://git.FreeBSD.org/ports.git
synced 2025-02-06 11:41:52 +00:00
- Unbreak fetch, switch to github, simplify port
PR: 212849 Submitted by: lightside@gmx.com
This commit is contained in:
parent
e99300673c
commit
a00bbe3288
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=422565
@ -4,22 +4,23 @@
|
||||
PORTNAME= osgg
|
||||
PORTVERSION= 1.0
|
||||
CATEGORIES= games
|
||||
MASTER_SITES= SF
|
||||
|
||||
MAINTAINER= amdmi3@FreeBSD.org
|
||||
COMMENT= OldSkool Gravity Game
|
||||
|
||||
LICENSE= GPLv3+
|
||||
|
||||
BROKEN= unfetchable (checksum mismatch)
|
||||
USE_GITHUB= yes
|
||||
GH_ACCOUNT= DusteDdk
|
||||
GH_PROJECT= Osgg
|
||||
GH_TAGNAME= 32d9e02 # 1.0 + extra FreeBSD-related fixes
|
||||
|
||||
USES= tar:bzip2
|
||||
USE_SDL= sdl image ttf mixer
|
||||
USE_GL= gl
|
||||
MAKE_ENV= DATADIR="${DATADIR}/"
|
||||
|
||||
PLIST_FILES= bin/${PORTNAME}
|
||||
PORTDATA= *
|
||||
PORTDATA= *.txt *.ogg Bandal.ttf icon.png levels
|
||||
|
||||
DESKTOP_ENTRIES="Osgg" \
|
||||
"" \
|
||||
@ -28,11 +29,8 @@ DESKTOP_ENTRIES="Osgg" \
|
||||
"Game;ArcadeGame;" \
|
||||
""
|
||||
|
||||
post-extract:
|
||||
@${RM} -f ${WRKSRC}/osgg ${WRKSRC}/launcher/launcher
|
||||
|
||||
do-install:
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin/
|
||||
cd ${WRKSRC} && ${COPYTREE_SHARE} "*.txt *.ogg Bandal.ttf icon.png levels" ${STAGEDIR}${DATADIR}/
|
||||
@cd ${WRKSRC} && ${COPYTREE_SHARE} "${PORTDATA}" ${STAGEDIR}${DATADIR}/
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
@ -1,3 +1,3 @@
|
||||
TIMESTAMP = 1471280939
|
||||
SHA256 (osgg-1.0.tar.bz2) = 59654b2a845883078071eca847a1fd07f0084302c1555a4d9d239155f29d758c
|
||||
SIZE (osgg-1.0.tar.bz2) = 300614
|
||||
TIMESTAMP = 1474370793
|
||||
SHA256 (DusteDdk-Osgg-1.0-32d9e02_GH0.tar.gz) = 5d21f7f2608e2b2f43b814e4e1b9fa46b05b18314ba8af0ab15c89302d61e46d
|
||||
SIZE (DusteDdk-Osgg-1.0-32d9e02_GH0.tar.gz) = 237328
|
||||
|
@ -1,37 +0,0 @@
|
||||
--- Makefile.orig 2016-08-13 02:07:57 UTC
|
||||
+++ Makefile
|
||||
@@ -1,26 +1,26 @@
|
||||
DATADIR?=./
|
||||
|
||||
-CC=g++ -DDATADIR="\"$(DATADIR)\""
|
||||
+CXX?=g++
|
||||
|
||||
-CFLAGS+=-Wall `sdl-config --cflags`
|
||||
+CXXFLAGS+=-Wall `sdl-config --cflags` -DDATADIR="\"$(DATADIR)\""
|
||||
|
||||
-LIBS+=-lGL `sdl-config --libs` -lSDL_ttf -lSDL_image -lSDL_mixer
|
||||
+LIBS+=`sdl-config --libs` -lSDL_ttf -lSDL_image -lSDL_mixer -lGL -lm
|
||||
|
||||
SOURCES=main.cpp text.cpp sound.cpp
|
||||
-OBJECTS=$(SOURCES:.c=.o)
|
||||
+OBJECTS=$(SOURCES:.cpp=.o)
|
||||
|
||||
EXECUTABLE=osgg
|
||||
|
||||
all: $(SOURCES) $(EXECUTABLE)
|
||||
|
||||
server: server.cpp
|
||||
- $(CC) $(LDFLAGS) server.cpp $(LIBS) -o $@
|
||||
-
|
||||
+ $(CXX) $(CXXFLAGS) $(LDFLAGS) server.cpp $(LIBS) -o $@
|
||||
+
|
||||
$(EXECUTABLE): $(OBJECTS)
|
||||
- $(CC) $(LDFLAGS) $(OBJECTS) $(LIBS) -o $@
|
||||
+ $(CXX) $(LDFLAGS) $(OBJECTS) $(LIBS) -o $@
|
||||
|
||||
.cpp.o:
|
||||
- $(CC) $(CFLAGS) $< -o $@
|
||||
+ $(CXX) $(CXXFLAGS) -c $< -o $@
|
||||
|
||||
clean:
|
||||
rm -f *.o $(EXECUTABLE)
|
@ -1,54 +0,0 @@
|
||||
--- main.cpp.orig 2016-08-13 02:07:57 UTC
|
||||
+++ main.cpp
|
||||
@@ -27,15 +27,18 @@
|
||||
#include <fstream>
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
+#include <unistd.h> // for usleep()
|
||||
|
||||
#include <sys/time.h>
|
||||
|
||||
-#ifndef WIN32
|
||||
- #include <endian.h>
|
||||
-#else
|
||||
+#if defined(WIN32)
|
||||
typedef unsigned int uint;
|
||||
#include <windows.h>
|
||||
#include <GL/glext.h>
|
||||
+#elif defined(__FreeBSD__)
|
||||
+ #include <sys/endian.h>
|
||||
+#else
|
||||
+ #include <endian.h>
|
||||
#endif
|
||||
|
||||
|
||||
@@ -348,6 +351,7 @@ bool classBullets::col(vector<vert> targ
|
||||
}
|
||||
}
|
||||
}
|
||||
+ return false;
|
||||
}
|
||||
|
||||
void classBullets::shoot(entity owner, gPs velocity)
|
||||
@@ -1826,9 +1830,9 @@ int main(int argc, char **argv)
|
||||
|
||||
GLfloat scale;
|
||||
|
||||
- readEnt("ship.txt", gameInfo.shipStaticVerts);
|
||||
- readEnt("base.txt", gameInfo.baseStaticVerts);
|
||||
- readEnt("enemy.txt", gameInfo.enemyStaticVerts);
|
||||
+ readEnt(DATADIR "ship.txt", gameInfo.shipStaticVerts);
|
||||
+ readEnt(DATADIR "base.txt", gameInfo.baseStaticVerts);
|
||||
+ readEnt(DATADIR "enemy.txt", gameInfo.enemyStaticVerts);
|
||||
|
||||
//Enter Main loop
|
||||
while(gameState != GameStateQuit)
|
||||
@@ -1958,7 +1962,7 @@ int main(int argc, char **argv)
|
||||
break;
|
||||
|
||||
case SDLK_d:
|
||||
- saveMap(polys, ents, "verts.txt");
|
||||
+ saveMap(polys, ents, DATADIR "verts.txt");
|
||||
break;
|
||||
|
||||
case SDLK_s:
|
Loading…
x
Reference in New Issue
Block a user