From 500cf85b0395b6835818b6248681bbbc27563dc1 Mon Sep 17 00:00:00 2001 From: Jason King Date: Fri, 16 Feb 2018 16:21:53 +0000 Subject: [PATCH] 9762 Split the custr functions into their own library Reviewed by: Igor Kozhukhov Reviewed by: Toomas Soome Reviewed by: Yuri Pankov Reviewed by: Andy Fiddaman Approved by: Dan McDonald --- exception_lists/packaging | 19 ++++- usr/src/cmd/mailx/Makefile | 6 +- usr/src/cmd/mailx/hdr/def.h | 4 +- usr/src/lib/Makefile | 2 + usr/src/lib/libcmdutils/Makefile.com | 3 +- usr/src/lib/libcmdutils/common/mapfile-vers | 21 +++--- usr/src/lib/libcmdutils/libcmdutils.h | 56 +-------------- usr/src/lib/libcustr/Makefile | 43 ++++++++++++ usr/src/lib/libcustr/Makefile.com | 40 +++++++++++ usr/src/lib/libcustr/amd64/Makefile | 19 +++++ .../lib/{libcmdutils => libcustr}/common/custr.c | 5 +- usr/src/lib/libcustr/common/libcustr.h | 82 ++++++++++++++++++++++ usr/src/lib/libcustr/common/llib-lcustr | 20 ++++++ usr/src/lib/libcustr/common/mapfile-vers | 46 ++++++++++++ usr/src/lib/libcustr/i386/Makefile | 18 +++++ usr/src/lib/libcustr/sparc/Makefile | 18 +++++ usr/src/lib/libcustr/sparcv9/Makefile | 19 +++++ usr/src/pkg/manifests/system-library.mf | 3 + usr/src/test/libc-tests/tests/symbols/Makefile | 11 +-- .../test/libc-tests/tests/symbols/symbols_test.c | 4 +- 20 files changed, 353 insertions(+), 86 deletions(-) create mode 100644 usr/src/lib/libcustr/Makefile create mode 100644 usr/src/lib/libcustr/Makefile.com create mode 100644 usr/src/lib/libcustr/amd64/Makefile rename usr/src/lib/{libcmdutils => libcustr}/common/custr.c (97%) create mode 100644 usr/src/lib/libcustr/common/libcustr.h create mode 100644 usr/src/lib/libcustr/common/llib-lcustr create mode 100644 usr/src/lib/libcustr/common/mapfile-vers create mode 100644 usr/src/lib/libcustr/i386/Makefile create mode 100644 usr/src/lib/libcustr/sparc/Makefile create mode 100644 usr/src/lib/libcustr/sparcv9/Makefile diff --git a/exception_lists/packaging b/exception_lists/packaging index 9260c36069..e5d28d6bc4 100644 --- a/exception_lists/packaging +++ b/exception_lists/packaging @@ -27,6 +27,7 @@ # Copyright 2018 Nexenta Systems, Inc. # Copyright 2017 Toomas Soome # Copyright 2017 RackTop Systems. +# Copyright 2018, Joyent, Inc. # # @@ -948,10 +949,10 @@ usr/include/sys/ipmi.h sparc # # libsaveargs is private # -usr/include/saveargs.h i386 -usr/lib/amd64/libsaveargs.so i386 +usr/include/saveargs.h i386 +usr/lib/amd64/libsaveargs.so i386 usr/lib/amd64/libstandsaveargs.so i386 -usr/lib/amd64/llib-lsaveargs.ln i386 +usr/lib/amd64/llib-lsaveargs.ln i386 # # libpcidb is private @@ -997,3 +998,15 @@ usr/lib/sparcv9/llib-lsff.ln sparc usr/lib/libsff.so usr/lib/llib-lsff usr/lib/llib-lsff.ln + +# +# libcustr is private +# +usr/include/libcustr.h +lib/amd64/libcustr.so i386 +lib/amd64/llib-lcustr.ln i386 +lib/sparcv9/libcustr.so sparc +lib/sparcv9/llib-lcustr.ln sparc +lib/libcustr.so +lib/llib-lcustr +lib/llib-lcustr.ln diff --git a/usr/src/cmd/mailx/Makefile b/usr/src/cmd/mailx/Makefile index 4fb19334f2..6afe955bf2 100644 --- a/usr/src/cmd/mailx/Makefile +++ b/usr/src/cmd/mailx/Makefile @@ -22,7 +22,7 @@ # Copyright 2009 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # -# Copyright 2014 Joyent, Inc. +# Copyright 2018 Joyent, Inc. # # cmd/mailx/Makefile @@ -68,8 +68,8 @@ CERRWARN += -_gcc=-Wno-parentheses CERRWARN += -_gcc=-Wno-uninitialized CERRWARN += -_gcc=-Wno-unused-variable CERRWARN += -_gcc=-Wno-clobbered -LINTFLAGS= -hb -LDLIBS += -lmail -lcmdutils +LINTFLAGS= -hb +LDLIBS += -lmail -lcustr LDFLAGS += $(MAPFILE.NGB:%=-M%) CLOBBERFILES += $(MAILXHELP) diff --git a/usr/src/cmd/mailx/hdr/def.h b/usr/src/cmd/mailx/hdr/def.h index 2480cb84da..a343afab38 100644 --- a/usr/src/cmd/mailx/hdr/def.h +++ b/usr/src/cmd/mailx/hdr/def.h @@ -20,7 +20,7 @@ */ /* - * Copyright 2014 Joyent, Inc. + * Copyright 2018 Joyent, Inc. */ /* @@ -65,7 +65,7 @@ extern "C" { #include #include #include -#include +#include #endif #ifdef VMUNIX #include diff --git a/usr/src/lib/Makefile b/usr/src/lib/Makefile index 90cffe62f7..21a3bde545 100644 --- a/usr/src/lib/Makefile +++ b/usr/src/lib/Makefile @@ -105,6 +105,7 @@ SUBDIRS += \ libcryptoutil \ libctf \ libcurses \ + libcustr \ libdevice \ libdevid \ libdevinfo \ @@ -377,6 +378,7 @@ HDRSUBDIRS= \ libcryptoutil \ libctf \ libcurses \ + libcustr \ libdevice \ libdevid \ libdevinfo \ diff --git a/usr/src/lib/libcmdutils/Makefile.com b/usr/src/lib/libcmdutils/Makefile.com index 9cb35f8795..72e7330eba 100644 --- a/usr/src/lib/libcmdutils/Makefile.com +++ b/usr/src/lib/libcmdutils/Makefile.com @@ -21,12 +21,13 @@ # # Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2013 RackTop Systems. +# Copyright 2018, Joyent, Inc. # LIBRARY= libcmdutils.a VERS= .1 CMD_OBJS= avltree.o sysattrs.o writefile.o process_xattrs.o uid.o gid.o \ - custr.o nicenum.o + nicenum.o COM_OBJS= list.o OBJECTS= $(CMD_OBJS) $(COM_OBJS) diff --git a/usr/src/lib/libcmdutils/common/mapfile-vers b/usr/src/lib/libcmdutils/common/mapfile-vers index 0ac77eb010..2a3e95f95c 100644 --- a/usr/src/lib/libcmdutils/common/mapfile-vers +++ b/usr/src/lib/libcmdutils/common/mapfile-vers @@ -21,6 +21,7 @@ # # Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2013 RackTop Systems. +# Copyright 2018, Joyent, Inc. # # @@ -42,16 +43,16 @@ $mapfile_version 2 SYMBOL_VERSION SUNWprivate_1.1 { global: add_tnode; - custr_alloc; - custr_alloc_buf; - custr_append; - custr_appendc; - custr_append_printf; - custr_append_vprintf; - custr_cstr; - custr_free; - custr_len; - custr_reset; + custr_alloc { TYPE = FUNCTION; FILTER = libcustr.so.1 }; + custr_alloc_buf { TYPE = FUNCTION; FILTER = libcustr.so.1 }; + custr_append { TYPE = FUNCTION; FILTER = libcustr.so.1 }; + custr_appendc { TYPE = FUNCTION; FILTER = libcustr.so.1 }; + custr_append_printf { TYPE = FUNCTION; FILTER = libcustr.so.1 }; + custr_append_vprintf { TYPE = FUNCTION; FILTER = libcustr.so.1 }; + custr_cstr { TYPE = FUNCTION; FILTER = libcustr.so.1 }; + custr_free { TYPE = FUNCTION; FILTER = libcustr.so.1 }; + custr_len { TYPE = FUNCTION; FILTER = libcustr.so.1 }; + custr_reset { TYPE = FUNCTION; FILTER = libcustr.so.1 }; destroy_tree; findnextgid; findnextuid; diff --git a/usr/src/lib/libcmdutils/libcmdutils.h b/usr/src/lib/libcmdutils/libcmdutils.h index 5f9957b861..c9a61aab4d 100644 --- a/usr/src/lib/libcmdutils/libcmdutils.h +++ b/usr/src/lib/libcmdutils/libcmdutils.h @@ -26,7 +26,7 @@ * Copyright (c) 2013 RackTop Systems. */ /* - * Copyright 2017 Joyent, Inc. + * Copyright 2018 Joyent, Inc. */ /* @@ -162,60 +162,6 @@ extern int findnextuid(uid_t, uid_t, uid_t *); */ extern int findnextgid(gid_t, gid_t, gid_t *); - - - /* dynamic string utilities */ - -typedef struct custr custr_t; - -/* - * Allocate and free a "custr_t" dynamic string object. Returns 0 on success - * and -1 otherwise. - */ -extern int custr_alloc(custr_t **); -extern void custr_free(custr_t *); - -/* - * Allocate a "custr_t" dynamic string object that operates on a fixed external - * buffer. - */ -extern int custr_alloc_buf(custr_t **, void *, size_t); - -/* - * Append a single character, or a NUL-terminated string of characters, to a - * dynamic string. Returns 0 on success and -1 otherwise. The dynamic string - * will be unmodified if the function returns -1. - */ -extern int custr_appendc(custr_t *, char); -extern int custr_append(custr_t *, const char *); - -/* - * Append a format string and arguments as though the contents were being parsed - * through snprintf. Returns 0 on success and -1 otherwise. The dynamic string - * will be unmodified if the function returns -1. - */ -extern int custr_append_printf(custr_t *, const char *, ...); -extern int custr_append_vprintf(custr_t *, const char *, va_list); - -/* - * Determine the length in bytes, not including the NUL terminator, of the - * dynamic string. - */ -extern size_t custr_len(custr_t *); - -/* - * Clear the contents of a dynamic string. Does not free the underlying - * memory. - */ -extern void custr_reset(custr_t *); - -/* - * Retrieve a const pointer to a NUL-terminated string version of the contents - * of the dynamic string. Storage for this string should not be freed, and - * the pointer will be invalidated by any mutations to the dynamic string. - */ -extern const char *custr_cstr(custr_t *str); - #define NN_DIVISOR_1000 (1U << 0) /* Minimum size for the output of nicenum, including NULL */ diff --git a/usr/src/lib/libcustr/Makefile b/usr/src/lib/libcustr/Makefile new file mode 100644 index 0000000000..19b08dc521 --- /dev/null +++ b/usr/src/lib/libcustr/Makefile @@ -0,0 +1,43 @@ +# +# This file and its contents are supplied under the terms of the +# Common Development and Distribution License ("CDDL"), version 1.0. +# You may only use this file in accordance with the terms of version +# 1.0 of the CDDL. +# +# A full copy of the text of the CDDL should have accompanied this +# source. A copy of the CDDL is also available via the Internet at +# http://www.illumos.org/license/CDDL. +# + +# +# Copyright 2018, Joyent, Inc. +# + +include $(SRC)/lib/Makefile.lib + +HDRS = libcustr.h +HDRDIR = common + +SUBDIRS = $(MACH) +$(BUILD64)SUBDIRS += $(MACH64) + +all := TARGET= all +clean := TARGET= clean +clobber := TARGET= clobber +install := TARGET= install +lint := TARGET= lint + +.KEEP_STATE: + +all clean clobber install lint: $(SUBDIRS) + +install_h: $(ROOTHDRS) + +check: $(CHECKHDRS) + +$(SUBDIRS): FRC + @cd $@; pwd; $(MAKE) $(TARGET) + +FRC: + +include $(SRC)/lib/Makefile.targ diff --git a/usr/src/lib/libcustr/Makefile.com b/usr/src/lib/libcustr/Makefile.com new file mode 100644 index 0000000000..cbd61ece4b --- /dev/null +++ b/usr/src/lib/libcustr/Makefile.com @@ -0,0 +1,40 @@ +# +# This file and its contents are supplied under the terms of the +# Common Development and Distribution License ("CDDL"), version 1.0. +# You may only use this file in accordance with the terms of version +# 1.0 of the CDDL. +# +# A full copy of the text of the CDDL should have accompanied this +# source. A copy of the CDDL is also available via the Internet at +# http://www.illumos.org/license/CDDL. +# + +# +# Copyright 2018, Joyent, Inc. +# + +LIBRARY = libcustr.a +VERS = .1 +OBJECTS = custr.o + +include $(SRC)/lib/Makefile.lib + +# On some illumos distributions (e.g. SmartOS), utilities in /sbin require +# custr. Place libcustr in /lib so such distros can work even if /usr is +# split onto its own filesystem. +include $(SRC)/lib/Makefile.rootfs + +LIBS = $(DYNLIB) $(LINTLIB) +LDLIBS += -lc +CPPFLAGS += -D__EXTENSIONS__ + +SRCDIR = ../common +$(LINTLIB) := SRCS = $(SRCDIR)/$(LINTSRC) + +.KEEP_STATE: + +all: $(LIBS) + +lint: lintcheck + +include $(SRC)/lib/Makefile.targ diff --git a/usr/src/lib/libcustr/amd64/Makefile b/usr/src/lib/libcustr/amd64/Makefile new file mode 100644 index 0000000000..4b3c5dd187 --- /dev/null +++ b/usr/src/lib/libcustr/amd64/Makefile @@ -0,0 +1,19 @@ +# +# This file and its contents are supplied under the terms of the +# Common Development and Distribution License ("CDDL"), version 1.0. +# You may only use this file in accordance with the terms of version +# 1.0 of the CDDL. +# +# A full copy of the text of the CDDL should have accompanied this +# source. A copy of the CDDL is also available via the Internet at +# http://www.illumos.org/license/CDDL. +# + +# +# Copyright 2018, Joyent, Inc. +# + +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 + +install: all $(ROOTLIBS64) $(ROOTLINKS64) diff --git a/usr/src/lib/libcmdutils/common/custr.c b/usr/src/lib/libcustr/common/custr.c similarity index 97% rename from usr/src/lib/libcmdutils/common/custr.c rename to usr/src/lib/libcustr/common/custr.c index 95d44e431f..5c5b0e370a 100644 --- a/usr/src/lib/libcmdutils/common/custr.c +++ b/usr/src/lib/libcustr/common/custr.c @@ -14,17 +14,18 @@ */ /* - * Copyright 2016 Joyent, Inc. + * Copyright 2018 Joyent, Inc. */ #include #include +#include #include #include #include #include -#include "libcmdutils.h" +#include "libcustr.h" typedef enum { CUSTR_FIXEDBUF = 0x01 diff --git a/usr/src/lib/libcustr/common/libcustr.h b/usr/src/lib/libcustr/common/libcustr.h new file mode 100644 index 0000000000..7671390d7f --- /dev/null +++ b/usr/src/lib/libcustr/common/libcustr.h @@ -0,0 +1,82 @@ +/* + * This file and its contents are supplied under the terms of the + * Common Development and Distribution License ("CDDL"), version 1.0. + * You may only use this file in accordance with the terms of version + * 1.0 of the CDDL. + * + * A full copy of the text of the CDDL should have accompanied this + * source. A copy of the CDDL is also available via the Internet at + * http://www.illumos.org/license/CDDL. + */ + +/* + * Copyright 2018, Joyent, Inc. + */ + +#ifndef _LIBCUSTR_H +#define _LIBCUSTR_H + +#include +#include + +/* dynamic string utilities */ + +#ifdef __cplusplus +extern "C" { +#endif + +typedef struct custr custr_t; + +/* + * Allocate and free a "custr_t" dynamic string object. Returns 0 on success + * and -1 otherwise. + */ +int custr_alloc(custr_t **); +void custr_free(custr_t *); + +/* + * Allocate a "custr_t" dynamic string object that operates on a fixed external + * buffer. + */ +int custr_alloc_buf(custr_t **, void *, size_t); + +/* + * Append a single character, or a NUL-terminated string of characters, to a + * dynamic string. Returns 0 on success and -1 otherwise. The dynamic string + * will be unmodified if the function returns -1. + */ +int custr_appendc(custr_t *, char); +int custr_append(custr_t *, const char *); + +/* + * Append a format string and arguments as though the contents were being parsed + * through snprintf. Returns 0 on success and -1 otherwise. The dynamic string + * will be unmodified if the function returns -1. + */ +int custr_append_printf(custr_t *, const char *, ...); +int custr_append_vprintf(custr_t *, const char *, va_list); + +/* + * Determine the length in bytes, not including the NUL terminator, of the + * dynamic string. + */ +size_t custr_len(custr_t *); + +/* + * Clear the contents of a dynamic string. Does not free the underlying + * memory. + */ +void custr_reset(custr_t *); + +/* + * Retrieve a const pointer to a NUL-terminated string version of the contents + * of the dynamic string. Storage for this string should not be freed, and + * the pointer will be invalidated by any mutations to the dynamic string. + */ +const char *custr_cstr(custr_t *str); + +#ifdef __cplusplus +} +#endif + +#endif /* _LIBCUSTR_H */ diff --git a/usr/src/lib/libcustr/common/llib-lcustr b/usr/src/lib/libcustr/common/llib-lcustr new file mode 100644 index 0000000000..61a1885c85 --- /dev/null +++ b/usr/src/lib/libcustr/common/llib-lcustr @@ -0,0 +1,20 @@ +/* + * This file and its contents are supplied under the terms of the + * Common Development and Distribution License ("CDDL"), version 1.0. + * You may only use this file in accordance with the terms of version + * 1.0 of the CDDL. + * + * A full copy of the text of the CDDL should have accompanied this + * source. A copy of the CDDL is also available via the Internet at + * http://www.illumos.org/license/CDDL. + */ + +/* + * Copyright 2018, Joyent, Inc. + */ + +/*LINTLIBRARY*/ +/*PROTOLIB1*/ + +#include +#include diff --git a/usr/src/lib/libcustr/common/mapfile-vers b/usr/src/lib/libcustr/common/mapfile-vers new file mode 100644 index 0000000000..369771929a --- /dev/null +++ b/usr/src/lib/libcustr/common/mapfile-vers @@ -0,0 +1,46 @@ +# +# This file and its contents are supplied under the terms of the +# Common Development and Distribution License ("CDDL"), version 1.0. +# You may only use this file in accordance with the terms of version +# 1.0 of the CDDL. +# +# A full copy of the text of the CDDL should have accompanied this +# source. A copy of the CDDL is also available via the Internet at +# http://www.illumos.org/license/CDDL. +# + +# +# Copyright 2018, Joyent, Inc. +# + +# +# MAPFILE HEADER START +# +# WARNING: STOP NOW. DO NOT MODIFY THIS FILE. +# Object versioning must comply with the rules detailed in +# +# usr/src/lib/README.mapfiles +# +# You should not be making modifications here until you've read the most current +# copy of that file. If you need help, contact a gatekeeper for guidance. +# +# MAPFILE HEADER END +# + +$mapfile_version 2 + +SYMBOL_VERSION ILLUMOSprivate { + global: + custr_alloc; + custr_alloc_buf; + custr_append; + custr_appendc; + custr_append_printf; + custr_append_vprintf; + custr_cstr; + custr_free; + custr_len; + custr_reset; + local: + *; +}; diff --git a/usr/src/lib/libcustr/i386/Makefile b/usr/src/lib/libcustr/i386/Makefile new file mode 100644 index 0000000000..f32d7a5b91 --- /dev/null +++ b/usr/src/lib/libcustr/i386/Makefile @@ -0,0 +1,18 @@ +# +# This file and its contents are supplied under the terms of the +# Common Development and Distribution License ("CDDL"), version 1.0. +# You may only use this file in accordance with the terms of version +# 1.0 of the CDDL. +# +# A full copy of the text of the CDDL should have accompanied this +# source. A copy of the CDDL is also available via the Internet at +# http://www.illumos.org/license/CDDL. +# + +# +# Copyright 2018, Joyent, Inc. +# + +include ../Makefile.com + +install: all $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) diff --git a/usr/src/lib/libcustr/sparc/Makefile b/usr/src/lib/libcustr/sparc/Makefile new file mode 100644 index 0000000000..f32d7a5b91 --- /dev/null +++ b/usr/src/lib/libcustr/sparc/Makefile @@ -0,0 +1,18 @@ +# +# This file and its contents are supplied under the terms of the +# Common Development and Distribution License ("CDDL"), version 1.0. +# You may only use this file in accordance with the terms of version +# 1.0 of the CDDL. +# +# A full copy of the text of the CDDL should have accompanied this +# source. A copy of the CDDL is also available via the Internet at +# http://www.illumos.org/license/CDDL. +# + +# +# Copyright 2018, Joyent, Inc. +# + +include ../Makefile.com + +install: all $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) diff --git a/usr/src/lib/libcustr/sparcv9/Makefile b/usr/src/lib/libcustr/sparcv9/Makefile new file mode 100644 index 0000000000..4b3c5dd187 --- /dev/null +++ b/usr/src/lib/libcustr/sparcv9/Makefile @@ -0,0 +1,19 @@ +# +# This file and its contents are supplied under the terms of the +# Common Development and Distribution License ("CDDL"), version 1.0. +# You may only use this file in accordance with the terms of version +# 1.0 of the CDDL. +# +# A full copy of the text of the CDDL should have accompanied this +# source. A copy of the CDDL is also available via the Internet at +# http://www.illumos.org/license/CDDL. +# + +# +# Copyright 2018, Joyent, Inc. +# + +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 + +install: all $(ROOTLIBS64) $(ROOTLINKS64) diff --git a/usr/src/pkg/manifests/system-library.mf b/usr/src/pkg/manifests/system-library.mf index c8cdd6f53f..94ae932b59 100644 --- a/usr/src/pkg/manifests/system-library.mf +++ b/usr/src/pkg/manifests/system-library.mf @@ -25,6 +25,7 @@ # Copyright (c) 2013 Gary Mills # Copyright 2017 Nexenta Systems, Inc. # Copyright 2017 RackTop Systems. +# Copyright 2018, Joyent, Inc. # @@ -193,6 +194,7 @@ file path=lib/$(ARCH64)/libcontract.so.1 file path=lib/$(ARCH64)/libcryptoutil.so.1 file path=lib/$(ARCH64)/libctf.so.1 file path=lib/$(ARCH64)/libcurses.so.1 +file path=lib/$(ARCH64)/libcustr.so.1 file path=lib/$(ARCH64)/libdevice.so.1 file path=lib/$(ARCH64)/libdevid.so.1 file path=lib/$(ARCH64)/libdevinfo.so.1 @@ -270,6 +272,7 @@ file path=lib/libcontract.so.1 file path=lib/libcryptoutil.so.1 file path=lib/libctf.so.1 file path=lib/libcurses.so.1 +file path=lib/libcustr.so.1 file path=lib/libdevice.so.1 file path=lib/libdevid.so.1 file path=lib/libdevinfo.so.1 diff --git a/usr/src/test/libc-tests/tests/symbols/Makefile b/usr/src/test/libc-tests/tests/symbols/Makefile index cd499add8c..a5eef8a3a8 100644 --- a/usr/src/test/libc-tests/tests/symbols/Makefile +++ b/usr/src/test/libc-tests/tests/symbols/Makefile @@ -11,6 +11,7 @@ # # Copyright 2014 Garrett D'Amore +# Copyright 2018, Joyent, Inc. # include $(SRC)/Makefile.master @@ -49,14 +50,8 @@ EXTRAPROG += $(SYMTESTS) include ../Makefile.com -# -# Since we use libcmdutils which is LF64, we need to be LF64 even though we're -# not using the LF64 related features at the moment, lint catches us otherwise. -# -CPPFLAGS += -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE - -LDLIBS += -lcmdutils -LDLIBS64 += -lcmdutils +LDLIBS += -lcustr +LDLIBS64 += -lcustr $(SYMTESTS:%=$(TESTDIR)/%): $(TESTDIR)/setup -$(RM) $@ diff --git a/usr/src/test/libc-tests/tests/symbols/symbols_test.c b/usr/src/test/libc-tests/tests/symbols/symbols_test.c index 53e0d015de..ac92feb2b6 100644 --- a/usr/src/test/libc-tests/tests/symbols/symbols_test.c +++ b/usr/src/test/libc-tests/tests/symbols/symbols_test.c @@ -11,7 +11,7 @@ /* * Copyright 2015 Garrett D'Amore - * Copyright 2016 Joyent, Inc. + * Copyright 2018 Joyent, Inc. */ /* @@ -27,7 +27,7 @@ #include #include #include -#include +#include #include #include "test_common.h" -- 2.11.4.GIT