--- 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
