? config.h.in Index: ChangeLog =================================================================== RCS file: /cvsroot/xforms/xforms/ChangeLog,v retrieving revision 1.42 diff -u -p -r1.42 ChangeLog --- ChangeLog 30 May 2003 11:04:56 -0000 1.42 +++ ChangeLog 5 Sep 2003 13:40:11 -0000 @@ -1,3 +1,26 @@ +2003-09-05 Jean-Marc Lasgouttes + + * lib/version.c (fl_print_version): remove workaround for XENIX + + * lib/local.h: remove NO_SOCK (who wants to support old SCO anyway?) + +2003-07-31 Jean-Marc Lasgouttes + + * lib/local.h (FL_SIGRET): + + * lib/signal.c (default_signal_handler): use RETSIGTYPE instead of + FL_SIG_RET + + * lib/errmsg.c (fl_get_syserror_msg): use HAVE_STRERROR + + * lib/sysdep.c (fl_msleep): use HAVE_USLEEP + + * lib/local.h: remove variables DONT_HAVE_USLEEP, + DONT_HAVE_STRERROR, NO_CONST (handled by AC_C_CONST), + FL_SIGRET_IS_VOID, FL_SIGRET + + * configure.ac: check for usleep too + 2003-05-23 Angus Leeming * image/rgb_db.c: follow Rouben Rostamian's advice and remove all the Index: configure.ac =================================================================== RCS file: /cvsroot/xforms/xforms/configure.ac,v retrieving revision 1.3 diff -u -p -r1.3 configure.ac --- configure.ac 22 May 2003 17:47:15 -0000 1.3 +++ configure.ac 5 Sep 2003 13:40:11 -0000 @@ -84,7 +84,7 @@ AC_CHECK_HEADERS([fcntl.h float.h limits # Checks for typedefs, structures, and compiler characteristics. AC_HEADER_STAT -AC_C_CONST +AC_C_CONST dnl used AC_TYPE_PID_T AC_TYPE_SIZE_T AC_HEADER_TIME @@ -93,11 +93,11 @@ AC_STRUCT_TM # Checks for library functions. AC_FUNC_FORK AC_FUNC_MALLOC -AC_TYPE_SIGNAL +AC_TYPE_SIGNAL dnl used AC_FUNC_STAT AC_FUNC_STRTOD AC_FUNC_VPRINTF -AC_CHECK_FUNCS([dup2 endpwent floor ftime getcwd gethostname gettimeofday getwd memmove memset modf pow putenv select setlocale strcasecmp strchr strdup strerror strrchr strstr strtol]) +AC_CHECK_FUNCS([usleep dup2 endpwent floor ftime getcwd gethostname gettimeofday getwd memmove memset modf pow putenv select setlocale strcasecmp strchr strdup strerror strrchr strstr strtol]) AC_CHECK_FUNCS(snprintf vsnprintf) XFORMS_CHECK_DECL(snprintf, stdio.h) Index: lib/errmsg.c =================================================================== RCS file: /cvsroot/xforms/xforms/lib/errmsg.c,v retrieving revision 1.7 diff -u -p -r1.7 errmsg.c --- lib/errmsg.c 24 Apr 2003 09:35:34 -0000 1.7 +++ lib/errmsg.c 5 Sep 2003 13:40:11 -0000 @@ -58,7 +58,7 @@ char *id_errm = "$Id: errmsg.c,v 1.7 200 #include "ulib.h" extern int errno; /* system error no */ -#ifdef DONT_HAVE_STRERROR +#ifndef HAVE_STRERROR extern char *sys_errlist[]; #endif @@ -98,7 +98,7 @@ fl_set_error_handler( FL_ERROR_FUNC user const char *fl_get_syserror_msg(void) { const char *pp; -#ifndef DONT_HAVE_STRERROR +#ifdef HAVE_STRERROR pp = errno ? strerror(errno) : ""; #else pp = errno ? sys_errlist[errno]:""; Index: lib/flinternal.h =================================================================== RCS file: /cvsroot/xforms/xforms/lib/flinternal.h,v retrieving revision 1.3 diff -u -p -r1.3 flinternal.h --- lib/flinternal.h 17 Apr 2003 11:48:17 -0000 1.3 +++ lib/flinternal.h 5 Sep 2003 13:40:11 -0000 @@ -353,7 +353,7 @@ typedef struct fl_freelist_ } FL_FREE_REC; -typedef FL_SIGRET(*FL_OSSIG_HANDLER) (int); +typedef RETSIGTYPE(*FL_OSSIG_HANDLER) (int); typedef struct fl_signallist_ { Index: lib/listdir.c =================================================================== RCS file: /cvsroot/xforms/xforms/lib/listdir.c,v retrieving revision 1.5 diff -u -p -r1.5 listdir.c --- lib/listdir.c 24 Apr 2003 09:35:34 -0000 1.5 +++ lib/listdir.c 5 Sep 2003 13:40:11 -0000 @@ -184,10 +184,8 @@ mode2type(unsigned mode, int *type) *type = FT_FILE; else if (S_ISLNK(mode)) *type = FT_LINK; -#if !defined(NO_SOCK) /* only old SCO */ else if (S_ISSOCK(mode)) *type = FT_SOCK; -#endif else if (S_ISFIFO(mode)) *type = FT_FIFO; else if (S_ISCHR(mode)) Index: lib/local.h =================================================================== RCS file: /cvsroot/xforms/xforms/lib/local.h,v retrieving revision 1.5 diff -u -p -r1.5 local.h --- lib/local.h 30 May 2003 10:09:37 -0000 1.5 +++ lib/local.h 5 Sep 2003 13:40:11 -0000 @@ -41,19 +41,6 @@ extern int strcasecmp(const char *, const char *); #endif -#define DONT_HAVE_USLEEP - -#define FL_SIGRET_IS_VOID -#define FL_SIGRET void - -#if defined(__linux__)||defined(linux) -#undef DONT_HAVE_USLEEP -#endif - -/* solaris: do we need to check the version number ? */ -#if defined(__SUNPRO_C) && __SUNPRO_C >=0x500 -#endif - #if defined(Lynx) #define NEED_GETCWD #endif @@ -76,39 +63,15 @@ extern int gettimeofday(struct timeval * /* (some) suns do not have strerror, use sys_errlist */ #if ( defined(sun) || defined(__sun__) ) && !defined( SYSV ) -#define DONT_HAVE_STRERROR -#define DONT_HAVE_ATEXIT #define BAD_SPRINTF /* returns char * */ #endif -/*#if defined(__sgi) - #endif - */ - -/* #if defined(_HPUX_SOURCE) - #endif - */ - -#if defined(M_XENIX) -#define NO_SOCK -#endif - -/* #define NO_CONST */ - -/* prototype is currently required */ - -/* #define NO_PROTOTYPE */ /********* End of Configurable stuff ***********/ /* some header has XK_XP_Left etc */ #if (XlibSpecificationRelease>=6) #define HAVE_KP_DEFINE 1 -#endif - -#ifdef NO_CONST -#undef const -#define const #endif #ifndef FL_PATH_MAX Index: lib/signal.c =================================================================== RCS file: /cvsroot/xforms/xforms/lib/signal.c,v retrieving revision 1.5 diff -u -p -r1.5 signal.c --- lib/signal.c 24 Apr 2003 09:35:35 -0000 1.5 +++ lib/signal.c 5 Sep 2003 13:40:11 -0000 @@ -63,7 +63,7 @@ handle_signal(void) static int sig_direct; -static FL_SIGRET +static RETSIGTYPE default_signal_handler(int sig) { fl_signal_caught(sig); @@ -78,10 +78,8 @@ default_signal_handler(int sig) exit(sig); } -#if !defined(M_XENIX) && !defined(_WIN32) -#if !defined( FL_SIGRET_IS_VOID ) +#if RETSYGTYPE != void return 0; -#endif #endif } Index: lib/sysdep.c =================================================================== RCS file: /cvsroot/xforms/xforms/lib/sysdep.c,v retrieving revision 1.5 diff -u -p -r1.5 sysdep.c --- lib/sysdep.c 24 Apr 2003 09:35:35 -0000 1.5 +++ lib/sysdep.c 5 Sep 2003 13:40:11 -0000 @@ -140,7 +140,7 @@ fl_msleep(unsigned long msec) _sleep(msec); return 0; #else -#if !defined(DONT_HAVE_USLEEP) +#ifdef HAVE_USLEEP usleep(msec * 1000); return 0; #else Index: lib/version.c =================================================================== RCS file: /cvsroot/xforms/xforms/lib/version.c,v retrieving revision 1.10 diff -u -p -r1.10 version.c --- lib/version.c 24 Apr 2003 09:35:35 -0000 1.10 +++ lib/version.c 5 Sep 2003 13:40:11 -0000 @@ -77,19 +77,14 @@ void fl_print_version(int g) { char tmp[100]; -#ifndef M_XENIX const char *p[5], **q = version; -#else - char *p[5], **q = (char **) version; -#endif int n; fl_snprintf(tmp, 100, "FORMS Library Version %d.%d", FL_VERSION, FL_REVISION); p[0] = tmp; for (n = 1; *q; n++, q++) { - /* SCO compiler needs the cast */ - p[n] = (char *) fl_rm_rcs_kw(*q); + p[n] = fl_rm_rcs_kw(*q); } if (g) {