summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwtc <devnull@localhost>1998-04-30 19:36:53 +0000
committerwtc <devnull@localhost>1998-04-30 19:36:53 +0000
commit8cd65b9f79376863fdfee8144800a77f6cc53d85 (patch)
treef1311f9a23566e24b343e16a7cf7d141fe85c9bc
parent1e332bf7c01e73848e01b7dc81a40efb2553afba (diff)
downloadnspr-hg-8cd65b9f79376863fdfee8144800a77f6cc53d85.tar.gz
Various makefile cleanups. On SCO OpenServer, the value of OS_ARCH
is now 'SCOOS' instead of 'SCO_SV'. Also, we just use the cpp macro 'SCO' and deleted the macro 'SCO_SV'. In pr/src/md/unix/Makefile, we do not assemble the ultrasparc assembly file if we are compiling with gcc.
-rw-r--r--config/SCOOS.mk5
-rw-r--r--config/SINIX.mk18
-rw-r--r--config/UNIXWARE.mk6
-rw-r--r--lib/ds/Makefile4
-rw-r--r--lib/libc/src/Makefile4
-rw-r--r--lib/msgc/src/Makefile4
-rw-r--r--lib/msgc/tests/Makefile4
-rw-r--r--lib/prstreams/Makefile4
-rw-r--r--lib/prstreams/tests/testprstrm/Makefile2
-rw-r--r--pr/include/md/Makefile2
-rw-r--r--pr/src/md/unix/Makefile18
-rw-r--r--pr/src/md/unix/objs.mk2
-rw-r--r--pr/src/md/unix/unix_errors.c20
-rw-r--r--pr/tests/Makefile4
-rw-r--r--tools/Makefile2
15 files changed, 54 insertions, 45 deletions
diff --git a/config/SCOOS.mk b/config/SCOOS.mk
index 9ac1cb07..c1d24468 100644
--- a/config/SCOOS.mk
+++ b/config/SCOOS.mk
@@ -17,6 +17,8 @@
#
# Config stuff for SCO OpenServer for x86.
+# SCO OpenServer 5, based on SVR3.2, is intended for small to
+# medium customers.
#
include $(MOD_DEPTH)/config/UNIX.mk
@@ -28,11 +30,10 @@ RANLIB = /bin/true
DEFINES += -D_PR_LOCAL_THREADS_ONLY
#
-# -DSCO_PM - Policy Manager AKA: SCO Licensing
# -DSCO - Changes to Netscape source (consistent with AIX, LINUX, etc..)
# -Dsco - Needed for /usr/include/X11/*
#
-OS_CFLAGS = -DSCO_SV -DSYSV -D_SVID3 -DHAVE_STRERROR -D_PR_NEED_H_ERRNO -DSCO_PM -DSCO -Dsco
+OS_CFLAGS = -DSYSV -D_SVID3 -DHAVE_STRERROR -D_PR_NEED_H_ERRNO -DSCO -Dsco
#OS_LIBS = -lpmapi -lsocket -lc
MKSHLIB = $(LD) $(DSO_LDOPTS)
diff --git a/config/SINIX.mk b/config/SINIX.mk
index 8e992692..61333672 100644
--- a/config/SINIX.mk
+++ b/config/SINIX.mk
@@ -16,7 +16,7 @@
#
#
-# Config stuff for SNI SINIX-N (aka ReliantUNIX)
+# Config stuff for SNI SINIX (aka ReliantUNIX)
#
include $(MOD_DEPTH)/config/UNIX.mk
@@ -24,7 +24,7 @@ include $(MOD_DEPTH)/config/UNIX.mk
# use gcc -tf-
NS_USE_GCC = 1
-ifdef NS_USE_GCC
+ifeq ($(NS_USE_GCC),1)
## gcc-2.7.2 homebrewn
CC = gcc
COMPILER_TAG = _gcc
@@ -36,8 +36,8 @@ ifdef BUILD_OPT
OPTIMIZER = -O
#OPTIMIZER = -O6
endif
-MKSHLIB = $(LD) -G -h $(@:$(OBJDIR)/%.so=%.so)
-DSO_LDOPTS = -G -Xlinker -Blargedynsym
+MKSHLIB = $(LD) -G -z defs -h $(@:$(OBJDIR)/%.so=%.so)
+#DSO_LDOPTS = -G -Xlinker -Blargedynsym
else
## native compiler (CDS++ 1.0)
CC = /usr/bin/cc
@@ -49,11 +49,11 @@ ifdef BUILD_OPT
#OPTIMIZER = -Olimit 4000
OPTIMIZER = -O -F Olimit,4000
endif
-MKSHLIB = $(CC) -G -h $(@:$(OBJDIR)/%.so=%.so)
-DSO_LDOPTS = -G -W l,-Blargedynsym
+MKSHLIB = $(LD) -G -z defs -h $(@:$(OBJDIR)/%.so=%.so)
+#DSO_LDOPTS = -G -W l,-Blargedynsym
endif
-ODD_CFLAGS += -DSVR4 -DSNI -DRELIANTUNIX -D_SVID_GETTOD
+ODD_CFLAGS += -DSVR4 -DSNI -DRELIANTUNIX -Dsinix -D_SVID_GETTOD
CPU_ARCH = mips
@@ -64,11 +64,9 @@ NOMD_OS_CFLAGS = $(ODD_CFLAGS)
# we do not have -MDupdate ...
OS_CFLAGS = $(NOMD_OS_CFLAGS)
-OS_LIBS = -lsocket -lnsl -lresolv -lgen -ldl -lc $(UCBLIB)
-UCBLIB = -L/usr/ucblib -lucb
+OS_LIBS = -lsocket -lnsl -lresolv -ldl -lc
NOSUCHFILE = /no-such-file
HAVE_PURIFY = 0
DEFINES += -D_PR_LOCAL_THREADS_ONLY
-OS_CFLAGS = $(ODD_CFLAGS) -DSVR4 -DSNI -Dsinix
diff --git a/config/UNIXWARE.mk b/config/UNIXWARE.mk
index e8b45c9c..f15a5a41 100644
--- a/config/UNIXWARE.mk
+++ b/config/UNIXWARE.mk
@@ -17,6 +17,12 @@
#
# Config stuff for SCO UnixWare
+# UnixWare is intended for high-end enterprise customers.
+# UnixWare 2.1 and 2.1.1 are based on SVR4. (2.1.2 is a maintenance
+# release.)
+# UnixWare 7 (codename Gemini) is based on what SCO calls SVR5.
+# The somewhat odd version number 7 was chosen to suggest that
+# UnixWare 2 + OpenServer 5 = UnixWare 7
#
include $(MOD_DEPTH)/config/UNIX.mk
diff --git a/lib/ds/Makefile b/lib/ds/Makefile
index 9c45c1b3..71effd21 100644
--- a/lib/ds/Makefile
+++ b/lib/ds/Makefile
@@ -69,14 +69,14 @@ EXTRA_LIBS = -L$(DIST)/lib -lnspr$(MOD_VERSION)
endif
endif
-# On NCR and SCO_SV, we can't link with extra libraries when
+# On NCR and SCOOS, we can't link with extra libraries when
# we build a shared library. If we do so, the linker doesn't
# complain, but we would run into weird problems at run-time.
# Therefore on these platforms, we link just the .o files.
ifeq ($(OS_ARCH),NCR)
EXTRA_LIBS =
endif
-ifeq ($(OS_ARCH),SCO_SV)
+ifeq ($(OS_ARCH),SCOOS)
EXTRA_LIBS =
endif
diff --git a/lib/libc/src/Makefile b/lib/libc/src/Makefile
index 978d3ae7..4bff96a7 100644
--- a/lib/libc/src/Makefile
+++ b/lib/libc/src/Makefile
@@ -75,14 +75,14 @@ EXTRA_LIBS = -L$(DIST)/lib -lnspr$(MOD_VERSION)
endif
endif
-# On NCR and SCO_SV, we can't link with extra libraries when
+# On NCR and SCOOS, we can't link with extra libraries when
# we build a shared library. If we do so, the linker doesn't
# complain, but we would run into weird problems at run-time.
# Therefore on these platforms, we link just the .o files.
ifeq ($(OS_ARCH),NCR)
EXTRA_LIBS =
endif
-ifeq ($(OS_ARCH),SCO_SV)
+ifeq ($(OS_ARCH),SCOOS)
EXTRA_LIBS =
endif
diff --git a/lib/msgc/src/Makefile b/lib/msgc/src/Makefile
index 39f3369a..91e25c31 100644
--- a/lib/msgc/src/Makefile
+++ b/lib/msgc/src/Makefile
@@ -73,14 +73,14 @@ EXTRA_LIBS = -L$(DIST)/lib -lnspr$(NSPR_VERSION)
endif
endif
-# On NCR and SCO_SV, we can't link with extra libraries when
+# On NCR and SCOOS, we can't link with extra libraries when
# we build a shared library. If we do so, the linker doesn't
# complain, but we would run into weird problems at run-time.
# Therefore on these platforms, we link just the .o files.
ifeq ($(OS_ARCH),NCR)
EXTRA_LIBS =
endif
-ifeq ($(OS_ARCH),SCO_SV)
+ifeq ($(OS_ARCH),SCOOS)
EXTRA_LIBS =
endif
diff --git a/lib/msgc/tests/Makefile b/lib/msgc/tests/Makefile
index 73fc9c81..12d751e4 100644
--- a/lib/msgc/tests/Makefile
+++ b/lib/msgc/tests/Makefile
@@ -181,7 +181,7 @@ EXTRA_LIBS = -ldl
endif
endif
-ifeq ($(OS_ARCH), SCO_SV)
+ifeq ($(OS_ARCH), SCOOS)
# SCO Unix needs to link against -lsocket again even though we
# already linked with these system libraries when we built libnspr.so.
EXTRA_LIBS = -lsocket
@@ -192,7 +192,7 @@ export LD_RUN_PATH = $(PWD)/$(DIST)/lib
endif
ifeq ($(OS_ARCH),SINIX)
-EXTRA_LIBS = -lsocket -lnsl -lgen -ldl -lresolv /usr/ucblib/libucb.a
+EXTRA_LIBS = -lsocket -lnsl -lresolv -ldl
# This hardcodes in the executable programs the directory to find
# libnspr.so etc. at program startup. Equivalent to the -R or -rpath
# option for ld on other platforms.
diff --git a/lib/prstreams/Makefile b/lib/prstreams/Makefile
index 28b7840e..164878de 100644
--- a/lib/prstreams/Makefile
+++ b/lib/prstreams/Makefile
@@ -78,14 +78,14 @@ EXTRA_LIBS = -L$(DIST)/lib -lnspr$(MOD_VERSION)
endif
endif
-# On NCR and SCO_SV, we can't link with extra libraries when
+# On NCR and SCOOS, we can't link with extra libraries when
# we build a shared library. If we do so, the linker doesn't
# complain, but we would run into weird problems at run-time.
# Therefore on these platforms, we link just the object files.
ifeq ($(OS_ARCH),NCR)
EXTRA_LIBS =
endif
-ifeq ($(OS_ARCH),SCO_SV)
+ifeq ($(OS_ARCH),SCOOS)
EXTRA_LIBS =
endif
diff --git a/lib/prstreams/tests/testprstrm/Makefile b/lib/prstreams/tests/testprstrm/Makefile
index 92c7c013..f17cb0d4 100644
--- a/lib/prstreams/tests/testprstrm/Makefile
+++ b/lib/prstreams/tests/testprstrm/Makefile
@@ -129,7 +129,7 @@ EXTRA_LIBS = -lsocket -lnsl -ldl
#export LD_RUN_PATH = $(PWD)/$(DIST)/lib
endif
-ifeq ($(OS_ARCH), SCO_SV)
+ifeq ($(OS_ARCH), SCOOS)
# SCO Unix needs to link against -lsocket again even though we
# already linked with these system libraries when we built libnspr.so.
EXTRA_LIBS = -lsocket
diff --git a/pr/include/md/Makefile b/pr/include/md/Makefile
index 589aa855..198f8554 100644
--- a/pr/include/md/Makefile
+++ b/pr/include/md/Makefile
@@ -87,7 +87,7 @@ ifeq ($(OS_ARCH),NEC)
MDCPUCFG_H = _nec.cfg
endif
-ifeq ($(OS_ARCH),SCO_SV)
+ifeq ($(OS_ARCH),SCOOS)
MDCPUCFG_H = _scoos.cfg
endif
diff --git a/pr/src/md/unix/Makefile b/pr/src/md/unix/Makefile
index e5fb34e5..2fb04575 100644
--- a/pr/src/md/unix/Makefile
+++ b/pr/src/md/unix/Makefile
@@ -146,7 +146,7 @@ endif
ifeq ($(OS_ARCH),NCR)
CSRCS += $(NCR_CSRCS)
endif
-ifeq ($(OS_ARCH),SCO_SV)
+ifeq ($(OS_ARCH),SCOOS)
CSRCS += $(SCOOS_CSRCS)
endif
@@ -191,11 +191,13 @@ endif
ifeq ($(OS_ARCH),SunOS)
ifneq ($(OS_RELEASE),4.1.3_U1)
ifeq ($(OS_TEST),sun4u)
- LIBRARY_NAME = $(ULTRASPARC_LIBRARY)
- LIBRARY_VERSION = $(MOD_VERSION)
- ULTRASPARC_ASFILES = os_$(OS_ARCH)_ultrasparc.s
- ULTRASPARC_ASOBJS = $(addprefix $(OBJDIR)/,$(ULTRASPARC_ASFILES:.s=.$(OBJ_SUFFIX)))
- TARGETS += $(ULTRASPARC_ASOBJS) $(SHARED_LIBRARY)
+ ifneq ($(NS_USE_GCC),1)
+ LIBRARY_NAME = $(ULTRASPARC_LIBRARY)
+ LIBRARY_VERSION = $(MOD_VERSION)
+ ULTRASPARC_ASFILES = os_$(OS_ARCH)_ultrasparc.s
+ ULTRASPARC_ASOBJS = $(addprefix $(OBJDIR)/,$(ULTRASPARC_ASFILES:.s=.$(OBJ_SUFFIX)))
+ TARGETS += $(ULTRASPARC_ASOBJS) $(SHARED_LIBRARY)
+ endif
endif
endif
endif
@@ -212,9 +214,11 @@ export:: $(TARGETS)
#endif
#endif
#endif
+
ifeq ($(OS_ARCH),SunOS)
ifneq ($(OS_RELEASE),4.1.3_U1)
ifeq ($(OS_TEST),sun4u)
+ifneq ($(NS_USE_GCC),1)
$(SHARED_LIBRARY): $(ULTRASPARC_ASOBJS)
$(LD) -G -z text -o $@ $(ULTRASPARC_ASOBJS)
$(INSTALL) -m 444 $(SHARED_LIBRARY) $(DIST)/lib
@@ -224,6 +228,6 @@ $(ULTRASPARC_ASOBJS): $(ULTRASPARC_ASFILES)
endif
endif
endif
-
+endif
install:: export
diff --git a/pr/src/md/unix/objs.mk b/pr/src/md/unix/objs.mk
index abb77d73..7de75fd3 100644
--- a/pr/src/md/unix/objs.mk
+++ b/pr/src/md/unix/objs.mk
@@ -139,7 +139,7 @@ endif
ifeq ($(OS_ARCH),NCR)
CSRCS += $(NCR_CSRCS)
endif
-ifeq ($(OS_ARCH),SCO_SV)
+ifeq ($(OS_ARCH),SCOOS)
CSRCS += $(SCOOS_CSRCS)
endif
diff --git a/pr/src/md/unix/unix_errors.c b/pr/src/md/unix/unix_errors.c
index 802125e3..793cbaed 100644
--- a/pr/src/md/unix/unix_errors.c
+++ b/pr/src/md/unix/unix_errors.c
@@ -670,9 +670,9 @@ void _MD_unix_map_socket_error(int err)
case EACCES:
PR_SetError(PR_NO_ACCESS_RIGHTS_ERROR, err);
break;
-#if !defined(SCO_SV)
+#if !defined(SCO)
case ENOBUFS:
-#endif /* !defined(SCO_SV) */
+#endif /* !defined(SCO) */
case ENOMEM:
#ifdef ENOSR
case ENOSR:
@@ -786,11 +786,11 @@ void _MD_unix_map_send_error(int err)
case EINVAL:
PR_SetError(PR_INVALID_ARGUMENT_ERROR, err);
break;
-#if !defined(SCO_SV)
+#if !defined(SCO)
case ENOBUFS:
PR_SetError(PR_INSUFFICIENT_RESOURCES_ERROR, err);
break;
-#endif /* !defined(SCO_SV) */
+#endif /* !defined(SCO) */
case ECONNREFUSED:
PR_SetError(PR_CONNECT_REFUSED_ERROR, err);
break;
@@ -840,11 +840,11 @@ void _MD_unix_map_sendto_error(int err)
case EINVAL:
PR_SetError(PR_INVALID_ARGUMENT_ERROR, err);
break;
-#if !defined(SCO_SV)
+#if !defined(SCO)
case ENOBUFS:
PR_SetError(PR_INSUFFICIENT_RESOURCES_ERROR, err);
break;
-#endif /* !defined(SCO_SV) */
+#endif /* !defined(SCO) */
case ECONNREFUSED:
PR_SetError(PR_CONNECT_REFUSED_ERROR, err);
break;
@@ -1174,9 +1174,9 @@ void _MD_unix_map_getsockname_error(int err)
case EFAULT:
PR_SetError(PR_ACCESS_FAULT_ERROR, err);
break;
-#if !defined(SCO_SV)
+#if !defined(SCO)
case ENOBUFS:
-#endif /* !defined(SCO_SV) */
+#endif /* !defined(SCO) */
case ENOMEM:
#ifdef ENOSR
case ENOSR:
@@ -1205,9 +1205,9 @@ void _MD_unix_map_getpeername_error(int err)
case EFAULT:
PR_SetError(PR_ACCESS_FAULT_ERROR, err);
break;
-#if !defined(SCO_SV)
+#if !defined(SCO)
case ENOBUFS:
-#endif /* !defined(SCO_SV) */
+#endif /* !defined(SCO) */
case ENOMEM:
#ifdef ENOSR
case ENOSR:
diff --git a/pr/tests/Makefile b/pr/tests/Makefile
index 1ca516b7..9b456944 100644
--- a/pr/tests/Makefile
+++ b/pr/tests/Makefile
@@ -269,7 +269,7 @@ endif
endif
endif
-ifeq ($(OS_ARCH), SCO_SV)
+ifeq ($(OS_ARCH), SCOOS)
# SCO Unix needs to link against -lsocket again even though we
# already linked with these system libraries when we built libnspr.so.
EXTRA_LIBS = -lsocket
@@ -280,7 +280,7 @@ export LD_RUN_PATH = $(PWD)/$(DIST)/lib
endif
ifeq ($(OS_ARCH),SINIX)
-EXTRA_LIBS = -lsocket -lnsl -lgen -ldl -lresolv /usr/ucblib/libucb.a
+EXTRA_LIBS = -lsocket -lnsl -lresolv -ldl
# This hardcodes in the executable programs the directory to find
# libnspr.so etc. at program startup. Equivalent to the -R or -rpath
# option for ld on other platforms.
diff --git a/tools/Makefile b/tools/Makefile
index 0e8b3aa5..8477d866 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -131,7 +131,7 @@ EXTRA_LIBS = -lsocket -lnsl -ldl
#export LD_RUN_PATH = $(PWD)/$(DIST)/lib
endif
-ifeq ($(OS_ARCH), SCO_SV)
+ifeq ($(OS_ARCH), SCOOS)
# SCO Unix needs to link against -lsocket again even though we
# already linked with these system libraries when we built libnspr.so.
EXTRA_LIBS = -lsocket