Imported Upstream version 0.19.7
[platform/upstream/gettext.git] / gettext-tools / misc / Makefile.am
1 ## Makefile for the gettext-tools/misc subdirectory of GNU gettext
2 ## Copyright (C) 1995-1997, 2000-2003, 2005-2007, 2009-2010, 2015 Free
3 ## Software Foundation, Inc.
4 ##
5 ## This program is free software: you can redistribute it and/or modify
6 ## it under the terms of the GNU General Public License as published by
7 ## the Free Software Foundation; either version 3 of the License, or
8 ## (at your option) any later version.
9 ##
10 ## This program is distributed in the hope that it will be useful,
11 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
12 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 ## GNU General Public License for more details.
14 ##
15 ## You should have received a copy of the GNU General Public License
16 ## along with this program.  If not, see <http://www.gnu.org/licenses/>.
17
18 ## Process this file with automake to produce Makefile.in.
19
20 AUTOMAKE_OPTIONS = 1.2 gnits
21 EXTRA_DIST =
22 MOSTLYCLEANFILES =
23 CLEANFILES =
24 DISTCLEANFILES =
25
26
27 # Scripts for maintainers.
28
29 bin_SCRIPTS = gettextize autopoint
30
31 DISTCLEANFILES += gettextize autopoint convert-archive
32
33 CLEANFILES += \
34   archive.dir.tar.gz \
35   archive.dir.tar.bz2 \
36   archive.dir.tar.xz \
37   archive.cvs.tar.gz \
38   archive.git.tar.gz
39
40 EXTRA_DIST += add-to-archive cvsuser.c archive.dir.tar
41
42 gettextsrcdir = $(datadir)/gettext
43 gettextsrc_DATA = $(ARCHIVE_@ARCHIVE_FORMAT@)
44 ARCHIVE_dirgz = archive.dir.tar.gz
45 ARCHIVE_dirbz2 = archive.dir.tar.bz2
46 ARCHIVE_dirxz = archive.dir.tar.xz
47 ARCHIVE_git = archive.git.tar.gz
48 ARCHIVE_cvs = archive.cvs.tar.gz
49
50 # The archive.dir.tar is not in the CVS. Alpha-testers must use the one from
51 # an already installed release.
52 archive.dir.tar:
53         if test -f $(gettextsrcdir)/archive.dir.tar.gz; then \
54           gzip -d -c < $(gettextsrcdir)/archive.dir.tar.gz > $@-t && mv $@-t $@; \
55         else \
56           if test -f $(gettextsrcdir)/archive.dir.tar.bz2; then \
57             bzip2 -d -c < $(gettextsrcdir)/archive.dir.tar.bz2 > $@-t && mv $@-t $@; \
58           else \
59             if test -f $(gettextsrcdir)/archive.dir.tar.xz; then \
60               xz -d -c < $(gettextsrcdir)/archive.dir.tar.xz > $@-t && mv $@-t $@; \
61             else \
62               echo "archive.dir.tar is not under version control. Please copy the archive.dir.tar.{gz,bz2,xz} from an already installed release to gettext-tools/misc/ and decompress it there." 1>&2; \
63               exit 1; \
64             fi; \
65           fi; \
66         fi
67 MOSTLYCLEANFILES += archive.dir.tar-t
68
69 # The archive.dir.tar.gz is generated from archive.dir.tar.
70 archive.dir.tar.gz: archive.dir.tar
71         if test -f archive.dir.tar; then \
72           inputfile=archive.dir.tar; \
73         else \
74           inputfile='$(srcdir)'/archive.dir.tar; \
75         fi; \
76         gzip -c -9 < "$$inputfile" > $@-t && mv $@-t $@
77 MOSTLYCLEANFILES += archive.dir.tar.gz-t
78
79 # The archive.dir.tar.bz2 is generated from archive.dir.tar.
80 archive.dir.tar.bz2: archive.dir.tar
81         if test -f archive.dir.tar; then \
82           inputfile=archive.dir.tar; \
83         else \
84           inputfile='$(srcdir)'/archive.dir.tar; \
85         fi; \
86         bzip2 -c -9 < "$$inputfile" > $@-t && mv $@-t $@
87 MOSTLYCLEANFILES += archive.dir.tar.bz2-t
88
89 # The archive.dir.tar.xz is generated from archive.dir.tar.
90 archive.dir.tar.xz: archive.dir.tar
91         if test -f archive.dir.tar; then \
92           inputfile=archive.dir.tar; \
93         else \
94           inputfile='$(srcdir)'/archive.dir.tar; \
95         fi; \
96         xz -c -5 < "$$inputfile" > $@-t && mv $@-t $@
97 MOSTLYCLEANFILES += archive.dir.tar.xz-t
98
99 # The archive.git.tar.gz is generated from archive.dir.tar.
100 archive.git.tar.gz: archive.dir.tar
101         if test -f archive.dir.tar; then \
102           inputfile=archive.dir.tar; \
103         else \
104           inputfile='$(srcdir)'/archive.dir.tar; \
105         fi; \
106         ./convert-archive dir git "$$inputfile" $@
107
108 # The archive.cvs.tar.gz is generated from archive.dir.tar.
109 archive.cvs.tar.gz: archive.dir.tar
110         if test -f archive.dir.tar; then \
111           inputfile=archive.dir.tar; \
112         else \
113           inputfile='$(srcdir)'/archive.dir.tar; \
114         fi; \
115         ./convert-archive dir cvs "$$inputfile" $@
116
117 # Emacs Lisp code.
118
119 lisp_LISP = start-po.el po-mode.el po-compat.el
120
121 EXTRA_DIST += $(lisp_LISP)