Putt: call maemo_init()
authorAlberto Mardegan <mardy@users.sourceforge.net>
Wed, 13 Jul 2011 10:25:07 +0000 (13:25 +0300)
committerAlberto Mardegan <mardy@users.sourceforge.net>
Wed, 13 Jul 2011 10:25:07 +0000 (13:25 +0300)
This currently takes care of keeping the display on, and setting up fast FPU
moed.

Makefile
putt/main.c

index e594c89..fdabded 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -327,6 +327,7 @@ else
 ifeq ($(PLATFORM),maemo)
 BALL_OBJS += share/tilt_maemo.o
 BALL_OBJS += share/maemo.o
+PUTT_OBJS += share/maemo.o
 else
 BALL_OBJS += share/tilt_null.o
 endif
index 1c173da..e636580 100644 (file)
@@ -32,6 +32,9 @@
 #include "game.h"
 #include "gui.h"
 #include "fs.h"
+#ifdef __MAEMO__
+#include "maemo.h"
+#endif
 
 #include "st_conf.h"
 #include "st_all.h"
@@ -218,7 +221,12 @@ int main(int argc, char *argv[])
     config_paths(argc > 1 ? argv[1] : NULL);
     fs_mkdir("Screenshots");
 
-    if (SDL_Init(SDL_INIT_VIDEO | SDL_INIT_AUDIO | SDL_INIT_JOYSTICK) == 0)
+    if (SDL_Init(SDL_INIT_VIDEO |
+                 SDL_INIT_AUDIO |
+#ifdef __MAEMO__
+                 SDL_INIT_TIMER |
+#endif
+                 SDL_INIT_JOYSTICK) == 0)
     {
         config_init();
         config_load();
@@ -243,6 +251,10 @@ int main(int argc, char *argv[])
 
         audio_init();
 
+#ifdef __MAEMO__
+        maemo_init("neverputt");
+#endif
+
         /* Initialize the video. */
 
         if (video_init(TITLE, ICON))