components/p7zip/Makefile
author Danek Duvall <danek.duvall@oracle.com>
Fri, 14 Nov 2014 15:24:09 -0800
changeset 2209 69f745d47612
parent 2164 b580bc10e31a
child 3817 30b42c38bbc4
permissions -rw-r--r--
19078624 p7zip version 9.20.1 needs a TPNO at the appropriate juncture
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     1
#
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     2
# CDDL HEADER START
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     3
#
089c2065503f 7016734 move pz7ip 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
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     5
# Common Development and Distribution License (the "License").
089c2065503f 7016734 move pz7ip 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.
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     7
#
089c2065503f 7016734 move pz7ip 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
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
     9
# or http://www.opensolaris.org/os/licensing.
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    10
# See the License for the specific language governing permissions
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    11
# and limitations under the License.
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    12
#
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    13
# When distributing Covered Code, include this CDDL HEADER in each
089c2065503f 7016734 move pz7ip 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.
089c2065503f 7016734 move pz7ip 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
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    16
# fields enclosed by brackets "[]" replaced with your own identifying
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    17
# information: Portions Copyright [yyyy] [name of copyright owner]
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    18
#
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    19
# CDDL HEADER END
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    20
#
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    21
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    22
#
1701
279ed2832e3f 18176569 userland should move to studio 12.3
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1394
diff changeset
    23
# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    24
#
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    25
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    26
include ../../make-rules/shared-macros.mk
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    27
139
5ae244456983 7016734 move pz7ip from sfw to userland (fix path)
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 138
diff changeset
    28
PATH=$(SPRO_VROOT)/bin:/usr/bin:/usr/gnu/bin
1394
5f86498eee95 16991973 some things ain't parfait'n
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1205
diff changeset
    29
ifeq   ($(strip $(PARFAIT_BUILD)),yes)
5f86498eee95 16991973 some things ain't parfait'n
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1205
diff changeset
    30
PATH=$(PARFAIT_TOOLS):$(SPRO_VROOT)/bin:/usr/bin
5f86498eee95 16991973 some things ain't parfait'n
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1205
diff changeset
    31
endif
139
5ae244456983 7016734 move pz7ip from sfw to userland (fix path)
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 138
diff changeset
    32
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    33
COMPONENT_NAME=		p7zip
421
032ffcef8039 7068248 p7zip 9.20.1
Danek Duvall <danek.duvall@oracle.com>
parents: 181
diff changeset
    34
COMPONENT_VERSION=	9.20.1
609
775168282b2f 7037821 Userland migration of data from Makefile to manifest may have been a little overzealous
Rich Burridge <rich.burridge@oracle.com>
parents: 421
diff changeset
    35
COMPONENT_PROJECT_URL=	http://p7zip.sourceforge.net/
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    36
COMPONENT_SRC=		$(COMPONENT_NAME)_$(COMPONENT_VERSION)
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    37
COMPONENT_ARCHIVE=	$(COMPONENT_SRC)_src_all.tar.bz2
800
2ad056ed89ec 7163771 sha1 should not be used in userland-fetch and userland component/*/Makefile
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 609
diff changeset
    38
COMPONENT_ARCHIVE_HASH=	\
2ad056ed89ec 7163771 sha1 should not be used in userland-fetch and userland component/*/Makefile
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 609
diff changeset
    39
    sha256:49557e7ffca08100f9fc687f4dfc5aea703ca207640c76d9dee7b66f03cb4782
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    40
COMPONENT_ARCHIVE_URL=	http://downloads.sourceforge.net/project/p7zip/p7zip/$(COMPONENT_VERSION)/$(COMPONENT_ARCHIVE)
1058
34d7aaa03423 15886624 Auto-generation of Userland gate list - Phase 3
Rich Burridge <rich.burridge@oracle.com>
parents: 800
diff changeset
    41
COMPONENT_BUGDB=	utility/p7zip
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    42
2209
69f745d47612 19078624 p7zip version 9.20.1 needs a TPNO at the appropriate juncture
Danek Duvall <danek.duvall@oracle.com>
parents: 2164
diff changeset
    43
TPNO=			20368
69f745d47612 19078624 p7zip version 9.20.1 needs a TPNO at the appropriate juncture
Danek Duvall <danek.duvall@oracle.com>
parents: 2164
diff changeset
    44
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    45
include ../../make-rules/prep.mk
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    46
include ../../make-rules/justmake.mk
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    47
include ../../make-rules/ips.mk
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    48
1701
279ed2832e3f 18176569 userland should move to studio 12.3
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1394
diff changeset
    49
# the tests fail horribly with -Bdirect
279ed2832e3f 18176569 userland should move to studio 12.3
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1394
diff changeset
    50
LD_B_DIRECT=
279ed2832e3f 18176569 userland should move to studio 12.3
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1394
diff changeset
    51
