Makefile revision 618
e334405421979688f2d838805ac67ee47bd62976Mark Andrews#
e334405421979688f2d838805ac67ee47bd62976Mark Andrews# CDDL HEADER START
8aee18709f238406719768b8a6b843a15c5075f8Mark Andrews#
8aee18709f238406719768b8a6b843a15c5075f8Mark Andrews# The contents of this file are subject to the terms of the
8aee18709f238406719768b8a6b843a15c5075f8Mark Andrews# Common Development and Distribution License (the "License").
e78c2b856b9bfbf713fe805224f345f8e8f84e4aEvan Hunt# You may not use this file except in compliance with the License.
e78c2b856b9bfbf713fe805224f345f8e8f84e4aEvan Hunt#
e78c2b856b9bfbf713fe805224f345f8e8f84e4aEvan Hunt# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
e78c2b856b9bfbf713fe805224f345f8e8f84e4aEvan Hunt# or http://www.opensolaris.org/os/licensing.
c0a76b3c0b42a110e14eb56103973944900400c4Mark Andrews# See the License for the specific language governing permissions
c0a76b3c0b42a110e14eb56103973944900400c4Mark Andrews# and limitations under the License.
82f0630bae09598209cc37c1db00ff4356efee27Mark Andrews#
82f0630bae09598209cc37c1db00ff4356efee27Mark Andrews# When distributing Covered Code, include this CDDL HEADER in each
82f0630bae09598209cc37c1db00ff4356efee27Mark Andrews# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
36fc19f9397ac2469d5432e5eb6ff8774cf60676Mark Andrews# If applicable, add the following below this CDDL HEADER, with the
b44b120c66d9c36f1648f18d169bb4daf4b921afMark Andrews# fields enclosed by brackets "[]" replaced with your own identifying
c87f15dac8bb22ffb3ebf044ee48ce570c87948bMark Andrews# information: Portions Copyright [yyyy] [name of copyright owner]
97664670d0e45ec865da407112fceb892133eaf3Mark Andrews#
97664670d0e45ec865da407112fceb892133eaf3Mark Andrews# CDDL HEADER END
97664670d0e45ec865da407112fceb892133eaf3Mark Andrews#
97664670d0e45ec865da407112fceb892133eaf3Mark Andrews# Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
b5b934a0bb46aded1552a17473652b5a7f4a3274Evan Hunt#
b5b934a0bb46aded1552a17473652b5a7f4a3274Evan Huntinclude ../../make-rules/shared-macros.mk
b5b934a0bb46aded1552a17473652b5a7f4a3274Evan Hunt
b5b934a0bb46aded1552a17473652b5a7f4a3274Evan HuntPATH=$(dir $(CC)):/usr/bin:/usr/gnu/bin
b5b934a0bb46aded1552a17473652b5a7f4a3274Evan Hunt
5af195d1dbe4c266a47264111a9293069041209dMark Andrews# I want to override PERL_VERSION and PERL_ARCH because when building
5af195d1dbe4c266a47264111a9293069041209dMark Andrews# a new version of perl it probably isn't installed so shared-macros.mk
5af195d1dbe4c266a47264111a9293069041209dMark Andrews# can't call it.
5af195d1dbe4c266a47264111a9293069041209dMark Andrews
5af195d1dbe4c266a47264111a9293069041209dMark AndrewsCOMPONENT_NAME= perl
5a636f9951e0a6968498d588a57cb01161d2a109Mark AndrewsCOMPONENT_VERSION= 5.12.3
5a636f9951e0a6968498d588a57cb01161d2a109Mark AndrewsPERL_VERSION= 5.12
8eb30f8dd3c1170406f4f2307964e4c0994494beEvan HuntCOMPONENT_PROJECT_URL= http://www.perl.org/
8eb30f8dd3c1170406f4f2307964e4c0994494beEvan HuntCOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
8eb30f8dd3c1170406f4f2307964e4c0994494beEvan HuntCOMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.bz2
8eb30f8dd3c1170406f4f2307964e4c0994494beEvan HuntCOMPONENT_ARCHIVE_HASH= sha1:86d77c6cbc7a60068dc14c88ffd0729324d1174f
d48730a446ffffa8d75462a4abefce030425fa64Mark AndrewsCOMPONENT_ARCHIVE_URL= http://www.cpan.org/src/5.0/$(COMPONENT_ARCHIVE)
d48730a446ffffa8d75462a4abefce030425fa64Mark Andrews
d48730a446ffffa8d75462a4abefce030425fa64Mark Andrewsinclude ../../make-rules/prep.mk
d48730a446ffffa8d75462a4abefce030425fa64Mark Andrewsinclude ../../make-rules/justmake.mk
7ffe86618c91097b73cde82fb535180dbd5f8e91Mark Andrewsinclude ../../make-rules/ips.mk
7ffe86618c91097b73cde82fb535180dbd5f8e91Mark Andrews
7ffe86618c91097b73cde82fb535180dbd5f8e91Mark Andrews#
d48730a446ffffa8d75462a4abefce030425fa64Mark Andrews# Override these compiler settings because they are causing problems
380c874925f684847d9278b909cf511cb5b0289aShawn Routhier# in the ON build of the contrib components.
380c874925f684847d9278b909cf511cb5b0289aShawn Routhier# ON doesn't use or need these settings or the compiler has some of them
380c874925f684847d9278b909cf511cb5b0289aShawn Routhier# on by default.
7ffe86618c91097b73cde82fb535180dbd5f8e91Mark Andrews# This also produces a perl more inline with past perl's. For better
7ffe86618c91097b73cde82fb535180dbd5f8e91Mark Andrews# or worse.
380c874925f684847d9278b909cf511cb5b0289aShawn Routhier#
a27b3757fdd8976ce05e37f391ad9e7ac4638e5dMark Andrewsstudio_XBITS=
a27b3757fdd8976ce05e37f391ad9e7ac4638e5dMark Andrewsstudio_XREGS=
a27b3757fdd8976ce05e37f391ad9e7ac4638e5dMark Andrewsstudio_IROPTS=
7ffe86618c91097b73cde82fb535180dbd5f8e91Mark Andrewsstudio_C99MODE=
7ffe86618c91097b73cde82fb535180dbd5f8e91Mark Andrewsstudio_ALIGN=
7ffe86618c91097b73cde82fb535180dbd5f8e91Mark Andrewsstudio_MT=
a27b3757fdd8976ce05e37f391ad9e7ac4638e5dMark Andrews
c9c2ffe729bf24a7fd0f0a234a4a84e67621d414Mark Andrews#
c9c2ffe729bf24a7fd0f0a234a4a84e67621d414Mark Andrews# The extra Configure parameters (cf_email, cf_by, myhostname) and
c9c2ffe729bf24a7fd0f0a234a4a84e67621d414Mark Andrews# the gawk and sed that follow are attempting to sanatize the
7bce3361868c7c00929e0c1b64a45f24a714972fMark Andrews# resulting config.sh of values from our build environment that
7bce3361868c7c00929e0c1b64a45f24a714972fMark Andrews# are discoverable in perl's config via "perl -V".
7bce3361868c7c00929e0c1b64a45f24a714972fMark Andrews# I'm assuming our compilers live on a path that contains "SUNWspro".
7bce3361868c7c00929e0c1b64a45f24a714972fMark Andrews# If that changes the sed filter needs to change.
7bce3361868c7c00929e0c1b64a45f24a714972fMark Andrews#
2015023399657c36e9dcc8b5dc35ce20dfc876f0Mark Andrews
2015023399657c36e9dcc8b5dc35ce20dfc876f0Mark AndrewsCOMPONENT_PRE_BUILD_ACTION= \
2015023399657c36e9dcc8b5dc35ce20dfc876f0Mark Andrews (cd $(@D); $(ENV) -i \
b2c8cc4f2d61f0593300a5851e26e7ddb30b7e10Mark Andrews MAKE=$(GMAKE) \
b2c8cc4f2d61f0593300a5851e26e7ddb30b7e10Mark Andrews PATH=$(dir $(CC.studio.32)):$(PATH) \
ed83fa75f5657ab2394a701f7ccc169dd9ef48fcMark Andrews $(CONFIG_SHELL) ./Configure \
ed83fa75f5657ab2394a701f7ccc169dd9ef48fcMark Andrews -Dprefix=/usr/perl5/$(PERL_VERSION) \
ed83fa75f5657ab2394a701f7ccc169dd9ef48fcMark Andrews -Dprivlib=/usr/perl5/$(PERL_VERSION)/lib \
9eba1cf5e5420aeded5ed380d9942269fbde90f1Mark Andrews -Dsitelib=/usr/perl5/site_perl/$(PERL_VERSION) \
c470afc7ac0040f1bf7553ce8183b7a1d1726211Mark Andrews -Dvendorprefix=/usr/perl5/$(PERL_VERSION) \
c470afc7ac0040f1bf7553ce8183b7a1d1726211Mark Andrews -Dvendorlib=/usr/perl5/vendor_perl/$(PERL_VERSION) \
506a2177bfafa4321cf1ba27ff4a1d09bac69e14Mark Andrews -Dlibperl=libperl.so \
506a2177bfafa4321cf1ba27ff4a1d09bac69e14Mark Andrews -Duseshrplib \
506a2177bfafa4321cf1ba27ff4a1d09bac69e14Mark Andrews -Dusedtrace \
082f42dcf2f38509a8c842013548f680a6ad06f3Mark Andrews -Duse64bitint \
082f42dcf2f38509a8c842013548f680a6ad06f3Mark Andrews -Dcc="cc" \
082f42dcf2f38509a8c842013548f680a6ad06f3Mark Andrews -Doptimize="$(CFLAGS.studio)" \
c75523bcb30c2b8426ee7cb226d9b429c337325bMark Andrews -Dcf_email="userland-discuss@opensolaris.org" \
c75523bcb30c2b8426ee7cb226d9b429c337325bMark Andrews -Dcf_by="perl-bugs" \
c75523bcb30c2b8426ee7cb226d9b429c337325bMark Andrews -Dmyhostname="localhost" \
c75523bcb30c2b8426ee7cb226d9b429c337325bMark Andrews -O \
c75523bcb30c2b8426ee7cb226d9b429c337325bMark Andrews -de ) ; \
c75523bcb30c2b8426ee7cb226d9b429c337325bMark Andrews (cd $(@D); \
70ba55161bbecab6b58ad4d2203741e9b57951bcMark Andrews cp config.sh config.sh_orig ; \
70ba55161bbecab6b58ad4d2203741e9b57951bcMark Andrews gawk \
70ba55161bbecab6b58ad4d2203741e9b57951bcMark Andrews '/^myuname=/{print $$1" localhost "$$3" "$$5" "$$6" "$$7"\047"} ; \
70ba55161bbecab6b58ad4d2203741e9b57951bcMark Andrews !/^myuname=/ {print}' config.sh_orig \
ad9107efaaae2407cf11bf0c55407d8daed2e2d4Mark Andrews | \
ad9107efaaae2407cf11bf0c55407d8daed2e2d4Mark Andrews sed -e 's/[^ ]*SUNWspro[^ ]*//g' > config.sh )
3f9f14055b85c2dda341b341de0e65d4639542c5Mark Andrews
3f9f14055b85c2dda341b341de0e65d4639542c5Mark Andrews
75f48cecb3289c6d23a45127da65f18937160341Mark AndrewsCOMPONENT_INSTALL_ENV += DESTDIR="$(PROTO_DIR)"
75f48cecb3289c6d23a45127da65f18937160341Mark Andrews#
75f48cecb3289c6d23a45127da65f18937160341Mark Andrews# perl's install path for sparc is based off the value of the
8fb412590e03dcf9de775dad1eb7acf320b575edMark Andrews# "arch" command. So we must package that way also.
8fb412590e03dcf9de775dad1eb7acf320b575edMark Andrews#
8fb412590e03dcf9de775dad1eb7acf320b575edMark AndrewsPKG_MACROS += PERL_ARCH=$(shell arch)
8fb412590e03dcf9de775dad1eb7acf320b575edMark AndrewsPKG_MACROS += PERL_VERSION=$(PERL_VERSION)
1b42401954a8770d82a168ae1ac06ce66862fd25Mark Andrews#
1b42401954a8770d82a168ae1ac06ce66862fd25Mark Andrews# Put studio compilers in PATH so we can tell Configure and gmake just
1b42401954a8770d82a168ae1ac06ce66862fd25Mark Andrews# use cc. Trying to avoid the full path so it doesn't end up in
240a7dc59d6bc135ed298436b59dc86c84928ca2Mark Andrews# perl's config.
240a7dc59d6bc135ed298436b59dc86c84928ca2Mark Andrews#
240a7dc59d6bc135ed298436b59dc86c84928ca2Mark AndrewsCOMPONENT_BUILD_ENV += PATH=$(dir $(CC.studio.32)):$(PATH)
240a7dc59d6bc135ed298436b59dc86c84928ca2Mark Andrews
e588bfe68951d3a88f56640fdc7e43d8623642f4Mark Andrewsbuild: $(BUILD_32)
e588bfe68951d3a88f56640fdc7e43d8623642f4Mark Andrews
e588bfe68951d3a88f56640fdc7e43d8623642f4Mark Andrewsinstall: $(INSTALL_32)
e588bfe68951d3a88f56640fdc7e43d8623642f4Mark Andrews
02a211f4c4d86f283f9c94bc7e5ab07b547e49f4Mark Andrewstest: $(TEST_32)
02a211f4c4d86f283f9c94bc7e5ab07b547e49f4Mark Andrews #
02a211f4c4d86f283f9c94bc7e5ab07b547e49f4Mark Andrews # 2 expected failures because of the use of cloney in this build.
17be07ab818846dffb79e898da888a29c919bb02Mark Andrews # Without cloney all tests pass.
17be07ab818846dffb79e898da888a29c919bb02Mark Andrews #
17be07ab818846dffb79e898da888a29c919bb02Mark Andrews # Failed 2 tests out of 1697, 99.88% okay.
17be07ab818846dffb79e898da888a29c919bb02Mark Andrews # ../cpan/Archive-Tar/t/02_methods.t
708b78f15764a8836a6f5b6d89d3a6ac05a0ffdaTatuya JINMEI 神明達哉 # ../lib/File/stat.t
708b78f15764a8836a6f5b6d89d3a6ac05a0ffdaTatuya JINMEI 神明達哉 #
20599f3d0e20fe6e253f59f043f3bef5d6635de6Mark Andrews
20599f3d0e20fe6e253f59f043f3bef5d6635de6Mark AndrewsBUILD_PKG_DEPENDENCIES = $(BUILD_TOOLS)
20599f3d0e20fe6e253f59f043f3bef5d6635de6Mark Andrews
38abdbf816fac8386d6f5259d5d6bdfb1b4b3d05Mark Andrewsinclude ../../make-rules/depend.mk
38abdbf816fac8386d6f5259d5d6bdfb1b4b3d05Mark Andrews