From 7f89e78fd32b31f93a33318c30c9b00173ffe5ae Mon Sep 17 00:00:00 2001 From: Wichert Akkerman Date: Sun, 12 Dec 1999 23:44:46 +0000 Subject: [PATCH] dselect/main.cc: We need to printf programdesc as well autogen.sh: Remove libtoolize call automake/sysconf.m4: new autoconf-macros for sysconf filesdb/main.c: also check MEMINFO_IN_SYSINFO configure.in: remove ugly sysinfo-hacks to use new ac macros instead utils/start-stop-daemon.c: modify to build on sunos --- ChangeLog | 11 ++++++++++- acconfig.h | 6 ++++++ autogen.sh | 1 - configure.in | 30 ++---------------------------- debian/changelog | 3 ++- dselect/main.cc | 3 ++- main/filesdb.c | 2 +- utils/start-stop-daemon.c | 10 ++++++++-- 8 files changed, 31 insertions(+), 35 deletions(-) diff --git a/ChangeLog b/ChangeLog index 07fa65a5..88a6ffa2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,13 @@ -Sun Dec 12 17:20:12 CET 1999 +Sun Dec 12 23:59:25 CET 1999 Wichert Akkerman + + * dselect/main.cc: We need to printf programdesc as well + * autogen.sh: Remove libtoolize call + * automake/sysconf.m4: new autoconf-macros for sysconf + * filesdb/main.c: also check MEMINFO_IN_SYSINFO + * configure.in: remove ugly sysinfo-hacks to use new ac macros instead + * utils/start-stop-daemon.c: modify to build on sunos + +Sun Dec 12 17:20:12 CET 1999 Wichert Akkerman * Update the Swedish translation * start-stop-daemon.c: check exitnodo-flag if we fail to kill a diff --git a/acconfig.h b/acconfig.h index 281d27f0..a194cbf7 100644 --- a/acconfig.h +++ b/acconfig.h @@ -63,3 +63,9 @@ /* Defined to the $(libdir) location */ #undef LLIBDIR +/* Is sysinfo() persent */ +#undef HAVE_SYSINFO + +/* Do we have proper memory information in struct sysinfo */ +#undef MEMINFO_IN_SYSINFO + diff --git a/autogen.sh b/autogen.sh index 279a37ef..5dbd9a44 100755 --- a/autogen.sh +++ b/autogen.sh @@ -5,6 +5,5 @@ copy=$1 # Start by setting up everything for main tree aclocal -I ./automake gettextize $copy -f -libtoolize --force $copy autoheader autoconf diff --git a/configure.in b/configure.in index 571f6295..cd2713c8 100644 --- a/configure.in +++ b/configure.in @@ -84,21 +84,8 @@ AC_CHECK_HEADERS(error.h hurd.h ps.h hurd/ihash.h) AC_CHECK_LIB(shouldbeinlibc, fmt_past_time) AC_CHECK_LIB(ps, proc_stat_list_pid_proc_stat) -AC_CHECK_FUNC(sysinfo, - AC_DEFINE(HAVE_SYSINFO), - AC_MSG_CHECKING(__NR_sysinfo) - AC_EGREP_CPP(yes, [ -#include -#include -#include -#ifdef __NR_sysinfo - yes -#endif -], - AC_MSG_RESULT([yes; tsk tsk - get your libc fixed.]) - AC_DEFINE(HAVE_NRSYSINFO), - AC_MSG_RESULT(no) - AC_MSG_WARN([sysinfo missing; compilation of dpkg proper may fail.]))) +AC_HAVE_SYSINFO +AC_MEMINFO_IN_SYSINFO AC_SUBST(OPTCFLAGS) if test "${GCC-no}" = yes; then @@ -118,19 +105,6 @@ AC_TRY_COMPILE([ AC_TRY_COMPILE(,[ } inline int foo (int x) {], AC_DEFINE(HAVE_INLINE)) -AC_TRY_COMPILE(, - [extern int testfunction(int x) __attribute__((,,))], - AC_DEFINE(HAVE_GNUC25_ATTRIB) - AC_TRY_COMPILE(, - [extern int testfunction(int x) __attribute__((noreturn))], - AC_DEFINE(HAVE_GNUC25_NORETURN)) - AC_TRY_COMPILE(, - [extern int testfunction(int x) __attribute__((const))], - AC_DEFINE(HAVE_GNUC25_CONST)) - AC_TRY_COMPILE(, - [extern int testfunction(char *y, ...) __attribute__((format(printf,1,2)))], - AC_DEFINE(HAVE_GNUC25_PRINTFFORMAT)) - ) DPKG_C_GCC_TRY_WARNS(-Wall -Wno-implicit, dpkg_cv_c_gcc_warn_all) DPKG_C_GCC_TRY_WARNS(-Wwrite-strings, dpkg_cv_c_gcc_warn_writestrings) diff --git a/debian/changelog b/debian/changelog index 9c9f115a..66a43af2 100644 --- a/debian/changelog +++ b/debian/changelog @@ -3,7 +3,8 @@ dpkg (1.6.4) unstable; urgency=low * No longer byte-compile for emacs * Add Swedish translation * start-stop-daemon: honour --oknodo if we fail to kill a process - Closes: Bug# 52580 + Closes: Bug#52580,#52185 + * Fix dselect program description, Closes: Bug#52328 -- Wichert Akkerman UNRELEASED diff --git a/dselect/main.cc b/dselect/main.cc index 0d05e52c..2ab579c1 100644 --- a/dselect/main.cc +++ b/dselect/main.cc @@ -234,7 +234,8 @@ int refreshmenu(void) { clear(); attrset(A_BOLD); - mvaddnstr(0,0, gettext(programdesc),x-1); + sprintf(buf,gettext(programdesc),DSELECT); + mvaddnstr(0,0,buf,x-1); attrset(A_NORMAL); const struct menuentry *mep; int i; diff --git a/main/filesdb.c b/main/filesdb.c index 0754555b..3d390aa3 100644 --- a/main/filesdb.c +++ b/main/filesdb.c @@ -515,7 +515,7 @@ void iterfileend(struct fileiterator *i) { } static int autodetect_largemem(void) { -#ifdef HAVE_SYSINFO +#if defined(HAVE_SYSINFO) && defined (MEMINFO_IN_SYSINFO) struct sysinfo info; if (sysinfo(&info)) return 0; if (info.freeram + (info.sharedram>>2) + (info.bufferram>>2) < 24576*1024 && diff --git a/utils/start-stop-daemon.c b/utils/start-stop-daemon.c index 2588f14c..9d49f98b 100644 --- a/utils/start-stop-daemon.c +++ b/utils/start-stop-daemon.c @@ -21,6 +21,10 @@ #define OSLinux #endif +#ifdef sunos +#define OSsunos +#endif + #ifdef __GNU__ #define OSHURD #endif @@ -46,6 +50,7 @@ #include #include #include +#include #include #ifdef HAVE_ERROR_H @@ -472,8 +477,9 @@ do_pidfile(const char *name) } } - -#if defined(OSLinux) +/* WTA: this needs to be an autoconf check for /proc/pid existance. + */ +#if defined(OSLinux) || defined (OSsunos) static void do_procinit(void) { -- 2.39.5