| |
1 # |
| |
2 # Makefile.mingw |
| |
3 # |
| |
4 # Description: Makefile for Gaim perl module. |
| |
5 # |
| |
6 |
| |
7 GAIM_TOP := ../../../.. |
| |
8 include $(GAIM_TOP)/libgaim/win32/global.mak |
| |
9 |
| |
10 TARGET = Gaim |
| |
11 AUTOSPLIT = lib/auto/Gaim/autosplit.ix |
| |
12 EXTUTILS := C:/perl/lib/ExtUtils |
| |
13 PERL_PLUGIN_TOP := .. |
| |
14 |
| |
15 CFLAGS += -Wno-comment |
| |
16 |
| |
17 ## |
| |
18 ## INCLUDE PATHS |
| |
19 ## |
| |
20 INCLUDE_PATHS = -I. \ |
| |
21 -I$(GAIM_TOP) \ |
| |
22 -I$(GAIM_LIB_TOP) \ |
| |
23 -I$(GTK_TOP)/include \ |
| |
24 -I$(GTK_TOP)/include/glib-2.0 \ |
| |
25 -I$(GTK_TOP)/lib/glib-2.0/include \ |
| |
26 -I$(PERL_LIB_TOP)/CORE |
| |
27 |
| |
28 LIB_PATHS = -L$(PERL_LIB_TOP) \ |
| |
29 -L$(PERL_PLUGIN_TOP) \ |
| |
30 -L$(GAIM_LIB_TOP) \ |
| |
31 -L$(GTK_TOP)/lib |
| |
32 |
| |
33 ## |
| |
34 ## SOURCES, OBJECTS |
| |
35 ## |
| |
36 XS_FILES = Account.xs \ |
| |
37 AccountOpts.xs \ |
| |
38 BuddyIcon.xs \ |
| |
39 BuddyList.xs \ |
| |
40 Cipher.xs \ |
| |
41 Cmds.xs \ |
| |
42 Connection.xs \ |
| |
43 Conversation.xs \ |
| |
44 Core.xs \ |
| |
45 Debug.xs \ |
| |
46 FT.xs \ |
| |
47 Gaim.xs \ |
| |
48 ImgStore.xs \ |
| |
49 Log.xs \ |
| |
50 Network.xs \ |
| |
51 Notify.xs \ |
| |
52 Plugin.xs \ |
| |
53 PluginPref.xs \ |
| |
54 Pounce.xs \ |
| |
55 Prefs.xs \ |
| |
56 Privacy.xs \ |
| |
57 Proxy.xs \ |
| |
58 Prpl.xs \ |
| |
59 Request.xs \ |
| |
60 Roomlist.xs \ |
| |
61 SSLConn.xs \ |
| |
62 SavedStatuses.xs \ |
| |
63 Signal.xs \ |
| |
64 Server.xs \ |
| |
65 Sound.xs \ |
| |
66 Status.xs \ |
| |
67 Stringref.xs \ |
| |
68 Util.xs \ |
| |
69 XMLNode.xs \ |
| |
70 |
| |
71 FALLBACKS = const-c.inc const-xs.inc |
| |
72 C_FILES = $(XS_FILES:%.xs=%.c) |
| |
73 OBJECTS = $(C_FILES:%.c=%.o) |
| |
74 |
| |
75 ## |
| |
76 ## LIBRARIES |
| |
77 ## |
| |
78 LIBS = -lperl58 \ |
| |
79 -lperl \ |
| |
80 -lgaim \ |
| |
81 -lglib-2.0 |
| |
82 |
| |
83 include $(GAIM_COMMON_RULES) |
| |
84 |
| |
85 %.inc: |
| |
86 cp fallback/$@ ./ |
| |
87 |
| |
88 ## |
| |
89 ## TARGETS |
| |
90 ## |
| |
91 .PHONY: all install clean |
| |
92 |
| |
93 all: $(TARGET).dll $(AUTOSPLIT) |
| |
94 |
| |
95 install: all |
| |
96 rm -rf $(GAIM_INSTALL_PERLMOD_DIR) |
| |
97 cp -R lib $(GAIM_INSTALL_PERLMOD_DIR) |
| |
98 cp $(TARGET).dll $(GAIM_INSTALL_PERLMOD_DIR) |
| |
99 |
| |
100 $(C_FILES): $(GAIM_CONFIG_H) |
| |
101 |
| |
102 $(AUTOSPLIT): |
| |
103 mkdir -p ./lib/auto |
| |
104 cp Gaim.pm ./lib |
| |
105 $(PERL) -MAutoSplit -e 'autosplit("lib/Gaim.pm")' |
| |
106 |
| |
107 $(TARGET).dll: $(GAIM_LIBGAIM_DLL).a $(GAIM_LIBGAIM_PERL_DLL).a $(FALLBACKS) $(OBJECTS) |
| |
108 $(CC) -shared $(OBJECTS) $(LIB_PATHS) $(LIBS) -o $(TARGET).dll |
| |
109 |
| |
110 ## |
| |
111 ## CLEAN |
| |
112 ## |
| |
113 clean: |
| |
114 rm -rf $(TARGET).dll $(FALLBACKS) lib |
| |
115 rm -f *.o $(C_FILES) |
| |
116 |
| |
117 include $(GAIM_COMMON_TARGETS) |