"src/global.c" did not exist on "f7c6811e36e5fdda1c23a4b210411777546b63e2"
configure.ac 16.6 KB
Newer Older
1
2
3
4
# Configuration for GNU nano - a small and user-friendly text editor
#
# Copyright (C) 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
#
5
6
7
8
# GNU nano is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
# Free Software Foundation; either version 2, or (at your option) any
# later version.
9
#
10
11
12
13
# GNU nano is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
# General Public License for more details.
14
15
#
# You should have received a copy of the GNU General Public License
David Lawrence Ramsey's avatar
David Lawrence Ramsey committed
16
# along with GNU nano; if not, write to the Free Software
17
18
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301,
# USA.
19
#
20
# $Id$
21

David Lawrence Ramsey's avatar
David Lawrence Ramsey committed
22
AC_INIT([GNU nano], [1.3.8-cvs], [nano-devel@gnu.org], [nano])
Jordi Mallach's avatar
Jordi Mallach committed
23
AC_CONFIG_SRCDIR([src/nano.c])
24
AC_CANONICAL_TARGET([])
25
AM_INIT_AUTOMAKE
26
AC_CONFIG_HEADERS([config.h])
27

28
AC_PREREQ(2.54)
Chris Allegretta's avatar
Chris Allegretta committed
29
30

dnl Checks for programs.
David Lawrence Ramsey's avatar
David Lawrence Ramsey committed
31

32
AC_GNU_SOURCE
Chris Allegretta's avatar
Chris Allegretta committed
33
AC_PROG_CC
34
AC_PROG_LN_S
Chris Allegretta's avatar
Chris Allegretta committed
35
AC_ISC_POSIX
Jordi Mallach's avatar
Jordi Mallach committed
36
AC_SYS_LARGEFILE
Chris Allegretta's avatar
Chris Allegretta committed
37

38
dnl Internationalization macros.
David Lawrence Ramsey's avatar
David Lawrence Ramsey committed
39

40
41
42
AM_GNU_GETTEXT_VERSION(0.11.5)
AM_GNU_GETTEXT([external], [need-ngettext])

Chris Allegretta's avatar
Chris Allegretta committed
43
dnl Checks for header files.
David Lawrence Ramsey's avatar
David Lawrence Ramsey committed
44

Chris Allegretta's avatar
Chris Allegretta committed
45
AC_HEADER_STDC
46
AC_CHECK_HEADERS(fcntl.h getopt.h libintl.h limits.h regex.h termios.h wchar.h wctype.h)
47
AC_CHECK_HEADER(regex.h,
48
    AC_MSG_CHECKING([for broken regexec from glibc 2.2.3])
49
50
51
    AC_TRY_RUN([
#include <sys/types.h>
#include <regex.h>
52
53
54
55
56
57
58
59
60
61
int main(void)
{
    regex_t reg;
    size_t n = 1;
    regmatch_t r;
    regcomp(&reg, "\\<", 0);
    regexec(&reg, "", n, &r, 0);
    regfree(&reg);
    return 0;
}],
62
	AC_MSG_RESULT(no),
63
	AC_MSG_RESULT(yes)
64
	AC_DEFINE(BROKEN_REGEXEC, 1, [Define this if your regexec() function segfaults when passed an empty string under certain conditions, as the one from glibc 2.2.3 does.]),
65
	AC_MSG_RESULT([cross-compiling; assuming no])))
Chris Allegretta's avatar
Chris Allegretta committed
66

67
68
dnl Checks for options.

Chris Allegretta's avatar
Chris Allegretta committed
69
70
AC_ARG_ENABLE(debug, 
[  --enable-debug          Enable debugging (disabled by default)],
71
[if test x$enableval = xyes; then
72
    AC_DEFINE(DEBUG, 1, [Define this to enable nano debug messages and assert warnings.])
Chris Allegretta's avatar
Chris Allegretta committed
73
    debug_support=yes
74
fi])
Chris Allegretta's avatar
Chris Allegretta committed
75

76
if test x$debug_support != xyes; then
David Lawrence Ramsey's avatar
David Lawrence Ramsey committed
77
    AC_DEFINE(NDEBUG, 1, [Shut up the assert warnings :-)])
Chris Allegretta's avatar
Chris Allegretta committed
78
79
fi

