Add SEE ALSO section (bug 2085)
[platform/upstream/fontconfig.git] / Makefile.am
1
2 #  $Id$
3
4 #  Copyright © 2003 Keith Packard
5
6 #  Permission to use, copy, modify, distribute, and sell this software and its
7 #  documentation for any purpose is hereby granted without fee, provided that
8 #  the above copyright notice appear in all copies and that both that
9 #  copyright notice and this permission notice appear in supporting
10 #  documentation, and that the name of Keith Packard not be used in
11 #  advertising or publicity pertaining to distribution of the software without
12 #  specific, written prior permission.  Keith Packard makes no
13 #  representations about the suitability of this software for any purpose.  It
14 #  is provided "as is" without express or implied warranty.
15
16 #  KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
17 #  INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
18 #  EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR
19 #  CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
20 #  DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
21 #  TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
22 #  PERFORMANCE OF THIS SOFTWARE.
23
24 DOCSRC=@DOCSRC@
25 SUBDIRS=fontconfig fc-case fc-lang fc-glyphname src fc-cache fc-list fc-match $(DOCSRC) test
26
27 EXTRA_DIST = \
28         fontconfig.pc.in \
29         fonts.conf.in \
30         fonts.dtd \
31         local.conf \
32         fontconfig.spec.in \
33         fontconfig.spec \
34         fontconfig-zip.in
35
36 pkgconfigdir=$(libdir)/pkgconfig
37 pkgconfig_DATA = fontconfig.pc
38
39 configdir=$(CONFDIR)
40 config_DATA=fonts.dtd
41
42 if CROSS_COMPILING
43   RUN_FC_CACHE_TEST=false
44 else
45   RUN_FC_CACHE_TEST=test -z "$(DESTDIR)"
46 endif
47
48 install-data-local:
49         $(mkinstalldirs) $(DESTDIR)$(configdir)
50         if [ -f $(DESTDIR)$(configdir)/fonts.conf ]; then \
51           echo "backing up existing $(DESTDIR)$(configdir)/fonts.conf"; \
52           mv $(DESTDIR)$(configdir)/fonts.conf $(DESTDIR)$(configdir)/fonts.conf.bak; \
53         fi
54         if [ -f $(srcdir)/fonts.conf ]; then \
55           echo " $(INSTALL_DATA) $(srcdir)/fonts.conf $(DESTDIR)$(configdir)/fonts.conf"; \
56           $(INSTALL_DATA) $(srcdir)/fonts.conf $(DESTDIR)$(configdir)/fonts.conf; \
57         else if [ -f fonts.conf ]; then \
58           echo " $(INSTALL_DATA) fonts.conf $(DESTDIR)$(configdir)/fonts.conf"; \
59           $(INSTALL_DATA) fonts.conf $(DESTDIR)$(configdir)/fonts.conf; \
60         fi; fi
61         if [ -f $(DESTDIR)$(configdir)/local.conf ]; then \
62           echo "not overwriting existing $(DESTDIR)$(configdir)/local.conf"; \
63         else if [ -f $(srcdir)/local.conf ]; then \
64           echo " $(INSTALL_DATA) $(srcdir)/local.conf $(DESTDIR)$(configdir)/local.conf"; \
65           $(INSTALL_DATA) $(srcdir)/local.conf $(DESTDIR)$(configdir)/local.conf; \
66         else if [ -f local.conf ]; then \
67           echo " $(INSTALL_DATA) local.conf $(DESTDIR)$(configdir)/local.conf"; \
68           $(INSTALL_DATA) local.conf $(DESTDIR)$(configdir)/local.conf; \
69         fi; fi; fi
70         if $(RUN_FC_CACHE_TEST); then \
71             echo " fc-cache/fc-cache -f -v"; \
72             fc-cache/fc-cache -f -v; \
73         else \
74             echo "***"; \
75             echo "*** Warning: fonts.cache not built"; \
76             echo "***"; \
77             echo "*** Generate this file manually on host system using fc-cache"; \
78             echo "***"; \
79         fi
80
81 uninstall-local:
82         if [ -f $(srcdir)/fonts.conf ]; then \
83           if cmp -s $(srcdir)/fonts.conf $(DESTDIR)$(configdir)/fonts.conf; then \
84              echo " uninstall standard $(DESTDIR)$(configdir)/fonts.conf"; \
85              rm -f $(DESTDIR)$(configdir)/fonts.conf; \
86           fi; \
87         else if [ -f fonts.conf ]; then \
88           if cmp -s fonts.conf $(DESTDIR)$(configdir)/fonts.conf; then \
89              echo " uninstall standard $(DESTDIR)$(configdir)/fonts.conf"; \
90              rm -f $(DESTDIR)$(configdir)/fonts.conf; \
91           fi; \
92         fi; fi
93         if [ -f $(srcdir)/local.conf ]; then \
94           if cmp -s $(srcdir)/local.conf $(DESTDIR)$(configdir)/local.conf; then \
95              echo " uninstall standard $(DESTDIR)$(configdir)/local.conf"; \
96              rm -f $(DESTDIR)$(configdir)/local.conf; \
97           fi; \
98         else if [ -f local.conf ]; then \
99           if cmp -s local.conf $(DESTDIR)$(configdir)/local.conf; then \
100              echo " uninstall standard $(DESTDIR)$(configdir)/local.conf"; \
101              rm -f $(DESTDIR)$(configdir)/local.conf; \
102           fi; \
103         fi; fi