1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
|
--- include/config.h.orig 2005-04-27 15:01:54.000000000 +0200
+++ include/config.h 2003-12-08 00:39:13.000000000 +0100
@@ -48,0 +48,1 @@
+#define GTK2_GRAPHICS /* Gtk2 interface */
@@ -55 +56 @@
- * tty, X11, mac, amii, BeOS, Qt, Gem, Gnome
+ * tty, X11, mac, amii, BeOS, Qt, Gem, Gnome, Gtk2
@@ -107,1 +105,8 @@
+#ifdef GTK2_GRAPHICS
+ #define USE_XPM /* Use XPM format for images (required) */
+ #define GRAPHIC_TOMBSTONE /* Use graphical tombstone (rip.ppm) */
+ #ifndef DEFAULT_WINDOW_SYS
+ #define DEFAULT_WINDOW_SYS "Gtk2"
+ #endif
+ #define ENABLE_NLS /* Use translated gui strings */
+#endif
-
@@ -351 +341 @@
-/* #define SCORE_ON_BOTL */ /* added by Gary Erickson (erickson@ucivax) */
+#define SCORE_ON_BOTL /* added by Gary Erickson (erickson@ucivax) */
@@ -362 +352 @@
-/*#define AUTOPICKUP_EXCEPTIONS */ /* exceptions to autopickup */
+#define AUTOPICKUP_EXCEPTIONS /* exceptions to autopickup */
--- src/Makefile.orig 2005-10-31 20:44:09.000000000 +0100
+++ src/Makefile 2005-04-27 15:01:54.000000000 +0200
@@ -150,0 +150 @@
+GTK2INC=`pkg-config gtk+-2.0 --cflags`
@@ -202,0 +202,9 @@
+#
+# Files for a Gtk2 port
+#
+WINGTK2SRC = ../win/gtk2/g2bind.c ../win/gtk2/g2main.c ../win/gtk2/g2mesg.c\
+ ../win/gtk2/g2player.c ../win/gtk2/g2map.c ../win/gtk2/g2marsh.c\
+ ../win/gtk2/g2status.c ../win/gtk2/g2menu.c ../win/gtk2/g2text.c\
+ ../win/gtk2/g2equip.c
+WINGTK2OBJ = g2bind.o g2main.o g2mesg.o g2player.o g2map.o g2marsh.o g2status.o\
+ g2menu.o g2text.o g2equip.o tile.o
@@ -217,2 +218,2 @@
-WINSRC = $(WINGNOMESRC)
-WINOBJ = $(WINGNOMEOBJ)
+WINSRC = $(WINTTYSRC) $(WINGTK2SRC)
+WINOBJ = $(WINTTYOBJ) $(WINGTK2OBJ)
@@ -250 +251,6 @@
-WINGNOMELIB = -lgnomeui -lgnome -lart_lgpl -lgtk -lgdk -lpopt
+WINGNOMELIB = -L/opt/gnome/lib -lgnomeui -lgnome -lart_lgpl -lgtk -lgdk -lpopt
+
+#
+# libraries for Gtk2
+WINGTK2LIB =`pkg-config gtk+-2.0 --libs`
+
@@ -258 +264 @@
-WINLIB = $(WINGNOMELIB)
+WINLIB = $(WINTTYLIB) $(WINGTK2LIB)
@@ -341 +347 @@
-WINCSRC = $(WINTTYSRC) $(WINX11SRC) $(WINGNOMESRC) $(WINGEMSRC)
+WINCSRC = $(WINTTYSRC) $(WINX11SRC) $(WINGNOMESRC) $(WINGTK2SRC)$(WINGEMSRC)
@@ -729,1 +735,24 @@
+
+# Gtk2 stuff
+g2bind.o: ../win/gtk2/g2bind.c ../win/gtk2/g2bind.h $(HACK_H)
+ $(CC) $(MAEMO_FLAGS) $(CFLAGS) $(GTK2INC) -c ../win/gtk2/g2bind.c
+g2main.o: ../win/gtk2/g2main.c ../win/gtk2/g2main.h ../win/gtk2/g2i18n.h $(HACK_H)
+ $(CC) $(MAEMO_FLAGS) $(CFLAGS) $(GTK2INC) -c ../win/gtk2/g2main.c
+g2mesg.o: ../win/gtk2/g2mesg.c ../win/gtk2/g2mesg.h $(HACK_H)
+ $(CC) $(MAEMO_FLAGS) $(CFLAGS) $(GTK2INC) -c ../win/gtk2/g2mesg.c
+g2player.o: ../win/gtk2/g2player.c ../win/gtk2/g2player.h ../win/gtk2/g2i18n.h $(HACK_H)
+ $(CC) $(MAEMO_FLAGS) $(CFLAGS) $(GTK2INC) -c ../win/gtk2/g2player.c
+g2map.o: ../win/gtk2/g2map.c ../win/gtk2/g2map.h $(HACK_H)
+ $(CC) $(MAEMO_FLAGS) $(CFLAGS) $(GTK2INC) -c ../win/gtk2/g2map.c
+g2marsh.o: ../win/gtk2/g2marsh.c ../win/gtk2/g2marsh.h $(HACK_H)
+ $(CC) $(MAEMO_FLAGS) $(CFLAGS) $(GTK2INC) -c ../win/gtk2/g2marsh.c
+g2status.o: ../win/gtk2/g2status.c ../win/gtk2/g2status.h ../win/gtk2/g2i18n.h $(HACK_H)
+ $(CC) $(MAEMO_FLAGS) $(CFLAGS) $(GTK2INC) -c ../win/gtk2/g2status.c
+g2menu.o: ../win/gtk2/g2menu.c ../win/gtk2/g2menu.h ../win/gtk2/g2i18n.h $(HACK_H)
+ $(CC) $(MAEMO_FLAGS) $(CFLAGS) $(GTK2INC) -c ../win/gtk2/g2menu.c
+g2text.o: ../win/gtk2/g2text.c ../win/gtk2/g2text.h $(HACK_H)
+ $(CC) $(MAEMO_FLAGS) $(CFLAGS) $(GTK2INC) -c ../win/gtk2/g2text.c
+g2equip.o: ../win/gtk2/g2equip.c ../win/gtk2/g2equip.h ../win/gtk2/g2i18n.h $(HACK_H)
+ $(CC) $(MAEMO_FLAGS) $(CFLAGS) $(GTK2INC) -c ../win/gtk2/g2equip.c
+
--- Makefile.orig 2005-10-31 20:44:09.000000000 +0100
+++ Makefile 2005-04-27 15:01:54.000000000 +0200
@@ -43 +43 @@
-VARDATND =
+# VARDATND =
@@ -51,0 +52,2 @@
+# for Gtk2
+ VARDATND = x11tiles equip.png rip.xpm mapbg.xpm gtk2hack.png gold24.png
@@ -149,0 +152,8 @@
+# for gtk2
+equip.png:
+ (cd dat ; $(MAKE) equip.png )
+gtk2hack.png:
+ (cd dat ; $(MAKE) gtk2hack.png )
+gold24.png:
+ (cd dat ; $(MAKE) gold24.png )
+
@@ -244,0 +255,3 @@
+# copy translations for gtk2hack
+ (cd dat ; $(MAKE) locale )
+ cp -r dat/locale $(GAMEDIR)
|