Tue, 19 Jul 2005 10:16:32 +0000
[gaim-migrate @ 13187]
Fixed warning messages
| 6816 | 1 | # |
| 2 | # Makefile.mingw | |
| 3 | # | |
| 4 | # Description: Makefile for Gaim perl module. | |
| 5 | # | |
| 6 | ||
| 7 | TARGET = Gaim | |
|
7383
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
8 | AUTOSPLIT = lib/auto/Gaim/autosplit.ix |
| 6816 | 9 | |
|
7383
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
10 | ## |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
11 | ## TOOLS |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
12 | ## |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
13 | |
|
10804
e51729c86312
[gaim-migrate @ 12452]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
7383
diff
changeset
|
14 | CC := gcc |
|
e51729c86312
[gaim-migrate @ 12452]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
7383
diff
changeset
|
15 | PERL := /cygdrive/c/perl/bin/perl |
|
7383
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
16 | |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
17 | ## |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
18 | ## PATHS |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
19 | ## |
| 6816 | 20 | |
| 21 | EXTUTILS := C:/perl/lib/ExtUtils | |
| 22 | GAIM_TOP := ../../.. | |
| 23 | GTK_TOP := ../../../../win32-dev/gtk_2_0 | |
| 24 | PERL_TOP := ../../../../win32-dev/perl58 | |
| 25 | PERL_PLUGIN_TOP := .. | |
| 26 | GAIM_INSTALL_DIR := $(GAIM_TOP)/win32-install-dir | |
| 27 | PERLMOD_INSTALL_DIR := $(GAIM_INSTALL_DIR)/perlmod | |
| 28 | ||
|
7383
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
29 | |
| 6816 | 30 | INCLUDE_PATHS = -I. \ |
| 31 | -I$(GAIM_TOP) \ | |
| 32 | -I$(GAIM_TOP)/src \ | |
| 33 | -I$(GTK_TOP)/include/glib-2.0 \ | |
| 34 | -I$(GTK_TOP)/lib/glib-2.0/include \ | |
| 35 | -I$(PERL_TOP)/CORE | |
| 36 | ||
| 37 | LIB_PATHS = -L$(PERL_TOP) \ | |
| 38 | -L$(PERL_PLUGIN_TOP) \ | |
| 39 | -L$(GAIM_TOP)/src \ | |
| 40 | -L$(GTK_TOP)/lib | |
| 41 | ||
| 42 | ||
|
7383
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
43 | ## |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
44 | ## SOURCES, OBJECTS |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
45 | ## |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
46 | |
| 11130 | 47 | XS_FILES = Account.xs |
| 48 | AccountOpts.xs | |
| 49 | BuddyIcon.xs | |
| 50 | BuddyList.xs | |
| 51 | Cipher.xs | |
| 52 | Cmds.xs | |
| 53 | Connection.xs | |
| 54 | Conversation.xs | |
| 55 | FT.xs | |
| 56 | Gaim.xs | |
| 57 | ImgStore.xs | |
| 58 | Log.xs | |
| 59 | Network.xs | |
| 60 | Notify.xs | |
| 61 | Plugin.xs | |
| 62 | PluginPref.xs | |
| 63 | Pounce.xs | |
| 64 | Prefs.xs | |
| 65 | Privacy.xs | |
| 66 | Proxy.xs | |
| 67 | Prpl.xs | |
| 68 | Request.xs | |
| 69 | Roomlist.xs | |
| 70 | SSLConn.xs | |
| 71 | SavedStatuses.xs | |
| 72 | Server.xs | |
| 73 | Sound.xs | |
| 74 | Status.xs | |
| 75 | Stringref.xs | |
| 76 | Util.xs | |
| 77 | XMLNode.xs | |
| 6816 | 78 | |
| 79 | FALLBACKS = const-c.inc const-xs.inc | |
| 80 | ||
| 81 | C_FILES = $(XS_FILES:%.xs=%.c) | |
| 82 | ||
| 83 | OBJECTS = $(C_FILES:%.c=%.o) | |
| 84 | ||
|
7383
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
85 | ## |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
86 | ## LIBRARIES |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
87 | ## |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
88 | |
| 6816 | 89 | LIBS = -lperl58 \ |
| 90 | -lperl \ | |
| 91 | -lgaim \ | |
| 92 | -lglib-2.0 | |
| 93 | ||
|
7383
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
94 | ## |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
95 | ## RULES |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
96 | ## |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
97 | |
| 6816 | 98 | # How to make a C file |
| 99 | %.o: %.c | |
| 100 | $(CC) $(CFLAGS) $(INCLUDE_PATHS) $(DEFINES) -c $< -o $@ | |
| 101 | ||
| 102 | # How to make a XS file | |
| 103 | %.c: %.xs | |
| 104 | $(PERL) $(EXTUTILS)/xsubpp -typemap $(EXTUTILS)/typemap -typemap typemap $< > $@ | |
| 105 | ||
| 106 | %.inc: | |
| 107 | cp fallback/$@ ./ | |
| 108 | ||
|
7383
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
109 | ## |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
110 | ## TARGETS |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
111 | ## |
| 6816 | 112 | |
|
7383
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
113 | .PHONY: all clean |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
114 | |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
115 | all: $(TARGET).dll $(AUTOSPLIT) |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
116 | |
| 6816 | 117 | install: |
|
7383
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
118 | rm -rf $(PERLMOD_INSTALL_DIR) |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
119 | cp -R lib $(PERLMOD_INSTALL_DIR) |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
120 | cp $(TARGET).dll $(PERLMOD_INSTALL_DIR) |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
121 | |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
122 | $(AUTOSPLIT): Gaim.pm |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
123 | mkdir -p ./lib/auto |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
124 | cp Gaim.pm ./lib |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
125 | $(PERL) -MAutoSplit -e 'autosplit("lib/Gaim.pm")' |
| 6816 | 126 | |
| 127 | $(TARGET).dll: $(FALLBACKS) $(OBJECTS) | |
| 128 | $(CC) -shared $(OBJECTS) $(LIB_PATHS) $(LIBS) -o $(TARGET).dll | |
| 129 | ||
|
7383
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
130 | ## |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
131 | ## CLEAN |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
132 | ## |
|
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
133 | |
| 6816 | 134 | clean: |
|
7383
d6b354fc9ea2
[gaim-migrate @ 7978]
Herman Bloggs <herman@bluedigits.com>
parents:
6816
diff
changeset
|
135 | rm -rf *.o $(TARGET).dll $(FALLBACKS) lib |