80
AC_ARG_ENABLE(extra,
81
[  --enable-extra          Enable extra features, currently only easter eggs],
82
83
[if test x$enableval = xyes; then
    AC_DEFINE(NANO_EXTRA, 1, [Define this to enable the extra stuff.]) extra_support=yes
84
fi])
85

Chris Allegretta's avatar
Chris Allegretta committed
86
AC_ARG_ENABLE(tiny,
87
[  --enable-tiny           Disable features for the sake of size],
Chris Allegretta's avatar
Chris Allegretta committed
88
[if test x$enableval = xyes; then
89
    AC_DEFINE(NANO_SMALL, 1, [Define this to make the nano executable as small as possible.]) tiny_support=yes
90
    AC_DEFINE(DISABLE_BROWSER, 1, [Define this to disable the built-in file browser.]) 
91
    AC_DEFINE(DISABLE_HELP, 1, [Define this to disable the help menu.]) 
92
    AC_DEFINE(DISABLE_JUSTIFY, 1, [Define this to disable the justify routine.]) 
Chris Allegretta's avatar
Chris Allegretta committed
93
94
    AC_DEFINE(DISABLE_MOUSE, 1, [Define this to disable the mouse functions.]) 
    AC_DEFINE(DISABLE_OPERATINGDIR, 1, [Define this to disable setting of the operating directory (chroot of sorts).]) 
95
96
    AC_DEFINE(DISABLE_SPELLER, 1, [Define this to disable the use(full|less) spelling functions.]) 
    AC_DEFINE(DISABLE_TABCOMP, 1, [Define to disable the tab completion code Chris worked so hard on!]) 
97
fi])
Chris Allegretta's avatar
Chris Allegretta committed
98

99
100
AC_ARG_ENABLE(browser,
[  --disable-browser       Disable mini file browser],
101
[if test x$enableval != xyes; then
102
    AC_DEFINE(DISABLE_BROWSER, 1, [Define this to disable the built-in file browser.])
103
fi])
104

105
AC_ARG_ENABLE(help,
106
[  --disable-help          Disable help function],
107
[if test x$enableval != xyes; then
108
    AC_DEFINE(DISABLE_HELP, 1, [Define this to disable the help menu.])
109
fi])
110

111
112
AC_ARG_ENABLE(justify,
[  --disable-justify       Disable justify/unjustify function],
113
[if test x$enableval != xyes; then
114
    AC_DEFINE(DISABLE_JUSTIFY, 1, [Define this to disable the justify routine.]) 
115
fi])
116

117
118
AC_ARG_ENABLE(mouse,
[  --disable-mouse         Disable mouse support (and -m flag)],
119
[if test x$enableval != xyes; then
120
    AC_DEFINE(DISABLE_MOUSE, 1, [Define this to disable the mouse functions.])
121
fi])
122

123
124
AC_ARG_ENABLE(operatingdir,
[  --disable-operatingdir  Disable setting of operating directory (chroot of sorts)],
125
[if test x$enableval != xyes; then
126
    AC_DEFINE(DISABLE_OPERATINGDIR, 1, [Define this to disable setting of the operating directory (chroot of sorts).])
127
fi])
128

129
AC_ARG_ENABLE(speller,
130
[  --disable-speller       Disable spell checker function],
131
[if test x$enableval != xyes; then
132
    AC_DEFINE(DISABLE_SPELLER, 1, [Define this to disable the use(full|less) spelling functions.])
133
fi])
134

135
136
AC_ARG_ENABLE(tabcomp,
[  --disable-tabcomp       Disable tab completion code for a smaller binary],
137
[if test x$enableval != xyes; then
138
    AC_DEFINE(DISABLE_TABCOMP, 1, [Define to disable the tab completion code Chris worked so hard on!]) 
139
fi])
Chris Allegretta's avatar
Chris Allegretta committed
140

141
AC_ARG_ENABLE(wrapping,
142
[  --disable-wrapping      Disable all wrapping of text (and -w flag)],
143
[if test x$enableval != xyes; then
144
    AC_DEFINE(DISABLE_WRAPPING, 1, [Define this to disable any and all text wrapping.])
145
fi])
146

147
148
AC_ARG_ENABLE(wrapping-as-root,
[  --disable-wrapping-as-root  Disable wrapping of text as root by default],
149
[if test x$enableval != xyes; then
150
    AC_DEFINE(DISABLE_ROOTWRAP, 1, [Define this to disable wrapping as root by default.])
151
fi])
152

