summaryrefslogtreecommitdiff
path: root/usr/src/lib/libc
diff options
context:
space:
mode:
Diffstat (limited to 'usr/src/lib/libc')
-rw-r--r--usr/src/lib/libc/amd64/mapfile-vers8
-rw-r--r--usr/src/lib/libc/i386/Makefile.com2
-rw-r--r--usr/src/lib/libc/i386/mapfile-vers8
-rw-r--r--usr/src/lib/libc/port/mapfile-vers4
-rw-r--r--usr/src/lib/libc/sparc/Makefile4
-rw-r--r--usr/src/lib/libc/sparc/gen/byteorder.c63
-rw-r--r--usr/src/lib/libc/sparc/mapfile-vers4
-rw-r--r--usr/src/lib/libc/sparcv9/Makefile2
-rw-r--r--usr/src/lib/libc/sparcv9/gen/byteorder.c63
-rw-r--r--usr/src/lib/libc/sparcv9/mapfile-vers4
10 files changed, 144 insertions, 18 deletions
diff --git a/usr/src/lib/libc/amd64/mapfile-vers b/usr/src/lib/libc/amd64/mapfile-vers
index 4c3570420c..7abfaef170 100644
--- a/usr/src/lib/libc/amd64/mapfile-vers
+++ b/usr/src/lib/libc/amd64/mapfile-vers
@@ -19,7 +19,7 @@
# CDDL HEADER END
#
#
-# Copyright 2006 Sun Microsystems, Inc. All rights reserved.
+# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
# ident "%Z%%M% %I% %E% SMI"
@@ -144,7 +144,7 @@ SUNW_0.7 {
endpwent;
environ = NODIRECT;
_environ = NODIRECT;
- errno;
+ errno = NODIRECT;
___errno;
execl;
_execl;
@@ -745,15 +745,11 @@ SUNWprivate_1.1 {
gtty;
_gtty;
_hasmntopt;
- htonl;
- htons;
_ld_libc = FUNCTION FILTER /usr/lib/amd64/ld.so.1;
_memcmp;
_memcpy;
_memmove;
_memset;
- ntohl;
- ntohs;
sysi86;
_sysi86;
_X_cplx_div;
diff --git a/usr/src/lib/libc/i386/Makefile.com b/usr/src/lib/libc/i386/Makefile.com
index d59790ac8c..61d1454346 100644
--- a/usr/src/lib/libc/i386/Makefile.com
+++ b/usr/src/lib/libc/i386/Makefile.com
@@ -983,7 +983,7 @@ DTRACE_DATA = -zdtrace=dtrace_data
DYNFLAGS += $(DTRACE_DATA)
# DTrace needs an executable data segment.
-NX_MAP=
+MAPFILE.NED=
BUILD.s= $(AS) $(ASFLAGS) $< -o $@
diff --git a/usr/src/lib/libc/i386/mapfile-vers b/usr/src/lib/libc/i386/mapfile-vers
index 6923652e79..e9a3049d52 100644
--- a/usr/src/lib/libc/i386/mapfile-vers
+++ b/usr/src/lib/libc/i386/mapfile-vers
@@ -19,7 +19,7 @@
# CDDL HEADER END
#
#
-# Copyright 2006 Sun Microsystems, Inc. All rights reserved.
+# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
# ident "%Z%%M% %I% %E% SMI"
@@ -157,7 +157,7 @@ SUNW_0.7 {
_encrypt;
endgrent;
endpwent;
- errno;
+ errno = NODIRECT;
___errno;
fgetgrent;
fgetgrent_r;
@@ -844,8 +844,6 @@ SUNWprivate_1.1 {
gtty;
_gtty;
_hasmntopt;
- htonl;
- htons;
_imaxabs_c89;
_imaxdiv_c89;
_ld_libc = FUNCTION FILTER /usr/lib/ld.so.1;
@@ -854,8 +852,6 @@ SUNWprivate_1.1 {
_memmove;
_memset;
__moddi3;
- ntohl;
- ntohs;
_printf_c89;
_scanf_c89;
_snprintf_c89;
diff --git a/usr/src/lib/libc/port/mapfile-vers b/usr/src/lib/libc/port/mapfile-vers
index 1fd247c28e..2b4a48f3f9 100644
--- a/usr/src/lib/libc/port/mapfile-vers
+++ b/usr/src/lib/libc/port/mapfile-vers
@@ -63,6 +63,8 @@ SUNW_1.23 { # SunOS 5.11 (Solaris 11)
fdatasync;
forkallx;
forkx;
+ htonl;
+ htons;
lio_listio;
mkdtemp;
_mkdtemp;
@@ -81,6 +83,8 @@ SUNW_1.23 { # SunOS 5.11 (Solaris 11)
mq_timedsend;
mq_unlink;
nanosleep;
+ ntohl;
+ ntohs;
posix_fallocate;
pthread_key_create_once_np;
_renameat;
diff --git a/usr/src/lib/libc/sparc/Makefile b/usr/src/lib/libc/sparc/Makefile
index 97cb934f46..cabf23b2a8 100644
--- a/usr/src/lib/libc/sparc/Makefile
+++ b/usr/src/lib/libc/sparc/Makefile
@@ -121,6 +121,7 @@ GENOBJS= \
_xregs_clrptr.o \
abs.o \
alloca.o \
+ byteorder.o \
cuexit.o \
ecvt.o \
errlst.o \
@@ -1000,7 +1001,7 @@ DTRACE_DATA = -zdtrace=dtrace_data
DYNFLAGS += $(DTRACE_DATA)
# DTrace needs an executable data segment.
-NX_MAP=
+MAPFILE.NED=
BUILD.s= $(AS) $(ASFLAGS) $< -o $@
@@ -1049,6 +1050,7 @@ SRCS= \
$(FPOBJS:%.o=../$(MACH)/fp/%.c) \
$(LIBCBASE)/crt/_ftou.c \
$(LIBCBASE)/gen/_xregs_clrptr.c \
+ $(LIBCBASE)/gen/byteorder.c \
$(LIBCBASE)/gen/ecvt.c \
$(LIBCBASE)/gen/getctxt.c \
$(LIBCBASE)/gen/lexp10.c \
diff --git a/usr/src/lib/libc/sparc/gen/byteorder.c b/usr/src/lib/libc/sparc/gen/byteorder.c
new file mode 100644
index 0000000000..b28bfebdd0
--- /dev/null
+++ b/usr/src/lib/libc/sparc/gen/byteorder.c
@@ -0,0 +1,63 @@
+/*
+ * CDDL HEADER START
+ *
+ * The contents of this file are subject to the terms of the
+ * Common Development and Distribution License (the "License").
+ * You may not use this file except in compliance with the License.
+ *
+ * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
+ * or http://www.opensolaris.org/os/licensing.
+ * See the License for the specific language governing permissions
+ * and limitations under the License.
+ *
+ * When distributing Covered Code, include this CDDL HEADER in each
+ * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
+ * If applicable, add the following below this CDDL HEADER, with the
+ * fields enclosed by brackets "[]" replaced with your own identifying
+ * information: Portions Copyright [yyyy] [name of copyright owner]
+ *
+ * CDDL HEADER END
+ */
+
+/*
+ * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
+#pragma ident "%Z%%M% %I% %E% SMI"
+
+#include <sys/isa_defs.h>
+#include <sys/types.h>
+
+
+#if defined(_LITTLE_ENDIAN) && !defined(__lint)
+
+#error Use ISA-specific byteorder.s on a little-endian machine.
+
+#else /* !_LITTLE_ENDIAN */
+
+uint32_t
+htonl(uint32_t in)
+{
+ return (in);
+}
+
+uint32_t
+ntohl(uint32_t in)
+{
+ return (in);
+}
+
+uint16_t
+htons(uint16_t in)
+{
+ return (in);
+}
+
+uint16_t
+ntohs(uint16_t in)
+{
+ return (in);
+}
+
+#endif /* _LITTLE_ENDIAN */
diff --git a/usr/src/lib/libc/sparc/mapfile-vers b/usr/src/lib/libc/sparc/mapfile-vers
index 1de1823a76..d7c2f89726 100644
--- a/usr/src/lib/libc/sparc/mapfile-vers
+++ b/usr/src/lib/libc/sparc/mapfile-vers
@@ -19,7 +19,7 @@
# CDDL HEADER END
#
#
-# Copyright 2006 Sun Microsystems, Inc. All rights reserved.
+# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
# ident "%Z%%M% %I% %E% SMI"
@@ -194,7 +194,7 @@ SISCD_2.3 {
_encrypt;
endgrent;
endpwent;
- errno;
+ errno = NODIRECT;
___errno;
fgetgrent;
fgetgrent_r;
diff --git a/usr/src/lib/libc/sparcv9/Makefile b/usr/src/lib/libc/sparcv9/Makefile
index e4bd499cce..595c0a40c5 100644
--- a/usr/src/lib/libc/sparcv9/Makefile
+++ b/usr/src/lib/libc/sparcv9/Makefile
@@ -123,6 +123,7 @@ GENOBJS= \
_xregs_clrptr.o \
abs.o \
alloca.o \
+ byteorder.o \
cuexit.o \
ecvt.o \
getctxt.o \
@@ -983,6 +984,7 @@ SRCS= \
$(FPOBJS64:%.o=$(LIBCBASE)/fp/%.c) \
$(LIBCBASE)/crt/_ftou.c \
$(LIBCBASE)/gen/_xregs_clrptr.c \
+ $(LIBCBASE)/gen/byteorder.c \
$(LIBCBASE)/gen/ecvt.c \
$(LIBCBASE)/gen/getctxt.c \
$(LIBCBASE)/gen/lexp10.c \
diff --git a/usr/src/lib/libc/sparcv9/gen/byteorder.c b/usr/src/lib/libc/sparcv9/gen/byteorder.c
new file mode 100644
index 0000000000..3c26622a2d
--- /dev/null
+++ b/usr/src/lib/libc/sparcv9/gen/byteorder.c
@@ -0,0 +1,63 @@
+/*
+ * CDDL HEADER START
+ *
+ * The contents of this file are subject to the terms of the
+ * Common Development and Distribution License (the "License").
+ * You may not use this file except in compliance with the License.
+ *
+ * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
+ * or http://www.opensolaris.org/os/licensing.
+ * See the License for the specific language governing permissions
+ * and limitations under the License.
+ *
+ * When distributing Covered Code, include this CDDL HEADER in each
+ * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
+ * If applicable, add the following below this CDDL HEADER, with the
+ * fields enclosed by brackets "[]" replaced with your own identifying
+ * information: Portions Copyright [yyyy] [name of copyright owner]
+ *
+ * CDDL HEADER END
+ */
+
+/*
+ * Copyright 2007 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
+#pragma ident "%Z%%M% %I% %E% SMI"
+
+#include <sys/isa_defs.h>
+#include <sys/types.h>
+
+
+#if defined(_LITTLE_ENDIAN) && !defined(__lint)
+
+#error Use ISA-specific byteorder.s on a little-endian machine.
+
+#else /* !_LITTLE_ENDIAN */
+
+uint32_t
+htonl(uint32_t in)
+{
+ return (in);
+}
+
+uint32_t
+ntohl(uint32_t in)
+{
+ return (in);
+}
+
+uint16_t
+htons(uint16_t in)
+{
+ return (in);
+}
+
+uint16_t
+ntohs(uint16_t in)
+{
+ return (in);
+}
+
+#endif /* _LITTLE_ENDIAN */
diff --git a/usr/src/lib/libc/sparcv9/mapfile-vers b/usr/src/lib/libc/sparcv9/mapfile-vers
index 35ba6af356..208faa1ba6 100644
--- a/usr/src/lib/libc/sparcv9/mapfile-vers
+++ b/usr/src/lib/libc/sparcv9/mapfile-vers
@@ -19,7 +19,7 @@
# CDDL HEADER END
#
#
-# Copyright 2006 Sun Microsystems, Inc. All rights reserved.
+# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
# ident "%Z%%M% %I% %E% SMI"
@@ -136,7 +136,7 @@ SUNW_0.7 {
endpwent;
environ = NODIRECT;
_environ = NODIRECT;
- errno;
+ errno = NODIRECT;
___errno;
execl;
_execl;