1## Makefile for the gettext-tools directory of GNU gettext 2## Copyright (C) 1995-1999, 2000-2005 Free Software Foundation, Inc. 3## 4## This program is free software; you can redistribute it and/or modify 5## it under the terms of the GNU General Public License as published by 6## the Free Software Foundation; either version 2, or (at your option) 7## any later version. 8## 9## This program is distributed in the hope that it will be useful, 10## but WITHOUT ANY WARRANTY; without even the implied warranty of 11## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12## GNU General Public License for more details. 13## 14## You should have received a copy of the GNU General Public License 15## along with this program; if not, write to the Free Software 16## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 17 18## Process this file with automake to produce Makefile.in. 19 20AUTOMAKE_OPTIONS = 1.5 gnu no-dependencies 21ACLOCAL_AMFLAGS = -I m4 -I ../gettext-runtime/m4 -I ../autoconf-lib-link/m4 -I ../m4 22 23SUBDIRS = doc intl lib libgrep libuniname src po projects misc m4 tests examples 24 25EXTRA_DIST = misc/DISCLAIM 26 27 28# Files installed for use by gettextize. 29 30gettextsrcdir = $(datadir)/gettext 31gettextsrc_SCRIPTS = ../autoconf-lib-link/config.rpath ../build-aux/mkinstalldirs 32 33 34# Files copied from other directories. 35 36all-local: $(srcdir)/ABOUT-NLS 37$(srcdir)/ABOUT-NLS: $(srcdir)/../gettext-runtime/ABOUT-NLS 38 cp $(srcdir)/../gettext-runtime/ABOUT-NLS $(srcdir)/ABOUT-NLS 39 40 41# VMS support. 42 43config.h_vms: config.h.in ../version.sh 44 (echo '#define KEEP_CRTL_SETLOCALE 1'; echo '#include <vms_jackets.h>'; echo '#undef realpath'; \ 45 sed -e 's/#undef ENABLE_NLS$$/#define ENABLE_NLS 1/' \ 46 -e 's/#undef HAVE_ALLOCA$$/#define HAVE_ALLOCA 1/' \ 47 -e 's/#undef HAVE_ARPA_INET_H$$/#define HAVE_ARPA_INET_H 1/' \ 48 -e 's/#undef HAVE_BTOWC$$/#define HAVE_BTOWC 1/' \ 49 -e 's/#undef HAVE_CHOWN$$/#define HAVE_CHOWN 1/' \ 50 -e 's/#undef HAVE_DECL_GETENV$$/#define HAVE_DECL_GETENV 1/' \ 51 -e 's/#undef HAVE_DECL_STRDUP$$/#define HAVE_DECL_STRDUP 1/' \ 52 -e 's/#undef HAVE_DECL_WCWIDTH$$/#define HAVE_DECL_WCWIDTH 1/' \ 53 -e 's/#undef HAVE_DIRENT_H$$/#define HAVE_DIRENT_H 1/' \ 54 -e 's/#undef HAVE_DLFCN_H$$/#define HAVE_DLFCN_H 1/' \ 55 -e 's/#undef HAVE_ERRNO_DECL$$/#define HAVE_ERRNO_DECL 1/' \ 56 -e 's/#undef HAVE_FCNTL_H$$/#define HAVE_FCNTL_H 1/' \ 57 -e 's/#undef HAVE_GETCWD$$/#define HAVE_GETCWD 1/' \ 58 -e 's/#undef HAVE_GETEGID$$/#define HAVE_GETEGID 1/' \ 59 -e 's/#undef HAVE_GETEUID$$/#define HAVE_GETEUID 1/' \ 60 -e 's/#undef HAVE_GETGID$$/#define HAVE_GETGID 1/' \ 61 -e 's/#undef HAVE_GETHOSTBYNAME$$/#define HAVE_GETHOSTBYNAME 1/' \ 62 -e 's/#undef HAVE_GETHOSTNAME$$/#define HAVE_GETHOSTNAME 1/' \ 63 -e 's/#undef HAVE_GETPAGESIZE$$/#define HAVE_GETPAGESIZE 1/' \ 64 -e 's/#undef HAVE_GETTIMEOFDAY$$/#define HAVE_GETTIMEOFDAY 1/' \ 65 -e 's/#undef HAVE_GETUID$$/#define HAVE_GETUID 1/' \ 66 -e 's/#undef HAVE_ICONV$$/#define HAVE_ICONV 1/' \ 67 -e 's/#undef HAVE_INTTYPES_H$$/#define HAVE_INTTYPES_H 1/' \ 68 -e 's/#undef HAVE_ISASCII$$/#define HAVE_ISASCII 1/' \ 69 -e 's/#undef HAVE_ISWCNTRL$$/#define HAVE_ISWCNTRL 1/' \ 70 -e 's/#undef HAVE_ISWPRINT$$/#define HAVE_ISWPRINT 1/' \ 71 -e 's/#undef HAVE_LANGINFO_CODESET$$/#define HAVE_LANGINFO_CODESET 1/' \ 72 -e 's/#undef HAVE_LC_MESSAGES$$/#define HAVE_LC_MESSAGES 1/' \ 73 -e 's/#undef HAVE_LIBEXPAT$$/#define HAVE_LIBEXPAT 1/' \ 74 -e 's/#undef HAVE_LIMITS_H$$/#define HAVE_LIMITS_H 1/' \ 75 -e 's/#undef HAVE_LOCALE_H$$/#define HAVE_LOCALE_H 1/' \ 76 -e 's/#undef HAVE_LONG_FILE_NAMES$$/#define HAVE_LONG_FILE_NAMES 1/' \ 77 -e 's/#undef HAVE_MALLOC_H$$/#define HAVE_MALLOC_H 1/' \ 78 -e 's/#undef HAVE_MBRTOWC$$/#define HAVE_MBRTOWC 1/' \ 79 -e 's/#undef HAVE_MBSINIT$$/#define HAVE_MBSINIT 1/' \ 80 -e 's/#undef HAVE_MBSTATE_T$$/#define HAVE_MBSTATE_T 1/' \ 81 -e 's/#undef HAVE_MEMCHR$$/#define HAVE_MEMCHR 1/' \ 82 -e 's/#undef HAVE_MEMMOVE$$/#define HAVE_MEMMOVE 1/' \ 83 -e 's/#undef HAVE_MEMORY_H$$/#define HAVE_MEMORY_H 1/' \ 84 -e 's/#undef HAVE_MEMSET$$/#define HAVE_MEMSET 1/' \ 85 -e 's/#undef HAVE_MMAP$$/#define HAVE_MMAP 1/' \ 86 -e 's/#undef HAVE_MUNMAP$$/#define HAVE_MUNMAP 1/' \ 87 -e 's/#undef HAVE_NL_TYPES_H$$/#define HAVE_NL_TYPES_H 1/' \ 88 -e 's/#undef HAVE_PATHCONF$$/#define HAVE_PATHCONF 1/' \ 89 -e 's/#undef HAVE_POSIX_SIGNALBLOCKING$$/#define HAVE_POSIX_SIGNALBLOCKING 1/' \ 90 -e 's/#undef HAVE_PTRDIFF_T$$/#define HAVE_PTRDIFF_T 1/' \ 91 -e 's/#undef HAVE_PUTENV$$/#define HAVE_PUTENV 1/' \ 92 -e 's/#undef HAVE_RAISE$$/#define HAVE_RAISE 1/' \ 93 -e 's/#undef HAVE_READLINK$$/#define HAVE_READLINK 1/' \ 94 -e 's/#undef HAVE_SELECT$$/#define HAVE_SELECT 1/' \ 95 -e 's/#undef HAVE_SETENV$$/#define HAVE_SETENV 1/' \ 96 -e 's/#undef HAVE_SETLOCALE$$/#define HAVE_SETLOCALE 1/' \ 97 -e 's/#undef HAVE_SIG_ATOMIC_T$$/#define HAVE_SIG_ATOMIC_T 1/' \ 98 -e 's/#undef HAVE_STDBOOL_H$$/#define HAVE_STDBOOL_H 1/' \ 99 -e 's/#undef HAVE_STDDEF_H$$/#define HAVE_STDDEF_H 1/' \ 100 -e 's/#undef HAVE_STDLIB_H$$/#define HAVE_STDLIB_H 1/' \ 101 -e 's/#undef HAVE_STRCASECMP$$/#define HAVE_STRCASECMP 1/' \ 102 -e 's/#undef HAVE_STRCSPN$$/#define HAVE_STRCSPN 1/' \ 103 -e 's/#undef HAVE_STRDUP$$/#define HAVE_STRDUP 1/' \ 104 -e 's/#undef HAVE_STRERROR$$/#define HAVE_STRERROR 1/' \ 105 -e 's/#undef HAVE_STRINGS_H$$/#define HAVE_STRINGS_H 1/' \ 106 -e 's/#undef HAVE_STRING_H$$/#define HAVE_STRING_H 1/' \ 107 -e 's/#undef HAVE_STRNCASECMP$$/#define HAVE_STRNCASECMP 1/' \ 108 -e 's/#undef HAVE_STRPBRK$$/#define HAVE_STRPBRK 1/' \ 109 -e 's/#undef HAVE_STRSTR$$/#define HAVE_STRSTR 1/' \ 110 -e 's/#undef HAVE_STRTOUL$$/#define HAVE_STRTOUL 1/' \ 111 -e 's/#undef HAVE_SYS_PARAM_H$$/#define HAVE_SYS_PARAM_H 1/' \ 112 -e 's/#undef HAVE_SYS_STAT_H$$/#define HAVE_SYS_STAT_H 1/' \ 113 -e 's/#undef HAVE_SYS_TIME_H$$/#define HAVE_SYS_TIME_H 1/' \ 114 -e 's/#undef HAVE_SYS_TYPES_H$$/#define HAVE_SYS_TYPES_H 1/' \ 115 -e 's/#undef HAVE_TIME_H$$/#define HAVE_TIME_H 1/' \ 116 -e 's/#undef HAVE_UNAME$$/#define HAVE_UNAME 1/' \ 117 -e 's/#undef HAVE_UNISTD_H$$/#define HAVE_UNISTD_H 1/' \ 118 -e 's/#undef HAVE_UNSETENV$$/#define HAVE_UNSETENV 1/' \ 119 -e 's/#undef HAVE_UNSIGNED_LONG_LONG$$/#define HAVE_UNSIGNED_LONG_LONG 1/' \ 120 -e 's/#undef HAVE_UTIME$$/#define HAVE_UTIME 1/' \ 121 -e 's/#undef HAVE_UTIMES$$/#define HAVE_UTIMES 1/' \ 122 -e 's/#undef HAVE_UTIME_H$$/#define HAVE_UTIME_H 1/' \ 123 -e 's/#undef HAVE_VFORK$$/#define HAVE_VFORK 1/' \ 124 -e 's/#undef HAVE_VPRINTF$$/#define HAVE_VPRINTF 1/' \ 125 -e 's/#undef HAVE_WAITPID$$/#define HAVE_WAITPID 1/' \ 126 -e 's/#undef HAVE_WCHAR_H$$/#define HAVE_WCHAR_H 1/' \ 127 -e 's/#undef HAVE_WCSLEN$$/#define HAVE_WCSLEN 1/' \ 128 -e 's/#undef HAVE_WCTYPE_H$$/#define HAVE_WCTYPE_H 1/' \ 129 -e 's/#undef HAVE_WCWIDTH$$/#define HAVE_WCWIDTH 1/' \ 130 -e 's/#undef HAVE_WINT_T$$/#define HAVE_WINT_T 1/' \ 131 -e 's/#undef HAVE_WMEMCHR$$/#define HAVE_WMEMCHR 1/' \ 132 -e 's/#undef HAVE_WMEMCPY$$/#define HAVE_WMEMCPY 1/' \ 133 -e 's/#undef HAVE_WORKING_VFORK$$/#define HAVE_WORKING_VFORK 1/' \ 134 -e 's/#undef HAVE_WPRINTF$$/#define HAVE_WPRINTF 1/' \ 135 -e 's/#undef ICONV_CONST$$/#define ICONV_CONST/' \ 136 -e 's/#undef MALLOC_0_IS_NONNULL$$/#define MALLOC_0_IS_NONNULL 0/' \ 137 -e 's/#undef SETLOCALE_CONST$$/#define SETLOCALE_CONST const/' \ 138 -e 's/#undef STDC_HEADERS$$/#define STDC_HEADERS 1/' \ 139 -e 's/#undef USE_UNLOCKED_IO$$/#define USE_UNLOCKED_IO 1/' \ 140 -e 's/#undef __GETOPT_PREFIX$$/#define __GETOPT_PREFIX/' \ 141 -e 's/#undef eaccess$$/#define eaccess access/' \ 142 -e 's/#undef fnmatch$$/#define fnmatch rpl_fnmatch/' \ 143 -e 's/#undef getline$$/#define getline rpl_getline/' \ 144 -e 's/#undef realpath$$/#define realpath rpl_realpath/' \ 145 -e 's/#undef restrict$$/#define restrict/' \ 146 -e 's/#undef uintmax_t$$/#define uintmax_t unsigned long long/' \ 147 -e 's/#undef PACKAGE$$/#define PACKAGE "gettext-tools"/' \ 148 -e 's/#undef VERSION$$/#define VERSION "$(VERSION)"/' \ 149 < $(srcdir)/config.h.in; echo; echo '#define alloca __ALLOCA'; echo '#define pw_gecos pw_name') > $@ 150# vms_jackets.h is a header that comes with Compaq's "porting library". 151# KEEP_CRTL_SETLOCALE tells it to not override the native locale support. 152 153EXTRA_DIST += Makefile.vms config.h_vms 154 155 156# Woe32 support. 157 158config.h.msvc: config.h.in ../version.sh 159 sed -e 's/#undef ENABLE_NLS$$/#define ENABLE_NLS 1/' \ 160 -e 's/#undef ENABLE_RELOCATABLE$$/#define ENABLE_RELOCATABLE 1/' \ 161 -e 's/#undef HAVE_ALLOCA$$/#define HAVE_ALLOCA 1/' \ 162 -e 's/#undef HAVE_BTOWC$$/#define HAVE_BTOWC 1/' \ 163 -e 's/#undef HAVE_DECL_GETENV$$/#define HAVE_DECL_GETENV 1/' \ 164 -e 's/#undef HAVE_DECL_STRDUP$$/#define HAVE_DECL_STRDUP 1/' \ 165 -e 's/#undef HAVE_DECL_STRERROR$$/#define HAVE_DECL_STRERROR 1/' \ 166 -e 's/#undef HAVE_DECL_WCWIDTH$$/#define HAVE_DECL_WCWIDTH 0/' \ 167 -e 's/#undef HAVE_DECL__SNPRINTF$$/#define HAVE_DECL__SNPRINTF 1/' \ 168 -e 's/#undef HAVE_DECL__SNWPRINTF$$/#define HAVE_DECL__SNWPRINTF 1/' \ 169 -e 's/#undef HAVE_ENVIRON_DECL$$/#define HAVE_ENVIRON_DECL 1/' \ 170 -e 's/#undef HAVE_ERRNO_DECL$$/#define HAVE_ERRNO_DECL 1/' \ 171 -e 's/#undef HAVE_FCNTL_H$$/#define HAVE_FCNTL_H 1/' \ 172 -e 's/#undef HAVE_GETCWD$$/#define HAVE_GETCWD 1/' \ 173 -e 's/#undef HAVE_GETHOSTBYNAME$$/#define HAVE_GETHOSTBYNAME 1/' \ 174 -e 's/#undef HAVE_GETHOSTNAME$$/#define HAVE_GETHOSTNAME 1/' \ 175 -e 's/#undef HAVE_ICONV$$/#define HAVE_ICONV 1/' \ 176 -e 's/#undef HAVE_ISASCII$$/#define HAVE_ISASCII 1/' \ 177 -e 's/#undef HAVE_ISWCNTRL$$/#define HAVE_ISWCNTRL 1/' \ 178 -e 's/#undef HAVE_ISWPRINT$$/#define HAVE_ISWPRINT 1/' \ 179 -e 's/#undef HAVE_LIMITS_H$$/#define HAVE_LIMITS_H 1/' \ 180 -e 's/#undef HAVE_LOCALE_H$$/#define HAVE_LOCALE_H 1/' \ 181 -e 's/#undef HAVE_LONG_FILE_NAMES$$/#define HAVE_LONG_FILE_NAMES 1/' \ 182 -e 's/#undef HAVE_MEMCHR$$/#define HAVE_MEMCHR 1/' \ 183 -e 's/#undef HAVE_MEMMOVE$$/#define HAVE_MEMMOVE 1/' \ 184 -e 's/#undef HAVE_MEMSET$$/#define HAVE_MEMSET 1/' \ 185 -e 's/#undef HAVE_PTRDIFF_T$$/#define HAVE_PTRDIFF_T 1/' \ 186 -e 's/#undef HAVE_PUTENV$$/#define HAVE_PUTENV 1/' \ 187 -e 's/#undef HAVE_RAISE$$/#define HAVE_RAISE 1/' \ 188 -e 's/#undef HAVE_SEARCH_H$$/#define HAVE_SEARCH_H 1/' \ 189 -e 's/#undef HAVE_SETLOCALE$$/#define HAVE_SETLOCALE 1/' \ 190 -e 's/#undef HAVE_SIG_ATOMIC_T$$/#define HAVE_SIG_ATOMIC_T 1/' \ 191 -e 's/#undef HAVE_STDDEF_H$$/#define HAVE_STDDEF_H 1/' \ 192 -e 's/#undef HAVE_STDLIB_H$$/#define HAVE_STDLIB_H 1/' \ 193 -e 's/#undef HAVE_STRCSPN$$/#define HAVE_STRCSPN 1/' \ 194 -e 's/#undef HAVE_STRDUP$$/#define HAVE_STRDUP 1/' \ 195 -e 's/#undef HAVE_STRERROR$$/#define HAVE_STRERROR 1/' \ 196 -e 's/#undef HAVE_STRING_H$$/#define HAVE_STRING_H 1/' \ 197 -e 's/#undef HAVE_STRPBRK$$/#define HAVE_STRPBRK 1/' \ 198 -e 's/#undef HAVE_STRSTR$$/#define HAVE_STRSTR 1/' \ 199 -e 's/#undef HAVE_STRTOUL$$/#define HAVE_STRTOUL 1/' \ 200 -e 's/#undef HAVE_SYS_STAT_H$$/#define HAVE_SYS_STAT_H 1/' \ 201 -e 's/#undef HAVE_SYS_TYPES_H$$/#define HAVE_SYS_TYPES_H 1/' \ 202 -e 's/#undef HAVE_TIME_H$$/#define HAVE_TIME_H 1/' \ 203 -e 's/#undef HAVE_VPRINTF$$/#define HAVE_VPRINTF 1/' \ 204 -e 's/#undef HAVE_WCHAR_H$$/#define HAVE_WCHAR_H 1/' \ 205 -e 's/#undef HAVE_WCSLEN$$/#define HAVE_WCSLEN 1/' \ 206 -e 's/#undef HAVE_WINT_T$$/#define HAVE_WINT_T 1/' \ 207 -e 's/#undef HAVE_WMEMCHR$$/#define HAVE_WMEMCHR 1/' \ 208 -e 's/#undef HAVE_WMEMCPY$$/#define HAVE_WMEMCPY 1/' \ 209 -e 's/#undef HAVE_WPRINTF$$/#define HAVE_WPRINTF 1/' \ 210 -e 's/#undef ICONV_CONST$$/#define ICONV_CONST const/' \ 211 -e 's/#undef MALLOC_0_IS_NONNULL$$/#define MALLOC_0_IS_NONNULL 1/' \ 212 -e 's/#undef SETLOCALE_CONST$$/#define SETLOCALE_CONST const/' \ 213 -e 's/#undef SIZE_MAX$$/#define SIZE_MAX 4294967295U/' \ 214 -e 's/#undef STACK_DIRECTION$$/#define STACK_DIRECTION -1/' \ 215 -e 's/#undef STDC_HEADERS$$/#define STDC_HEADERS 1/' \ 216 -e 's/#undef USE_UNLOCKED_IO$$/#define USE_UNLOCKED_IO 1/' \ 217 -e 's/#undef __GETOPT_PREFIX$$/#define __GETOPT_PREFIX/' \ 218 -e 's/#undef fnmatch$$/#define fnmatch rpl_fnmatch/' \ 219 -e 's/#undef getline$$/#define getline rpl_getline/' \ 220 -e 's/#undef inline$$/#define inline __inline/' \ 221 -e 's/#undef mode_t$$/#define mode_t int/' \ 222 -e 's/#undef pid_t$$/#define pid_t int/' \ 223 -e 's/#undef restrict$$/#define restrict/' \ 224 -e 's/#undef ssize_t$$/#define ssize_t int/' \ 225 -e 's/#undef uintmax_t$$/#define uintmax_t unsigned long/' \ 226 -e 's/#undef PACKAGE$$/#define PACKAGE "gettext-tools"/' \ 227 -e 's/#undef VERSION$$/#define VERSION "$(VERSION)"/' \ 228 -e '/#undef INSTALLPREFIX$$/d' \ 229 < $(srcdir)/config.h.in > $@ 230 231windows/stdbool.h: lib/stdbool_.h 232 sed -e 's/@''HAVE__BOOL''@/0/' < $(srcdir)/lib/stdbool_.h > $@ 233 234all-local : windows/stdbool.h 235 236EXTRA_DIST += README.woe32 Makefile.msvc config.h.msvc windows/alloca.h windows/fnmatch.h windows/getopt.h windows/stdbool.h windows/gettextlib.def windows/gettextsrc.def windows/gettextpo.def windows/gettextlib.rc windows/gettextsrc.rc windows/gettextpo.rc 237