Makefile revision 729
184N/A#
184N/A# CDDL HEADER START
184N/A#
184N/A# The contents of this file are subject to the terms of the
184N/A# Common Development and Distribution License (the "License").
184N/A# You may not use this file except in compliance with the License.
184N/A#
184N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
184N/A# or http://www.opensolaris.org/os/licensing.
184N/A# See the License for the specific language governing permissions
184N/A# and limitations under the License.
184N/A#
184N/A# When distributing Covered Code, include this CDDL HEADER in each
184N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
184N/A# If applicable, add the following below this CDDL HEADER, with the
184N/A# fields enclosed by brackets "[]" replaced with your own identifying
184N/A# information: Portions Copyright [yyyy] [name of copyright owner]
184N/A#
184N/A# CDDL HEADER END
184N/A#
184N/A
184N/A#
184N/A# Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
184N/A#
184N/A
184N/Ainclude ../../make-rules/shared-macros.mk
184N/A
184N/ACOMPONENT_NAME= zlib
184N/ACOMPONENT_VERSION= 1.2.3
618N/ACOMPONENT_PROJECT_URL= http://www.zlib.net/
184N/ACOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
184N/ACOMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.gz
184N/ACOMPONENT_ARCHIVE_HASH= sha1:60faeaaf250642db5c0ea36cd6dcc9f99c8f3902
184N/ACOMPONENT_ARCHIVE_URL= http://downloads.sourceforge.net/project/libpng/zlib/$(COMPONENT_VERSION)/$(COMPONENT_ARCHIVE)
184N/A
184N/Ainclude ../../make-rules/prep.mk
184N/Ainclude ../../make-rules/configure.mk
184N/Ainclude ../../make-rules/ips.mk
184N/Ainclude ../../make-rules/lint-libraries.mk
184N/A
184N/A# Zlib won't build without cloning. We need also to get rid of default
184N/A# Makefile and get our own version of zlib.h to avoid interactions
184N/A# between 32 and 64 bit builds.
184N/ACOMPONENT_PRE_CONFIGURE_ACTION = ( \
184N/A $(CLONEY) $(SOURCE_DIR) $(@D); \
184N/A $(RM) $(@D)/Makefile $(@D)/zconf.h; \
184N/A $(CP) $(SOURCE_DIR)/zconf.h $(@D) )
184N/A
184N/ACFLAGS += $(CC_PIC)
184N/A
184N/A# We need to reset configure options here because zlib is confused with
184N/A# CC and CFLAGS definitions as configure parameters.
184N/ACONFIGURE_OPTIONS = --shared
184N/ACONFIGURE_OPTIONS += --prefix=/usr
184N/ACONFIGURE_OPTIONS += $(CONFIGURE_OPTIONS.$(BITS))
184N/ACONFIGURE_OPTIONS.64 += --libdir=/usr/lib/$(MACH64)
184N/A
184N/ACONFIGURE_ENV += CC="$(CC)"
184N/ACONFIGURE_ENV += CFLAGS="$(CFLAGS)"
184N/ACONFIGURE_ENV += LDSHARED="$(CC) $(CFLAGS) -G"
184N/A
184N/A# This LDSHARED definitions is forced to get all required options plus
184N/A# mapfile for result linking. While the one used with configure is just
184N/A# to allow Zlib detect capability of creating shared libraries.
184N/ACOMPONENT_BUILD_ARGS = LDSHARED="$(CC) $(CFLAGS) -G -h libz.so.1 $(LD_OPTIONS_SO) -M ../../mapfile -L."
184N/A
184N/ACOMPONENT_TEST_TARGETS = test
184N/A
184N/Abuild: $(BUILD_32_and_64)
184N/A
184N/Ainstall: $(INSTALL_32_and_64)
184N/A
184N/Atest: $(TEST_32_and_64)
184N/A
184N/ABUILD_PKG_DEPENDENCIES = $(BUILD_TOOLS)
184N/A
184N/Ainclude ../../make-rules/depend.mk