components/git/Makefile
author Norm Jacobs <Norm.Jacobs@Oracle.COM>
Fri, 24 Feb 2012 13:30:24 -0800
changeset 706 6e61f0012046
parent 667 bf7a382b5272
child 731 2a19ec4c0d8f
permissions -rw-r--r--
7108059 Userland should have python2.7 version of its python modules
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
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    26
COMPONENT_VERSION=	1.7.3.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)
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    29
COMPONENT_ARCHIVE=	$(COMPONENT_SRC).tar.bz2
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    30
COMPONENT_ARCHIVE_HASH=	sha1:cd8d806752aa6f5716cf193585024a002e098bf4
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    31
COMPONENT_ARCHIVE_URL=	http://kernel.org/pub/software/scm/git/$(COMPONENT_ARCHIVE)
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    32
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    33
# 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
    34
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    35
COMPONENT_ARCHIVE_1 =	$(COMPONENT_NAME)-manpages-$(COMPONENT_VERSION).tar.bz2
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    36
COMPONENT_ARCHIVE_HASH_1 = sha1:0be6fabbca523085e185711f2b80c99330f1e4ac
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    37
COMPONENT_ARCHIVE_URL_1 = http://kernel.org/pub/software/scm/git/$(COMPONENT_ARCHIVE_1)
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    38
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    39
include ../../make-rules/prep.mk
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    40
include ../../make-rules/configure.mk
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    41
include ../../make-rules/ips.mk
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    42
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    43
CONFIGURE_PREFIX    =	/usr
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    44
CONFIGURE_OPTIONS  +=	--without-openssl
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    45
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
    46
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
    47
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
    48
CONFIGURE_OPTIONS  +=	CFLAGS="$(CFLAGS)"
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    49
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    50
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
    51
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
    52
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
    53
181
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    54
COMPONENT_TEST_TARGETS = test
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    55
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    56
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    57
# This runs configure but configure doesn't generate a Makefile.
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    58
# Instead a Makefile comes with git ...
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    59
# Anyways viewpathing doesn't work.
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    60
# Therefore we need cloney to copy a set of files to build.
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    61
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    62
COMPONENT_PRE_CONFIGURE_ACTION = \
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    63
	($(CLONEY) $(SOURCE_DIR) $(@D))
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    64
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    65
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    66
# Processed man pages go here.
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    67
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    68
DOC=$(BUILD_DIR)/Documentation
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    69
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    70
build:		$(BUILD_32) $(DOC)/.manpages
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    71
181
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    72
install:	$(INSTALL_32)
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    73
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    74
#
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    75
# tests fully pass when done in the archive directory.
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    76
# fail here; probably due to the use of cloney.
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    77
#
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    78
test:	$(TEST_32)
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    79
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    80
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    81
# I know.  It's ugly.
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    82
# But these man pages come in a separate archive with no Makefile
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    83
# 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
    84
# do it manually here.
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    85
#
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    86
$(DOC)/.manpages:
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    87
	cd $(BUILD_DIR) ; $(UNPACK) $(UNPACK_ARGS) ../$(COMPONENT_ARCHIVE_1)
181
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    88
	$(MKDIR) $(@D)
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    89
	cd $(BUILD_DIR)/man1 ; for manfile in *.1; \
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    90
	do \
181
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
    91
		name=`basename $$manfile .1`; \
552
540527b8254a 7073887 Solaris nroff can't render git man pages correctly
Rich Burridge <rich.burridge@oracle.com>
parents: 277
diff changeset
    92
		sed -e 's/\\m\[blue\]//g' -e 's/\\m\[\]//g' $$manfile > $(DOC)/$$name.1; \
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    93
	done
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    94
	cd $(BUILD_DIR)/man5 ; for manfile in *.5; \
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    95
	do \
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    96
		name=`basename $$manfile .5`; \
552
540527b8254a 7073887 Solaris nroff can't render git man pages correctly
Rich Burridge <rich.burridge@oracle.com>
parents: 277
diff changeset
    97
		sed -e 's/\\m\[blue\]//g' -e 's/\\m\[\]//g' -e 's/"5"/"4"/' $$manfile > $(DOC)/$$name.4; \
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    98
	done
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
    99
	cd $(BUILD_DIR)/man7 ; for manfile in *.7; \
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
   100
        do \
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
   101
		name=`basename $$manfile .7`; \
552
540527b8254a 7073887 Solaris nroff can't render git man pages correctly
Rich Burridge <rich.burridge@oracle.com>
parents: 277
diff changeset
   102
		sed -e 's/\\m\[blue\]//g' -e 's/\\m\[\]//g' -e 's/"7"/"5"/' $$manfile > $(DOC)/$$name.5; \
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
   103
	done
181
87e11e685b1f 7003927 userland should postprocess packaged files
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 152
diff changeset
   104
	$(TOUCH) $@
152
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
   105
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
   106
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
   107
BUILD_PKG_DEPENDENCIES =	$(BUILD_TOOLS)
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
   108
f0ba422362c2 7030869 move git from sfw consolidation to userland consolidation
Craig Mohrman <Craig.Mohrman@oracle.com>
parents:
diff changeset
   109
include ../../make-rules/depend.mk