Andreas Wacknitz
2023-11-05 5f04177d06cd09f4d1d1c02c4b89e5ea72dafa97
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
#
# CDDL HEADER START
#
# The contents of this file are subject to the terms of the
# Common Development and Distribution License (the "License").
# You may not use this file except in compliance with the License.
#
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
# or http://www.opensolaris.org/os/licensing.
# See the License for the specific language governing permissions
# and limitations under the License.
#
# When distributing Covered Code, include this CDDL HEADER in each
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
# If applicable, add the following below this CDDL HEADER, with the
# fields enclosed by brackets "[]" replaced with your own identifying
# information: Portions Copyright [yyyy] [name of copyright owner]
#
# CDDL HEADER END
#
 
#
# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
#
 
BUILD_BITS= 64_and_32
include ../../../make-rules/shared-macros.mk
 
COMPONENT_NAME=        cups
COMPONENT_VERSION=    2.4.7
COMPONENT_REVISION=    4
COMPONENT_SRC=        $(COMPONENT_NAME)-$(HUMAN_VERSION)
COMPONENT_PROJECT_URL=    https://openprinting.github.io/cups/
COMPONENT_ARCHIVE=    $(COMPONENT_SRC)-source.tar.gz
COMPONENT_ARCHIVE_HASH=    sha256:9b9a126018462f7326baa828bdf861939e37e00bc63884e03129b3f3360c44fe
COMPONENT_ARCHIVE_URL=  https://github.com/OpenPrinting/cups/archive/refs/tags/v$(HUMAN_VERSION).tar.gz
COMPONENT_LICENSE=    Apache 2.0 with an exception to allow linking against GNU GPL2-only software
 
include $(WS_MAKE_RULES)/common.mk
 
$(CONFIGURE_32):    LDFLAGS += -m32
$(CONFIGURE_64):    LDFLAGS += -m64
 
COMPONENT_PRE_CONFIGURE_ACTION += $(CLONEY) $(SOURCE_DIR) $(@D)
 
COMPONENT_PREP_ACTION= ( cd $(@D) ; autoconf -f )
 
# Make sure that "install-sh -s" calls "strip -x" and not "strip";
# we want to remove debugging data but not the symbols.
COMPONENT_INSTALL_ENV += STRIPPROG="strip -x"
 
CFLAGS += $(CPP_XPG6MODE)
LDFLAGS += -lsocket
 
# Ensure dynamic shared objects are linked using same LDFLAGS as executables.
CONFIGURE_ENV += DSOFLAGS="$(LDFLAGS)"
CONFIGURE_ENV += LDFLAGS="$(LDFLAGS)"
CONFIGURE_ENV += CFLAGS="$(CFLAGS)"
COMPONENT_BUILD_ENV += LDFLAGS="$(LDFLAGS)"
COMPONENT_BUILD_ENV += CFLAGS="$(CFLAGS)"
 
CONFIGURE_OPTIONS += --prefix=/usr
CONFIGURE_OPTIONS += --mandir=/usr/share/man
CONFIGURE_OPTIONS += --localedir=$(USRSHARELOCALEDIR)
CONFIGURE_OPTIONS += --sysconfdir=$(ETCDIR)
CONFIGURE_OPTIONS += --localstatedir=$(VARDIR)
# Unlike Solaris 11 which has combined and renamed /var/run and /etc/volatile into /system/volatile
# we still use the traditional state folder:
CONFIGURE_OPTIONS += --with-rundir=/var/run/cups
CONFIGURE_OPTIONS += --with-smfmanifestdir=/lib/svc/manifest/application
CONFIGURE_OPTIONS += --with-printcap=/etc/printers.conf
CONFIGURE_OPTIONS += --with-cups-user=lp
CONFIGURE_OPTIONS += --with-cups-group=lp
CONFIGURE_OPTIONS += --with-tls=gnutls
CONFIGURE_OPTIONS += --without-rcdir
CONFIGURE_OPTIONS += --disable-static
CONFIGURE_OPTIONS += --enable-dbus
CONFIGURE_OPTIONS += --with-archflags="$(CC_BITS)"
 
# Dynamically create the license file from its sources:
cups.license: $(SOURCE_DIR)/LICENSE $(SOURCE_DIR)/NOTICE
    cat $? > $@
 
# IdleExitTimeout is unknown and throws an error.
COMPONENT_POST_INSTALL_ACTION= $(GSED) -i -e "s:IdleExitTimeout 60:\#IdleExitTimeout 60:" $(PROTOETCDIR)/cups/cupsd.conf*
 
# Manually added build dependencies
REQUIRED_PACKAGES += image/library/libpng16
REQUIRED_PACKAGES += image/library/libtiff
REQUIRED_PACKAGES += service/network/slp
 
# Auto-generated dependencies
REQUIRED_PACKAGES += $(GCC_RUNTIME_PKG)
REQUIRED_PACKAGES += $(GXX_RUNTIME_PKG)
REQUIRED_PACKAGES += SUNWcs
REQUIRED_PACKAGES += library/gnutls-3
REQUIRED_PACKAGES += library/libusb-1
REQUIRED_PACKAGES += library/zlib
REQUIRED_PACKAGES += runtime/perl
REQUIRED_PACKAGES += service/network/dns/mdns
REQUIRED_PACKAGES += shell/ksh93
REQUIRED_PACKAGES += system/ca-certificates
REQUIRED_PACKAGES += system/library
REQUIRED_PACKAGES += system/library/libdbus
REQUIRED_PACKAGES += system/library/math