Use UTF-8 case-insensitive hashes and comparisons for language identifiers.
[pspp] / Smake
1 # -*- makefile -*-
2
3 # Adjust these to reflect where you've installed gnulib.
4 GNULIB = ../gnulib
5 GNULIB_TOOL = $(GNULIB)/gnulib-tool
6
7 GNULIB_MODULES = \
8         assert \
9         byteswap \
10         c-snprintf \
11         c-strcase \
12         c-strcasestr \
13         c-ctype \
14         c-strtod \
15         c-xvasprintf \
16         clean-temp \
17         close \
18         configmake \
19         count-one-bits \
20         crc \
21         crypto/md4 \
22         crypto/md5 \
23         dirname \
24         dtoastr \
25         environ \
26         fatal-signal \
27         fcntl \
28         fpieee \
29         fprintf-posix \
30         full-read \
31         full-write \
32         fseeko \
33         ftello \
34         fwriteerror \
35         getline \
36         gettext \
37         gettimeofday \
38         getopt-gnu \
39         gitlog-to-changelog \
40         include_next \
41         isfinite \
42         isinf \
43         isnan \
44         intprops \
45         inttostr \
46         localcharset \
47         mbchar \
48         mbiter \
49         memcasecmp \
50         memchr \
51         mempcpy \
52         memrchr \
53         minmax \
54         mkdtemp \
55         mkstemp \
56         printf-posix \
57         printf-safe \
58         progname \
59         rawmemchr \
60         read-file \
61         regex \
62         relocatable-prog \
63         rename \
64         round \
65         snprintf \
66         snprintf-posix \
67         sprintf-posix \
68         stdarg \
69         stdbool \
70         stdint \
71         stpcpy \
72         strerror \
73         strftime \
74         strtod \
75         strtok_r \
76         sys_stat \
77         tempname \
78         trunc \
79         unicase/u8-casecmp \
80         unicase/u8-casefold \
81         unictype/ctype-print \
82         unictype/property-id-continue \
83         unictype/property-id-start \
84         unigbrk/uc-is-grapheme-break \
85         unilbrk/u8-possible-linebreaks \
86         uninorm/nfkd \
87         unistd \
88         unistr/u8-check \
89         unistr/u8-cpy \
90         unistr/u8-mblen \
91         unistr/u8-mbtouc \
92         unistr/u8-mbtoucr \
93         unistr/u8-strlen \
94         unistr/u8-strmbtouc \
95         unistr/u8-strncat \
96         unistr/u8-uctomb \
97         uniwidth/u8-strwidth \
98         unitypes \
99         unlocked-io \
100         vasprintf-posix \
101         version-etc \
102         version-etc-fsf \
103         vfprintf-posix \
104         vprintf-posix \
105         vsnprintf \
106         vsnprintf-posix \
107         vsprintf-posix \
108         xalloc \
109         xalloc-die \
110         xmalloca \
111         xmemdup0 \
112         xsize \
113         xstrndup \
114         xvasprintf
115
116 all: prep_ph
117         $(MAKE) -f Smake Makefile.in configure
118
119 .PHONY: prep_ph
120 prep_ph: 
121         test -e ChangeLog || touch ChangeLog
122         test -d m4 || mkdir m4
123         touch m4/Makefile.am
124         $(GNULIB_TOOL) --add-import --no-changelog --m4-base=gl/m4 \
125                 --source-base=gl --lib=libgl --tests-base=tests \
126                 --doc-base=gl/doc --aux-dir=build-aux  \
127                 --libtool $(GNULIB_MODULES)
128         libtoolize --force --automake
129
130 aclocal.m4:
131         aclocal -I m4 -I gl/m4
132
133 configure: configure.ac aclocal.m4
134         autoconf
135
136 config.h.in: configure.ac
137         autoheader
138
139 Makefile.in: Makefile.am config.h.in aclocal.m4
140         automake --add-missing --copy --no-force --include-deps
141
142
143 gettextize:
144         test -d m4 || mkdir m4
145         touch m4/Makefile.am
146         gettextize --force --no-changelog
147
148 check: all
149         rm -rf _check
150         mkdir _check
151         cd _check && ../configure $(CONFIGUREFLAGS)
152         cd _check && make distcheck
153         rm -rf _check
154
155 _build: all
156         test -d _build || mkdir _build
157         cd _build && ../configure $(CONFIGUREFLAGS)
158
159 _debug: all
160         test -d _debug || mkdir _debug
161         cd _debug && ../configure $(CONFIGUREFLAGS) --enable-debug
162
163 PO_FILES = po/ChangeLog \
164 po/Rules-quot po/boldquot.sed           \
165 po/cat-id-tbl.c po/en@boldquot.header po/en@quot.header                 \
166 po/insert-header.sin po/quot.sed po/remove-potcdate.sin po/stamp-po     \
167 po/Makevars.template po/pspp.pot
168
169 clean:
170         rm -f config.sub config.guess config.rpath
171         rm -fr autom4te.cache
172         rm -f aclocal.m4
173         rm -f missing mkinstalldirs
174         rm -f install-sh
175         rm -f configure Makefile 
176         rm -f depcomp
177         rm -rf intl gl
178         rm -f m4/*.m4
179         rm -f $(PO_FILES) po/*.gmo 
180         rm -f mdate-sh texinfo.tex
181         rm -f doc/stamp-vti
182         rm -f config.h.in~
183         rm -f config.h.in
184         find . -name Makefile.in -exec rm -f {} \; 
185         rm -f compile
186         rm -f ltmain.sh
187         rm -f reloc-ldflags install-reloc
188
189 .PHONY: all gettextize clean