Makefile revision dbed73cbda2229fd1aa6dc5743993cae7f0a7ee9
c3d42e13d2a7c3749229498658aec34e7e4fd0a0Christian Maeder# CDDL HEADER START
2d453384452f29ab46f29c0163a830492f936512Till Mossakowski# The contents of this file are subject to the terms of the
6034a40f7444be44812edc9819de3b184220e4cbChristian Maeder# Common Development and Distribution License (the "License").
98890889ffb2e8f6f722b00e265a211f13b5a861Corneliu-Claudiu Prodescu# You may not use this file except in compliance with the License.
c3d42e13d2a7c3749229498658aec34e7e4fd0a0Christian Maeder# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
2d453384452f29ab46f29c0163a830492f936512Till Mossakowski# or http://www.opensolaris.org/os/licensing.
c673000621dd506e5fc7babf8ca6303b7fcefc14Christian Maeder# See the License for the specific language governing permissions
2d453384452f29ab46f29c0163a830492f936512Till Mossakowski# and limitations under the License.
2d453384452f29ab46f29c0163a830492f936512Till Mossakowski# When distributing Covered Code, include this CDDL HEADER in each
2d453384452f29ab46f29c0163a830492f936512Till Mossakowski# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
2f65d931e866162d39d09c43021a55314040b377Christian Maeder# If applicable, add the following below this CDDL HEADER, with the
613bf0ed7d98a961755408ead328687ec17f74fdChristian Maeder# fields enclosed by brackets "[]" replaced with your own identifying
b6a54d7292d7a3713000847334de4316d105f40fChristian Maeder# information: Portions Copyright [yyyy] [name of copyright owner]
036037a4510ea63a81a4829ad0c11ef39b2391b0Christian Maeder# CDDL HEADER END
2f65d931e866162d39d09c43021a55314040b377Christian Maeder# Copyright 2009 Sun Microsystems, Inc. All rights reserved.
d5ef5a29a89fa5548f81fcd49fcf0ffda69d45b0Christian Maeder# Use is subject to license terms.
39982c927a6052fe2ebd13d4c03b2fcbae0d2f0cJian Chun Wang# EXPORT DELETE START
8b66de47c89e252c907c8ed3a5ccd16dbccbfb3eChristian Maeder# EXPORT DELETE END
62dd3cd58cda003c32ac69ff12dc82b0a6f5d9d3Christian Maeder in.comsat in.fingerd in.rarpd in.rexecd in.rlogind \
42b0311155dd27a5f8ba917b280c9f7989b73ec9Jonathan von Schroeder in.rshd in.rwhod in.telnetd in.tftpd ipaddrsel \
c4ba3e20a432419afff01558e425e00be42871d8Christian MaederMANIFEST= rarp.xml telnet.xml comsat.xml finger.xml \
153d2d8931968e86ced679540ebc5e583e425af3Christian MaederAUDITPROG= in.rexecd in.rlogind in.rshd in.telnetd
ad3ebaa39d875ef0069f3b8084c8a17432073cf9Christian MaederPAMPROG= in.rexecd in.rlogind in.rshd in.telnetd
88742725989560e29a45dcef33ebd87e97e5f967Jonathan von SchroederSOCKETPROG= 6to4relay arp gettable hostconfig if_mpadm in.comsat \
88742725989560e29a45dcef33ebd87e97e5f967Jonathan von Schroeder in.fingerd in.rarpd in.rexecd in.rlogind in.rshd \
88742725989560e29a45dcef33ebd87e97e5f967Jonathan von Schroeder in.rwhod in.telnetd in.tftpd ipaddrsel route
ad3ebaa39d875ef0069f3b8084c8a17432073cf9Christian MaederNSLPROG= 6to4relay arp gettable hostconfig in.comsat in.rarpd \
ad3ebaa39d875ef0069f3b8084c8a17432073cf9Christian Maeder in.rexecd in.rlogind in.rshd in.rwhod in.telnetd \
85078a17c8b15bdab3e3ccae95449eff7660e4a8Jonathan von SchroederSUBDIRS= bootconfchk htable ifconfig ilbadm in.ftpd in.rdisc in.routed \
85078a17c8b15bdab3e3ccae95449eff7660e4a8Jonathan von Schroeder in.talkd inetadm inetconv ipmpstat ipqosconf ipsecutils \
85078a17c8b15bdab3e3ccae95449eff7660e4a8Jonathan von Schroeder kssl/kssladm kssl/ksslcfg ping routeadm snoop sppptun \
153d2d8931968e86ced679540ebc5e583e425af3Christian MaederMSGSUBDIRS= bootconfchk htable ifconfig ilbadm in.ftpd in.routed in.talkd \
ad3ebaa39d875ef0069f3b8084c8a17432073cf9Christian Maeder inetadm inetconv ipmpstat ipqosconf ipsecutils kssl/ksslcfg \
85078a17c8b15bdab3e3ccae95449eff7660e4a8Jonathan von Schroeder# As programs get lint-clean, add them here and to the 'lint' target.
ad3ebaa39d875ef0069f3b8084c8a17432073cf9Christian Maeder# Eventually this hack should go away, and all in PROG should be
ad3ebaa39d875ef0069f3b8084c8a17432073cf9Christian MaederLINTCLEAN= 6to4relay arp in.rlogind in.rshd in.telnetd in.tftpd \
85078a17c8b15bdab3e3ccae95449eff7660e4a8Jonathan von Schroeder# Likewise, as subdirs get lint-clean, add them here. Once
85078a17c8b15bdab3e3ccae95449eff7660e4a8Jonathan von Schroeder# they're all clean, replace the dependency of the lint target
85078a17c8b15bdab3e3ccae95449eff7660e4a8Jonathan von Schroeder# with SUBDIRS. Also (sigh) deal with the commented-out build lines
85078a17c8b15bdab3e3ccae95449eff7660e4a8Jonathan von Schroeder# for the lint rule.
ad3ebaa39d875ef0069f3b8084c8a17432073cf9Christian MaederLINTSUBDIRS= bootconfchk ilbadm in.rdisc in.routed in.talkd inetadm \
ad3ebaa39d875ef0069f3b8084c8a17432073cf9Christian Maeder inetconv ipmpstat ipqosconf ipsecutils ping routeadm sppptun \
ad3ebaa39d875ef0069f3b8084c8a17432073cf9Christian Maeder# And as programs are verified not to attempt to write into constants,
ad3ebaa39d875ef0069f3b8084c8a17432073cf9Christian Maeder# -xstrconst should be used to ensure they stay that way.
1bd563a2040525e10f6d1ce12f6701ebeed70668Christian MaederROOTSBINPROG = $(ROOTFS_PROG:%=$(ROOTSBIN)/%)
1bd563a2040525e10f6d1ce12f6701ebeed70668Christian MaederROOTUSRSBINLINKS = $(SBINLINKS:%=$(ROOTUSRSBIN)/%)
622752e655865004756e41d39f110209dca367d0Christian MaederCOMMONOBJS= addr_match.o kcmd.o store_forw_creds.o
622752e655865004756e41d39f110209dca367d0Christian MaederCOMMONSRCS= $(COMMONOBJS:%.o=$(CMDINETCOMMONDIR)/%.c)
c962b775a1084a2013cdf23fd1e4a91a7994daa2Christian Maeder# Message catalog
705d8c3d5549a00d4b00e0cb80e3a77441f85267Jonathan von SchroederPOFILES= 6to4relay.po if_mpadm.po in.comsat.po ipaddrsel.po route.po
b6a54d7292d7a3713000847334de4316d105f40fChristian MaederCLEANFILES += $(COMMONOBJS) $(K5RLOGINOBJS) $(K5RSHDOBJS) $(TFTPDOBJS)
b6a54d7292d7a3713000847334de4316d105f40fChristian MaederCPPFLAGS += -DSYSV -DBSD_COMP -I$(CMDINETCOMMONDIR) -I
b6a54d7292d7a3713000847334de4316d105f40fChristian Maederinclude $(SRC)/lib/gss_mechs/mech_krb5/Makefile.mech_krb5
b6a54d7292d7a3713000847334de4316d105f40fChristian Maeder# Eventually just plain CFLAGS should be += -v, but not until all in
c962b775a1084a2013cdf23fd1e4a91a7994daa2Christian Maeder# PROGS are lint clean.
c962b775a1084a2013cdf23fd1e4a91a7994daa2Christian Maeder -L$(ROOT)$(KLIBDIR_DO) -L$(ROOT)$(KLIBDIR_GL)
c962b775a1084a2013cdf23fd1e4a91a7994daa2Christian Maeder -I$(SRC)/uts/common/gssapi/mechs/krb5/include \
62dd3cd58cda003c32ac69ff12dc82b0a6f5d9d3Christian Maedergettable in.comsat := LDFLAGS += $(MAPFILE.NGB:%=-M%)
89873d3eb29b4ef32bfac57443cf831c8b2e0e82Christian Maederall: $(PROG) $(ROOTFS_PROG) $(SUBDIRS) THIRDPARTYLICENSE.arp
89873d3eb29b4ef32bfac57443cf831c8b2e0e82Christian Maeder# message catalog
62dd3cd58cda003c32ac69ff12dc82b0a6f5d9d3Christian Maeder $(LINK.c) $(K5RLOGINOBJS) $(COMMONOBJS) -o $@ $(LDLIBS)
3b8ed4c60cde6b3fc00836e7814262c4377e8648Paolo Torrini $(LINK.c) $(K5RSHDOBJS) $(COMMONOBJS) -o $@ $(LDLIBS)
613bf0ed7d98a961755408ead328687ec17f74fdChristian Maederinstall: $(PROG) $(ROOTFS_PROG) $(SUBDIRS) .WAIT $(ROOTUSRSBINPROG) \
62dd3cd58cda003c32ac69ff12dc82b0a6f5d9d3Christian Maeder $(ROOTSBINPROG) $(ROOTUSRSBINLINKS) $(ROOTETCDEFAULTFILES) \
62dd3cd58cda003c32ac69ff12dc82b0a6f5d9d3Christian Maeder $(SED) -n '/University of California/,/SUCH DAMAGE/p' arp.c > $@
2f65d931e866162d39d09c43021a55314040b377Christian Maeder# The reason this rule checks for the existence of the
2f65d931e866162d39d09c43021a55314040b377Christian Maeder# Makefile is that some of the directories do not exist
7a760fce86044af4d2998c956b2b4dd29115df99Christian Maeder# in our exportable source builds.
62dd3cd58cda003c32ac69ff12dc82b0a6f5d9d3Christian Maeder @if [ -f $@/Makefile ]; then \
61091743da1a9ed6dfd5e077fdcc972553358962Christian Maeder $(LINT.c) 6to4relay.c $(LDLIBS) -lsocket -ldladm
61091743da1a9ed6dfd5e077fdcc972553358962Christian Maeder @# $(LINT.c) in.rexecd.c $(LDLIBS) -lbsm -lpam
72aaab1105e454ec9f49103874cd8006dc2a358cLiam O'Reilly $(LINT.c) -erroff=E_NAME_USED_NOT_DEF2 -erroff=E_NAME_DEF_NOT_USED2 \
e79249c976eff391999c5caebd171bededc26e33Liam O'Reilly -I$(SRC)/uts/common/gssapi/mechs/krb5/include \
ca8f01a2b83fbb929aaf29629f71b10fd867956aJonathan von Schroeder in.rlogind.c $(COMMONSRCS) $(LDLIBS) -lbsm -lpam -lsocket -lnsl
ca8f01a2b83fbb929aaf29629f71b10fd867956aJonathan von Schroeder $(LINT.c) -erroff=E_NAME_USED_NOT_DEF2 -erroff=E_NAME_DEF_NOT_USED2 \
f34d3f5bda0be3ded217da71c1e2e30ee03ca5a1Jonathan von Schroeder -I$(SRC)/uts/common/gssapi/mechs/krb5/include \
ca8f01a2b83fbb929aaf29629f71b10fd867956aJonathan von Schroeder -I$(SRC)/lib/gss_mechs/mech_krb5/include \
ca8f01a2b83fbb929aaf29629f71b10fd867956aJonathan von Schroeder in.rshd.c $(COMMONSRCS) $(LDLIBS) -lbsm -lpam -lsocket -lnsl
ca8f01a2b83fbb929aaf29629f71b10fd867956aJonathan von Schroeder $(LINT.c) -erroff=E_NAME_USED_NOT_DEF2 \
59bed9a19a4646b44b7e837f5f9ab35183833d3bJonathan von Schroeder -I$(SRC)/uts/common/gssapi/mechs/krb5/include \
59bed9a19a4646b44b7e837f5f9ab35183833d3bJonathan von Schroeder -I$(SRC)/lib/gss_mechs/mech_krb5/include \
d40eeef0175161a089443ba027dcb635ed11a1bdJonathan von Schroeder in.telnetd.c $(LDLIBS) -lbsm -lpam -lsocket -lnsl
e604ebb440d3ed0414aa2d54ff962768f0a27933Jonathan von Schroeder $(LINT.c) if_mpadm.c $(LDLIBS) -lsocket -lnsl -lipmp -linetutil
8a5f04e1494456d1270f272db0890c327797f05eJonathan von Schroeder $(LINT.c) ipaddrsel.c $(LDLIBS) -lsocket -lnsl
8a5f04e1494456d1270f272db0890c327797f05eJonathan von Schroeder $(LINT.c) route.c $(LDLIBS) -lsocket -lnsl -ltsnet
8a5f04e1494456d1270f272db0890c327797f05eJonathan von Schroeder $(LINT.c) syncinit.c $(LDLIBS) -ldlpi
e42eddbc69dd31f7cd696e38f82acad678831cb7Jian Chun Wang $(LINT.c) -erroff=E_NAME_USED_NOT_DEF2 in.rarpd.c $(LDLIBS) \
99c923311eab71a85f1dcc4785d349609c828da4Christian Maeder $(LINT.c) in.tftpd.c ../usr.bin/tftp/tftpsubs.c $(LDLIBS) \
f794aa9c06cdd6626e541bc56584da1f9a9a5a4cChristian Maeder# EXPORT DELETE START
c4ba3e20a432419afff01558e425e00be42871d8Christian Maeder sed -e "/^# EXPORT DELETE START/,/^# EXPORT DELETE END/d" \
036037a4510ea63a81a4829ad0c11ef39b2391b0Christian Maeder# EXPORT DELETE END