Fix patch.
[gpg4win.git] / patches / claws-mail-2.10.0 / 02-w32-icon.patch
1 #! /bin/sh
2 patch -p1 -f $* < $0
3 exit $?
4
5 For the logo, see actually 01-w32-logo.patch.
6
7 2007-07-02  Marcus Brinkmann <mb@g10code.com>
8
9         * w32-resource.rc: New file.
10         * w32-logo.ico: New file.
11         * src/Makefile.am: Define rules to compile resource files.
12         (claws_mail_LDFLAGS): Add $(claws_mail_res_ldflag).
13         (claws_mail_DEPENDENCIES): Add $(claws_mail_deps).
14         (EXTRA_DIST): Add w32-logo.ico and w32-resource.rc.
15
16
17 diff -rupN claws-mail-2.10.0-orig/src/Makefile.am claws-mail-2.10.0/src/Makefile.am
18 --- claws-mail-2.10.0-orig/src/Makefile.am      2007-07-02 10:32:18.000000000 +0200
19 +++ claws-mail-2.10.0/src/Makefile.am   2007-07-03 18:28:46.000000000 +0200
20 @@ -14,6 +14,21 @@ install-exec-hook:
21         @rm -f $(DESTDIR)$(bindir)/sylpheed-claws
22         @ln -s claws-mail $(DESTDIR)$(bindir)/sylpheed-claws
23  
24 +if PLATFORM_WIN32
25 +LTRCCOMPILE = $(LIBTOOL) --mode=compile $(RC) \
26 +     `echo $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) | \
27 +     sed -e 's/-I/--include-dir /g;s/-D/--define /g'`
28 +
29 +%.o : %.rc
30 +       $(LTRCCOMPILE) -i $< -o $@
31 +
32 +claws_mail_res_ldflag = -Wl,w32-resource.o
33 +claws_mail_deps = w32-resource.o
34 +else
35 +claws_mail_res_ldflag =
36 +claws_mail_deps =
37 +endif
38 +
39  claws_mail_SOURCES = \
40         account.c \
41         action.c \
42 @@ -301,6 +316,7 @@ BUILT_SOURCES = \
43         quote_fmt_parse.h
44  
45  EXTRA_DIST = \
46 +       w32-logo.ico w32-resource.rc \
47         pixmaps/addr_one.xpm \
48         pixmaps/addr_two.xpm \
49         pixmaps/address_book.xpm \
50 @@ -456,7 +472,11 @@ arch_ldflags :=
51  endif
52  
53  claws_mail_LDFLAGS = \
54 -       $(arch_ldflags) -export-dynamic
55 +       $(arch_ldflags) -export-dynamic $(claws_mail_res_ldflag)
56 +
57 +claws_mail_DEPENDENCIES = $(claws_mail_deps) \
58 +       $(etpan_library) \
59 +       gtk/libclawsgtk.la
60  
61  claws_mail_LDADD = \
62         $(etpan_library) \
63 diff -rupN claws-mail-2.10.0-orig/src/w32-resource.rc claws-mail-2.10.0/src/w32-resource.rc
64 --- claws-mail-2.10.0-orig/src/w32-resource.rc  1970-01-01 01:00:00.000000000 +0100
65 +++ claws-mail-2.10.0/src/w32-resource.rc       2007-07-03 18:28:46.000000000 +0200
66 @@ -0,0 +1 @@
67 +1 ICON "w32-logo.ico"