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 2008 Sun Microsystems, Inc. All rights reserved. 23# Use is subject to license terms. 24# 25# Copyright 2017 Nexenta Systems, Inc. All rights reserved. 26# 27 28LIBRARY = libfksmbfs.a 29VERS = .1 30 31OBJS_LOCAL = \ 32 fksmbfs_rwlock.o \ 33 fake_fssub.o \ 34 fake_getdents.o \ 35 fake_lookup.o \ 36 fake_misc.o \ 37 fake_modconf.o \ 38 fake_nbmlock.o \ 39 fake_open.o \ 40 fake_rename.o \ 41 fake_rw.o \ 42 fake_stat.o \ 43 fake_unlink.o \ 44 fake_vfs.o \ 45 fake_vnode.o \ 46 fake_zone.o 47 48# See also: $SRC/uts/common/Makefile.files 49# NB: Intentionally ommitted, compared w/ the above: 50# smbfs_rwlock.o 51# 52OBJS_FS_SMBFS = \ 53 smbfs_vfsops.o \ 54 smbfs_vnops.o \ 55 smbfs_client.o \ 56 smbfs_node.o \ 57 smbfs_smb.o \ 58 smbfs_subr.o \ 59 smbfs_subr2.o \ 60 smbfs_acl.o \ 61 smbfs_xattr.o 62 63OBJS_CMN_SMBFS = \ 64 smbfs_ntacl.o 65 66OBJS_MISC = \ 67 acl_common.o \ 68 pathname.o \ 69 refstr.o 70 71OBJECTS = \ 72 $(OBJS_LOCAL) \ 73 $(OBJS_FS_SMBFS) \ 74 $(OBJS_CMN_SMBFS) \ 75 $(OBJS_MISC) 76 77include ../../../Makefile.lib 78include ../../Makefile.lib 79 80# Force SOURCEDEBUG 81CSOURCEDEBUGFLAGS = -g 82CCSOURCEDEBUGFLAGS = -g 83STRIP_STABS = : 84 85# Note: need our sys includes _before_ ENVCPPFLAGS, proto etc. 86# Also, like Makefile.uts, reset CPPFLAGS 87CPPFLAGS.first += -I../../../libfakekernel/common 88CPPFLAGS.first += -I../../libfknsmb/common 89CPPFLAGS.first += -I../common 90CPPFLAGS= $(CPPFLAGS.first) 91 92INCS += -I$(SRC)/uts/common/fs/smbclnt 93INCS += -I$(SRC)/uts/common 94INCS += -I$(SRC)/common/smbclnt 95INCS += -I$(SRC)/common 96 97CPPFLAGS += $(INCS) -D_REENTRANT -D_FAKE_KERNEL 98CPPFLAGS += -D_FILE_OFFSET_BITS=64 99# Always want DEBUG here 100CPPFLAGS += -DDEBUG 101 102CERRWARN += -_gcc=-Wno-switch 103CERRWARN += -_gcc=-Wno-parentheses 104 105LDLIBS += $(MACH_LDLIBS) 106LDLIBS += -lfknsmb -lfakekernel -lidmap -lcmdutils -lavl -lc 107 108FS_SMBFS_DIR=$(SRC)/uts/common/fs/smbclnt/smbfs 109CMN_SMBFS_DIR=$(SRC)/common/smbclnt 110SRCS= $(OBJS_LOCAL:%.o=$(SRCDIR)/%.c) \ 111 $(OBJS_FS_SMBFS:%.o=$(FS_SMBFS_DIR)/%.c) \ 112 $(OBJS_CMN_SMBFS:%.o=$(CMN_SMBFS_DIR)/%.c) 113 114all: 115 116pics/%.o: $(FS_SMBFS_DIR)/%.c 117 $(COMPILE.c) -o $@ $< 118 $(POST_PROCESS_O) 119 120# pathname.o 121pics/%.o: $(SRC)/uts/common/fs/%.c 122 $(COMPILE.c) -o $@ $< 123 $(POST_PROCESS_O) 124 125# refstr.o 126pics/%.o: $(SRC)/uts/common/os/%.c 127 $(COMPILE.c) -o $@ $< 128 $(POST_PROCESS_O) 129 130pics/acl_common.o: $(SRC)/common/acl/acl_common.c 131 $(COMPILE.c) -o $@ $(SRC)/common/acl/acl_common.c 132 $(POST_PROCESS_O) 133 134.KEEP_STATE: 135 136include ../../Makefile.targ 137include ../../../Makefile.targ 138