Revert manifest to default one
[external/cups.git] / conf / Makefile
1 #
2 # "$Id: Makefile 9771 2011-05-12 05:21:56Z mike $"
3 #
4 #   Configuration file makefile for CUPS.
5 #
6 #   Copyright 2007-2011 by Apple Inc.
7 #   Copyright 1993-2006 by Easy Software Products.
8 #
9 #   These coded instructions, statements, and computer programs are the
10 #   property of Apple Inc. and are protected by Federal copyright
11 #   law.  Distribution and use rights are outlined in the file "LICENSE.txt"
12 #   which should have been included with this file.  If this file is
13 #   file is missing or damaged, see the license at "http://www.cups.org/".
14 #
15
16 include ../Makedefs
17
18 #
19 # Config files...
20 #
21
22 KEEP    =       cupsd.conf snmp.conf
23 REPLACE =       mime.convs mime.types
24
25
26 #
27 # Make everything...
28 #
29
30 all:
31
32
33 #
34 # Make library targets...
35 #
36
37 libs:
38
39
40 #
41 # Make unit tests...
42 #
43
44 unittests:
45
46
47 #
48 # Clean all config and object files...
49 #
50
51 clean:
52
53
54 #
55 # Dummy depend...
56 #
57
58 depend:
59
60
61 #
62 # Install all targets...
63 #
64
65 install:        all install-data install-headers install-libs install-exec
66
67
68 #
69 # Install data files...
70 #
71
72 install-data:
73         for file in $(KEEP); do \
74                 if test -r $(SERVERROOT)/$$file ; then \
75                         $(INSTALL_CONFIG) -g $(CUPS_GROUP) $$file $(SERVERROOT)/$$file.N ; \
76                 else \
77                         $(INSTALL_CONFIG) -g $(CUPS_GROUP) $$file $(SERVERROOT) ; \
78                         grep -v "\$$Id:" $(SERVERROOT)/$$file > $(SERVERROOT)/$$file.n ; \
79                         mv $(SERVERROOT)/$$file.n $(SERVERROOT)/$$file ; \
80                 fi ; \
81         done
82         $(INSTALL_CONFIG) -g $(CUPS_GROUP) cupsd.conf $(SERVERROOT)/cupsd.conf.default
83         $(INSTALL_DIR) -m 755 $(DATADIR)/mime
84         for file in $(REPLACE); do \
85                 if test -r $(DATADIR)/mime/$$file ; then \
86                         $(MV) $(DATADIR)/mime/$$file $(DATADIR)/mime/$$file.O ; \
87                 fi ; \
88                 if test -r $(SERVERROOT)/$$file ; then \
89                         $(MV) $(SERVERROOT)/$$file $(DATADIR)/mime/$$file.O ; \
90                 fi ; \
91                 $(INSTALL_DATA) $$file $(DATADIR)/mime ; \
92         done
93         -if test x$(PAMDIR) != x; then \
94                 $(INSTALL_DIR) -m 755 $(BUILDROOT)$(PAMDIR); \
95                 if test -r $(BUILDROOT)$(PAMDIR)/cups ; then \
96                         $(INSTALL_DATA) $(PAMFILE) $(BUILDROOT)$(PAMDIR)/cups.N ; \
97                 else \
98                         $(INSTALL_DATA) $(PAMFILE) $(BUILDROOT)$(PAMDIR)/cups ; \
99                 fi ; \
100         fi
101
102
103 #
104 # Install programs...
105 #
106
107 install-exec:
108
109
110 #
111 # Install headers...
112 #
113
114 install-headers:
115
116
117 #
118 # Install libraries...
119 #
120
121 install-libs:
122
123
124 #
125 # Uninstall files...
126 #
127
128 uninstall:
129         for file in $(KEEP) $(REPLACE) cupsd.conf.default; do \
130                 $(RM) $(SERVERROOT)/$$file; \
131         done
132         -$(RMDIR) $(SERVERROOT)
133         for file in $(REPLACE); do \
134                 $(RM) $(DATADIR)/mime/$$file; \
135         done
136         -$(RMDIR) $(DATADIR)/mime
137         -if test x$(PAMDIR) != x; then \
138                 $(RM) $(BUILDROOT)$(PAMDIR)/cups; \
139                 $(RMDIR) $(BUILDROOT)$(PAMDIR); \
140         fi
141
142
143 #
144 # End of "$Id: Makefile 9771 2011-05-12 05:21:56Z mike $".
145 #