components/zsh/Makefile
author Danek Duvall <danek.duvall@oracle.com>
Thu, 12 May 2011 14:41:22 -0700
changeset 285 6ce8a202e4f3
parent 181 87e11e685b1f
child 609 775168282b2f
permissions -rw-r--r--
7051367 zsh 4.3.12
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
93
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     1
#
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     2
# CDDL HEADER START
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     3
#
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     4
# The contents of this file are subject to the terms of the
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     5
# Common Development and Distribution License (the "License").
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     6
# You may not use this file except in compliance with the License.
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     7
#
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     8
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     9
# or http://www.opensolaris.org/os/licensing.
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    10
# See the License for the specific language governing permissions
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    11
# and limitations under the License.
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    12
#
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    13
# When distributing Covered Code, include this CDDL HEADER in each
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    14
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    15
# If applicable, add the following below this CDDL HEADER, with the
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    16
# fields enclosed by brackets "[]" replaced with your own identifying
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    17
# information: Portions Copyright [yyyy] [name of copyright owner]
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    18
#
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    19
# CDDL HEADER END
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    20
#
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    21
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    22
#
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    23
# Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    24
#
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    25
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    26
include ../../make-rules/shared-macros.mk
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    27
include ../../make-rules/shared-targets.mk
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    28
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    29
COMPONENT_NAME=		zsh
285
6ce8a202e4f3 7051367 zsh 4.3.12
Danek Duvall <danek.duvall@oracle.com>
parents: 181
diff changeset
    30
COMPONENT_VERSION=	4.3.12
93
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    31
COMPONENT_SRC=		$(COMPONENT_NAME)-$(COMPONENT_VERSION)
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    32
COMPONENT_ARCHIVE=	$(COMPONENT_SRC).tar.bz2
285
6ce8a202e4f3 7051367 zsh 4.3.12
Danek Duvall <danek.duvall@oracle.com>
parents: 181
diff changeset
    33
COMPONENT_ARCHIVE_HASH=	sha1:8fd7a6d841770c8b12cf3ae8229dd857ecdbad93
93
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    34
COMPONENT_ARCHIVE_URL=	http://downloads.sourceforge.net/project/zsh/zsh-dev/$(COMPONENT_VERSION)/$(COMPONENT_ARCHIVE)
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    35
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    36
include ../../make-rules/prep.mk
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    37
include ../../make-rules/configure.mk
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    38
include ../../make-rules/ips.mk
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    39
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    40
CONFIGURE_OPTIONS += -n
99
c15c9099bb44 6841644 OpenSolaris Python should support gdbm
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 93
diff changeset
    41
CONFIGURE_OPTIONS += --enable-cppflags="$(CPP_LARGEFILES)"
93
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    42
CONFIGURE_OPTIONS += --enable-dynamic
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    43
CONFIGURE_OPTIONS += --enable-etcdir=/etc
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    44
CONFIGURE_OPTIONS += --enable-function-subdirs
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    45
CONFIGURE_OPTIONS += --enable-ldflags="-zignore"
285
6ce8a202e4f3 7051367 zsh 4.3.12
Danek Duvall <danek.duvall@oracle.com>
parents: 181
diff changeset
    46
CONFIGURE_OPTIONS += --enable-libs="-lnsl"
93
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    47
CONFIGURE_OPTIONS += --enable-maildir-support
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    48
CONFIGURE_OPTIONS += --enable-multibyte
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    49
CONFIGURE_OPTIONS += --enable-pcre
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    50
CONFIGURE_OPTIONS += --with-tcsetpgrp
285
6ce8a202e4f3 7051367 zsh 4.3.12
Danek Duvall <danek.duvall@oracle.com>
parents: 181
diff changeset
    51
CONFIGURE_OPTIONS += --disable-gdbm
93
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    52
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    53
# pcre-config --libs unnecessarily emits "-L/usr/lib -R/usr/lib"; we remove it
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    54
# so that it doesn't end up in the binaries.
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    55
COMPONENT_POST_CONFIGURE_ACTION = \
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    56
	(cd $(@D); \
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    57
	sed -e 's,-L/usr/lib -R/usr/lib,,' \
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    58
		config.status > config.status.new; \
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    59
	mv config.status.new config.status; \
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    60
	chmod 755 config.status; \
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    61
	./config.status)
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    62
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    63
COMPOVERRIDES = $(shell find Completion -type f -print)
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    64
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    65
$(PROTOETCDIR)/%: % $(PROTOETCDIR)
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    66
	$(INS.file)
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    67
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    68
$(PROTOETCDIR)/zprofile: $(PROTOETCDIR)
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    69
	$(RM) [email protected]; $(SYMLINK) profile [email protected]
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    70
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    71
# makepro.awk leaves turds behind when using gawk 3.1.5 and LANG=en_US.UTF-8.
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    72
# Upgrading gawk would fix the problem, but for now, all we can do is change
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    73
# the language.
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    74
COMPONENT_BUILD_ENV += LANG=C
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    75
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    76
$(COMPONENT_SRC)/Completion/%: Completion/%
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    77
	$(CP) $< [email protected]
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    78
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    79
$(COMPONENT_SRC)/LICENCE: prep
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    80
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    81
license: $(COMPONENT_SRC)/LICENCE
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    82
	iconv -f 8859-1 -t utf-8 $< > [email protected]
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    83
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    84
CLEAN_PATHS += license
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    85
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    86
# common targets
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    87
build:		$(BUILD_32) $(COMPOVERRIDES:%=$(COMPONENT_SRC)/%)
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    88
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    89
install:	build $(INSTALL_32) $(PROTOETCDIR)/zprofile $(PROTOETCDIR)/zshrc license
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    90
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    91
# build does this always
285
6ce8a202e4f3 7051367 zsh 4.3.12
Danek Duvall <danek.duvall@oracle.com>
parents: 181
diff changeset
    92
test:		$(TEST_32)
93
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    93
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    94
BUILD_PKG_DEPENDENCIES =	$(BUILD_TOOLS)
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    95
b579c7b1bb44 7016731 move zsh from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    96
include ../../make-rules/depend.mk