Support for new Solaris/OpenIndiana versions

This commit is contained in:
Ulrich Wilkens
2015-05-09 00:14:52 +02:00
committed by Jon Trulson
parent 0306c7c6f2
commit 2b8b5f25b5
14 changed files with 21 additions and 616 deletions

View File

@@ -1729,7 +1729,7 @@ do_round(double result, int ndigits)
int temp;
if (isnan(result)) return result;
#if defined(_AIX) || defined(__aix) || defined(__osf__)
#if defined(_AIX) || defined(__aix) || defined(__osf__) || defined(__sparc)
temp = finite(result);
if (!temp)
return (temp > 0) ? HUGE : -HUGE;
@@ -1849,7 +1849,7 @@ try_compute_i(double guess, double *result, int method)
new_w = w - f / f_prime;
#if defined(_AIX) || defined(__aix) || defined (__osf__)
#if defined(_AIX) || defined(__aix) || defined (__osf__) || defined(__sparc)
if (!(!isnan(new_w) && finite(new_w)))
return FALSE;
#else

View File

@@ -85,7 +85,7 @@ NormalProgramTarget($(PROGRAM),$(OBJS),,$(LOCAL_LIBRARIES),)
.y.c:
$(YACC) -d $(YFLAGS) $<
sed -e "s/yy/yyy/g" -e "\a# linea D" y.tab.c > $*.c
sed -e "s/yy/yyy/g" -e "/# line/d" y.tab.c > $*.c
sed s/yy/yyy/g y.tab.h > $*.h
$(RM) y.tab.c y.tab.h

View File

@@ -57,7 +57,10 @@ XCOMM ##########################################################################
#elif defined (__hpux)
# define cpp_XDMSYS "/usr/lib/X11/xdm/sys.xsession"
#elif defined (sun)
# define cpp_XINITUSER "$HOME/.xinitrc"
# define cpp_MAIL "/var/mail/$USER"
# undef cpp_HELLO
# define cpp_HELLO "$DT_BINPATH/dthello -file $DT_INSTALL/copyright &"
#endif
#ifdef __osf__

View File

@@ -117,7 +117,7 @@
#define DEF_NLS_DIR "/usr/lib/nls/loc"
#elif defined(hpV4)
#define DEF_NLS_DIR "/usr/lib/nls/msg"
#elif defined(sun) || defined(__uxp__) || defined(USL)
#elif defined(__uxp__) || defined(USL)
#define DEF_NLS_DIR "/usr/lib/locale"
#else
#define DEF_NLS_DIR CDE_INSTALLATION_TOP "/lib/nls/msg"

View File

@@ -951,48 +951,6 @@ ScanNLSDir(char *dirname)
}
#endif /* __osf__obsoleted__ */
#elif defined(sun)
/*
* Scan for installed locales on Sun platform.
*/
{
DIR *dirp;
struct dirent *dp;
char* filename;
char path1[MAXPATHLEN], path2[MAXPATHLEN];
struct stat stat1, stat2;
int retval1, retval2;
/*
* To determin the fully installed locale list, check several locations.
*/
if((dirp = opendir(DEF_X11_NLS_SHARE_DIR)) != NULL)
{
while((dp = readdir(dirp)) != NULL)
{
filename = dp->d_name;
if ( filename[0] != '.' &&
(int)(strlen(languageList) +
strlen(filename) + 2) < LANGLISTSIZE)
{
(void) sprintf(path1, "%s/%s", DEF_X11_NLS_LIB_DIR, filename);
(void) sprintf(path2, "%s/%s", dirname, filename);
retval1 = stat(path1, &stat1);
retval2 = stat(path2, &stat2);
if ( retval1==0 && retval2==0 &&
S_ISDIR(stat1.st_mode) && S_ISDIR(stat2.st_mode) )
{
strcat(languageList, " ");
strcat(languageList, filename);
}
}
}
closedir(dirp);
}
}
#elif defined(__uxp__) || defined(USL)
#define LC_COLLATE "LC_COLLATE"

View File

@@ -35,7 +35,7 @@ EXTRA_CCOPTIONS += -DSPRO_V2
# endif /* USE_SPRO_V3 */
EXTRA_C++OPTIONS = +p +w $(SPRO_V3_OPTIONS)
MT_LIBS = -i $(C++_LIB) -lm -lw -lc
MT_LIBS = $(C++_LIB) -lm -lw -lc
SYS_LIBRARIES = -lintl -lnsl $(MT_LIBS)
#endif /* SunArchitecture */

View File

@@ -122,7 +122,6 @@ M4 = /bin/m4
CXXOPTIONS = \
-DSP_VOLATILE= -DSP_CONST= \
-DSP_HAVE_LOCALE -DSP_MULTI_BYTE -DSP_ANSI_CLASS_INST
EXTRA_INCLUDES = -I/opt/SUNWspro/SC2.0.1/include/CC
/*
* Flags passed into compile step when doing manual template instantiation.

View File

@@ -28,7 +28,7 @@
#include <stdlib.h>
#include "macros.h"
#ifdef __GNUG__
#if defined(__GNUG__) && !defined(sun)
void exit(int) __attribute__((noreturn));
#endif