Makefile revision 1202
98N/A#
98N/A# CDDL HEADER START
98N/A#
98N/A# The contents of this file are subject to the terms of the
493N/A# Common Development and Distribution License (the "License").
98N/A# You may not use this file except in compliance with the License.
98N/A#
98N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
98N/A# or http://www.opensolaris.org/os/licensing.
98N/A# See the License for the specific language governing permissions
98N/A# and limitations under the License.
98N/A#
98N/A# When distributing Covered Code, include this CDDL HEADER in each
98N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
98N/A# If applicable, add the following below this CDDL HEADER, with the
98N/A# fields enclosed by brackets "[]" replaced with your own identifying
98N/A# information: Portions Copyright [yyyy] [name of copyright owner]
98N/A#
98N/A# CDDL HEADER END
98N/A#
98N/A# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
98N/A#
98N/Ainclude ../../make-rules/shared-macros.mk
98N/A
98N/ACOMPONENT_NAME= gzip
98N/ACOMPONENT_VERSION= 1.5
98N/ACOMPONENT_PROJECT_URL= http://www.gnu.org/software/gzip/
98N/ACOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
98N/ACOMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.gz
98N/ACOMPONENT_ARCHIVE_HASH= \
98N/A sha256:b5d56e8ffc9918e8c941fab56e04121194f9870adeeb859e09c09eac264035a3
98N/ACOMPONENT_ARCHIVE_URL= ftp://ftp.gnu.org/gnu/gzip/$(COMPONENT_ARCHIVE)
601N/A
98N/Ainclude ../../make-rules/prep.mk
98N/Ainclude ../../make-rules/configure.mk
98N/Ainclude ../../make-rules/ips.mk
493N/A
98N/A# To get correct @bindir@ substitution in the various gz<whatever> scripts.
98N/ACONFIGURE_BINDIR.64 = $(CONFIGURE_PREFIX)/bin
601N/A
98N/ACONFIGURE_OPTIONS += --infodir=$(CONFIGURE_INFODIR)
98N/ACONFIGURE_OPTIONS += CFLAGS="$(CFLAGS)"
601N/A
98N/A# Needed for "gmake test" to work successfully.
98N/A# If SHELLOPTS is exported (as it is by the userland makefiles),
98N/A# then all shell options get exported to child invocations of bash,
493N/A# which results in test failures due to nounset and xtrace being
493N/A# set unexpectedly, and errors such as "$1: unbound variable" and
98N/A# diffs failing due to script tracing in output files.
98N/Aunexport SHELLOPTS
493N/A
493N/A# Get the binaries to test from the component build area.
493N/ACOMPONENT_TEST_ENV += PATH=$(BUILD_DIR_$(BITS)):/usr/xpg4/bin:/usr/bin
194N/ACOMPONENT_TEST_TARGETS = check
98N/A
98N/A# Fix references to Solaris renamed programs (z*->gz*) in man pages, info
# pages and in wrapper scripts.
COMPONENT_PRE_INSTALL_ACTION = \
(cd $(COMPONENT_SRC) ; \
for file in `ls *.1 doc/*.info z*.in` ; do \
mv $$file $$file.tmp ; \
$(GSED) -f $(COMPONENT_DIR)/renaming.sed $$file.tmp > $$file ; \
$(RM) $$file.tmp ; \
done)
# Rename installed programs and man pages in proto dir (z*->gz*).
COMPONENT_POST_INSTALL_ACTION = \
(for dir in $(PROTOUSRBINDIR) $(PROTOUSRSHAREMAN1DIR) ; do \
cd $$dir; \
for zfile in `ls z*`; do \
mv $$zfile g$$zfile ; \
done ; \
done)
# Provide missing man pages.
GZGREP_MAN_VARIANTS+=$(PROTOUSRSHAREMAN1DIR)/gzegrep.1
GZGREP_MAN_VARIANTS+=$(PROTOUSRSHAREMAN1DIR)/gzfgrep.1
$(GZGREP_MAN_VARIANTS):
$(RM) $@; echo ".so man1/gzgrep.1" > $@
build: $(BUILD_64)
install: $(INSTALL_64) $(GZGREP_MAN_VARIANTS)
test: $(TEST_64)
BUILD_PKG_DEPENDENCIES = $(BUILD_TOOLS)
include ../../make-rules/depend.mk