components/python/cffi/Makefile
author John Beck <John.Beck@Oracle.COM>
Fri, 21 Apr 2017 13:19:38 -0700
branchs11u3-sru
changeset 7935 52155d3dac9e
parent 7085 cad8ee01213d
permissions -rw-r--r--
25933124 cffi/Makefile must drop library/python/pycparser-35 from REQUIRED_PACKAGES
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
3113
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     1
#
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     2
# CDDL HEADER START
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     3
#
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     4
# The contents of this file are subject to the terms of the
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     5
# Common Development and Distribution License (the "License").
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     6
# You may not use this file except in compliance with the License.
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     7
#
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     8
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     9
# or http://www.opensolaris.org/os/licensing.
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    10
# See the License for the specific language governing permissions
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    11
# and limitations under the License.
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    12
#
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    13
# When distributing Covered Code, include this CDDL HEADER in each
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    14
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    15
# If applicable, add the following below this CDDL HEADER, with the
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    16
# fields enclosed by brackets "[]" replaced with your own identifying
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    17
# information: Portions Copyright [yyyy] [name of copyright owner]
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    18
#
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    19
# CDDL HEADER END
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    20
#
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    21
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    22
#
7935
52155d3dac9e 25933124 cffi/Makefile must drop library/python/pycparser-35 from REQUIRED_PACKAGES
John Beck <John.Beck@Oracle.COM>
parents: 7085
diff changeset
    23
# Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
3113
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    24
#
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    25
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    26
include ../../../make-rules/shared-macros.mk
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    27
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    28
COMPONENT_NAME=		cffi
7085
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    29
COMPONENT_VERSION=	1.5.2
3113
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    30
COMPONENT_SRC=		$(COMPONENT_NAME)-$(COMPONENT_VERSION)
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    31
COMPONENT_ARCHIVE=	$(COMPONENT_SRC).tar.gz
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    32
COMPONENT_ARCHIVE_HASH=	\
7085
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    33
    sha256:da9bde99872e46f7bb5cff40a9b1cc08406765efafb583c704de108b6cb821dd
3113
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    34
COMPONENT_ARCHIVE_URL=	$(call pypi_url)
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    35
COMPONENT_PROJECT_URL=	http://cffi.readthedocs.org/
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    36
COMPONENT_BUGDB=	python-mod/cffi
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    37
7085
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    38
TPNO=			29371
3661
47545fb8aed4 18978320 Userland components should specify TPNOs in Makefiles instead of pkg manifests
John Beck <John.Beck@Oracle.COM>
parents: 3113
diff changeset
    39
3996
20c0f21bbe1e 15786608 SUNBT7162754 create new meta package developer/opensolaris/userland
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 3661
diff changeset
    40
include $(WS_MAKE_RULES)/prep.mk
20c0f21bbe1e 15786608 SUNBT7162754 create new meta package developer/opensolaris/userland
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 3661
diff changeset
    41
include $(WS_MAKE_RULES)/setup.py.mk
20c0f21bbe1e 15786608 SUNBT7162754 create new meta package developer/opensolaris/userland
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 3661
diff changeset
    42
include $(WS_MAKE_RULES)/ips.mk
3113
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    43
7085
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    44
# SolarisStudio12.4 is needed for mbarrier.h
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    45
SPRO_VROOT = $(SPRO_ROOT)/solarisstudio12.4
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    46
3113
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    47
ASLR_MODE = $(ASLR_NOT_APPLICABLE)
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    48
7085
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    49
LDSHARED=      $(CC) -G
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    50
PYTHON_ENV +=  LDSHARED="$(LDSHARED)"
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    51
3113
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    52
COMPONENT_TEST_DIR =	$(@D)/tests
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    53
COMPONENT_TEST_ENV =	$(PYTHON_ENV)
4072
db0cec748ec0 PSARC 2015/110 OpenStack service updates for Juno
Danek Duvall <danek.duvall@oracle.com>
parents: 3996
diff changeset
    54
COMPONENT_TEST_ENV +=	PYTHONPATH=$(PROTO_DIR)/$(PYTHON_LIB)
3113
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    55
COMPONENT_TEST_ENV +=	TESTOWNLIB_CC="$(CC) %s $(CC_BITS) -G -KPIC -o %s"
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    56
COMPONENT_TEST_CMD =	$(PYTHON.$(BITS)) /usr/bin/py.test-$(PYTHON_VERSION)
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    57
COMPONENT_TEST_ARGS =	--resultlog $(@D)/testresults
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    58
COMPONENT_TEST_ARGS +=	-p no:codechecker
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    59
COMPONENT_TEST_ARGS +=	$(TEST_SKIPS)
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    60
COMPONENT_TEST_ARGS +=	c testing
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    61
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    62
# Copy the tests and a few of the source files they read into a scratch
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    63
# directory so running the tests don't leave turds in the source directory.
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    64
COMPONENT_PRE_TEST_ACTION = \
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    65
	$(MKDIR) $(@D)/tests/doc/source; \
7085
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    66
	$(CP) -r $(SOURCE_DIR)/c $(SOURCE_DIR)/testing $(SOURCE_DIR)/cffi $(@D)/tests; \
3113
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    67
	$(CP) $(SOURCE_DIR)/setup.py $(@D)/tests; \
4072
db0cec748ec0 PSARC 2015/110 OpenStack service updates for Juno
Danek Duvall <danek.duvall@oracle.com>
parents: 3996
diff changeset
    68
	$(CP) \
db0cec748ec0 PSARC 2015/110 OpenStack service updates for Juno
Danek Duvall <danek.duvall@oracle.com>
parents: 3996
diff changeset
    69
	    $(SOURCE_DIR)/doc/source/conf.py \
db0cec748ec0 PSARC 2015/110 OpenStack service updates for Juno
Danek Duvall <danek.duvall@oracle.com>
parents: 3996
diff changeset
    70
	    $(SOURCE_DIR)/doc/source/index.rst \
7085
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    71
	    $(SOURCE_DIR)/doc/source/installation.rst \
4072
db0cec748ec0 PSARC 2015/110 OpenStack service updates for Juno
Danek Duvall <danek.duvall@oracle.com>
parents: 3996
diff changeset
    72
	    $(@D)/tests/doc/source
3113
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    73
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    74
# common targets
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    75
build:		$(BUILD_32_and_64)
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    76
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    77
install:	$(INSTALL_32_and_64)
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    78
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    79
test:		$(TEST_32_and_64)
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    80
7085
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    81
system-test:    $(SYSTEM_TESTS_NOT_IMPLEMENTED)
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    82
3113
49fd14223e17 PSARC/2014/110 CFFI: foreign function interface for Python calling C code
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    83
3996
20c0f21bbe1e 15786608 SUNBT7162754 create new meta package developer/opensolaris/userland
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 3661
diff changeset
    84
REQUIRED_PACKAGES += library/libffi
7085
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    85
REQUIRED_PACKAGES += library/python/pycparser-27
cad8ee01213d 23206271 Upgrade cffi to 1.5.2
Ronald Jordan <ron.jordan@oracle.com>
parents: 4072
diff changeset
    86
REQUIRED_PACKAGES += library/python/pycparser-34
3996
20c0f21bbe1e 15786608 SUNBT7162754 create new meta package developer/opensolaris/userland
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 3661
diff changeset
    87
REQUIRED_PACKAGES += system/library