Makefile revision 6255
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe#
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# CDDL HEADER START
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe#
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# The contents of this file are subject to the terms of the
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# Common Development and Distribution License (the "License").
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# You may not use this file except in compliance with the License.
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe#
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# or http://www.opensolaris.org/os/licensing.
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# See the License for the specific language governing permissions
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# and limitations under the License.
a9478106a12424322498e53cf7cd75bd8a4d6004Yuri Pankov#
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# When distributing Covered Code, include this CDDL HEADER in each
a9478106a12424322498e53cf7cd75bd8a4d6004Yuri Pankov# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
a9478106a12424322498e53cf7cd75bd8a4d6004Yuri Pankov# If applicable, add the following below this CDDL HEADER, with the
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# fields enclosed by brackets "[]" replaced with your own identifying
a9478106a12424322498e53cf7cd75bd8a4d6004Yuri Pankov# information: Portions Copyright [yyyy] [name of copyright owner]
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe#
a9478106a12424322498e53cf7cd75bd8a4d6004Yuri Pankov# CDDL HEADER END
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe
a9478106a12424322498e53cf7cd75bd8a4d6004Yuri Pankov#
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe#
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweBUILD_BITS= 64
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Loweinclude ../../make-rules/shared-macros.mk
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweCOMPONENT_NAME= libpki
a9478106a12424322498e53cf7cd75bd8a4d6004Yuri PankovCOMPONENT_VERSION= 0.8.9
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweCOMPONENT_PROJECT_URL= https://www.openca.org/projects/libpki/
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweCOMPONENT_ARCHIVE_SRC= git
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweCOMPONENT_BUGDB= library/smartcard
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweGIT_REPO= https://github.com/openca/libpki
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweGIT_COMMIT_ID= b46aebc
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweGIT_HASH= sha256:16e84a529f0871dcff175c717cf472bdad0de0a4719bf1f204d49d9011eace2c
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweTPNO = 26905
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Loweinclude $(WS_MAKE_RULES)/common.mk
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LowePKG_PROTO_DIRS += $(COMPONENT_SRC)/docs
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# Need to include the path below because not all headers are available in
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# $(BUILD_DIR)/src/libpki.
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweCPPFLAGS += -I$(COMPONENT_DIR)/$(COMPONENT_SRC)/src
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# configure.in and Makefile.am patches need configure script recreation.
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweCOMPONENT_PREP_ACTION +=(cd $(@D); autoreconf);
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# This is necessary because 'gmake install' tries to install some files under
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# /usr/bin without it.
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweCONFIGURE_ENV += DESTDIR="$(PROTO_DIR)"
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweCONFIGURE_OPTIONS += --with-libdir=$(USRLIBDIR64)
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweCONFIGURE_OPTIONS += --with-lib-prefix=$(USRLIBDIR64)
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweCOMPONENT_PRE_TEST_ACTION = files/setup_test.sh $(@D) $(COMPONENT_SRC)
efbf89fbc68a0864d303fe237fc420cf018d52f7Robert Mustacchi
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# Tests may output some compilation lines, so just pull out the relevant test
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe# output lines for the test results comparison.
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweCOMPONENT_TEST_TRANSFORMS += \
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe '-n ' \
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe '-e "/\# TOTAL:/p" ' \
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe '-e "/\# PASS:/p" ' \
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe '-e "/\# SKIP:/p" ' \
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe '-e "/\# XFAIL:/p" ' \
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe '-e "/\# FAIL:/p" ' \
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe '-e "/\# XPASS:/p" ' \
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe '-e "/\# ERROR:/p" '
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweREQUIRED_PACKAGES += library/libxml2
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweREQUIRED_PACKAGES += library/openldap
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweREQUIRED_PACKAGES += library/security/openssl
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweREQUIRED_PACKAGES += library/security/openssl/openssl-fips-140
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweREQUIRED_PACKAGES += shell/ksh93
c10c16dec587a0662068f6e2991c29ed3a9db943Richard LoweREQUIRED_PACKAGES += system/network/ldap/openldap
c10c16dec587a0662068f6e2991c29ed3a9db943Richard Lowe