153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
AC_ARG_ENABLE(color,
[  --enable-color          Enable color and syntax highlighting],
[if test x$enableval = xyes; then
    AC_DEFINE(ENABLE_NANORC, 1, [Define this to use the .nanorc file.]) nanorc_support=yes
    AC_DEFINE(ENABLE_COLOR, 1, [Define this to have syntax highlighting, requires ENABLE_NANORC too!]) color_support=yes
    AC_MSG_WARN([
***********************************************************************
*** WARNING: Color support is far from perfect, but functional.     ***
*** Be careful with syntax in your .nanorc or nano may malfunction. ***
***********************************************************************
])
fi])

AC_ARG_ENABLE(multibuffer,
[  --enable-multibuffer    Enable multiple file buffers],
[if test x$enableval = xyes; then
    AC_DEFINE(ENABLE_MULTIBUFFER, 1, [Define this to enable multiple file buffers.]) multibuffer_support=yes
170
fi])
171

172
173
174
175
AC_ARG_ENABLE(nanorc,
[  --enable-nanorc         Enable use of .nanorc file],
[if test x$enableval = xyes; then
    AC_DEFINE(ENABLE_NANORC, 1, [Define this to use the .nanorc file.]) nanorc_support=yes
176
fi])
177

178
179
180
181
182
183
184
185
186
187
188
189
AC_ARG_ENABLE(all,
[  --enable-all            Enable ALL extra nano functionality (kitchen sink option)],
[if test x$enableval = xyes; then
    AC_DEFINE(ENABLE_NANORC, 1, [Define this to use the .nanorc file.]) nanorc_support=yes
    AC_DEFINE(ENABLE_COLOR, 1, [Define this to have syntax highlighting, requires ENABLE_NANORC too!]) color_support=yes
    AC_DEFINE(ENABLE_MULTIBUFFER, 1, [Define this to enable multiple file buffers.]) multibuffer_support=yes
    AC_DEFINE(NANO_EXTRA, 1, [Define this to enable the extra stuff.]) extra_support=yes
    AC_MSG_WARN([
***********************************************************************
*** WARNING: Color support is far from perfect, but functional.     ***
*** Be careful with syntax in your .nanorc or nano may malfunction. ***
***********************************************************************
190
    ])
191
192
fi])

193
194
195
196
197
198
199
200
201
202
203
AC_MSG_CHECKING([whether to enable UTF-8 support])
AC_ARG_ENABLE(utf8,
[  --enable-utf8           Enable UTF-8 support],
[if test x$enableval = xyes; then
    enable_utf8=yes
else
    enable_utf8=no
fi],
[enable_utf8=auto])
AC_MSG_RESULT($enable_utf8)

204
AC_MSG_CHECKING([whether to use slang])
Chris Allegretta's avatar
Chris Allegretta committed
205
206
207
208
209
210
211
212
213
214
CURSES_LIB_NAME=""
AC_ARG_WITH(slang,
[  --with-slang[=DIR]      Use the slang library instead of curses],
[    case "$with_slang" in
    no)
	AC_MSG_RESULT(no)
	;;
    *)
	AC_MSG_RESULT(yes)

215
	if test x$with_slang != xyes; then
216
217
218
219
	    # Add additional search path
	    LDFLAGS="-L$with_slang/lib $LDFLAGS"
	    CPPFLAGS="-I$with_slang/include $CPPFLAGS"
	fi
Chris Allegretta's avatar
Chris Allegretta committed
220

221
	if test x$enable_utf8 != xno; then
