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