Makefile revision 4337
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# CDDL HEADER START
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# The contents of this file are subject to the terms of the
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# Common Development and Distribution License (the "License").
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# You may not use this file except in compliance with the License.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# See the License for the specific language governing permissions
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# and limitations under the License.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# When distributing Covered Code, include this CDDL HEADER in each
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# If applicable, add the following below this CDDL HEADER, with the
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# fields enclosed by brackets "[]" replaced with your own identifying
75c0816e8295e180f4bc7f10db3d0d880383bc1cMark Andrews# information: Portions Copyright [yyyy] [name of copyright owner]
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# CDDL HEADER END
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# Copyright (c) 2012, 2015, Oracle and/or its affiliates. All rights reserved.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_DOWNLOAD_URL= https://fedorahosted.org/releases/o/p/openscap
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_ARCHIVE_HASH= sha256:c15d587e5cdfcef1316536e6ed8ad66fea3e083ac3d3b723b7e54208f63787c7
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_ARCHIVE_URL= $(COMPONENT_DOWNLOAD_URL)/$(COMPONENT_ARCHIVE)
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# When Python 2.6 goes away, the _VERSION (singular) line below can go as well,
75c0816e8295e180f4bc7f10db3d0d880383bc1cMark Andrews# as can the COMPONENT_POST_CONFIGURE_ACTION and possibly more.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# Perl related patch needs configure script recreation.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# Need to do cloney, so that the schema files can get packaged.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# We could use a single regular expression to cover all of the following,
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# but we want to be as specific as possible to avoid accidentally catching
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# workspace paths in our substitution.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein $(GSED) -i -e 's|usr/include/python2.6|usr/include/python2.7|' \
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein -e 's|$(PYTHON.2.6.VENDOR_PACKAGES.32)|$(PYTHON.2.7.VENDOR_PACKAGES.32)|' \
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein -e 's|PYTHON_VERSION = 2.6|PYTHON_VERSION = 2.7|' swig2.7/Makefile swig2.7/python2/Makefile)
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein (cd $(@D)/swig2.7 ; $(GMAKE) $(COMPONENT_INSTALL_ARGS) install) ; \
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein $(RM) $(PROTO_DIR)/usr/share/openscap/cpe/* && \
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein $(CP) files/cpe/* $(PROTO_DIR)/usr/share/openscap/cpe
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# Needed to make "gmake test" work.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCONFIGURE_OPTIONS.64 += CFLAGS="$(CFLAGS) -D_FILE_OFFSET_BITS=64"
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCONFIGURE_OPTIONS += --libexecdir=$(CONFIGURE_LIBDIR.$(BITS))
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCONFIGURE_OPTIONS += am_cv_python_pythondir=$(PYTHON_VENDOR_PACKAGES)
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCONFIGURE_OPTIONS += am_cv_python_pyexecdir=$(PYTHON_VENDOR_PACKAGES)
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCONFIGURE_OPTIONS += LIBS="-lldap_r -lscf -ldlpi -lsec -lzonecfg"
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinDOCS_DIR = $(PROTO_DIR)/usr/share/docs/openscap/html/
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# Enable ASLR for this component
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# common targets
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinREQUIRED_PACKAGES += security/compliance/openscap
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinREQUIRED_PACKAGES += system/library/gcc-3-runtime
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinREQUIRED_PACKAGES += system/library/gcc-45-runtime
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinREQUIRED_PACKAGES += system/library/gcc/gcc-c-runtime