222
223
224
225
226
	    AC_CHECK_HEADER(slcurses.h,
		AC_MSG_CHECKING([for SLutf8_enable in -lslang])
		_libs=$LIBS
		LIBS="$LIBS -lslang"
		AC_TRY_RUN([
227
#include <slcurses.h>
228
int main(void)
229
230
231
232
{
    SLutf8_enable(TRUE);
    return 0;
}],
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
		    [AC_MSG_RESULT(yes)
		    AC_DEFINE(USE_SLANG, 1, [Define to use the slang wrappers for curses instead of native curses.])
		    slang_support=yes
		    CURSES_LIB_WIDE=yes
		    if test x$with_slang != xyes; then
			CURSES_LIB="-L${with_slang}/lib -lslang"
		    else
			CURSES_LIB="-lslang"
		    fi
		    CURSES_LIB_NAME=slang],
		    [AC_MSG_RESULT(no)

		    # We might need the term library
		    for termlib in ncurses curses termcap terminfo termlib; do
			AC_CHECK_LIB([${termlib}], tputs, [tcap="-l$termlib"])
			test -n "$tcap" && break
		    done

		    AC_MSG_CHECKING([for SLutf8_enable in -lslang $tcap])
		    LIBS="$LIBS $tcap"
		    AC_TRY_RUN([
254
255
#include <slcurses.h>
int main(void)
256
{
257
    SLutf8_enable(TRUE);
258
259
    return 0;
}],
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
			[AC_MSG_RESULT(yes)
			AC_DEFINE(USE_SLANG, 1, [Define to use the slang wrappers for curses instead of native curses.])
			slang_support=yes
			CURSES_LIB_WIDE=yes
			if test x$with_slang != xyes; then
			    CURSES_LIB="-L${with_slang}/lib -lslang $tcap"
			else
			    CURSES_LIB="-lslang $tcap"
			fi
			CURSES_LIB_NAME=slang],
			[AC_MSG_RESULT(no)

			# We might need the math library
			AC_MSG_CHECKING([for SLutf8_enable in -lslang $tcap -lm])
			LIBS="$LIBS -lm"
			AC_TRY_RUN([
276
#include <slcurses.h>
277
int main(void)
278
279
280
281
{
    SLutf8_enable(TRUE);
    return 0;
}],
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
			    [AC_MSG_RESULT(yes)
			    AC_DEFINE(USE_SLANG, 1, [Define to use the slang wrappers for curses instead of native curses.])
			    slang_support=yes
			    CURSES_LIB_WIDE=yes
			    if test x$with_slang != xyes; then
				CURSES_LIB="-L${with_slang}/lib -lslang $tcap -lm"
			    else
				CURSES_LIB="-lslang $tcap -lm"
			    fi
			    CURSES_LIB_NAME=slang],
			    [AC_MSG_RESULT(no)],
    AC_MSG_WARN([*** Can not use slang when cross-compiling]))],
    AC_MSG_WARN([*** Can not use slang when cross-compiling]))],
    AC_MSG_WARN([*** Can not use slang when cross-compiling])),
	    AC_MSG_ERROR([
*** The header file slcurses.h was not found. If you wish to use
*** slang support this header file is required. Please either
*** install a version of slang that includes the slcurses.h file or
*** do not call the configure script with --with-slang
	    ]))
	fi

304
305
306
307
308
309
	if eval "test x$CURSES_LIB_NAME = x"; then
	    # Reset libs if the above slang tests failed
	    if test x$enable_utf8 != xno; then
		LIBS=$_libs
	    fi

310
311
312
313
314
	    AC_CHECK_HEADER(slcurses.h,
		AC_MSG_CHECKING([for SLtt_initialize in -lslang])
		_libs=$LIBS
		LIBS="$LIBS -lslang"
		AC_TRY_RUN([
315
316
#include <slcurses.h>
int main(void)
317
318
319
320
{
    SLtt_initialize(NULL);
    return 0;
}],
321
		    [AC_MSG_RESULT(yes)
322
		    AC_DEFINE(USE_SLANG, 1, [Define to use the slang wrappers for curses instead of native curses.])
323
		    slang_support=yes
324
325
		    if test x$with_slang != xyes; then
			CURSES_LIB="-L${with_slang}/lib -lslang"
326
		    else
327
			CURSES_LIB="-lslang"
328
		    fi
329
330
331
		    CURSES_LIB_NAME=slang],
		    [AC_MSG_RESULT(no)

332
333
334
335
336
337
338
339
		    # We might need the term library
		    for termlib in ncurses curses termcap terminfo termlib; do
			AC_CHECK_LIB([${termlib}], tputs, [tcap="-l$termlib"])
			test -n "$tcap" && break
		    done

		    AC_MSG_CHECKING([for SLtt_initialize in -lslang $tcap])
		    LIBS="$LIBS $tcap"
340
341
		    AC_TRY_RUN([
#include <slcurses.h>
342
int main(void)
343
{
344
    SLtt_initialize(NULL);
345
346
347
348
349
    return 0;
}],
			[AC_MSG_RESULT(yes)
			AC_DEFINE(USE_SLANG, 1, [Define to use the slang wrappers for curses instead of native curses.])
			slang_support=yes
350
351
			if test x$with_slang != xyes; then
			    CURSES_LIB="-L${with_slang}/lib -lslang $tcap"
352
			else
353
			    CURSES_LIB="-lslang $tcap"
354
355
			fi
			CURSES_LIB_NAME=slang],
356
357
358
			[AC_MSG_RESULT(no)

			# We might need the math library
359
			AC_MSG_CHECKING([for SLtt_initialize in -lslang $tcap -lm])
360
			LIBS="$LIBS -lm"
361
362
363
			AC_TRY_RUN([
#include <slcurses.h>
int main(void)
364
365
366
367
{
    SLtt_initialize(NULL);
    return 0;
}],
368
369
370
371
372
373
374
375
376
377
378
379
380
			    [AC_MSG_RESULT(yes)
			    AC_DEFINE(USE_SLANG, 1, [Define to use the slang wrappers for curses instead of native curses.])
			    slang_support=yes
			    if test x$with_slang != xyes; then
				CURSES_LIB="-L${with_slang}/lib -lslang $tcap -lm"
			    else
				CURSES_LIB="-lslang $tcap -lm"
			    fi
			    CURSES_LIB_NAME=slang],
			    [AC_MSG_RESULT(no)],
    AC_MSG_WARN([*** Can not use slang when cross-compiling]))],
    AC_MSG_WARN([*** Can not use slang when cross-compiling]))],
    AC_MSG_WARN([*** Can not use slang when cross-compiling])),
Chris Allegretta's avatar
Chris Allegretta committed
381
382
383
384
385
	    AC_MSG_ERROR([
*** The header file slcurses.h was not found. If you wish to use
*** slang support this header file is required. Please either
*** install a version of slang that includes the slcurses.h file or
*** do not call the configure script with --with-slang
386
387
	    ]))
	fi
