2007-06-12 [wwp] 2.9.2cvs56
[claws.git] / src / Makefile.am
1
2 if CLAWS_LIBETPAN
3 etpan_dir = etpan
4 etpan_library = etpan/libclawsetpan.la
5 else
6 etpan_dir =
7 etpan_library = 
8 endif
9
10 SUBDIRS = common gtk $(etpan_dir) . plugins
11
12 bin_PROGRAMS = claws-mail
13 install-exec-hook:
14         @rm -f $(DESTDIR)$(bindir)/sylpheed-claws
15         @ln -s claws-mail $(DESTDIR)$(bindir)/sylpheed-claws
16
17 claws_mail_SOURCES = \
18         account.c \
19         action.c \
20         addrbook.c \
21         addrcache.c \
22         addrclip.c \
23         addr_compl.c \
24         addressadd.c \
25         addressbook.c \
26         addressbook_foldersel.c \
27         addrgather.c \
28         addrharvest.c \
29         addrindex.c \
30         addritem.c \
31         addrquery.c \
32         addrselect.c \
33         alertpanel.c \
34         browseldap.c \
35         codeconv.c \
36         compose.c \
37         crash.c \
38         customheader.c \
39         displayheader.c \
40         editaddress.c \
41         editbook.c \
42         editgroup.c \
43         editjpilot.c \
44         editldap_basedn.c \
45         editldap.c \
46         editvcard.c \
47         enriched.c \
48         exphtmldlg.c \
49         expldifdlg.c \
50         export.c \
51         exporthtml.c \
52         exportldif.c \
53         filtering.c \
54         folder.c \
55         folder_item_prefs.c \
56         foldersel.c \
57         folderutils.c \
58         folderview.c \
59         gedit-print.c \
60         grouplistdialog.c \
61         headerview.c \
62         html.c \
63         image_viewer.c \
64         imap.c \
65         imap_gtk.c \
66         import.c \
67         importldif.c \
68         importmutt.c \
69         importpine.c \
70         inc.c \
71         jpilot.c \
72         ldapctrl.c \
73         ldaplocate.c \
74         ldapquery.c \
75         ldapserver.c \
76         ldapupdate.c \
77         ldaputil.c \
78         ldif.c \
79         localfolder.c \
80         main.c \
81         mainwindow.c \
82         manual.c \
83         matcher.c \
84         matcher_parser_lex.l \
85         matcher_parser_parse.y \
86         mbox.c \
87         message_search.c \
88         messageview.c \
89         mh.c \
90         mh_gtk.c \
91         mimeview.c \
92         msgcache.c \
93         mutt.c \
94         news.c \
95         news_gtk.c \
96         noticeview.c \
97         partial_download.c \
98         pine.c \
99         pop.c \
100         prefs_account.c \
101         prefs_actions.c \
102         prefs_common.c \
103         prefs_compose_writing.c \
104         prefs_customheader.c \
105         prefs_display_header.c \
106         prefs_ext_prog.c \
107         prefs_filtering_action.c \
108         prefs_filtering.c \
109         prefs_folder_item.c \
110         prefs_fonts.c \
111         prefs_gtk.c \
112         prefs_image_viewer.c \
113         prefs_logging.c \
114         prefs_matcher.c \
115         prefs_message.c \
116         prefs_msg_colors.c \
117         prefs_other.c \
118         prefs_quote.c \
119         prefs_receive.c \
120         prefs_send.c \
121         prefs_spelling.c \
122         prefs_summaries.c \
123         prefs_summary_column.c \
124         prefs_folder_column.c \
125         prefs_template.c \
126         prefs_themes.c \
127         prefs_toolbar.c \
128         prefs_wrapping.c \
129         privacy.c \
130         procheader.c \
131         procmime.c \
132         procmsg.c \
133         quote_fmt.c \
134         quote_fmt_lex.l \
135         quote_fmt_parse.y \
136         recv.c \
137         remotefolder.c \
138         send_message.c \
139         setup.c \
140         simple-gettext.c \
141         sourcewindow.c \
142         ssl_manager.c \
143         statusbar.c \
144         stock_pixmap.c \
145         summary_search.c \
146         summaryview.c \
147         textview.c \
148         toolbar.c \
149         undo.c \
150         unmime.c \
151         uri_opener.c \
152         vcard.c \
153         wizard.c
154
155 claws_mailincludedir = $(pkgincludedir)
156 claws_mailinclude_HEADERS = \
157         account.h \
158         action.h \
159         adbookbase.h \
160         addrbook.h \
161         addrcache.h \
162         addrclip.h \
163         addr_compl.h \
164         addrdefs.h \
165         addressadd.h \
166         addressbook.h \
167         addressbook_foldersel.h \
168         addressitem.h \
169         addrgather.h \
170         addrharvest.h \
171         addrindex.h \
172         addritem.h \
173         addrquery.h \
174         addrselect.h \
175         alertpanel.h \
176         browseldap.h \
177         codeconv.h \
178         compose.h \
179         crash.h \
180         customheader.h \
181         displayheader.h \
182         editaddress.h \
183         editbook.h \
184         editgroup.h \
185         editjpilot.h \
186         editldap_basedn.h \
187         editldap.h \
188         editvcard.h \
189         enriched.h \
190         exphtmldlg.h \
191         expldifdlg.h \
192         export.h \
193         exporthtml.h \
194         exportldif.h \
195         filtering.h \
196         folder.h \
197         folder_item_prefs.h \
198         foldersel.h \
199         folderutils.h \
200         folderview.h \
201         gedit-print.h \
202         grouplistdialog.h \
203         headerview.h \
204         html.h \
205         image_viewer.h \
206         imap.h \
207         imap_gtk.h \
208         import.h \
209         importldif.h \
210         importmutt.h \
211         importpine.h \
212         inc.h \
213         jpilot.h \
214         ldapctrl.h \
215         ldaplocate.h \
216         ldapquery.h \
217         ldapserver.h \
218         ldapupdate.h \
219         ldaputil.h \
220         ldif.h \
221         localfolder.h \
222         main.h \
223         mainwindow.h \
224         manual.h \
225         matcher.h \
226         matcher_parser.h \
227         matcher_parser_lex.h \
228         matcher_parser_parse.h \
229         mbox.h \
230         message_search.h \
231         messageview.h \
232         mh.h \
233         mh_gtk.h \
234         mimeview.h \
235         msgcache.h \
236         mutt.h \
237         news.h \
238         news_gtk.h \
239         noticeview.h \
240         partial_download.h \
241         pine.h \
242         pop.h \
243         prefs_account.h \
244         prefs_actions.h \
245         prefs_common.h \
246         prefs_compose_writing.h \
247         prefs_customheader.h \
248         prefs_display_header.h \
249         prefs_ext_prog.h \
250         prefs_filtering_action.h \
251         prefs_filtering.h \
252         prefs_folder_item.h \
253         prefs_fonts.h \
254         prefs_gtk.h \
255         prefs_image_viewer.h \
256         prefs_logging.h \
257         prefs_matcher.h \
258         prefs_message.h \
259         prefs_msg_colors.h \
260         prefs_other.h \
261         prefs_quote.h \
262         prefs_receive.h \
263         prefs_send.h \
264         prefs_spelling.h \
265         prefs_summaries.h \
266         prefs_summary_column.h \
267         prefs_folder_column.h \
268         prefs_template.h \
269         prefs_themes.h \
270         prefs_toolbar.h \
271         prefs_wrapping.h \
272         privacy.h \
273         procheader.h \
274         procmime.h \
275         procmsg.h \
276         quote_fmt.h \
277         quote_fmt_lex.h \
278         quote_fmt_parse.h \
279         recv.h \
280         remotefolder.h \
281         send_message.h \
282         setup.h \
283         sourcewindow.h \
284         ssl_manager.h \
285         statusbar.h \
286         stock_pixmap.h \
287         summary_search.h \
288         summaryview.h \
289         textview.h \
290         toolbar.h \
291         undo.h \
292         unmime.h \
293         uri_opener.h \
294         vcard.h \
295         wizard.h
296
297 BUILT_SOURCES = \
298         matcher_parser_parse.h \
299         quote_fmt_parse.h
300
301 EXTRA_DIST = \
302         pixmaps/addr_one.xpm \
303         pixmaps/addr_two.xpm \
304         pixmaps/address_book.xpm \
305         pixmaps/address_search.xpm \
306         pixmaps/address.xpm \
307         pixmaps/book.xpm \
308         pixmaps/category.xpm \
309         pixmaps/checkbox_off.xpm \
310         pixmaps/checkbox_on.xpm \
311         pixmaps/check_spelling.xpm \
312         pixmaps/clipkey.xpm \
313         pixmaps/clip.xpm \
314         pixmaps/clip_gpg_signed.xpm \
315         pixmaps/close.xpm \
316         pixmaps/complete.xpm \
317         pixmaps/continue.xpm \
318         pixmaps/deleted.xpm \
319         pixmaps/dir_close.xpm \
320         pixmaps/dir_close_hrm.xpm \
321         pixmaps/dir_noselect.xpm \
322         pixmaps/dir_open_hrm.xpm \
323         pixmaps/dir_open.xpm \
324         pixmaps/down_arrow.xpm \
325         pixmaps/drafts_close.xpm \
326         pixmaps/drafts_open.xpm \
327         pixmaps/drafts_close.xpm \
328         pixmaps/drafts_open.xpm \
329         pixmaps/edit_extern.xpm \
330         pixmaps/error.xpm \
331         pixmaps/exec.xpm \
332         pixmaps/forwarded.xpm \
333         pixmaps/gpg_signed.xpm \
334         pixmaps/group.xpm \
335         pixmaps/ham_btn.xpm \
336         pixmaps/ignorethread.xpm \
337         pixmaps/inbox_open_hrm.xpm \
338         pixmaps/inbox_open.xpm \
339         pixmaps/inbox_close_hrm.xpm \
340         pixmaps/inbox_close.xpm \
341         pixmaps/interface.xpm \
342         pixmaps/jpilot.xpm \
343         pixmaps/key.xpm \
344         pixmaps/ldap.xpm \
345         pixmaps/linewrap.xpm \
346         pixmaps/linewrapcurrent.xpm \
347         pixmaps/locked.xpm \
348         pixmaps/mail_attach.xpm \
349         pixmaps/mail_compose.xpm \
350         pixmaps/mail_forward.xpm \
351         pixmaps/mail_receive_all.xpm \
352         pixmaps/mail_receive.xpm \
353         pixmaps/mail_reply_to_all.xpm \
354         pixmaps/mail_reply_to_author.xpm \
355         pixmaps/mail_reply.xpm \
356         pixmaps/mail_send_queue.xpm \
357         pixmaps/mail_send.xpm \
358         pixmaps/mail_sign.xpm \
359         pixmaps/mail.xpm \
360         pixmaps/mark.xpm \
361         pixmaps/mime_application.xpm \
362         pixmaps/mime_audio.xpm \
363         pixmaps/mime_image.xpm \
364         pixmaps/mime_message.xpm \
365         pixmaps/mime_pdf.xpm \
366         pixmaps/mime_ps.xpm \
367         pixmaps/mime_calendar.xpm \
368         pixmaps/mime_pgpsig.xpm \
369         pixmaps/mime_text_enriched.xpm \
370         pixmaps/mime_text_html.xpm \
371         pixmaps/mime_text_plain.xpm \
372         pixmaps/mime_unknown.xpm \
373         pixmaps/news_compose.xpm \
374         pixmaps/new.xpm \
375         pixmaps/notice_error.xpm \
376         pixmaps/notice_note.xpm \
377         pixmaps/notice_warn.xpm \
378         pixmaps/offline.xpm \
379         pixmaps/online.xpm \
380         pixmaps/open_mail.xpm \
381         pixmaps/outbox_close.xpm \
382         pixmaps/outbox_close_hrm.xpm \
383         pixmaps/outbox_open.xpm \
384         pixmaps/outbox_open_hrm.xpm \
385         pixmaps/outbox_close_mark.xpm \
386         pixmaps/outbox_close_hrm_mark.xpm \
387         pixmaps/outbox_open_mark.xpm \
388         pixmaps/outbox_open_hrm_mark.xpm \
389         pixmaps/paste.xpm \
390         pixmaps/preferences.xpm \
391         pixmaps/printer.xpm \
392         pixmaps/privacy_expired.xpm \
393         pixmaps/privacy_failed.xpm \
394         pixmaps/privacy_passed.xpm \
395         pixmaps/privacy_signed.xpm \
396         pixmaps/privacy_unknown.xpm \
397         pixmaps/privacy_warn.xpm \
398         pixmaps/privacy_emblem_encrypted.xpm \
399         pixmaps/privacy_emblem_failed.xpm \
400         pixmaps/privacy_emblem_passed.xpm \
401         pixmaps/privacy_emblem_signed.xpm \
402         pixmaps/privacy_emblem_warn.xpm \
403         pixmaps/properties.xpm \
404         pixmaps/queue_close.xpm \
405         pixmaps/queue_close_hrm.xpm \
406         pixmaps/queue_close_hrm_mark.xpm \
407         pixmaps/queue_close_mark.xpm \
408         pixmaps/queue_open.xpm \
409         pixmaps/queue_open_hrm.xpm \
410         pixmaps/queue_open_hrm_mark.xpm \
411         pixmaps/queue_open_mark.xpm \
412         pixmaps/quicksearch.xpm \
413         pixmaps/replied.xpm \
414         pixmaps/search.xpm \
415         pixmaps/selection.xpm \
416         pixmaps/spam.xpm \
417         pixmaps/spam_btn.xpm \
418         pixmaps/claws-mail_icon.xpm \
419         pixmaps/claws-mail_logo.xpm \
420         pixmaps/claws-mail.xpm \
421         pixmaps/trash_hrm.xpm \
422         pixmaps/trash.xpm \
423         pixmaps/trash_btn.xpm \
424         pixmaps/unread.xpm \
425         pixmaps/read.xpm \
426         pixmaps/up_arrow.xpm \
427         pixmaps/vcard.xpm \
428         pixmaps/dir_close_mark.xpm \
429         pixmaps/dir_close_hrm_mark.xpm \
430         pixmaps/dir_open_hrm_mark.xpm \
431         pixmaps/dir_open_mark.xpm \
432         pixmaps/drafts_close_mark.xpm \
433         pixmaps/drafts_open_mark.xpm \
434         pixmaps/inbox_open_hrm_mark.xpm \
435         pixmaps/inbox_open_mark.xpm \
436         pixmaps/inbox_close_hrm_mark.xpm \
437         pixmaps/inbox_close_mark.xpm \
438         pixmaps/trash_hrm_mark.xpm \
439         pixmaps/trash_mark.xpm \
440         pixmaps/moved.xpm \
441         pixmaps/copied.xpm \
442         pixmaps/empty.xpm
443
444
445 INCLUDES = \
446         -I$(srcdir)/common \
447         -I$(srcdir)/gtk \
448         -I$(srcdir)/etpan
449
450 if PLATFORM_WIN32
451 arch_ldflags := -export-all-symbols
452 else
453 arch_ldflags :=
454 endif
455
456 claws_mail_LDFLAGS = \
457         $(arch_ldflags) -export-dynamic
458
459 claws_mail_LDADD = \
460         $(etpan_library) \
461         gtk/libclawsgtk.la \
462         $(ASPELL_LIBS) \
463         $(INTLLIBS) \
464         $(GTK_LIBS) \
465         $(GPGME_LIBS) \
466         $(LDAP_LIBS) \
467         $(OPENSSL_LIBS) \
468         $(COMPFACE_LIBS) \
469         $(JPILOT_LIBS) \
470         $(PTHREAD_LIBS) \
471         $(GNOMEPRINT_LIBS) \
472         $(SM_LIBS) \
473         $(LIBICONV) \
474         $(STARTUP_NOTIFICATION_LIBS) \
475         $(LIBETPAN_LIBS) \
476         $(MAEMO_LIBS)
477
478 AM_CPPFLAGS = \
479         -DG_LOG_DOMAIN=\"Claws-Mail\" \
480         -DLOCALEDIR=\""$(localedir)"\" \
481         -DMANUALDIR=\""$(manualdir)"\" \
482         -DFAQDIR=\""$(faqdir)"\" \
483         -DTARGET_ALIAS=\""$(target_triplet)"\" \
484         -DSYSCONFDIR=\""$(sysconfdir)"\" \
485         -DDATAROOTDIR=\""$(datarootdir)"\" \
486         $(ASPELL_CFLAGS) \
487         $(GTK_CFLAGS) \
488         $(GPGME_CFLAGS) \
489         $(OPENSSL_CFLAGS) \
490         $(GNOMEPRINT_CFLAGS) \
491         $(LIBETPAN_CPPFLAGS) \
492         $(STARTUP_NOTIFICATION_CFLAGS) \
493         $(MAEMO_CFLAGS) \
494         -Wno-unused-function
495          
496 #no-unused-function is there because of bison stuff
497 #no-deprecated-declarations because of gpgme_data_rewind, which we have
498 #to call inside gpgme due to our lack of LARGEFILE support
499
500 AM_YFLAGS = -d
501
502 if CYGWIN
503 claws-mail$(EXEEXT): $(claws_mail_OBJECTS) $(claws_mail_DEPENDENCIES) 
504         @rm -f claws-mail$(EXEEXT)
505         @rm -f claws-mail.def claws-mail.base claws-mail.exp libclaws-mail.a .libs/libclaws-mail.a
506         $(LINK) -shared $(claws_mailLDFLAGS) -Wl,--out-implib=libclaws-mail.a -Wl,--export-all-symbols,--exclude-symbols,main $(claws_mail_OBJECTS) -Wl,--no-whole-archive $(claws_mail_LDADD) $(LIBS)
507         dlltool --output-def claws-mail.def --dllname claws-mail$(EXEEXT) --export-all-symbols --exclude-symbols main $(claws_mail_OBJECTS) gtk/.libs/libclawsgtk.a
508         $(LINK) $(claws_mail_LDFLAGS) -Wl,--base-file,claws-mail.base $(claws_mail_OBJECTS) $(claws_mail_LDADD) $(LIBS)
509         sleep 5
510         dlltool --base-file claws-mail.base --input-def claws-mail.def --output-exp claws-mail.exp
511         $(LINK) $(claws_mail_LDFLAGS) -Wl,claws-mail.exp $(claws_mail_OBJECTS) $(claws_mail_LDADD) $(LIBS)
512         @cp libclaws-mail.a .libs/libclaws-mail.a
513 else
514 #claws-mail$(EXEEXT): $(claws_mail_OBJECTS) $(claws_mail_DEPENDENCIES) 
515 #       @rm -f claws-mail$(EXEEXT)
516 #       $(LINK) $(claws_mail_LDFLAGS) $(claws_mail_OBJECTS) $(claws_mail_LDADD) $(LIBS)
517 endif