author | Ivo Raisr <ivo.raisr@oracle.com> |
Fri, 25 Nov 2016 17:16:40 -0800 | |
branch | s11u3-sru |
changeset 7453 | 688f73f0b72d |
parent 6364 | fd8be207f137 |
permissions | -rw-r--r-- |
6364
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
1 |
# |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
2 |
# CDDL HEADER START |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
3 |
# |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
4 |
# The contents of this file are subject to the terms of the |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
5 |
# Common Development and Distribution License (the "License"). |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
6 |
# You may not use this file except in compliance with the License. |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
7 |
# |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
8 |
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
9 |
# or http://www.opensolaris.org/os/licensing. |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
10 |
# See the License for the specific language governing permissions |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
11 |
# and limitations under the License. |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
12 |
# |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
13 |
# When distributing Covered Code, include this CDDL HEADER in each |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
14 |
# file and include the License file at usr/src/OPENSOLARIS.LICENSE. |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
15 |
# If applicable, add the following below this CDDL HEADER, with the |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
16 |
# fields enclosed by brackets "[]" replaced with your own identifying |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
17 |
# information: Portions Copyright [yyyy] [name of copyright owner] |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
18 |
# |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
19 |
# CDDL HEADER END |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
20 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
21 |
# |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
22 |
# Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
23 |
# |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
24 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
25 |
# TESTING: |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
26 |
# Requires physical card reader attached to USB with card inserted. |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
27 |
# SCM Microsystems, model SCR3310 is what was used in-house to test. |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
28 |
# |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
29 |
# To build the test: |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
30 |
# $ cd build/[64-bit directory] |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
31 |
# $ gmake build-test |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
32 |
# |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
33 |
# To run the test: |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
34 |
# $ cd build/[64-bit directory] |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
35 |
# $ ./testcackey> testoutput.log |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
36 |
# |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
37 |
# If the last line of output says: |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
38 |
# Testing libcackey... DONE. Status = 0 |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
39 |
# then you have a finished test and results. |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
40 |
# Search for CK_FAIL or "failed" in testoutput.log to see the actual failures, |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
41 |
# if no CK_FAIl or failed were reported, the test ran successfully. |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
42 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
43 |
include ../../make-rules/shared-macros.mk |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
44 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
45 |
COMPONENT_NAME= CACKey |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
46 |
COMPONENT_VERSION= 0.7.4 |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
47 |
COMPONENT_PROJECT_URL= http://www.rkeene.org/projects/info/wiki/161 |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
48 |
COMPONENT_COMMIT_ID= 2f51a0d2995c7fd6acb57a953ac24697671d1ef4 |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
49 |
COMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_COMMIT_ID) |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
50 |
COMPONENT_ARCHIVE= $(COMPONENT_SRC).zip |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
51 |
COMPONENT_ARCHIVE_URL= \ |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
52 |
https://github.com/Conservatory/CACKey/archive/$(COMPONENT_COMMIT_ID).zip |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
53 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
54 |
COMPONENT_BUGDB= library/smartcard |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
55 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
56 |
TPNO = 25489 |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
57 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
58 |
include $(WS_MAKE_RULES)/prep.mk |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
59 |
include $(WS_MAKE_RULES)/configure.mk |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
60 |
include $(WS_MAKE_RULES)/ips.mk |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
61 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
62 |
# does not use typical FOSS dir layout, source is at top level |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
63 |
COMPONENT_PRE_CONFIGURE_ACTION = ($(CLONEY) $(SOURCE_DIR) $(@D)) |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
64 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
65 |
# requires PC/SC libraries and headers |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
66 |
CONFIGURE_ENV += CFLAGS="$(CFLAGS) -I$(USRINCDIR)/PCSC" |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
67 |
CONFIGURE_ENV += LDFLAGS="-lpcsclite" |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
68 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
69 |
# options needed for configure, library location, PC/SC library and headers |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
70 |
CONFIGURE_OPTIONS += --exec-prefix=$(USRLIBDIR64) |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
71 |
CONFIGURE_OPTIONS += --with-pcsc-headers=$(USRINCDIR)/PCSC |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
72 |
CONFIGURE_OPTIONS += --enable-dod-certs-on-hw-slots |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
73 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
74 |
# configure.ac related patch needs configure script re-creation |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
75 |
COMPONENT_PREP_ACTION +=(cd $(@D); autoreconf); |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
76 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
77 |
# common targets |
7453
688f73f0b72d
PSARC/2016/232 CACkey Smartcard PKCS#11 provider
Ivo Raisr <ivo.raisr@oracle.com>
parents:
6364
diff
changeset
|
78 |
configure: $(CONFIGURE_32_and_64) |
6364
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
79 |
|
7453
688f73f0b72d
PSARC/2016/232 CACkey Smartcard PKCS#11 provider
Ivo Raisr <ivo.raisr@oracle.com>
parents:
6364
diff
changeset
|
80 |
build: $(BUILD_32_and_64) |
6364
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
81 |
|
7453
688f73f0b72d
PSARC/2016/232 CACkey Smartcard PKCS#11 provider
Ivo Raisr <ivo.raisr@oracle.com>
parents:
6364
diff
changeset
|
82 |
install: $(INSTALL_32_and_64) |
6364
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
83 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
84 |
test: $(NO_TEST) |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
85 |
|
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
86 |
# required packages |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
87 |
REQUIRED_PACKAGES += library/security/pcsc/pcsclite |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
88 |
REQUIRED_PACKAGES += library/zlib |
fd8be207f137
PSARC/2016/217 Smartcard Reintroduction
Jan Parcel <jan.parcel@oracle.com>
parents:
diff
changeset
|
89 |
REQUIRED_PACKAGES += system/library |