1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146
|
/*
*
* This file is part of the XForms library package.
*
* XForms is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1, or
* (at your option) any later version.
*
* XForms 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
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with XForms; see the file COPYING. If not, write to
* the Free Software Foundation, 59 Temple Place - Suite 330, Boston,
* MA 02111-1307, USA.
*
*/
/*
* $Id: local.h,v 1.0 2002/05/08 05:16:30 zhao Release $
*
*.
* This file is part of the XForms library package.
* Copyright (c) 1996-1998 T.C. Zhao and Mark Overmars
* All rights reserved.
*.
* Some machine specific stuff.
*
* if sprintf returns char *, need to define BAD_SPRINTF
*
*/
#ifndef FL_LOCAL_H
#define FL_LOCAL_H /* { */
#ifndef _WIN32
#include <unistd.h>
#endif
#if defined(_WIN32)
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
#define HAVE_SNPRINTF
#endif
/* solaris: do we need to check the version number ? */
#if defined(__SUNPRO_C) && __SUNPRO_C >=0x500
#define HAVE_SNPRINTF
#endif
#if defined(Lynx)
#define NEED_GETCWD
#endif
#if defined(__VMS)
#define NEED_GETCWD
#if __VMS_VER < 70000000
struct timezone
{
int tz_minuteswest; /* minutes west of Greenwich */
int tz_dsttime; /* type of dst correction */
};
extern int gettimeofday(struct timeval *tv, struct timezone *tz);
#endif /* ___VMS_VER */
#endif /* __VMS */
/* (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
#ifdef PATH_MAX
#define FL_PATH_MAX PATH_MAX
#else
#define FL_PATH_MAX 1024
#endif
#endif /* FL_PATH_MAX */
#ifndef FL_FLEN
#define FL_FLEN 256
#endif
/* There are two ways to handle motion events, one is to constantly
* query the server for mouse position, and the other is to use
* motion events. The first way obviously is slow and expensive
* if runs across network. The latter however suffers with stepping
* events.
*/
/*#define NO_MSG_INFO */
#ifdef HAVE_SNPRINTF
#define fl_snprintf snprintf
#else
extern int fl_snprintf(char *, size_t, const char *, ...);
#endif
#endif /* ifndef local.h } */
|