Makefile revision 1258
11e9368a226272085c337e9e74b79808c16fbdbaTinderbox User# CDDL HEADER START
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# The contents of this file are subject to the terms of the
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# Common Development and Distribution License (the "License").
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# You may not use this file except in compliance with the License.
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# See the License for the specific language governing permissions
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# and limitations under the License.
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# When distributing Covered Code, include this CDDL HEADER in each
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# If applicable, add the following below this CDDL HEADER, with the
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# fields enclosed by brackets "[]" replaced with your own identifying
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# information: Portions Copyright [yyyy] [name of copyright owner]
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# CDDL HEADER END
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox UserIPS_COMPONENT_VERSION= $(shell echo $(COMPONENT_HG_REV) | sed -e 's/-/./g' -e 's/v//')
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox UserCOMPONENT_ARCHIVE= vim-$(COMPONENT_HG_REV).tar.bz2
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox UserCOMPONENT_ARCHIVE_URL= $(EXTERNAL_ARCHIVE_MIRROR)/$(COMPONENT_ARCHIVE)
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox UserCOMPONENT_ARCHIVE_HASH= sha256:08875264e852cc2021e605f26353ba64874064d59dd8ec1ff5fc62265c4be3ac
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox UserCOMPONENT_HG_URL= https://vim.googlecode.com/hg
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox UserTARBALLDIR= $(COMPONENT_NAME)-$(COMPONENT_HG_REV)
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox Userhgball: COMPONENT_HG_REV = $(shell hg -R $(HGREPODIR) tags | awk '$$1 ~ /^v7-/ {print $$1; exit}')
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# Create the tarball. It should contain the working directory of the repo at
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# the desired revision, but not the .hg directory. Note that the digest will
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# be different every time because .hg doesn't set the timestamps of the files
11e9368a226272085c337e9e74b79808c16fbdbaTinderbox User# in the working directory.
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User hg clone -u $(COMPONENT_HG_REV) $(HGREPODIR) $(TARBALLDIR)
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User hg --cwd $(HGREPODIR) stat -ar --rev $(COMPONENT_HG_REV_OLD):$(COMPONENT_HG_REV) runtime src/po
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User digest=$$(digest -a sha256 $(COMPONENT_ARCHIVE)); \
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User -e "s/^COMPONENT_ARCHIVE_HASH=.*/COMPONENT_ARCHIVE_HASH= sha256:$$digest/" \
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User -e "s/^COMPONENT_HG_REV=.*/COMPONENT_HG_REV= $(COMPONENT_HG_REV)/" \
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User -e "s/^COMPONENT_HG_REV_OLD=.*/COMPONENT_HG_REV_OLD= $(COMPONENT_HG_REV)/" \
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# Only install the non-X variant. We will cherry-pick gvim out of the build
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# directory to avoid re-installing everything.
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# Override a broken imake that's always providing a 64-bit library directory.
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox UserCONFIGURE_OPTIONS += --x-libraries=$(CONFIGURE_LIBDIR.$(BITS))
11e9368a226272085c337e9e74b79808c16fbdbaTinderbox UserCONFIGURE_OPTIONS += --with-compiledby="the Solaris Userland build environment"
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox UserCONFIGURE_OPTIONS += --with-modified-by="Solaris Userland <userland-discuss@opensolaris.org>"
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox UserCONFIGURE_OPTIONS += --enable-luainterp=dynamic
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# XXX Perl compilation fails, for some reason.
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# - Perl_croak_nocontext is redefined (embed.h, line 5157), having something to
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# do with PERL_IMPLICIT_CONTEXT, which is discussed in perlguts(1). This is
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# just a warning, but looks like it might have nasty consequences.
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# - The declaration of Perl_Gthr_key_ptr() has a problem with its argument of
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# type pTHX. if_perl.xs defines that to void if it's not already defined,
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# but perl.h probably does something else to it, not sure what yet. This
e108f2ec640e1acb54999c0ade58af606149956dTinderbox User# also appears to have something to do with PERL_IMPLICIT_CONTEXT.
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# CONFIGURE_OPTIONS += --enable-perlinterp=dynamic
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox UserCONFIGURE_OPTIONS += --enable-pythoninterp=dynamic
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox UserCONFIGURE_OPTIONS += --enable-rubyinterp=dynamic
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# We build two variants: with and without X support.
e108f2ec640e1acb54999c0ade58af606149956dTinderbox User$(NOX_VARIANT)/.configured: CONFIGURE_OPTIONS += --without-x
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User$(NOX_VARIANT)/.configured: CONFIGURE_OPTIONS += --disable-gui
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User$(NOX_VARIANT)/.configured: CONFIGURE_OPTIONS += --disable-gtktest
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User$(X_VARIANT)/.configured: CONFIGURE_OPTIONS += --with-vim-name=gvim
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User$(X_VARIANT)/.configured: CONFIGURE_OPTIONS += --with-x
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User$(X_VARIANT)/.configured: CONFIGURE_OPTIONS += --enable-gui=gtk2
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User$(X_VARIANT)/.configured: CONFIGURE_OPTIONS += --enable-gtk2-check
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# Vim's build is too smart for itself and configure can't run outside of a
1ebb25608fa10737ea27abd4e0481707ccd45581Tinderbox User# complete source tree.
COMPONENT_TEST_TARGETS = test
test: $(TEST_32)