File: Makefile

package info (click to toggle)
cups 1.4.4-7+squeeze10
  • links: PTS, VCS
  • area: main
  • in suites: squeeze-lts
  • size: 25,548 kB
  • ctags: 9,583
  • sloc: ansic: 138,214; sh: 37,926; cpp: 25,469; makefile: 3,285; perl: 190; python: 127; php: 28
file content (205 lines) | stat: -rw-r--r-- 4,035 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
#
# "$Id: Makefile 8431 2009-03-12 22:59:58Z mike $"
#
#   Locale file makefile for the Common UNIX Printing System (CUPS).
#
#   Copyright 2007-2008 by Apple Inc.
#   Copyright 1993-2007 by Easy Software Products.
#
#   These coded instructions, statements, and computer programs are the
#   property of Apple Inc. and are protected by Federal copyright
#   law.  Distribution and use rights are outlined in the file "LICENSE.txt"
#   which should have been included with this file.  If this file is
#   file is missing or damaged, see the license at "http://www.cups.org/".
#

include ../Makedefs


OBJS	=	checkpo.o po2strings.o strings2po.o translate.o
TARGETS	=	checkpo po2strings strings2po translate


#
# Make everything...
#

all:	$(TARGETS)


#
# Make library targets...
#

libs:


#
# Make unit tests...
#

unittests:


#
# Clean all config and object files...
#

clean:
	$(RM) $(TARGETS) $(OBJS)


#
# Update dependencies (without system header dependencies...)
#

depend:
	makedepend -Y -I.. -fDependencies $(OBJS:.o=.c) >/dev/null 2>&1


#
# Install all targets...
#

install:	all install-data install-headers install-libs install-exec


#
# Install data files...
#

install-data: $(INSTALL_LANGUAGES)

install-languages:
	$(INSTALL_DIR) -m 755 $(LOCALEDIR)
	for loc in $(LANGUAGES) ; do \
		if test -f cups_$$loc.po; then \
			$(INSTALL_DIR) -m 755 $(LOCALEDIR)/$$loc ; \
			$(INSTALL_DATA) cups_$$loc.po $(LOCALEDIR)/$$loc/cups_$$loc.po ; \
		fi ; \
	done


#
# Install programs...
#

install-exec:


#
# Install headers...
#

install-headers:


#
# Install libraries...
#

install-libs:


#
# Uninstall files...
#

uninstall: $(UNINSTALL_LANGUAGES)

uninstall-languages:
	-for loc in $(LANGUAGES) ; do \
		$(RM) $(LOCALEDIR)/$$loc/cups_$$loc.po ; \
	done


#
# pot - Creates/updates the cups.pot template file, and merges changes
#       into existing message catalogs.
#

pot:
	echo Updating cups.pot...
	mv cups.pot cups.pot.bck
	touch cups.pot
	cd ..; xgettext -o locale/cups.pot -j -s --keyword=_ --no-wrap \
		--copyright-holder="Apple Inc." \
		--msgid-bugs-address="http://www.cups.org/str.php" \
		*/*.c */*.cxx
	(cat cups.header; \
	 cat cups.pot | sed -e '1,6d' -e '1,$$s/PACKAGE VERSION/CUPS 1.4/' \
	     -e '1,$$s/charset=CHARSET/charset=utf-8/'; \
	 cat cups.footer) > cups.pot.N
	mv cups.pot.N cups.pot
	for loc in $(LANGUAGES) ; do \
		echo Merging changes into cups_$$loc.po... ; \
		msgmerge -o cups_$$loc.po -s -N --no-location cups_$$loc.po cups.pot ; \
	done


#
# checkpo - A simple utility to check PO files for correct translation
#           strings.  Dependency on static library is deliberate.
#
# checkpo filename.po [... filenameN.po]
#

checkpo:	checkpo.o ../cups/libcups.a
	echo Linking $<...
	$(CC) $(LDFLAGS) -o checkpo checkpo.o ../cups/libcups.a \
		$(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ)

checkall:	checkpo
	for file in *.po; do \
		./checkpo $$file; \
	done


#
# po2strings - A simple utility which uses iconv to convert GNU gettext
#              message catalogs to Mac OS X .strings files.
#
# po2strings filename.po filename.strings
#

po2strings:	po2strings.o ../cups/libcups.a
	echo Linking $<...
	$(CC) $(LDFLAGS) -o po2strings po2strings.o ../cups/libcups.a \
		$(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ)


#
# strings2po - A simple utility which uses iconv to convert Mac OS X
#              .strings files to GNU gettext message catalogs.
#
# strings2po filename.strings filename.po
#

strings2po:	strings2po.o
	echo Linking $<...
	$(CC) $(LDFLAGS) -o strings2po strings2po.o


#
# translate - A simple utility which uses Google to translate the cups.pot
#             file to one of several languages.
#
# translate outfile language
#

translate:	translate.o ../cups/libcups.a
	echo Linking $<...
	$(CC) $(LDFLAGS) -o translate translate.o ../cups/libcups.a \
		$(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ)


#
# Dependencies...
#
  
include Dependencies


#
# End of "$Id: Makefile 8431 2009-03-12 22:59:58Z mike $".
#