components/ghostscript/Makefile
changeset 178 4340c0d63702
child 181 87e11e685b1f
equal deleted inserted replaced
177:fd9cb2273c9d 178:4340c0d63702
       
     1 #
       
     2 #
       
     3 # CDDL HEADER START
       
     4 #
       
     5 # The contents of this file are subject to the terms of the
       
     6 # Common Development and Distribution License (the "License").
       
     7 # You may not use this file except in compliance with the License.
       
     8 #
       
     9 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
       
    10 # or http://www.opensolaris.org/os/licensing.
       
    11 # See the License for the specific language governing permissions
       
    12 # and limitations under the License.
       
    13 #
       
    14 # When distributing Covered Code, include this CDDL HEADER in each
       
    15 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
       
    16 # If applicable, add the following below this CDDL HEADER, with the
       
    17 # fields enclosed by brackets "[]" replaced with your own identifying
       
    18 # information: Portions Copyright [yyyy] [name of copyright owner]
       
    19 #
       
    20 # CDDL HEADER END
       
    21 #
       
    22 # Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
       
    23 #
       
    24 include ../../make-rules/shared-macros.mk
       
    25 
       
    26 COMPONENT_NAME=         ghostscript
       
    27 COMPONENT_VERSION=      8.64
       
    28 COMPONENT_SRC=          $(COMPONENT_NAME)-$(COMPONENT_VERSION)
       
    29 COMPONENT_ARCHIVE=      $(COMPONENT_SRC).tar.gz
       
    30 COMPONENT_ARCHIVE_HASH= sha1:2e56a2fdd7912c0d04ad52c05d0e93e3e473b131
       
    31 COMPONENT_ARCHIVE_URL=  http://ghostscript.com/releases/$(COMPONENT_ARCHIVE)
       
    32 
       
    33 include ../../make-rules/prep.mk
       
    34 include ../../make-rules/ips.mk
       
    35 include ../../make-rules/configure.mk
       
    36 
       
    37 # configure(1) options to use
       
    38 CONFIGURE_OPTIONS +=	--with-drivers=ALL
       
    39 CONFIGURE_OPTIONS +=	--with-ijs
       
    40 CONFIGURE_OPTIONS +=	--without-omni
       
    41 CONFIGURE_OPTIONS +=	--with-jbig2dec
       
    42 CONFIGURE_OPTIONS +=	--with-jasper
       
    43 CONFIGURE_OPTIONS +=	--enable-cups
       
    44 CONFIGURE_OPTIONS +=	--enable-dynamic
       
    45 CONFIGURE_OPTIONS +=	--disable-compile-inits
       
    46 CONFIGURE_OPTIONS +=	--with-fontpath=/usr/share/ghostscript/$(COMPONENT_VERSION)/Resource:/usr/share/ghostscript/$(COMPONENT_VERSION)/Resource/Font:/usr/share/ghostscript/fonts:/usr/openwin/lib/X11/fonts/Type1:/usr/openwin/lib/X11/fonts/TrueType:/usr/openwin/lib/X11/fonts/Type3:/usr/X11/lib/X11/fonts/Type1:/usr/X11/lib/fonts/TrueType:/usr/X11/lib/X11/fonts/Type3:/usr/X11/lib/X11/fonts/Resource:/usr/X11/lib/X11/Resource/Font
       
    47 
       
    48 # config env
       
    49 CONFIGURE_ENV += LDFLAGS_SO="-G"
       
    50 CONFIGURE_ENV += CUPSCONFIG=/usr/bin/cups-config
       
    51 
       
    52 GS_VARIANT = $(BUILD_DIR)/$(MACH32)
       
    53 IJS_VARIANT = $(BUILD_DIR)/$(MACH32)/ijs
       
    54 
       
    55 VARIANTS = $(GS_VARIANT) $(IJS_VARIANT)
       
    56 
       
    57 # autoconf - Generate configuration scripts
       
    58 COMPONENT_PREP_ACTION = \
       
    59 	 (cd $(@D)/jasper/src/libjasper/jpc ; \
       
    60 	 $(MV) jpc_qmfb.c jpc_qmfb.c.orig ; \
       
    61 	 dos2unix jpc_qmfb.c.orig >jpc_qmfb.c) ; \
       
    62 	 (cd $(@D); autoconf)
       
    63 
       
    64 $(GS_VARIANT)/.configured: COMPONENT_PRE_CONFIGURE_ACTION = \
       
    65 	($(CLONEY) $(SOURCE_DIR) $(@D))
       
    66 
       
    67 $(GS_VARIANT)/.installed: COMPONENT_INSTALL_TARGETS += \
       
    68 	install-exec install-so install-scripts install-data \
       
    69 	install-contrib-extras
       
    70 
       
    71 $(IJS_VARIANT)/.configured: COMPONENT_PRE_CONFIGURE_ACTION = \
       
    72 	($(CLONEY) $(SOURCE_DIR)/ijs $(@D); \
       
    73 	cd $(@D) ; $(ENV) $(CONFIGURE_ENV) autogen.sh )
       
    74 
       
    75 CONFIGURE_SCRIPT = ./configure
       
    76 
       
    77 # build gs and ijs
       
    78 build: $(VARIANTS:%=%/.built)
       
    79 
       
    80 # install gs and ijs
       
    81 install: $(VARIANTS:%=%/.installed)
       
    82 
       
    83 # empty test target
       
    84 test:
       
    85 	@echo "no tests available"
       
    86 
       
    87 include ../../make-rules/depend.mk