gemdropx, new recipe and patch

This commit is contained in:
begasus
2014-10-19 17:59:02 +02:00
parent 1cdad40082
commit 1df07f38a3
2 changed files with 101 additions and 0 deletions

View File

@@ -0,0 +1,42 @@
--- gemdropx-0.9/gemdropx.c.org 2014-10-19 08:12:42.397672448 +0200
+++ gemdropx-0.9/gemdropx.c 2014-10-19 08:09:18.373555200 +0200
@@ -29,6 +29,7 @@
#include <sys/types.h>
#include <sys/time.h>
#include <unistd.h>
+#include <libgen.h>
#ifndef EMBEDDED
#include <SDL.h>
@@ -2560,7 +2561,10 @@
SDL_version sdlver;
#endif
-
+ #ifdef __HAIKU__
+ chdir(dirname(argv[0]));
+ #endif
+
no_music = 0;
if (argc == 2)
--- gemdropx-0.9/Makefile.org 2014-10-19 08:51:57.785383424 +0200
+++ gemdropx-0.9/Makefile 2014-10-19 08:51:18.383254528 +0200
@@ -14,7 +14,7 @@
# Added 'install' target (finally!): May 18, 2002
-DATA_PREFIX=/usr/local/share/gemdropx
+DATA_PREFIX=./data
SDL_CFLAGS := $(shell sdl-config --cflags)
SDL_LDFLAGS := $(shell sdl-config --libs)
CC=gcc
@@ -61,7 +61,7 @@
gemdropx: gemdropx.o
- $(CXX) $(CFLAGS) -o gemdropx gemdropx.o $(GFX_LIB) -lm
+ $(CXX) $(CFLAGS) -o gemdropx gemdropx.o $(GFX_LIB)
gemdropx.o: gemdropx.c