Chris Allegretta's avatar
Chris Allegretta committed
388

389
390
391
	if test "${_libs+set}" = "set"; then
	    LIBS=$_libs
	fi
392

393
	if test x$with_slang != xyes; then
394
395
	    LDFLAGS=${_ldflags}
	fi
Chris Allegretta's avatar
Chris Allegretta committed
396
	;;
397
    esac], [AC_MSG_RESULT(no)])
Chris Allegretta's avatar
Chris Allegretta committed
398

399
400
dnl Checks for functions.

401
AC_CHECK_FUNCS(getdelim getline isblank snprintf strcasecmp strcasestr strncasecmp strnlen vsnprintf)
402

403
if test x$enable_utf8 != xno; then
404
    AC_CHECK_FUNCS(iswalnum iswblank iswpunct iswspace mblen mbstowcs mbtowc wctomb wcwidth)
405
406
fi

407
if test x$ac_cv_func_snprintf = xno || test x$ac_cv_func_vsnprintf = xno; then
408
409
    AM_PATH_GLIB_2_0(2.0.0,,
	AC_MSG_ERROR([
410
*** snprintf() and/or vsnprintf() not found.  GLIB 2.x not found either.
Chris Allegretta's avatar
Chris Allegretta committed
411
*** You need both snprintf() and vsnprintf().  Alternatively you can
412
*** install the GLIB library which can be found at ftp://ftp.gtk.org/.]),
413
	glib)
Chris Allegretta's avatar
Chris Allegretta committed
414
415
416
417
418
419
420
421
422
423
fi

dnl Checks for typedefs, structures, and compiler characteristics.

dnl Checks for library functions.
AC_TYPE_SIGNAL
AC_FUNC_VPRINTF
AC_CHECK_FUNCS(getopt_long)

dnl Checks for libraries.
424
425

if eval "test x$CURSES_LIB_NAME = x"; then
426
    AC_CHECK_HEADERS(ncurses.h)
427

428
    if test x$enable_utf8 != xno; then
429
	AC_CHECK_LIB(ncursesw, get_wch, [CURSES_LIB="-lncursesw" CURSES_LIB_NAME=ncursesw CURSES_LIB_WIDE=yes])
430
431
    fi

432
    if eval "test x$CURSES_LIB_NAME = x"; then
433
	AC_CHECK_LIB(ncurses, initscr, [CURSES_LIB="-lncurses" CURSES_LIB_NAME=ncurses])
434
    fi
Chris Allegretta's avatar
Chris Allegretta committed
435
436
fi

437
if eval "test x$CURSES_LIB_NAME = x"; then
438
    AC_CHECK_HEADERS(curses.h)
439

440
    if test x$enable_utf8 != xno; then
441
	AC_CHECK_LIB(curses, get_wch, [CURSES_LIB="-lcurses" CURSES_LIB_NAME=curses CURSES_LIB_WIDE=yes])
442
443
    fi

444
    if eval "test x$CURSES_LIB_NAME = x"; then
445
446
	 AC_CHECK_LIB(curses, initscr, [CURSES_LIB="-lcurses" CURSES_LIB_NAME=curses])
    fi
Chris Allegretta's avatar
Chris Allegretta committed
447
448
fi

449
if eval "test x$CURSES_LIB_NAME = x"; then
Chris Allegretta's avatar
Chris Allegretta committed
450
    AC_MSG_WARN([
451
*** No curses lib available.  Consider getting the official ncurses
Chris Allegretta's avatar
Chris Allegretta committed
452
453
454
*** distribution from ftp://ftp.gnu.org/pub/gnu/ncurses if you get
*** errors compiling nano.])
else
455
    AC_MSG_RESULT([Using $CURSES_LIB_NAME as the curses library])
Chris Allegretta's avatar
Chris Allegretta committed
456
457
fi

458
AC_CHECK_LIB([$CURSES_LIB_NAME], use_default_colors, AC_DEFINE(HAVE_USE_DEFAULT_COLORS, 1, [Define this if your curses library has the use_default_colors command.]))
459

460
dnl Parse any configure options.
Chris Allegretta's avatar
Chris Allegretta committed
461
462

LIBS="$LIBS $CURSES_LIB"
Chris Allegretta's avatar
Chris Allegretta committed
463

Chris Allegretta's avatar
Chris Allegretta committed
464
465
AC_SUBST(CURSES_LIB)

466
if test "x$GLIB_CFLAGS" != "x"; then
467
    CFLAGS="$CFLAGS $GLIB_CFLAGS"
Chris Allegretta's avatar
Chris Allegretta committed
468
fi
469
if test "x$GLIB_LIBS" != "x"; then
470
    LDFLAGS="$LDFLAGS $GLIB_LIBS"
Chris Allegretta's avatar
Chris Allegretta committed
471
472
fi

473
if test x$enable_utf8 != xno && \
David Lawrence Ramsey's avatar
David Lawrence Ramsey committed
474
475
476
477
478
479
480
481
482
    test x$CURSES_LIB_WIDE = xyes && \
    test x$ac_cv_func_iswalnum = xyes && \
    test x$ac_cv_func_iswpunct = xyes && \
    (test x$ac_cv_func_iswblank = xyes || test x$ac_cv_func_iswspace = xyes) && \
    test x$ac_cv_func_mblen = xyes && \
    test x$ac_cv_func_mbstowcs = xyes && \
    test x$ac_cv_func_mbtowc = xyes && \
    test x$ac_cv_func_wctomb = xyes && \
    test x$ac_cv_func_wcwidth = xyes; then
483
	AC_DEFINE(NANO_WIDE, 1, [Define this if your system has sufficient wide character support (a wide curses library, iswalnum(), iswpunct(), iswblank() or iswspace(), mblen(), mbstowcs(), mbtowc(), wctomb(), and wcwidth()).])
484
else
485
    if test x$enable_utf8 = xyes; then
486
487
488
489
490
491
	AC_MSG_ERROR([
*** UTF-8 support was requested, but insufficient UTF-8 support was
*** detected in your curses and/or C libraries.  Please verify that your
*** slang was built with UTF-8 support or your curses was built with
*** wide character support, and that your C library was built with wide
*** character support.])
492
    elif test x$enable_utf8 != xno; then
493
494
495
496
497
498
499
	AC_MSG_WARN([
*** Insufficient UTF-8 support was detected in your curses and/or C
*** libraries.  If you want UTF-8 support, please verify that your slang
*** was built with UTF-8 support or your curses was built with wide
*** character support, and that your C library was built with wide
*** character support.])
    fi
500
501
fi

Jordi Mallach's avatar
Jordi Mallach committed
502
503
504
505
506
507
508
509
510
511
512
513
AC_CONFIG_FILES([
Makefile
doc/Makefile
doc/man/Makefile
doc/man/fr/Makefile
doc/texinfo/Makefile
m4/Makefile
po/Makefile.in
src/Makefile
nano.spec
])

Jordi Mallach's avatar
Jordi Mallach committed
514
AC_OUTPUT