2164
b580bc10e31a 19824924 Various Userland component test: Makefile targets should be standardized
Rich Burridge <rich.burridge@oracle.com>
parents: 2075
diff changeset
    52
COMPONENT_TEST_DIR =		$(@D)
b580bc10e31a 19824924 Various Userland component test: Makefile targets should be standardized
Rich Burridge <rich.burridge@oracle.com>
parents: 2075
diff changeset
    53
COMPONENT_TEST_ENV =		P7ZIP_HOME_DIR=$(BUILD_DIR)/$(MACH$(BITS))/bin
b580bc10e31a 19824924 Various Userland component test: Makefile targets should be standardized
Rich Burridge <rich.burridge@oracle.com>
parents: 2075
diff changeset
    54
COMPONENT_TEST_TARGETS =	test test_7z test_7zr
b580bc10e31a 19824924 Various Userland component test: Makefile targets should be standardized
Rich Burridge <rich.burridge@oracle.com>
parents: 2075
diff changeset
    55
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    56
COMPONENT_PREP_ACTION = (cd $(@D); cp ../makefile.solaris makefile.machine)
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    57
COMPONENT_BUILD_TARGETS = all3
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    58
COMPONENT_INSTALL_ARGS += DEST_HOME=/usr DEST_DIR=$(PROTO_DIR)
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    59
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    60
$(SOURCE_DIR)/DOCS/copying.txt $(SOURCE_DIR)/DOCS/unRarLicense.txt: prep
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    61
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    62
$(BUILD_DIR)/%: $(SOURCE_DIR)/DOCS/%
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    63
	$(CP) $< $@
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    64
1205
6c6c27bcf9ac 16431724 Adjust how license text and Oracle internal tracking numbers are propagated
Rich Burridge <rich.burridge@oracle.com>
parents: 1058
diff changeset
    65
$(BUILD_DIR)/copying.txt: $(SOURCE_DIR)/DOCS/copying.txt
6c6c27bcf9ac 16431724 Adjust how license text and Oracle internal tracking numbers are propagated
Rich Burridge <rich.burridge@oracle.com>
parents: 1058
diff changeset
    66
	$(CP) $(SOURCE_DIR)/DOCS/copying.txt $@
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    67
2075
17fc4867be16 19581879 p7zip 64-bit and ASLR
Michael Nestler <Michael.Nestler@Oracle.COM>
parents: 1930
diff changeset
    68
ASLR_MODE = $(ASLR_ENABLE)
17fc4867be16 19581879 p7zip 64-bit and ASLR
Michael Nestler <Michael.Nestler@Oracle.COM>
parents: 1930
diff changeset
    69
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    70
# common targets
2075
17fc4867be16 19581879 p7zip 64-bit and ASLR
Michael Nestler <Michael.Nestler@Oracle.COM>
parents: 1930
diff changeset
    71
build:		$(BUILD_64)
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    72
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    73
EXTRATARGETS = \
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    74
	$(BUILD_DIR)/copying.txt $(BUILD_DIR)/unRarLicense.txt
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    75
2075
17fc4867be16 19581879 p7zip 64-bit and ASLR
Michael Nestler <Michael.Nestler@Oracle.COM>
parents: 1930
diff changeset
    76
install:	build $(INSTALL_64) $(EXTRATARGETS)
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    77
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    78
# When p7zip's install target is run, it creates all its directories mode 555,
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    79
# so they're impossible to remove without adding the write bit first.
1930
062897f667fa 18897274 /usr/share/man/man1/7zr.1 should be delivered by unix text format
Danek Duvall <danek.duvall@oracle.com>
parents: 1701
diff changeset
    80
COMPONENT_POST_INSTALL_ACTION += $(CHMOD) -R u+w $(PROTO_DIR);
062897f667fa 18897274 /usr/share/man/man1/7zr.1 should be delivered by unix text format
Danek Duvall <danek.duvall@oracle.com>
parents: 1701
diff changeset
    81
# 7zr.1 is in DOS format for some reason, and geqn can't handle it.
062897f667fa 18897274 /usr/share/man/man1/7zr.1 should be delivered by unix text format
Danek Duvall <danek.duvall@oracle.com>
parents: 1701
diff changeset
    82
COMPONENT_POST_INSTALL_ACTION += $(GSED) -i -e 's/\r//' $(PROTO_DIR)/usr/man/man1/7zr.1
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    83
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    84
# build does this always
2164
b580bc10e31a 19824924 Various Userland component test: Makefile targets should be standardized
Rich Burridge <rich.burridge@oracle.com>
parents: 2075
diff changeset
    85
test:	$(TEST_64)
138
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    86
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    87
BUILD_PKG_DEPENDENCIES =	$(BUILD_TOOLS)
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    88
089c2065503f 7016734 move pz7ip from sfw to userland
Danek Duvall <danek.duvall@oracle.com>
parents:
diff changeset
    89
include ../../make-rules/depend.mk