xref: /titanic_41/usr/src/lib/pkcs11/pkcs11_tpm/Makefile.com (revision cde2885fdf538266ee2a3b08dee2d5075ce8fa2b)
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# Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
22# Use is subject to license terms.
23#
24LIBRARY =	pkcs11_tpm.a
25VERS =		.1
26
27OBJECTS= api_interface.o \
28	apiutil.o \
29	asn1.o \
30	cert.o \
31	data_obj.o \
32	decr_mgr.o \
33	dig_mgr.o \
34	encr_mgr.o \
35	globals.o \
36	hwf_obj.o \
37	key.o \
38	key_mgr.o \
39	loadsave.o \
40	log.o \
41	mech_md5.o \
42	mech_rsa.o \
43	mech_sha.o \
44	new_host.o \
45	obj_mgr.o \
46	object.o \
47	sess_mgr.o \
48	sign_mgr.o \
49	template.o \
50	tpm_specific.o \
51	utility.o \
52	verify_mgr.o
53
54
55include $(SRC)/lib/Makefile.lib
56
57SRCDIR= ../common
58
59SRCS=	$(OBJECTS:%.o=$(SRCDIR)/%.c)
60
61#       set signing mode
62POST_PROCESS_SO +=      ; $(ELFSIGN_CRYPTO)
63
64ROOTLIBDIR=$(ROOT)/usr/lib/security
65ROOTLIBDIR64=$(ROOT)/usr/lib/security/$(MACH64)
66
67LIBS=$(DYNLIB) $(DYNLIB64)
68
69TSSROOT=
70TSPILIBDIR=$(TSSROOT)/usr/lib
71TSPIINCDIR=$(TSSROOT)/usr/include
72TSSLIB=-L$(TSPILIBDIR)
73TSSLIB64=-L$(TSPILIBDIR)/$(MACH64)
74TSSINC=-I$(TSPIINCDIR)
75
76LDLIBS += $(TSSLIB) -lc -luuid -lmd -ltspi
77CPPFLAGS += -xCC -D_POSIX_PTHREAD_SEMANTICS $(TSSINC)
78CPPFLAGS64 += $(CPPFLAGS)
79C99MODE=        $(C99_ENABLE)
80
81LINTSRC= $(OBJECTS:%.o=$(SRCDIR)/%.c)
82
83$(LINTLIB):=	SRCS	=	$(SRCDIR)/$(LINTSRC)
84LINTSRC= $(SRCS)
85
86.KEEP_STATE:
87
88all: $(LIBS)
89
90lint: $$(LINTSRC)
91	$(LINT.c) $(LINTCHECKFLAGS) $(LINTSRC) $(LDLIBS)
92
93pics/%.o: $(SRCDIR)/%.c
94	$(COMPILE.c) -o $@ $<
95	$(POST_PROCESS_O)
96
97include $(SRC)/lib/Makefile.targ
98