c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington#
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington# CDDL HEADER START
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington#
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington# The contents of this file are subject to the terms of the
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington# Common Development and Distribution License (the "License").
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington# You may not use this file except in compliance with the License.
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington#
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington# or http://www.opensolaris.org/os/licensing.
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington# See the License for the specific language governing permissions
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington# and limitations under the License.
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington#
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington# When distributing Covered Code, include this CDDL HEADER in each
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington# If applicable, add the following below this CDDL HEADER, with the
c49a898cb851f8fef7d7a6a9501c66b8f03ae05cPhill Cunnington# fields enclosed by brackets "[]" replaced with your own identifying
537857b204a4425e0ea257b0413a02c5c7c5e266Robert Wapshott# information: Portions Copyright [yyyy] [name of copyright owner]
537857b204a4425e0ea257b0413a02c5c7c5e266Robert Wapshott#
537857b204a4425e0ea257b0413a02c5c7c5e266Robert Wapshott# CDDL HEADER END
57a1b25dcdf865eacb2fe2e17c5ca83e942da047David Luna#
57a1b25dcdf865eacb2fe2e17c5ca83e942da047David Luna
537857b204a4425e0ea257b0413a02c5c7c5e266Robert Wapshott#
537857b204a4425e0ea257b0413a02c5c7c5e266Robert Wapshott# Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
537857b204a4425e0ea257b0413a02c5c7c5e266Robert Wapshott#
537857b204a4425e0ea257b0413a02c5c7c5e266Robert Wapshott
537857b204a4425e0ea257b0413a02c5c7c5e266Robert Wapshottinclude ../../../make-rules/shared-macros.mk
537857b204a4425e0ea257b0413a02c5c7c5e266Robert Wapshott
537857b204a4425e0ea257b0413a02c5c7c5e266Robert WapshottCOMPONENT_NAME= pysmi
537857b204a4425e0ea257b0413a02c5c7c5e266Robert WapshottCOMPONENT_VERSION= 0.0.7
537857b204a4425e0ea257b0413a02c5c7c5e266Robert WapshottCOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
537857b204a4425e0ea257b0413a02c5c7c5e266Robert WapshottCOMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.gz
57a1b25dcdf865eacb2fe2e17c5ca83e942da047David LunaCOMPONENT_ARCHIVE_HASH= \
537857b204a4425e0ea257b0413a02c5c7c5e266Robert Wapshott sha256:999f6db9e16f4cc2804263d825553dbdd188c4313ca5c1244eeb20a3c4a60116
537857b204a4425e0ea257b0413a02c5c7c5e266Robert WapshottCOMPONENT_ARCHIVE_URL= $(call pypi_url)
537857b204a4425e0ea257b0413a02c5c7c5e266Robert WapshottCOMPONENT_PROJECT_URL= http://pysmi.sf.net
COMPONENT_BUGDB= python-mod/pysmi
TPNO= 29887
include $(WS_MAKE_RULES)/prep.mk
include $(WS_MAKE_RULES)/setup.py.mk
include $(WS_MAKE_RULES)/ips.mk
ASLR_MODE = $(ASLR_NOT_APPLICABLE)
# Allow pkg to create the mediated link.
COMPONENT_POST_INSTALL_ACTION = \
(cd $(PROTO_DIR)/usr/bin; $(MV) mibdump.py mibdump.py-$(PYTHON_VERSION))
# common targets
build: $(BUILD_NO_ARCH)
install: $(INSTALL_NO_ARCH)
# Run the tests in the build directory so as not to touch the source directory.
# Because they're not copied over during the build, we do that now. There are
# four test failures due simply to the tests being incompatible with Python 3,
# and four other failures that show up in Python 2 as well.
COMPONENT_PRE_TEST_ACTION = \
$(CP) -r $(COMPONENT_SRC)/tests $(@D)
COMPONENT_TEST_DIR = $(@D)
COMPONENT_TEST_CMD = py.test-$(PYTHON_VERSION)
COMPONENT_TEST_ARGS = --result-log=$(COMPONENT_TEST_OUTPUT)
COMPONENT_TEST_MASTER = \
$(COMPONENT_TEST_RESULTS_DIR)/results-py$(basename $(PYTHON_VERSION)).master
test: $(TEST_NO_ARCH)
system-test: $(NO_TESTS)