Makefile revision 2300
0N/A#
381N/A# CDDL HEADER START
0N/A#
0N/A# The contents of this file are subject to the terms of the
0N/A# Common Development and Distribution License (the "License").
0N/A# You may not use this file except in compliance with the License.
0N/A#
0N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
0N/A# or http://www.opensolaris.org/os/licensing.
0N/A# See the License for the specific language governing permissions
0N/A# and limitations under the License.
0N/A#
0N/A# When distributing Covered Code, include this CDDL HEADER in each
0N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
0N/A# If applicable, add the following below this CDDL HEADER, with the
0N/A# fields enclosed by brackets "[]" replaced with your own identifying
0N/A# information: Portions Copyright [yyyy] [name of copyright owner]
0N/A#
0N/A# CDDL HEADER END
0N/A#
0N/A
0N/A#
0N/A# Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
0N/A#
0N/A
0N/Ainclude ../../make-rules/shared-macros.mk
2080N/A
0N/ACOMPONENT_NAME= ImageMagick
0N/ACOMPONENT_VERSION= 6.8.3
0N/ACOMPONENT_SUBVERSION= 5
0N/AHUMAN_VERSION= $(COMPONENT_VERSION)-$(COMPONENT_SUBVERSION)
0N/ACOMPONENT_PROJECT_URL= http://www.imagemagick.org/
0N/ACOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
0N/ACOMPONENT_ARCHIVE= $(COMPONENT_SRC)-$(COMPONENT_SUBVERSION).tar.gz
0N/ACOMPONENT_ARCHIVE_HASH= \
0N/A sha256:daead80170bc6d44cf6a54b4817446cbb7211b8ee445532b64033af190265fe3
0N/ACOMPONENT_ARCHIVE_URL= http://image_magick.veidrodis.com/image_magick/$(COMPONENT_ARCHIVE)
0N/ACOMPONENT_BUGDB= utility/imagemagick
0N/A
0N/Ainclude ../../make-rules/prep.mk
0N/Ainclude ../../make-rules/configure.mk
0N/Ainclude ../../make-rules/ips.mk
0N/A
0N/APATH=$(SPRO_VROOT)/bin:/usr/bin:/usr/gnu/bin
295N/A
295N/A# IPS_COMPONENT_VERSION is by default set to $(COMPONENT_VERSION) but in
0N/A# this case we need to replace the '-' by '.'.
0N/A#
2080N/AIPS_COMPONENT_VERSION= $(COMPONENT_VERSION).$(COMPONENT_SUBVERSION)
2080N/A
0N/ACOMPONENT_POST_UNPACK_ACTION= ( $(MV) $(COMPONENT_SRC)-$(COMPONENT_SUBVERSION) \
0N/A $(COMPONENT_SRC))
2080N/A
2080N/A# To get the Perl modules built it is necessary to copy the PerlMagick directory
0N/A# to the build directory
0N/A#
2080N/ACOMPONENT_PRE_CONFIGURE_ACTION= ($(CP) -R $(SOURCE_DIR)/PerlMagick $(@D))
2080N/A
0N/ALIBS += -lsocket -lnsl
0N/ACONFIGURE_ENV += LIBS="$(LIBS)"
2080N/A
2080N/A# Show name of "error tag" as part of the warning
0N/A#
0N/ACFLAGS += -errtags=yes
2080N/A# To remove the complier complaints about __restrict keyword,
2080N/A# -D_magickcore_restrict should be used.
0N/ACFLAGS += -xc99=%all -D_magickcore_restrict=
0N/A
0N/A# Needed to generate a decent RUNPATH for Magick.so
0N/A#
0N/ACOMPONENT_BUILD_ARGS += LD="$(CC)"
0N/ACOMPONENT_BUILD_ARGS += LD_RUN_PATH="$(CONFIGURE_LIBDIR.$(BITS))"
0N/A
0N/ACONFIGURE_OPTIONS+= CFLAGS="$(CFLAGS)"
0N/ACONFIGURE_OPTIONS+= CXXFLAGS="$(CXXFLAGS)"
0N/ACONFIGURE_OPTIONS+= --with-modules
0N/ACONFIGURE_OPTIONS+= --enable-shared=yes
0N/ACONFIGURE_OPTIONS+= --enable-static=no
0N/ACONFIGURE_OPTIONS+= --without-gvc
0N/ACONFIGURE_OPTIONS+= --disable-openmp
0N/A# Using option 'with-fontconfig=no' so that the fonts/fonts path specified in
0N/A# configuration file 'type-ghostscript.xml' is being used.
0N/ACONFIGURE_OPTIONS+= --with-fontconfig=no
0N/A# Configure option 'with-gs-font-dir' is required because some build systems might
# not have ghostscript fonts installed.
CONFIGURE_OPTIONS+= --with-gs-font-dir="/usr/share/ghostscript/fonts"
CONFIGURE_OPTIONS+= --x-libraries=$(CONFIGURE_LIBDIR.$(BITS))
CONFIGURE_OPTIONS.32+= --with-perl=$(PERL)
CONFIGURE_OPTIONS.32+= --with-perl-options="INSTALLDIRS=vendor"
CONFIGURE_OPTIONS.64+= --without-perl
# common targets
#
build: $(BUILD_32_and_64)
# Remove build machine runpath from libMagick++-6.Q16.so.1.0.0 and
# libMagickCore-6.Q16.so.1.0.0
install: $(INSTALL_32_and_64)
/usr/bin/elfedit -e 'dyn:delete RUNPATH' \
$(PROTO_DIR)/usr/lib/libMagick++-6.Q16.so.1.0.0; \
/usr/bin/elfedit -e 'dyn:delete RUNPATH' \
$(PROTO_DIR)/usr/lib/$(MACH64)/libMagick++-6.Q16.so.1.0.0; \
/usr/bin/elfedit -e 'dyn:delete RPATH' \
$(PROTO_DIR)/usr/lib/libMagick++-6.Q16.so.1.0.0; \
/usr/bin/elfedit -e 'dyn:delete RPATH' \
$(PROTO_DIR)/usr/lib/$(MACH64)/libMagick++-6.Q16.so.1.0.0
/usr/bin/elfedit -e 'dyn:delete RUNPATH' \
$(PROTO_DIR)/usr/lib/libMagickCore-6.Q16.so.1.0.0; \
/usr/bin/elfedit -e 'dyn:delete RUNPATH' \
$(PROTO_DIR)/usr/lib/$(MACH64)/libMagickCore-6.Q16.so.1.0.0; \
/usr/bin/elfedit -e 'dyn:delete RPATH' \
$(PROTO_DIR)/usr/lib/libMagickCore-6.Q16.so.1.0.0; \
/usr/bin/elfedit -e 'dyn:delete RPATH' \
$(PROTO_DIR)/usr/lib/$(MACH64)/libMagickCore-6.Q16.so.1.0.0
# ImageMagick tests have hard-coded absolute paths inside, so essentially they
# can be run only after ImageMagick is actually installed and this is not
# possible, so the tests are not invoked.
#
test: $(NO_TESTS)
@echo "Tests can be run only after ImageMagick is installed."
BUILD_PKG_DEPENDENCIES= $(BUILD_TOOLS)
include ../../make-rules/depend.mk