diff options
-rw-r--r-- | ChangeLog | 11 | ||||
-rw-r--r-- | Makefile | 4 | ||||
-rw-r--r-- | aclocal.m4 | 55 | ||||
-rw-r--r-- | config.make.in | 4 | ||||
-rw-r--r-- | configure.in | 5 | ||||
-rw-r--r-- | console/ChangeLog | 5 | ||||
-rw-r--r-- | console/Makefile | 2 | ||||
-rw-r--r-- | console/console.c | 4 | ||||
-rw-r--r-- | console/display.c | 2 | ||||
-rw-r--r-- | hurd/ChangeLog | 5 | ||||
-rw-r--r-- | hurd/Makefile | 3 | ||||
-rw-r--r-- | utils/ChangeLog | 11 | ||||
-rw-r--r-- | utils/Makefile | 15 |
13 files changed, 117 insertions, 9 deletions
@@ -1,3 +1,14 @@ +2002-08-22 Marcus Brinkmann <marcus@gnu.org> + + * aclocal.m4 (hurd_LIB_NCURSESW): New test, modified from GNU + inetutils 1.4.0. + * configure.in: Use hurd_LIB_NCURSESW. + * config.make.in (LIBNCURSESW): New variable, substituted by + configure. + (NCURSESW_INCLUDE): Likewise. + * Makefile (lib-subdirs): Add libcons. + (prog-subdirs): Add console. + 2002-06-14 Roland McGrath <roland@frob.com> * Makeconf (cleantarg): Add $(libname).so.$(hurd-version). @@ -30,13 +30,13 @@ DIST_FILES = COPYING Makeconf config.make.in configure.in configure \ # Hurd libraries lib-subdirs = libshouldbeinlibc libihash libiohelp libports libthreads \ libpager libfshelp libdiskfs libtrivfs libps \ - libnetfs libpipe libstore libhurdbugaddr libftpconn + libnetfs libpipe libstore libhurdbugaddr libftpconn libcons # Hurd programs prog-subdirs = auth proc exec init term \ ufs ext2fs isofs nfs tmpfs \ storeio pflocal pfinet defpager mach-defpager \ - login daemons nfsd boot serverboot \ + login daemons nfsd boot serverboot console \ hostmux usermux ftpfs trans \ utils sutils ufs-fsck ufs-utils \ benchmarks fstests @@ -94,3 +94,58 @@ rm -f conftest*]) if test $hurd_cv_mig_retcode = yes; then AC_DEFINE(HAVE_MIG_RETCODE) fi]) + +dnl The following check is based on a similar check in GNU inetutils 1.4.0. +dnl +dnl hurd_LIB_NCURSESW -- check for, and configure, ncursesw +dnl +dnl If libncursesw is found to exist on this system and the --disable-ncursesw +dnl flag wasn't specified, defines LIBNCURSESW with the appropriate linker +dnl specification, and possibly defines NCURSESW_INCLUDE with the appropriate +dnl -I flag to get access to ncursesw include files. +dnl +AC_DEFUN([hurd_LIB_NCURSESW], [ + AC_ARG_ENABLE(ncursesw, [ --disable-ncursesw Do not use ncursesw], + , enable_ncursesw=yes) + if test "$enable_ncursesw" = yes; then + AC_CHECK_LIB(ncursesw, initscr, LIBNCURSESW="-lncursesw") + if test "$LIBNCURSESW"; then + AC_ARG_WITH(ncursesw-include-dir, +[ --with-ncursesw-include-dir=DIR + Set directory containing the include files for + use with -lncursesw, when it isn't installed as + the default curses library. If DIR is "none", + then no special ncursesw include files are used. + --without-ncursesw-include-dir + Equivalent to --with-ncursesw-include-dir=none])dnl + if test "${with_ncursesw_include_dir+set}" = set; then + AC_MSG_CHECKING(for ncursesw include dir) + case "$with_ncursesw_include_dir" in + no|none) + hurd_cv_includedir_ncursesw=none;; + *) + hurd_cv_includedir_ncursesw="$with_ncursesw_include_dir";; + esac + AC_MSG_RESULT($hurd_cv_includedir_ncursesw) + else + AC_CACHE_CHECK(for ncursesw include dir, + hurd_cv_includedir_ncursesw, + for D in $includedir $prefix/include /local/include /usr/local/include /include /usr/include; do + if test -d $D/ncursesw; then + hurd_cv_includedir_ncursesw="$D/ncursesw" + break + fi + test "$hurd_cv_includedir_ncursesw" \ + || hurd_cv_includedir_ncursesw=none + done) + fi + if test "$hurd_cv_includedir_ncursesw" = none; then + NCURSESW_INCLUDE="" + else + NCURSESW_INCLUDE="-I$hurd_cv_includedir_ncursesw" + fi + fi + fi + AC_SUBST(NCURSESW_INCLUDE) + AC_SUBST(LIBNCURSESW)])dnl + diff --git a/config.make.in b/config.make.in index a5e5632c..8a9ae22a 100644 --- a/config.make.in +++ b/config.make.in @@ -59,6 +59,10 @@ LIBCRYPT = @LIBCRYPT@ # How to link against Parted libraries, if at all. PARTED_LIBS = @PARTED_LIBS@ +# How to compile and link against ncursesw. +LIBNCURSESW = @LIBNCURSESW@ +NCURSESW_INCLUDE = @NCURSESW_INCLUDE@ + # Installation tools. INSTALL = @INSTALL@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ diff --git a/configure.in b/configure.in index c5cd14cd..91b178aa 100644 --- a/configure.in +++ b/configure.in @@ -1,5 +1,5 @@ dnl Process this file with autoconf to produce a configure script. -AC_REVISION([$Id: configure.in,v 1.32 2002/05/18 21:30:47 roland Exp $]) +AC_REVISION([$Id: configure.in,v 1.33 2002/08/22 21:25:03 marcus Exp $]) AC_PREREQ(2.12) dnl Minimum Autoconf version required. AC_INIT(hurd/hurd_types.h) dnl A distinctive file to look for in srcdir. @@ -178,6 +178,9 @@ AC_SUBST(boot_store_types)dnl AC_MSG_CHECKING(boot store types) AC_MSG_RESULT($boot_store_types) +# Check for ncursesw, which is needed for the console-curses client. +hurd_LIB_NCURSESW + if test -f ./$ac_unique_file; then # Configuring in source directory; don't create any Makefiles. makefiles= diff --git a/console/ChangeLog b/console/ChangeLog index 146451b2..462e998e 100644 --- a/console/ChangeLog +++ b/console/ChangeLog @@ -1,5 +1,10 @@ 2002-08-22 Marcus Brinkmann <marcus@gnu.org> + * console.h: Move file to ../hurd/. + * Makefile (LCLHDRS): Remove console.h. + * display.c: Include <hurd/console.h> instead "console.h". + * console.c: Likewise. + * display.h: Add prototype for display_get_size. * display.c (display_get_size): New function. (nowait_file_changed): Update for new interfaces. diff --git a/console/Makefile b/console/Makefile index 434d80e6..a7d47b85 100644 --- a/console/Makefile +++ b/console/Makefile @@ -24,7 +24,7 @@ makemode := server target = console SRCS = console.c display.c input.c -LCLHDRS = console.h display.h input.h priv.h mutations.h +LCLHDRS = display.h input.h priv.h mutations.h MIGSTUBS = notifyServer.o tioctlServer.o fs_notifyUser.o diff --git a/console/console.c b/console/console.c index b493f64e..204937f6 100644 --- a/console/console.c +++ b/console/console.c @@ -37,11 +37,11 @@ #include <hurd/netfs.h> #include <hurd/ioctl_types.h> +/* We include console.h for the color numbers. */ +#include <hurd/console.h> #include "display.h" #include "input.h" -/* We include console.h for the color numbers. */ -#include "console.h" #include "fs_notify_U.h" diff --git a/console/display.c b/console/display.c index fb0a6b0f..9af13f77 100644 --- a/console/display.c +++ b/console/display.c @@ -37,12 +37,12 @@ #include <hurd.h> #include <hurd/pager.h> +#include <hurd/console.h> #ifndef __STDC_ISO_10646__ #error It is required that wchar_t is UCS-4. #endif -#include "console.h" #include "display.h" diff --git a/hurd/ChangeLog b/hurd/ChangeLog index bb3949ae..00de9a94 100644 --- a/hurd/ChangeLog +++ b/hurd/ChangeLog @@ -1,3 +1,8 @@ +2002-08-22 Marcus Brinkmann <marcus@gnu.org> + + * console.h: Move here from ../console/. + * Makefile (INSTHDRS): Add console.h. + 2002-08-03 Marcus Brinkmann <marcus@gnu.org> * hurd_types.defs (fsys_statfsbuf_t): Bump size up to 22. diff --git a/hurd/Makefile b/hurd/Makefile index ea964446..66a6d287 100644 --- a/hurd/Makefile +++ b/hurd/Makefile @@ -1,4 +1,3 @@ -# # Copyright (C) 1993,94,95,96,99,2002 Free Software Foundation # # This program is free software; you can redistribute it and/or @@ -21,7 +20,7 @@ makemode := misc hdrs = $(wildcard $(srcdir)/*.defs $(srcdir)/*.h) DIST_FILES = subsystems $(notdir $(hdrs)) ioctl-tmpl.sym ioctl.awk gensym.awk -INSTHDRS = hurd_types.h version.h ioctl_types.h paths.h shared.h \ +INSTHDRS = hurd_types.h version.h ioctl_types.h paths.h shared.h console.h \ $(notdir $(wildcard $(srcdir)/*.defs)) include ../Makeconf diff --git a/utils/ChangeLog b/utils/ChangeLog index fb5a8db9..be04d8f2 100644 --- a/utils/ChangeLog +++ b/utils/ChangeLog @@ -1,3 +1,14 @@ +2002-08-22 Marcus Brinkmann <marcus@gnu.org> + + * Makefile: Include `../config.make' early on to get LIBNCURSESW + variable from configure before including Makeconf. + (targets) [LIBNCURSES]: Add console-ncurses. + (SRCS) [LIBNCURSES]: Add console-ncurses.c. + (HURDLIBS) [LIBNCURSES]: Add cons. + (console-ncurses): New target. + (console-ncurses-CPPFLAGS): New variable. + (console-ncurses-LDLIBS): Likewise. + 2002-08-18 Roland McGrath <roland@frob.com> * fakeroot.sh: Dont use "exec" command, since the original script diff --git a/utils/Makefile b/utils/Makefile index 06ef9bf2..3b2c12d7 100644 --- a/utils/Makefile +++ b/utils/Makefile @@ -18,6 +18,8 @@ dir := utils makemode := utilities +include ../config.make + targets = shd ps settrans showtrans syncfs fsysopts \ storeinfo login w uptime ids loginpr sush vmstat portinfo \ devprobe vminfo addauth rmauth unsu setauth ftpcp ftpdir storecat \ @@ -31,8 +33,16 @@ SRCS = shd.c ps.c settrans.c syncfs.c showtrans.c addauth.c rmauth.c \ rpctrace.c mount.c gcore.c fakeauth.c fakeroot.sh LCLHDRS = psout.h parse.h pids.h frobauth.h +ifneq ($(LIBNCURSESW),) +targets += console-ncurses +SRCS += console-ncurses.c +endif + OBJS = $(filter-out %.sh,$(SRCS:.c=.o)) HURDLIBS = ps ihash store fshelp threads ports ftpconn shouldbeinlibc +ifneq ($(LIBNCURSESW),) +HURDLIBS += cons +endif login-LDLIBS = -lutil $(LIBCRYPT) addauth-LDLIBS = $(LIBCRYPT) setauth-LDLIBS = $(LIBCRYPT) @@ -75,6 +85,11 @@ fakeauth-CPPFLAGS = -I$(srcdir)/../auth authServer-CPPFLAGS = -I$(srcdir)/../auth auth_requestUser-CPPFLAGS = -I$(srcdir)/../auth +console-ncurses: ../libcons/libcons.a ../libports/libports.a \ + ../libthreads/libthreads.a +console-ncurses-CPPFLAGS = $(NCURSESW_INCLUDE) +console-ncurses-LDLIBS = $(LIBNCURSESW) + mount: ../sutils/fstab.o ../sutils/clookup.o \ $(foreach L,fshelp ports,../lib$L/lib$L.a) ../sutils/fstab.o ../sutils/clookup.o: FORCE |