Makefile revision 328
0N/A#
0N/A#
0N/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# Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
0N/A#
0N/Ainclude ../../make-rules/shared-macros.mk
0N/A
0N/ACOMPONENT_NAME= hplip
0N/ACOMPONENT_VERSION= 3.10.9
0N/ACOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
0N/ACOMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.gz
0N/ACOMPONENT_ARCHIVE_HASH= sha1:5e145eafefbc5122bbe98345f2984fc0a55e5787
0N/ACOMPONENT_ARCHIVE_URL= http://sourceforge.net/projects/hplip/files/hplip/$(COMPONENT_VERSION)/$(COMPONENT_ARCHIVE)
0N/A
0N/Ainclude ../../make-rules/prep.mk
0N/Ainclude ../../make-rules/configure.mk
0N/Ainclude ../../make-rules/ips.mk
0N/A
0N/A# We need to be able to return from void functions
0N/ACC += $(studio_FEATURES_EXTENSIONS)
0N/ACXX += $(studio_FEATURES_EXTENSIONS) $(studio_NORUNPATH) $(studio_LIBRARY_NONE)
0N/A
0N/AROOTPPDCACHE = $(PROTO_DIR)/usr/lib/lp/caches/SUNWhpijs.cache
0N/A
0N/A# configure(1) options to use
0N/ACONFIGURE_OPTIONS += --localedir=$(CONFIGURE_LOCALEDIR)
0N/ACONFIGURE_OPTIONS += --disable-pp-build
0N/ACONFIGURE_OPTIONS += --disable-gui-build
0N/A
0N/ACONFIGURE_ENV += LDFLAGS=" -lnsl"
0N/A
0N/AHPLIP_VARIANT = $(BUILD_DIR)/$(MACH32)-hplip
0N/AHPIJS_VARIANT = $(BUILD_DIR)/$(MACH32)-hpijs
VARIANTS = $(HPLIP_VARIANT) $(HPIJS_VARIANT)
# We build two variants: for the CUPS/SANE support
# and for the HPIJS only support
# use these options for the CUPS/SANE support
$(HPLIP_VARIANT)/.built: CONFIGURE_OPTIONS += --with-hpppddir=/usr/share/cups/model/SUNWhplip
$(HPLIP_VARIANT)/.built: CONFIGURE_OPTIONS += --enable-fax-build
$(HPLIP_VARIANT)/.built: CONFIGURE_OPTIONS += --disable-udev-acl-rules
$(HPLIP_VARIANT)/.built: CONFIGURE_OPTIONS += --enable-hpcups-install
$(HPLIP_VARIANT)/.built: CONFIGURE_OPTIONS += --disable-new-hpcups
$(HPLIP_VARIANT)/.built: CONFIGURE_OPTIONS += --enable-cups-drv-install
# use these options for the HPIJS only support
$(HPIJS_VARIANT)/.built: CONFIGURE_OPTIONS += --enable-foomatic-ppd-install
$(HPIJS_VARIANT)/.built: CONFIGURE_OPTIONS += --with-hpppddir=/usr/share/ppd/SUNWhpijs/HP
$(HPIJS_VARIANT)/.built: CONFIGURE_OPTIONS += --disable-cups-drv-install
$(HPIJS_VARIANT)/.built: CONFIGURE_OPTIONS += --disable-hpcups-install
$(HPIJS_VARIANT)/.built: CONFIGURE_OPTIONS += --disable-doc-build
$(HPIJS_VARIANT)/.built: CONFIGURE_OPTIONS += --enable-hpijs-only-build
$(HPIJS_VARIANT)/.built: CONFIGURE_OPTIONS += --enable-hpijs-install
install: COMPONENT_INSTALL_ENV += halpredir=/etc/hal/fdi/preprobe/10osvendor
COMPONENT_INSTALL_ARGS += -e
COMPONENT_PRE_CONFIGURE_ACTION = \
($(CLONEY) $(SOURCE_DIR) $(@D))
# Generate configuration scripts
$(HPLIP_VARIANT)/.built: COMPONENT_PREP_ACTION = \
(cd $(@D) ; autoconf )
BUILD_PKG_DEPENDENCIES = $(BUILD_TOOLS)
#
# Since it looks like you can't build HPLIP with both HPIJS and CUPS support
# and seperate the HPIJS and CUPS PPD data, we need to replicate the code and
# build it twice. Once for the HPIJS support used by LP and once for the rest
# of the support used for CUPS and SANE.
#
build: $(VARIANTS:%=%/.built)
install: $(VARIANTS:%=%/.installed)
$(RM) $(ROOTPPDCACHE)
$(MKDIR) $(PROTO_DIR)/usr/lib/lp/caches
($(ENV) VER="$(BUILD_DIR)/$(MACH32)-hpijs" \
PPDSRC="$(PROTO_DIR)/usr/share/ppd/SUNWhpijs" \
DONOTINSTALL="/dev/null" \
CACHE="$(ROOTPPDCACHE)" \
IPATH="/usr/share/ppd/$(BUILD_DIR)/" \
$(KSH93) cache.ksh)
# empty test target
test: $(NO_TESTS)
include ../../make-rules/depend.mk