xref: /titanic_52/usr/src/cmd/smbsrv/smbd/Makefile (revision 9b241b4ed1cf882400b069ff9853cdd310d469bf)
1#
2# CDDL HEADER START
3#
4# The contents of this file are subject to the terms of the
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 (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
23#
24
25
26PROG=	smbd
27SRCS=				\
28	smbd_doorsvc.c		\
29	smbd_join.c		\
30	smbd_logon.c		\
31	smbd_main.c		\
32	smbd_nicmon.c		\
33	smbd_opipe_doorsvc.c	\
34	smbd_share_doorsvc.c	\
35	smbd_spool.c		\
36	smbd_vss.c
37
38include ../../Makefile.cmd
39
40MANIFEST=	server.xml
41SVCMETHOD=	svc-smbd
42LOGDLL=		eventlog.dll
43
44ROOTMANIFESTDIR	= $(ROOTSVCSMB)
45ROOTVARSMBDLLDIR = $(ROOTVARSMB)/cvol/windows/system32
46ROOTVARSMBDLL= $(LOGDLL:%=$(ROOTVARSMBDLLDIR)/%)
47
48$(ROOTMANIFEST):= FILEMODE = 0444
49$(ROOTSVCMETHOD):= FILEMODE = 0555
50$(ROOTVARSMBDLL):= FILEMODE = 0755
51
52include ../Makefile.smbsrv.defs
53
54LDLIBS += -L$(ROOT)/usr/lib/smbsrv -lmlsvc -lmlrpc -lsmbns -lsmb \
55	-lzfs -lbsm -lsocket -lnsl -lscf -lumem -lcmdutils
56LDFLAGS += -R/usr/lib/smbsrv
57
58ROOTSMBDDIR = $(ROOTLIB)/smbsrv
59ROOTSMBDFILE = $(PROG:%=$(ROOTSMBDDIR)/%)
60
61FILEMODE = 0444
62$(ROOTSMBDFILE):= FILEMODE = 0555
63
64$(ROOTSMBDDIR)/%: %
65	$(INS.file)
66
67$(ROOTVARSMBDLLDIR)/%: %
68	$(INS.file)
69
70all:		$(PROG)
71
72clean:
73	$(RM) $(OBJS)
74
75lint:		lint_SRCS
76
77$(PROG):	$(OBJS)
78	$(LINK.c) -o $@ $(OBJS) $(LDLIBS)
79	$(POST_PROCESS)
80
81check:		$(CHKMANIFEST)
82
83_msg:
84
85include ../../Makefile.targ
86
87install: all .WAIT $(ROOTETCDEFAULTFILES) $(ROOTMANIFEST) \
88		$(ROOTSMBDFILE) ${ROOTSVCMETHOD} $(ROOTVARSMBDLL)
89