]> git.donarmstrong.com Git - xournal.git/blob - Makefile.am
correction to the Spanish translation
[xournal.git] / Makefile.am
1 ## Process this file with automake to produce Makefile.in
2
3 SUBDIRS = src po
4
5 EXTRA_DIST = \
6         autogen.sh \
7         xournal.glade xournal.gladep \
8         xournal.xml x-xoj.desktop xournal.desktop
9
10 install-data-local:
11         @$(NORMAL_INSTALL)
12         if test -d $(srcdir)/pixmaps; then \
13           $(mkinstalldirs) $(DESTDIR)$(pkgdatadir)/pixmaps; \
14           for pixmap in $(srcdir)/pixmaps/*; do \
15             if test -f $$pixmap; then \
16               $(INSTALL_DATA) $$pixmap $(DESTDIR)$(pkgdatadir)/pixmaps; \
17             fi \
18           done \
19         fi; \
20         if test -d $(srcdir)/html-doc; then \
21           $(mkinstalldirs) $(DESTDIR)$(pkgdatadir)/html-doc; \
22           for docfile in $(srcdir)/html-doc/*; do \
23             if test -f $$docfile; then \
24               $(INSTALL_DATA) $$docfile $(DESTDIR)$(pkgdatadir)/html-doc; \
25             fi \
26           done; \
27           if test ! -e $(DESTDIR)$(pkgdatadir)/html-doc/pixmaps; then \
28             ln -s ../pixmaps $(DESTDIR)$(pkgdatadir)/html-doc/pixmaps; \
29           fi \
30         fi; \
31         echo "*** Desktop files, icons, MIME types not installed. Run 'make desktop-install'"; \
32         echo "*** (or 'make home-desktop-install' for installation in a home directory)."
33
34 desktop-install:
35         if test "$(datadir)" = "/usr/share"; then \
36           desktopdir=/usr/share; \
37         else \
38           desktopdir=/usr/local/share; \
39         fi; \
40         $(mkinstalldirs) $(DESTDIR)$$desktopdir/icons/hicolor/scalable/apps; \
41         $(mkinstalldirs) $(DESTDIR)$$desktopdir/icons/hicolor/scalable/mimetypes; \
42         $(mkinstalldirs) $(DESTDIR)$$desktopdir/mime/packages; \
43         $(mkinstalldirs) $(DESTDIR)$$desktopdir/applications; \
44         $(mkinstalldirs) $(DESTDIR)/usr/share/mimelnk/application; \
45         $(INSTALL_DATA) $(srcdir)/pixmaps/xournal.svg $(DESTDIR)$$desktopdir/icons/hicolor/scalable/apps; \
46         $(INSTALL_DATA) $(srcdir)/pixmaps/xoj.svg $(DESTDIR)$$desktopdir/icons/hicolor/scalable/mimetypes; \
47         if test ! -e $(DESTDIR)$$desktopdir/icons/hicolor/scalable/mimetypes/gnome-mime-application-x-xoj.svg; then \
48           ln -s xoj.svg $(DESTDIR)$$desktopdir/icons/hicolor/scalable/mimetypes/gnome-mime-application-x-xoj.svg; \
49         fi; \
50         $(INSTALL_DATA) $(srcdir)/xournal.xml $(DESTDIR)$$desktopdir/mime/packages; \
51         $(INSTALL_DATA) $(srcdir)/xournal.desktop $(DESTDIR)$$desktopdir/applications; \
52         $(INSTALL_DATA) $(srcdir)/x-xoj.desktop $(DESTDIR)/usr/share/mimelnk/application; \
53         if test -z "$(DESTDIR)"; then \
54           echo "Updating desktop, mime, and icon databases."; \
55           update-desktop-database; \
56           update-mime-database $$desktopdir/mime; \
57           gtk-update-icon-cache -f -t $$desktopdir/icons/hicolor; \
58         else \
59           echo "*** Not updating desktop, mime, and icon databases. After install, run:"; \
60           echo "***   update-desktop-database"; \
61           echo "***   update-mime-database $$desktopdir/mime"; \
62           echo "***   gtk-update-icon-cache -f -t $$desktopdir/icons/hicolor"; \
63         fi
64
65 home-desktop-install:
66         desktopdir=$(HOME)/.local/share; \
67         $(mkinstalldirs) $(DESTDIR)$$desktopdir/icons/hicolor/scalable/apps; \
68         $(mkinstalldirs) $(DESTDIR)$$desktopdir/icons/hicolor/scalable/mimetypes; \
69         $(mkinstalldirs) $(DESTDIR)$$desktopdir/mime/packages; \
70         $(mkinstalldirs) $(DESTDIR)$$desktopdir/applications; \
71         $(mkinstalldirs) $(DESTDIR)$(HOME)/.kde/share/mimelnk/application; \
72         $(INSTALL_DATA) $(srcdir)/pixmaps/xournal.svg $(DESTDIR)$$desktopdir/icons/hicolor/scalable/apps; \
73         $(INSTALL_DATA) $(srcdir)/pixmaps/xoj.svg $(DESTDIR)$$desktopdir/icons/hicolor/scalable/mimetypes; \
74         if test ! -e $(DESTDIR)$$desktopdir/icons/hicolor/scalable/mimetypes/gnome-mime-application-x-xoj.svg; then \
75           ln -s xoj.svg $(DESTDIR)$$desktopdir/icons/hicolor/scalable/mimetypes/gnome-mime-application-x-xoj.svg; \
76         fi; \
77         $(INSTALL_DATA) $(srcdir)/xournal.xml $(DESTDIR)$$desktopdir/mime/packages; \
78         $(INSTALL_DATA) $(srcdir)/xournal.desktop $(DESTDIR)$$desktopdir/applications; \
79         $(INSTALL_DATA) $(srcdir)/x-xoj.desktop $(DESTDIR)$(HOME)/.kde/share/mimelnk/application; \
80         if test -z "$(DESTDIR)"; then \
81           echo "Updating desktop, mime, and icon databases."; \
82           XDG_DATA_DIRS=$(HOME)/.local/share update-desktop-database; \
83           update-mime-database $$desktopdir/mime; \
84           gtk-update-icon-cache -f -t $$desktopdir/icons/hicolor; \
85         else \
86           echo "*** Not updating desktop, mime, and icon databases. After install, run:"; \
87           echo "***   update-desktop-database"; \
88           echo "***   update-mime-database $$desktopdir/mime"; \
89           echo "***   gtk-update-icon-cache -f -t $$desktopdir/icons/hicolor"; \
90         fi
91
92 dist-hook:
93         if test -d pixmaps; then \
94           mkdir $(distdir)/pixmaps; \
95           for pixmap in pixmaps/*; do \
96             if test -f $$pixmap; then \
97               cp -p $$pixmap $(distdir)/pixmaps; \
98             fi \
99           done \
100         fi; \
101         if test -d html-doc; then \
102           mkdir $(distdir)/html-doc; \
103           for docfile in html-doc/*; do \
104             if test -f $$docfile; then \
105               cp -p $$docfile $(distdir)/html-doc; \
106             fi \
107           done; \
108           if test ! -e $(distdir)/html-doc/pixmaps; then \
109             ln -s ../pixmaps $(distdir)/html-doc/pixmaps; \
110           fi \
111         fi
112