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.
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.
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]
21 # Copyright 2009 Sun Microsystems, Inc. All rights reserved.
22 # Use is subject to license terms.
24 LIBRARY = pkcs11_tpm.a
27 OBJECTS= api_interface.o \
55 include $(SRC)/lib/Makefile.lib
59 SRCS= $(OBJECTS:%.o=$(SRCDIR)/%.c)
62 POST_PROCESS_SO += ; $(ELFSIGN_CRYPTO)
64 ROOTLIBDIR=$(ROOT)/usr/lib/security
65 ROOTLIBDIR64=$(ROOT)/usr/lib/security/$(MACH64)
67 LIBS=$(DYNLIB) $(DYNLIB64)
69 TSSROOT=$(ADJUNCT_PROTO)
70 TSPILIBDIR=$(TSSROOT)/usr/lib
71 TSPIINCDIR=$(TSSROOT)/usr/include
72 TSSLIB=-L$(TSPILIBDIR)
73 TSSLIB64=-L$(TSPILIBDIR)/$(MACH64)
74 TSSINC=-I$(TSPIINCDIR)
76 LDLIBS += $(TSSLIB) -L$(ADJUNCT_PROTO)/lib -lc -luuid -lmd -ltspi
78 # libcrypto has no lint library, so we can only use it when
80 $(LIBS) := LDLIBS += -lcrypto
82 CPPFLAGS += -xCC -D_POSIX_PTHREAD_SEMANTICS $(TSSINC)
83 CPPFLAGS64 += $(CPPFLAGS)
84 C99MODE= $(C99_ENABLE)
86 CERRWARN += -_gcc=-Wno-parentheses
87 CERRWARN += -_gcc=-Wno-unused-label
88 CERRWARN += -_gcc=-Wno-uninitialized
90 LINTSRC= $(OBJECTS:%.o=$(SRCDIR)/%.c)
92 $(LINTLIB):= SRCS = $(SRCDIR)/$(LINTSRC)
102 $(LINT.c) $(LINTCHECKFLAGS) $(LINTSRC) $(LDLIBS)
104 pics/%.o: $(SRCDIR)/%.c
105 $(COMPILE.c) -o $@ $<
108 include $(SRC)/lib/Makefile.targ