components/git/Makefile
author Mike Sullivan <Mike.Sullivan@Oracle.COM>
Wed, 29 Aug 2012 11:05:56 -0700
changeset 957 255465c5756f
parent 800 2ad056ed89ec
child 1058 34d7aaa03423
permissions -rw-r--r--
Close of build 04.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
     1
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
     2
# CDDL HEADER START
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
     3
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
     4
# The contents of this file are subject to the terms of the
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
     5
# Common Development and Distribution License (the "License").
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
     6
# You may not use this file except in compliance with the License.
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
     7
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
     8
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
     9
# or http://www.opensolaris.org/os/licensing.
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    10
# See the License for the specific language governing permissions
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    11
# and limitations under the License.
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    12
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    13
# When distributing Covered Code, include this CDDL HEADER in each
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    14
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    15
# If applicable, add the following below this CDDL HEADER, with the
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    16
# fields enclosed by brackets "[]" replaced with your own identifying
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    17
# information: Portions Copyright [yyyy] [name of copyright owner]
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    18
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    19
# CDDL HEADER END
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    20
#
706
6e61f0012046 7108059 Userland should have python2.7 version of its python modules
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 667
diff changeset
    21
# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    22
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    23
include ../../make-rules/shared-macros.mk
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    24
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    25
COMPONENT_NAME=		git
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    26
COMPONENT_VERSION=	1.7.9.2
609
775168282b2f 7037821 Userland migration of data from Makefile to manifest may have been a little overzealous
Rich Burridge <rich.burridge@oracle.com>
parents: 552
diff changeset
    27
COMPONENT_PROJECT_URL=	http://git-scm.com/
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    28
COMPONENT_SRC=		$(COMPONENT_NAME)-$(COMPONENT_VERSION)
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    29
COMPONENT_ARCHIVE=	$(COMPONENT_SRC).tar.gz
800
2ad056ed89ec 7163771 sha1 should not be used in userland-fetch and userland component/*/Makefile
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 731
diff changeset
    30
COMPONENT_ARCHIVE_HASH=	\
2ad056ed89ec 7163771 sha1 should not be used in userland-fetch and userland component/*/Makefile
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 731
diff changeset
    31
    sha256:bd7725fb80f305bf27666e3d26a9b7b79596e2248f2ae2d27e06bc15a501ac75
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    32
COMPONENT_ARCHIVE_URL=	http://git-core.googlecode.com/files/$(COMPONENT_ARCHIVE)
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    33
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    34
# man pages are a separate archive
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    35
#
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    36
COMPONENT_ARCHIVE_1 =	$(COMPONENT_NAME)-manpages-$(COMPONENT_VERSION).tar.gz
800
2ad056ed89ec 7163771 sha1 should not be used in userland-fetch and userland component/*/Makefile
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 731
diff changeset
    37
COMPONENT_ARCHIVE_HASH_1 = \
2ad056ed89ec 7163771 sha1 should not be used in userland-fetch and userland component/*/Makefile
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 731
diff changeset
    38
    sha256:c653a3678bb5668c280a0d5ba584fdfb0e4272acbbd00901dc2363ea3f58eede
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    39
COMPONENT_ARCHIVE_URL_1 = http://git-core.googlecode.com/files/$(COMPONENT_ARCHIVE_1)
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    40
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    41
include ../../make-rules/prep.mk
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    42
include ../../make-rules/configure.mk
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    43
include ../../make-rules/ips.mk
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    44
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    45
CONFIGURE_PREFIX    =	/usr
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    46
CONFIGURE_OPTIONS  +=	--without-openssl
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    47
CONFIGURE_OPTIONS  +=	--libexecdir=/usr/lib
277
12ebd29ad46c 7050602 userland consolidation should build with perl 5.12 by default
craig mohrman <craig.mohrman@oracle.com>
parents: 181
diff changeset
    48
CONFIGURE_OPTIONS  +=	--with-perl=$(PERL)
706
6e61f0012046 7108059 Userland should have python2.7 version of its python modules
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 667
diff changeset
    49
CONFIGURE_OPTIONS  +=	--with-python=$(PYTHON)
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    50
CONFIGURE_OPTIONS  +=	CFLAGS="$(CFLAGS)"
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    51
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    52
COMPONENT_BUILD_ENV+=	NO_PERL_MAKEMAKER=1
277
12ebd29ad46c 7050602 userland consolidation should build with perl 5.12 by default
craig mohrman <craig.mohrman@oracle.com>
parents: 181
diff changeset
    53
COMPONENT_INSTALL_ENV+=	PERL_LIB=$(shell $(PERL) -MConfig -e 'print "$$Config{installvendorarch}"')
667
bf7a382b5272 7131234 userland should remove references to /usr/ucb
Rich Burridge <rich.burridge@oracle.com>
parents: 609
diff changeset
    54
COMPONENT_INSTALL_ARGS+=	INSTALL="$(INSTALL)"
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    55
181
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    56
COMPONENT_TEST_TARGETS = test
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    57
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    58
# This runs configure but configure doesn't generate a Makefile.
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    59
# Instead a Makefile comes with git.
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    60
# Anyways viewpathing doesn't work.
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    61
# Therefore we need cloney to copy a set of files to build.
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    62
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    63
COMPONENT_PRE_CONFIGURE_ACTION = \
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    64
	($(CLONEY) $(SOURCE_DIR) $(@D))
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    65
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    66
build:		$(BUILD_32)
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    67
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    68
install:	$(INSTALL_32) $(BUILD_DIR)/.manpages
181
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    69
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    70
# There are some known issues around I18N.
181
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    71
test:	$(TEST_32)
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    72
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    73
# These man pages come in a separate archive with no Makefile
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    74
# and Solaris likes some of them moved around hence we'll just
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    75
# do it manually here.
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    76
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    77
$(BUILD_DIR)/.manpages:
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    78
	cd $(BUILD_DIR) ; $(UNPACK) $(UNPACK_ARGS) ../$(COMPONENT_ARCHIVE_1)
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    79
	$(MKDIR) $(PROTOUSRSHAREMAN1DIR)
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    80
	$(MKDIR) $(PROTOUSRSHAREMAN4DIR)
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    81
	$(MKDIR) $(PROTOUSRSHAREMAN5DIR)
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    82
	cd $(BUILD_DIR) ; for manfile in man*/* ; \
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    83
	do \
731
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    84
		filename=`basename $$manfile`; \
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    85
		fname=$${filename%.*}; \
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    86
		ext=$${filename##*.}; \
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    87
		newext=1; \
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    88
		if [ $$ext = 5 ]; then newext=4; fi; \
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    89
		if [ $$ext = 7 ]; then newext=5; fi; \
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    90
		$(GSED) -e 's/\\m\[blue\]//g' -e 's/\\m\[\]//g' \
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    91
		        -e 's/"5"/"4"/' -e 's/(5)/(4)/g' \
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    92
			-e 's/"7"/"5"/' -e 's/(7)/(5)/g' $$manfile > \
2a19ec4c0d8f 7152417 upgrade git to version 1.7.9.2
Craig Mohrman <craig.mohrman@oracle.com>
parents: 706
diff changeset
    93
		   $(PROTOUSRSHAREMANDIR)/man$$newext/$$fname.$$newext; \
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    94
	done
181
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    95
	$(TOUCH) $@
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    96
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    97
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    98
BUILD_PKG_DEPENDENCIES =	$(BUILD_TOOLS)
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    99
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
   100
include ../../make-rules/depend.mk