Fix for boolean-related build breakage on Solaris 2.3.

git-svn-id: svn://10.0.0.236/trunk@56249 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
briano%netscape.com
1999-12-20 23:58:25 +00:00
parent 52bef58939
commit 9098313412
4 changed files with 31 additions and 4 deletions

View File

@@ -27,7 +27,7 @@ VPATH = @srcdir@
include $(DEPTH)/config/autoconf.mk
LIBRARY_NAME = nsjpg
IS_COMPONENT = 1
IS_COMPONENT = 1
REQUIRES += util jpeg xpcom img
@@ -52,3 +52,11 @@ endif
include $(topsrcdir)/config/rules.mk
ifeq ($(OS_ARCH)$(OS_RELEASE),SunOS5)
ifeq ($(shell uname -r),5.3)
# In this special case (jpeg.cpp), the compiler has to know
# the OS version to a finer granularity than normal.
DEFINES += -DOSMINOR=3
endif
endif

View File

@@ -22,7 +22,7 @@
/*
* jpeg.c --- Glue code to Independent JPEG Group decoder library
* $Id: jpeg.cpp,v 1.13 1999-12-03 01:05:41 pnunn%netscape.com Exp $
* $Id: jpeg.cpp,v 1.14 1999-12-20 23:58:23 briano%netscape.com Exp $
*/
@@ -40,6 +40,12 @@
# include <sys/types.h>
#endif
/* This is a lame hack to get around a problem with boolean on Solaris 2.3 */
#if defined(__sun) && defined(__sparc) && defined(__svr4__) && (OSMINOR == 3)
#define HAVE_BOOLEAN
#undef MUST_UNDEF_HAVE_BOOLEAN_AFTER_INCLUDES
#endif
PR_BEGIN_EXTERN_C
#include "jpeglib.h"
#include "jerror.h"

View File

@@ -54,6 +54,13 @@ override NO_STATIC_LIB=
include $(topsrcdir)/config/rules.mk
ifeq ($(OS_ARCH), Linux)
DEFINES += -D_BSD_SOURCE -D_XOPEN_SOURCE=500
ifeq ($(OS_ARCH),Linux)
DEFINES += -D_BSD_SOURCE -D_XOPEN_SOURCE=500
endif
ifeq ($(OS_ARCH)$(OS_RELEASE),SunOS5)
ifeq ($(shell uname -r),5.3)
# In this special case (dither.cpp), the compiler has to know
# the OS version to a finer granularity than normal.
DEFINES += -DOSMINOR=3
endif
endif

View File

@@ -23,6 +23,12 @@
#include "if.h"
#include "il.h"
/* This is a lame hack to get around a problem with boolean on Solaris 2.3 */
#if defined(__sun) && defined(__sparc) && defined(__svr4__) && (OSMINOR == 3)
#define HAVE_BOOLEAN
#undef MUST_UNDEF_HAVE_BOOLEAN_AFTER_INCLUDES
#endif
#include "jpeglib.h"
#include "jerror.h"
#include "nsCRT.h"