Print this page
10079 smatch Makefile changes for usr/src/lib


   5 # Common Development and Distribution License (the "License").
   6 # You may not use this file except in compliance with the License.
   7 #
   8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
   9 # or http://www.opensolaris.org/os/licensing.
  10 # See the License for the specific language governing permissions
  11 # and limitations under the License.
  12 #
  13 # When distributing Covered Code, include this CDDL HEADER in each
  14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15 # If applicable, add the following below this CDDL HEADER, with the
  16 # fields enclosed by brackets "[]" replaced with your own identifying
  17 # information: Portions Copyright [yyyy] [name of copyright owner]
  18 #
  19 # CDDL HEADER END
  20 #
  21 #
  22 # Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  23 # Use is subject to license terms.
  24 #
  25 #
  26 
  27 LIBRARY= libresolv.a
  28 VERS= .2
  29 
  30 BSDOBJS=        putenv.o        strcasecmp.o    strsep.o \
  31                 ftruncate.o     readv.o         strdup.o        strtoul.o \
  32                 gettimeofday.o  setenv.o        strerror.o      utimes.o \
  33                 mktemp.o        setitimer.o     strpbrk.o       writev.o
  34 
  35 DSTOBJS=        dst_api.o       support.o       hmac_link.o 
  36 
  37 # inet_addr, inet_pton, inet_ntop, and inet_ntoa removed due to overlap with 
  38 # libnsl
  39 INETOBJS=       inet_net_pton.o inet_neta.o     inet_lnaof.o \
  40                 inet_netof.o    nsap_addr.o     inet_makeaddr.o \
  41                 inet_network.o  inet_net_ntop.o inet_cidr_ntop.o \
  42                 inet_cidr_pton.o                inet_data.o
  43 
  44 # build only the IRS objects that the ISC libbind's make would 
  45 IRSTHROBJS=     gethostent_r.o  getnetent_r.o   getnetgrent_r.o \


  95                 $(RESOLVOBJS:%.o=../common/resolv/%.c) \
  96                 $(SUNWOBJS:%.o=../common/sunw/%.c)
  97 
  98 LIBS =          $(DYNLIB) $(LINTLIB)
  99 
 100 $(LINTLIB):=    SRCS = ../common/llib-lresolv
 101 
 102 # Local Libresolv definitions
 103 
 104 SOLCOMPAT =     -Dsocket=_socket
 105 CRYPTFLAGS=     -DHMAC_MD5 -DUSE_MD5
 106 
 107 LOCFLAGS +=     $(CRYPTFLAGS)
 108 LOCFLAGS +=     -D_SYS_STREAM_H -D_REENTRANT -DSVR4 -DSUNW_OPTIONS \
 109                 $(SOLCOMPAT) -I../include -I../../common/inc
 110 
 111 CPPFLAGS +=     $(LOCFLAGS) 
 112 
 113 CERRWARN +=     -_gcc=-Wno-implicit-function-declaration
 114 



 115 DYNFLAGS +=     $(ZNODELETE)
 116 
 117 LDLIBS +=       -lsocket -lnsl -lc -lmd
 118 
 119 .KEEP_STATE:
 120 
 121 all:    $(LIBS)
 122 
 123 lint:   lintcheck
 124 
 125 # include library targets
 126 include ../../Makefile.targ
 127 
 128 pics/%.o: ../common/bsd/%.c
 129         $(COMPILE.c) -o $@ $<
 130         $(POST_PROCESS_O)
 131 
 132 pics/%.o: ../common/dst/%.c
 133         $(COMPILE.c) -o $@ $<
 134         $(POST_PROCESS_O)




   5 # Common Development and Distribution License (the "License").
   6 # You may not use this file except in compliance with the License.
   7 #
   8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
   9 # or http://www.opensolaris.org/os/licensing.
  10 # See the License for the specific language governing permissions
  11 # and limitations under the License.
  12 #
  13 # When distributing Covered Code, include this CDDL HEADER in each
  14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15 # If applicable, add the following below this CDDL HEADER, with the
  16 # fields enclosed by brackets "[]" replaced with your own identifying
  17 # information: Portions Copyright [yyyy] [name of copyright owner]
  18 #
  19 # CDDL HEADER END
  20 #
  21 #
  22 # Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  23 # Use is subject to license terms.
  24 #
  25 # Copyright (c) 2018, Joyent, Inc.
  26 
  27 LIBRARY= libresolv.a
  28 VERS= .2
  29 
  30 BSDOBJS=        putenv.o        strcasecmp.o    strsep.o \
  31                 ftruncate.o     readv.o         strdup.o        strtoul.o \
  32                 gettimeofday.o  setenv.o        strerror.o      utimes.o \
  33                 mktemp.o        setitimer.o     strpbrk.o       writev.o
  34 
  35 DSTOBJS=        dst_api.o       support.o       hmac_link.o
  36 
  37 # inet_addr, inet_pton, inet_ntop, and inet_ntoa removed due to overlap with
  38 # libnsl
  39 INETOBJS=       inet_net_pton.o inet_neta.o     inet_lnaof.o \
  40                 inet_netof.o    nsap_addr.o     inet_makeaddr.o \
  41                 inet_network.o  inet_net_ntop.o inet_cidr_ntop.o \
  42                 inet_cidr_pton.o                inet_data.o
  43 
  44 # build only the IRS objects that the ISC libbind's make would
  45 IRSTHROBJS=     gethostent_r.o  getnetent_r.o   getnetgrent_r.o \


  95                 $(RESOLVOBJS:%.o=../common/resolv/%.c) \
  96                 $(SUNWOBJS:%.o=../common/sunw/%.c)
  97 
  98 LIBS =          $(DYNLIB) $(LINTLIB)
  99 
 100 $(LINTLIB):=    SRCS = ../common/llib-lresolv
 101 
 102 # Local Libresolv definitions
 103 
 104 SOLCOMPAT =     -Dsocket=_socket
 105 CRYPTFLAGS=     -DHMAC_MD5 -DUSE_MD5
 106 
 107 LOCFLAGS +=     $(CRYPTFLAGS)
 108 LOCFLAGS +=     -D_SYS_STREAM_H -D_REENTRANT -DSVR4 -DSUNW_OPTIONS \
 109                 $(SOLCOMPAT) -I../include -I../../common/inc
 110 
 111 CPPFLAGS +=     $(LOCFLAGS)
 112 
 113 CERRWARN +=     -_gcc=-Wno-implicit-function-declaration
 114 
 115 # not linted
 116 SMATCH=off
 117 
 118 DYNFLAGS +=     $(ZNODELETE)
 119 
 120 LDLIBS +=       -lsocket -lnsl -lc -lmd
 121 
 122 .KEEP_STATE:
 123 
 124 all:    $(LIBS)
 125 
 126 lint:   lintcheck
 127 
 128 # include library targets
 129 include ../../Makefile.targ
 130 
 131 pics/%.o: ../common/bsd/%.c
 132         $(COMPILE.c) -o $@ $<
 133         $(POST_PROCESS_O)
 134 
 135 pics/%.o: ../common/dst/%.c
 136         $(COMPILE.c) -o $@ $<
 137         $(POST_PROCESS_O)