aboutsummaryrefslogtreecommitdiff
path: root/cddl/contrib/opensolaris/lib/libctf/common
diff options
context:
space:
mode:
authorSteven Hartland <smh@FreeBSD.org>2015-01-17 14:44:59 +0000
committerSteven Hartland <smh@FreeBSD.org>2015-01-17 14:44:59 +0000
commitbc96366c864c07ef352edb92017357917c75b36c (patch)
tree09e9633064b6303a8afc6891fff761eb6e399cee /cddl/contrib/opensolaris/lib/libctf/common
parentb0b74fb366450ac61b7df38daa92bc19cbfc3ecc (diff)
downloadsrc-bc96366c864c07ef352edb92017357917c75b36c.tar.gz
src-bc96366c864c07ef352edb92017357917c75b36c.zip
Mechanically convert cddl sun #ifdef's to illumos
Since the upstream for cddl code is now illumos not sun, mechanically convert all sun #ifdef's to illumos #ifdef's which have been used in all newer code for some time. Also do a manual pass to correct the use if #ifdef comments as per style(9) as well as few uses of #if defined(__FreeBSD__) vs #ifndef illumos. MFC after: 1 month Sponsored by: Multiplay
Notes
Notes: svn path=/head/; revision=277300
Diffstat (limited to 'cddl/contrib/opensolaris/lib/libctf/common')
-rw-r--r--cddl/contrib/opensolaris/lib/libctf/common/ctf_lib.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/cddl/contrib/opensolaris/lib/libctf/common/ctf_lib.c b/cddl/contrib/opensolaris/lib/libctf/common/ctf_lib.c
index 58222670f4ff..b9f512d37739 100644
--- a/cddl/contrib/opensolaris/lib/libctf/common/ctf_lib.c
+++ b/cddl/contrib/opensolaris/lib/libctf/common/ctf_lib.c
@@ -34,14 +34,14 @@
#include <unistd.h>
#include <fcntl.h>
#include <errno.h>
-#if defined(sun)
+#ifdef illumos
#include <dlfcn.h>
#else
#include <zlib.h>
#endif
#include <gelf.h>
-#if defined(sun)
+#ifdef illumos
#ifdef _LP64
static const char *_libctf_zlib = "/usr/lib/64/libz.so";
#else
@@ -58,7 +58,7 @@ static struct {
static size_t _PAGESIZE;
static size_t _PAGEMASK;
-#if defined(sun)
+#ifdef illumos
#pragma init(_libctf_init)
#else
void _libctf_init(void) __attribute__ ((constructor));
@@ -66,7 +66,7 @@ void _libctf_init(void) __attribute__ ((constructor));
void
_libctf_init(void)
{
-#if defined(sun)
+#ifdef illumos
const char *p = getenv("LIBCTF_DECOMPRESSOR");
if (p != NULL)
@@ -87,7 +87,7 @@ _libctf_init(void)
void *
ctf_zopen(int *errp)
{
-#if defined(sun)
+#ifdef illumos
ctf_dprintf("decompressing CTF data using %s\n", _libctf_zlib);
if (zlib.z_dlp != NULL)