Andreas Wacknitz
2023-10-30 793d94d18e377f0ba4e3135d7c8381465924a5a4
commit | author | age
bbaf7a 1 #
AP 2 # CDDL HEADER START
3 #
4 # The contents of this file are subject to the terms of the
5 # Common Development and Distribution License (the "License").
6 # You may not use this file except in compliance with the License.
7 #
8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 # or http://www.opensolaris.org/os/licensing.
10 # See the License for the specific language governing permissions
11 # and limitations under the License.
12 #
13 # When distributing Covered Code, include this CDDL HEADER in each
14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 # If applicable, add the following below this CDDL HEADER, with the
16 # fields enclosed by brackets "[]" replaced with your own identifying
17 # information: Portions Copyright [yyyy] [name of copyright owner]
18 #
19 # CDDL HEADER END
20 #
21
22 #
68c100 23 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved.
5dfbed 24 # Copyright (c) 2023, Andreas Wacknitz
bbaf7a 25 #
827a06 26
5dfbed 27 BUILD_BITS= 64
827a06 28 USE_DEFAULT_TEST_TRANSFORMS= yes
bbaf7a 29 include ../../../make-rules/shared-macros.mk
AP 30
31 COMPONENT_NAME=            ImageMagick
5dfbed 32 COMPONENT_VERSION=        7.1.1
42e67e 33 COMPONENT_SUBVERSION=        21
bbaf7a 34 HUMAN_VERSION=            $(COMPONENT_VERSION)-$(COMPONENT_SUBVERSION)
8f8bee 35 IPS_COMPONENT_VERSION=    $(COMPONENT_VERSION).$(COMPONENT_SUBVERSION)
793d94 36 COMPONENT_REVISION=        1
bbaf7a 37 COMPONENT_SUMMARY=        ImageMagick - Image Manipulation Utilities and Libraries
42e67e 38 COMPONENT_PROJECT_URL=    https://imagemagick.org
5dfbed 39 COMPONENT_SRC=            $(COMPONENT_NAME)-$(COMPONENT_VERSION)-$(COMPONENT_SUBVERSION)
563d9d 40 COMPONENT_ARCHIVE=        $(COMPONENT_NAME)-$(HUMAN_VERSION).tar.gz
42e67e 41 COMPONENT_ARCHIVE_HASH=    sha256:09402e5f17c6575ef9f010bb2e21ae1710f1f3426f115ad4317ee9129c32608e
5dfbed 42 COMPONENT_ARCHIVE_URL=    https://github.com/ImageMagick/ImageMagick/archive/$(HUMAN_VERSION).tar.gz
827a06 43 COMPONENT_FMRI=            image/imagemagick
AW 44 COMPONENT_CLASSIFICATION=    System/Multimedia Libraries
8f8bee 45 COMPONENT_LICENSE= Apache 2.0 license
AW 46 COMPONENT_LICENSE_FILE= LICENSE
bbaf7a 47
8f8bee 48 include $(WS_MAKE_RULES)/common.mk
bbaf7a 49
5dfbed 50 COMPONENT_PREP_ACTION = ( cd $(@D) && libtoolize -f && autoreconf -fi )
bbaf7a 51
AP 52 # To get the Perl modules built it is necessary to copy the PerlMagick directory
53 # to the build directory
54 #
5dfbed 55 COMPONENT_PRE_CONFIGURE_ACTION= ( $(CP) -R $(SOURCE_DIR)/PerlMagick $(@D) )
bbaf7a 56
AP 57 # Don't use rpath, or relink!
58 COMPONENT_POST_CONFIGURE_ACTION = \
59     (cd $(BUILD_DIR_$(BITS)) ; \
60     $(GSED) -i \
61     -e 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' \
62     -e 's|need_relink=yes|need_relink=not_on_solaris|' \
63     libtool)
64
65 LIBS += -lsocket -lnsl
66 CONFIGURE_ENV += LIBS="$(LIBS)"
67
68c100 68 # build with the distribution preferred libjpeg implementation
AL 69 CFLAGS   += $(JPEG_CPPFLAGS) $(JPEG_CFLAGS)
70 CXXFLAGS += $(JPEG_CPPFLAGS) $(JPEG_CXXFLAGS)
71 LDFLAGS  += $(JPEG_LDFLAGS)
bbaf7a 72
5dfbed 73 CONFIGURE_OPTIONS += --with-modules
AW 74 CONFIGURE_OPTIONS += --enable-shared
75 CONFIGURE_OPTIONS += --disable-static
bbaf7a 76 # Using option 'with-fontconfig=no' so that the fonts/fonts path specified in
AP 77 # configuration file 'type-ghostscript.xml' is being used.
5dfbed 78 #CONFIGURE_OPTIONS+= --with-fontconfig=no
bbaf7a 79 # Configure option 'with-gs-font-dir' is required because some build systems might 
AP 80 # not have ghostscript fonts installed.
5dfbed 81 CONFIGURE_OPTIONS += --with-gs-font-dir="/usr/share/ghostscript/fonts"
AW 82 CONFIGURE_OPTIONS += --x-libraries=$(CONFIGURE_LIBDIR.$(BITS)) 
83 CONFIGURE_OPTIONS += --with-perl=$(PERL)
84 CONFIGURE_OPTIONS += --with-perl-options="INSTALLDIRS=vendor"
85 CONFIGURE_OPTIONS += --sysconfdir=/etc
86
87 # As of version 7.1.0-34, a "Linux-compatible sendfile()" is detected;
88 # override thiis.
89 CONFIGURE_OPTIONS += ac_cv_have_linux_sendfile=no
bbaf7a 90
9a68c5 91 # Needed for "gmake test" to work successfully.  If SHELLOPTS is exported (as
AP 92 # it is by the Userland Makefiles), then all shell options get exported to
93 # child invocations of bash, which results in test failures due to nounset and
94 # xtrace being set unexpectedly, and errors such as "$1: unbound variable" and
95 # diffs failing due to script tracing in output files.
96 unexport SHELLOPTS
97
98 # Tests hang waiting for input unless stdin is redirected.
99 COMPONENT_TEST_TARGETS = check < /dev/null
100
aa81e1 101 # PKGVERS is needed for manifest processing
MT 102 PKG_MACROS += PERLVER=$(PERL_VERSION)
103
68c100 104 # Build dependencies
AL 105 REQUIRED_PACKAGES += print/filter/ghostscript/fonts/gnu-gs-fonts-std
106
107 # Auto-generated dependencies
563d9d 108 REQUIRED_PACKAGES += $(GCC_RUNTIME_PKG)
MT 109 REQUIRED_PACKAGES += $(GXX_RUNTIME_PKG)
827a06 110 REQUIRED_PACKAGES += $(JPEG_IMPLEM_PKG)
bbaf7a 111 REQUIRED_PACKAGES += compress/bzip2
AP 112 REQUIRED_PACKAGES += compress/xz
113 REQUIRED_PACKAGES += image/djvulibre
5dfbed 114 REQUIRED_PACKAGES += image/graphviz
bbaf7a 115 REQUIRED_PACKAGES += image/library/libpng16
8c1e0e 116 REQUIRED_PACKAGES += image/library/libraw
bbaf7a 117 REQUIRED_PACKAGES += image/library/libtiff
AP 118 REQUIRED_PACKAGES += image/library/openjpeg
119 REQUIRED_PACKAGES += library/desktop/cairo
120 REQUIRED_PACKAGES += library/desktop/pango
121 REQUIRED_PACKAGES += library/glib2
122 REQUIRED_PACKAGES += library/lcms2
123 REQUIRED_PACKAGES += library/libtool/libltdl
124 REQUIRED_PACKAGES += library/libwebp
125 REQUIRED_PACKAGES += library/libxml2
5dfbed 126 REQUIRED_PACKAGES += library/libzip
68c100 127 REQUIRED_PACKAGES += library/openexr
bbaf7a 128 REQUIRED_PACKAGES += library/zlib
563d9d 129 REQUIRED_PACKAGES += shell/ksh93
bbaf7a 130 REQUIRED_PACKAGES += system/library
5dfbed 131 REQUIRED_PACKAGES += system/library/fontconfig
bbaf7a 132 REQUIRED_PACKAGES += system/library/freetype-2
AP 133 REQUIRED_PACKAGES += system/library/math
134 REQUIRED_PACKAGES += x11/library/libx11
135 REQUIRED_PACKAGES += x11/library/libxext