components/apache2-modules/mod_wsgi/Makefile
author Tim Foster <tim.s.foster@oracle.com>
Tue, 08 May 2012 09:45:06 +1200
changeset 804 6652c7c4eb82
child 1058 34d7aaa03423
permissions -rw-r--r--
6630237 supply mod_wsgi with Apache 2
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
804
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
     1
#
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
     2
# CDDL HEADER START
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
     3
#
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
     4
# The contents of this file are subject to the terms of the
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
     5
# Common Development and Distribution License (the "License").
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
     6
# You may not use this file except in compliance with the License.
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
     7
#
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
     8
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
     9
# or http://www.opensolaris.org/os/licensing.
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    10
# See the License for the specific language governing permissions
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    11
# and limitations under the License.
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    12
#
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    13
# When distributing Covered Code, include this CDDL HEADER in each
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    14
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    15
# If applicable, add the following below this CDDL HEADER, with the
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    16
# fields enclosed by brackets "[]" replaced with your own identifying
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    17
# information: Portions Copyright [yyyy] [name of copyright owner]
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    18
#
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    19
# CDDL HEADER END
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    20
#
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    21
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    22
#
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    23
# Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    24
#
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    25
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    26
include ../../../make-rules/shared-macros.mk
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    27
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    28
PATH=$(SPRO_VROOT)/bin:/usr/bin:/usr/gnu/bin
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    29
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    30
COMPONENT_NAME=		mod_wsgi
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    31
COMPONENT_VERSION=	3.3
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    32
COMPONENT_SRC=		$(COMPONENT_NAME)-$(COMPONENT_VERSION)
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    33
COMPONENT_ARCHIVE=	$(COMPONENT_SRC).tar.gz
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    34
COMPONENT_ARCHIVE_HASH=	sha256:d96e1078990484cfe5579df1e95dc73f009495e9c3f9a066b0983650bd9e3243
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    35
COMPONENT_ARCHIVE_URL=	http://modwsgi.googlecode.com/files/$(COMPONENT_ARCHIVE)
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    36
COMPONENT_PROJECT_URL=  http://code.google.com/p/modwsgi/
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    37
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    38
include $(WS_TOP)/make-rules/prep.mk
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    39
include $(WS_TOP)/make-rules/configure.mk
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    40
include $(WS_TOP)/make-rules/ips.mk
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    41
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    42
COMPONENT_PRE_CONFIGURE_ACTION = \
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    43
	($(CLONEY) $(SOURCE_DIR) $(@D))
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    44
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    45
# The following four paragraphs are copied from setup.py.mk
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    46
# but since mod_wsgi doesn't use setup.py, we can't just include
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    47
# setup.py.mk
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    48
$(BUILD_DIR)/%-2.6/.built:		PYTHON_VERSION=2.6
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    49
$(BUILD_DIR)/%-2.7/.built:		PYTHON_VERSION=2.7
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    50
$(BUILD_DIR)/$(MACH32)-%/.built:	BITS=32
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    51
$(BUILD_DIR)/$(MACH64)-%/.built:	BITS=64
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    52
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    53
$(BUILD_DIR)/%-2.6/.installed:	PYTHON_VERSION=2.6
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    54
$(BUILD_DIR)/%-2.7/.installed:  PYTHON_VERSION=2.7
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    55
$(BUILD_DIR)/$(MACH32)-%/.installed:	BITS=32
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    56
$(BUILD_DIR)/$(MACH64)-%/.installed:	BITS=64
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    57
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    58
BUILD_32 = $(PYTHON_VERSIONS:%=$(BUILD_DIR)/$(MACH32)-%/.built)
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    59
BUILD_64 = $(PYTHON_VERSIONS:%=$(BUILD_DIR)/$(MACH64)-%/.built)
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    60
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    61
INSTALL_32 = $(PYTHON_VERSIONS:%=$(BUILD_DIR)/$(MACH32)-%/.installed)
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    62
INSTALL_64 = $(PYTHON_VERSIONS:%=$(BUILD_DIR)/$(MACH64)-%/.installed)
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    63
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    64
$(BUILD_32): CONFIGURE_OPTIONS += --with-python=$(PYTHON.32)
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    65
$(BUILD_64): CONFIGURE_OPTIONS += --with-apxs=/usr/bin/$(MACH64)/apxs --with-python=$(PYTHON.64)
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    66
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    67
$(INSTALL_32): COMPONENT_POST_INSTALL_ACTION = \
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    68
	(cd $(PROTO_DIR)/usr/apache2/2.2/libexec ; \
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    69
		$(MV) mod_wsgi.so mod_wsgi-$(PYTHON_VERSION).so)
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    70
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    71
$(INSTALL_64): COMPONENT_POST_INSTALL_ACTION = \
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    72
	(cd $(PROTO_DIR)/usr/apache2/2.2/libexec/$(MACH64) ; \
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    73
		$(MV) mod_wsgi.so mod_wsgi-$(PYTHON_VERSION).so)
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    74
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    75
# common targets
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    76
build:		$(BUILD_32_and_64)
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    77
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    78
install:	$(INSTALL_32_and_64)
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    79
6652c7c4eb82 6630237 supply mod_wsgi with Apache 2
Tim Foster <tim.s.foster@oracle.com>
parents:
diff changeset
    80
BUILD_PKG_DEPENDENCIES =	$(BUILD_TOOLS)