Print this page
remove support for non-ANSI compilation

Split Close
Expand all
Collapse all
          --- old/usr/src/head/dlfcn.h
          +++ new/usr/src/head/dlfcn.h
↓ open down ↓ 11 lines elided ↑ open up ↑
  12   12   *
  13   13   * When distributing Covered Code, include this CDDL HEADER in each
  14   14   * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15   15   * If applicable, add the following below this CDDL HEADER, with the
  16   16   * fields enclosed by brackets "[]" replaced with your own identifying
  17   17   * information: Portions Copyright [yyyy] [name of copyright owner]
  18   18   *
  19   19   * CDDL HEADER END
  20   20   */
  21   21  /*
       22 + * Copyright 2014 Garrett D'Amore <garrett@damore.org>
  22   23   * Copyright (c) 1989, 2010, Oracle and/or its affiliates. All rights reserved.
  23   24   *
  24   25   *      Copyright (c) 1989 AT&T
  25   26   *        All Rights Reserved
  26   27   *
  27   28   */
  28   29  
  29   30  #ifndef _DLFCN_H
  30   31  #define _DLFCN_H
  31   32  
↓ open down ↓ 5 lines elided ↑ open up ↑
  37   38  #endif /* !defined(_XOPEN_SOURCE) || defined(__EXTENSIONS__) */
  38   39  
  39   40  #ifdef  __cplusplus
  40   41  extern "C" {
  41   42  #endif
  42   43  
  43   44  /*
  44   45   * Information structures for various dlinfo() requests.
  45   46   */
  46   47  #if !defined(_XOPEN_SOURCE) || defined(__EXTENSIONS__)
  47      -#ifdef __STDC__
  48   48  typedef struct  dl_info {
  49   49          const char      *dli_fname;     /* file containing address range */
  50   50          void            *dli_fbase;     /* base address of file image */
  51   51          const char      *dli_sname;     /* symbol name */
  52   52          void            *dli_saddr;     /* symbol address */
  53   53  } Dl_info;
  54      -#else
  55      -typedef struct  dl_info {
  56      -        char            *dli_fname;
  57      -        void            *dli_fbase;
  58      -        char            *dli_sname;
  59      -        void            *dli_saddr;
  60      -} Dl_info;
  61      -#endif /* __STDC__ */
  62   54  typedef Dl_info         Dl_info_t;
  63   55  
  64   56  typedef struct  dl_serpath {
  65   57          char            *dls_name;      /* library search path name */
  66   58          uint_t          dls_flags;      /* path information */
  67   59  } Dl_serpath;
  68   60  typedef Dl_serpath      Dl_serpath_t;
  69   61  
  70   62  typedef struct  dl_serinfo {
  71   63          size_t          dls_size;       /* total buffer size */
↓ open down ↓ 35 lines elided ↑ open up ↑
 107   99  } Dl_definfo_t;
 108  100  
 109  101  #endif /* !defined(_XOPEN_SOURCE) || defined(__EXTENSIONS__) */
 110  102  
 111  103  
 112  104  typedef ulong_t         Lmid_t;
 113  105  
 114  106  /*
 115  107   * Declarations used for dynamic linking support routines.
 116  108   */
 117      -#ifdef __STDC__
 118  109  extern void     *dlopen(const char *, int);
 119  110  extern void     *dlsym(void *_RESTRICT_KYWD, const char *_RESTRICT_KYWD);
 120  111  extern int      dlclose(void *);
 121  112  extern char     *dlerror(void);
 122  113  #if !defined(_XOPEN_SOURCE) || defined(__EXTENSIONS__)
 123  114  extern void     *dlmopen(Lmid_t, const char *, int);
 124  115  extern int      dladdr(void *, Dl_info *);
 125  116  extern int      dladdr1(void *, Dl_info *, void **, int);
 126  117  extern int      dldump(const char *, const char *, int);
 127  118  extern int      dlinfo(void *, int, void *);
 128  119  extern Dl_amd64_unwindinfo  *dlamd64getunwind(void *, Dl_amd64_unwindinfo *);
 129  120  #endif /* !defined(_XOPEN_SOURCE) || defined(__EXTENSIONS__) */
 130      -#else
 131      -extern void     *dlopen();
 132      -extern void     *dlsym();
 133      -extern int      dlclose();
 134      -extern char     *dlerror();
 135      -#if !defined(_XOPEN_SOURCE) || defined(__EXTENSIONS__)
 136      -extern void     *dlmopen();
 137      -extern int      dladdr();
 138      -extern int      dladdr1();
 139      -extern int      dldump();
 140      -extern int      dlinfo();
 141      -extern Dl_amd64_unwindinfo  *dlamd64getunwind();
 142      -#endif /* !defined(_XOPEN_SOURCE) || defined(__EXTENSIONS__) */
 143      -#endif /* __STDC__ */
 144  121  
 145  122  #pragma unknown_control_flow(dlopen, dlsym, dlclose, dlerror)
 146  123  #if !defined(_XOPEN_SOURCE) || defined(__EXTENSIONS__)
 147  124  #pragma unknown_control_flow(dlmopen, dladdr, dladdr1, dldump, dlinfo)
 148  125  #endif /* !defined(_XOPEN_SOURCE) || defined(__EXTENSIONS__) */
 149  126  
 150  127  /*
 151  128   * Valid values for handle argument to dlsym(3x).
 152  129   */
 153  130  #define RTLD_NEXT               (void *)-1      /* look in `next' dependency */
↓ open down ↓ 106 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX