6399N/A#
6399N/A# CDDL HEADER START
6399N/A#
6399N/A# The contents of this file are subject to the terms of the
6399N/A# Common Development and Distribution License (the "License").
6399N/A# You may not use this file except in compliance with the License.
6399N/A#
6399N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
6399N/A# or http://www.opensolaris.org/os/licensing.
6399N/A# See the License for the specific language governing permissions
6399N/A# and limitations under the License.
6399N/A#
6399N/A# When distributing Covered Code, include this CDDL HEADER in each
6399N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
6399N/A# If applicable, add the following below this CDDL HEADER, with the
6399N/A# fields enclosed by brackets "[]" replaced with your own identifying
6399N/A# information: Portions Copyright [yyyy] [name of copyright owner]
6399N/A#
6399N/A# CDDL HEADER END
6399N/A
6399N/A#
6399N/A# Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
6399N/A#
6399N/A
6399N/A# TESTING:
6399N/A# Requires physical card reader attached to USB with card inserted.
6399N/A# SCM Microsystems, model SCR3310 is what was used in-house to test.
6399N/A# The pkcs11_coolkey package, once built needs to be installed on
6399N/A# the system building and running the test.
6399N/A#
6399N/A# To build the test:
6399N/A# $ cd components/coolkey/test
6399N/A# $ gmake build-test
6399N/A#
6399N/A# To run the test, as root:
6399N/A# # cd components/coolkey/test
6399N/A# # ./testcoolkey> testoutput.log
6399N/A# enter PIN at prompt and press <enter>
6399N/A#
6399N/A# If the last line of output says:
6399N/A# Testing libcoolkey... DONE. Status = 0
6399N/A# then you have a finished test and results.
6399N/A# Search for "failed" in testoutput.log to see the actual failures, then
6399N/A# review any failed messages to determine if the test ran successfully or not.
6399N/A
6995N/ABUILD_BITS= 64_and_32
6399N/Ainclude ../../make-rules/shared-macros.mk
6399N/A
6399N/ACOMPONENT_NAME= coolkey
6399N/ACOMPONENT_VERSION= 1.1.0
6399N/ACOMPONENT_PROJECT_URL= http://pki.fedoraproject.org/wiki/CoolKey
6399N/ACOMPONENT_DOWNLOAD_URL= http://pkgs.fedoraproject.org/repo/pkgs/$(COMPONENT_NAME)/$(COMPONENT_NAME)-$(COMPONENT_VERSION).tar.gz/815a1811a46bf9b8782107c073149cbe
6399N/ACOMPONENT_ARCHIVE_HASH= sha256:8448e3abb81bffc593c96b577dcfbc05b40e8684188456c31be15fae73d730f7
6399N/ACOMPONENT_ARCHIVE_URL= $(COMPONENT_DOWNLOAD_URL)/$(COMPONENT_ARCHIVE)
6399N/ACOMPONENT_BUGDB= library/smartcard
6399N/A
6399N/ATPNO = 25487
6399N/A
6399N/Ainclude $(WS_MAKE_RULES)/common.mk
6399N/A
6399N/A# configuration related patch needs aclocal to be regenerated
6995N/ACOMPONENT_PREP_ACTION += (cd $(@D); autoconf);
6399N/A
6996N/A# Allow building with Developer Studio 12.5.
6996N/ACXX := $(CXX) -std=sun03
6996N/A
6995N/A# Do not add the SUNWspro area to the RUNPATH. Follow exactly what CC does.
6995N/ALD_UNSET.32.i386 = -R$(SPRO_VROOT)/lib
6995N/ALD_UNSET.32.sparc = -R$(SPRO_VROOT)/lib/$(MACH):$(SPRO_VROOT)/lib
6995N/ALD_UNSET.32 = $(LD_UNSET.32.$(MACH))
6995N/ALD_UNSET.64 = -R$(SPRO_VROOT)/lib/$(MACH64)
6995N/ALD_UNSET += $(LD_UNSET.$(BITS))
6995N/ACOMPONENT_BUILD_ENV += LD_UNSET="$(LD_UNSET)"
6995N/ACOMPONENT_INSTALL_ENV += LD_UNSET="$(LD_UNSET)"
6995N/A
6995N/A# Propagate correct LDFLAGS to the linking phase.
6995N/ALDFLAGS += $(CC_BITS)
6995N/ACOMPONENT_BUILD_ARGS += LDFLAGS="$(LDFLAGS)"
6995N/ACOMPONENT_INSTALL_ARGS += LDFLAGS="$(LDFLAGS)"
6399N/A
6399N/A# requires PC/SC headers and library
6399N/ACONFIGURE_ENV += PCSC_CFLAGS="-I$(USRINCDIR)/PCSC"
6399N/ACONFIGURE_ENV += PCSC_LIBS="-lpcsclite"
6399N/A
6399N/A# no dependency information exists the first time this package is built
6399N/ACONFIGURE_OPTIONS += --disable-dependency-tracking
6399N/A
6399N/A# required packages
6399N/AREQUIRED_PACKAGES += library/security/pcsc/pcsclite
6399N/AREQUIRED_PACKAGES += library/zlib
6399N/AREQUIRED_PACKAGES += system/library/c++-runtime