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