Makefile revision 782
5cd4555ad444fd391002ae32450572054369fd42Rob Austein#
5cd4555ad444fd391002ae32450572054369fd42Rob Austein# CDDL HEADER START
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein#
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington# The contents of this file are subject to the terms of the
6ea2385360e9e2167e65f9286447da9eea189457Tinderbox User# Common Development and Distribution License (the "License").
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# You may not use this file except in compliance with the License.
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington#
ec5347e2c775f027573ce5648b910361aa926c01Automatic Updater# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington# or http://www.opensolaris.org/os/licensing.
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington# See the License for the specific language governing permissions
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington# and limitations under the License.
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews#
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews# When distributing Covered Code, include this CDDL HEADER in each
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews# If applicable, add the following below this CDDL HEADER, with the
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews# fields enclosed by brackets "[]" replaced with your own identifying
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews# information: Portions Copyright [yyyy] [name of copyright owner]
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews#
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington# CDDL HEADER END
f5d30e2864e048a42c4dc1134993ae7efdb5d6c3Mark Andrews#
b5ad6dfea4cc3e7d1d322ac99f1e5a31096837c4Mark Andrews# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellington#
1753d3c4d74241a847794f7e7cfd94cc79be6600Evan Huntinclude ../../make-rules/shared-macros.mk
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellington
0b062f4990db5cc6db2fe3398926f71b92a67407Brian WellingtonCOMPONENT_NAME= gzip
0b062f4990db5cc6db2fe3398926f71b92a67407Brian WellingtonCOMPONENT_VERSION= 1.4
0b062f4990db5cc6db2fe3398926f71b92a67407Brian WellingtonCOMPONENT_PROJECT_URL= http://www.gnu.org/software/gzip/
6ed53e5949d9fcd9715b440015b56e5a896d63dfDavid HankinsCOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
0b062f4990db5cc6db2fe3398926f71b92a67407Brian WellingtonCOMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.gz
0b062f4990db5cc6db2fe3398926f71b92a67407Brian WellingtonCOMPONENT_ARCHIVE_HASH= sha1:1d398dac6a7920a7de6e2685fe472a840eb2ce6e
0b062f4990db5cc6db2fe3398926f71b92a67407Brian WellingtonCOMPONENT_ARCHIVE_URL= ftp://ftp.gnu.org/gnu/gzip/$(COMPONENT_ARCHIVE)
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellington
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellingtoninclude ../../make-rules/prep.mk
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellingtoninclude ../../make-rules/configure.mk
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellingtoninclude ../../make-rules/ips.mk
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellington
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinCONFIGURE_OPTIONS += --infodir=$(CONFIGURE_INFODIR)
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinCONFIGURE_OPTIONS += CFLAGS="$(CFLAGS)"
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinCOMPONENT_TEST_ENV += PATH=/usr/gnu/bin:/usr/bin
4b3f3cc67135e676a9b3b688685fb59e3494b0e6Mark AndrewsCOMPONENT_TEST_TARGETS = check
c1a883f2e04d94e99c433b1f6cfd0c0338f4ed85Mark Andrews
3398334b3acda24b086957286288ca9852662b12Automatic Updater# Fix references to Solaris renamed programs (z*->gz*) in man pages, info
39844d471080b2de4f8bb9d81f7e136ef80f0ae2Automatic Updater# pages and in wrapper scripts.
0e27506ce3135f9bd49e12564ad0e15256135118Automatic UpdaterCOMPONENT_PRE_INSTALL_ACTION = \
3b398443f0dca316ba7a6e057ba2d1b8ab4ddf70Tinderbox User (cd $(COMPONENT_SRC) ; \
43b94483957d3168796a816ed86cf097518817dcTinderbox User for file in `ls *.1 doc/*.info z*.in` ; do \
6ea2385360e9e2167e65f9286447da9eea189457Tinderbox User mv $$file $$file.tmp ; \
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein $(GSED) -f $(COMPONENT_DIR)/renaming.sed $$file.tmp > $$file ; \
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein $(RM) $$file.tmp ; \
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein done)
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein# Rename installed programs and man pages in proto dir (z*->gz*).
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinCOMPONENT_POST_INSTALL_ACTION = \
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein (for dir in $(PROTOUSRBINDIR)/$(MACH64) $(PROTOUSRSHAREMAN1DIR) ; do \
f5d30e2864e048a42c4dc1134993ae7efdb5d6c3Mark Andrews cd $$dir; \
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein for zfile in `ls z*`; do \
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein mv $$zfile g$$zfile ; \
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein done ; \
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellington done)
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellington
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellington# Provide missing man pages.
0b062f4990db5cc6db2fe3398926f71b92a67407Brian WellingtonGZGREP_MAN_VARIANTS+=$(PROTOUSRSHAREMAN1DIR)/gzegrep.1
0b062f4990db5cc6db2fe3398926f71b92a67407Brian WellingtonGZGREP_MAN_VARIANTS+=$(PROTOUSRSHAREMAN1DIR)/gzfgrep.1
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellington
eff7f78bc65f30efd87a398e66084ddab72799d3Mark Andrews$(GZGREP_MAN_VARIANTS):
8b78c993cb475cc94e88560941b28c37684789d9Francis Dupont $(RM) $@; echo ".so man1/gzgrep.1" > $@
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellington
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellingtonbuild: $(BUILD_64)
b0c15bd9792112fb47f6d956e580e4369e92f4e7Mark Andrews
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellingtoninstall: $(INSTALL_64) $(GZGREP_MAN_VARIANTS)
553ead32ff5b00284e574dcabc39115d4d74ec66Evan Hunt
b0c15bd9792112fb47f6d956e580e4369e92f4e7Mark Andrewstest: $(TEST_64)
f30785f506a522ed6a5e394af2bb13b6f883927eEvan Hunt
50105afc551903541608b11851d73278b23579a3Mark AndrewsBUILD_PKG_DEPENDENCIES = $(BUILD_TOOLS)
35f6a21f5f8114542c050bfcb484b39ce513d4bdEvan Hunt
0b062f4990db5cc6db2fe3398926f71b92a67407Brian Wellingtoninclude ../../make-rules/depend.mk
e174044290953a2499f574e35cc9c22ba126a303Mark Andrews