From: Felix Fietkau Date: Wed, 23 Mar 2005 21:18:15 +0000 (+0000) Subject: add cups X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=21aa4b20e69f5e77c920501a657de58ca1dd1df9;p=openwrt%2Fstaging%2Fnbd.git add cups SVN-Revision: 436 --- diff --git a/openwrt/package/Config.in b/openwrt/package/Config.in index 50827c4c57..9975141094 100644 --- a/openwrt/package/Config.in +++ b/openwrt/package/Config.in @@ -25,6 +25,7 @@ source "package/openvpn/Config.in" source "package/openntpd/Config.in" source "package/pptp/Config.in" source "package/pptpd/Config.in" +source "package/cups/Config.in" comment "Libraries" source "package/zlib/Config.in" diff --git a/openwrt/package/Makefile b/openwrt/package/Makefile index bf333d3570..48b5dcc7d2 100644 --- a/openwrt/package/Makefile +++ b/openwrt/package/Makefile @@ -5,6 +5,7 @@ package-y:=openwrt package-$(BR2_PACKAGE_ARPTABLES) += arptables package-$(BR2_PACKAGE_BRIDGE) += bridge package-$(BR2_PACKAGE_BUSYBOX) += busybox +package-$(BR2_PACKAGE_CUPS) += cups package-$(BR2_PACKAGE_DROPBEAR) += dropbear package-$(BR2_PACKAGE_DNSMASQ) += dnsmasq package-$(BR2_PACKAGE_EBTABLES) += ebtables diff --git a/openwrt/package/cups/Config.in b/openwrt/package/cups/Config.in new file mode 100644 index 0000000000..9adfb372df --- /dev/null +++ b/openwrt/package/cups/Config.in @@ -0,0 +1,5 @@ +config BR2_PACKAGE_CUPS + tristate "Common UNIX Printing System" + default m + help + A printer spooling system for devices with USB or LP support diff --git a/openwrt/package/cups/Makefile b/openwrt/package/cups/Makefile new file mode 100644 index 0000000000..9b84234bf7 --- /dev/null +++ b/openwrt/package/cups/Makefile @@ -0,0 +1,96 @@ +# $Id$ + +include $(TOPDIR)/rules.mk + +PKG_NAME:=cups +PKG_VERSION:=1.1.23 +PKG_RELEASE:=1 +PKG_MD5SUM:=4ce09b1dce09b6b9398af0daae9adf63 + +PKG_SOURCE_URL:=ftp://ftp3.easysw.com/pub/cups/1.1.23/ +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-source.tar.bz2 +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION) +PKG_CAT:=bzcat +PKG_IPK:=$(PACKAGE_DIR)/$(PKG_NAME)_$(PKG_VERSION)-$(PKG_RELEASE)_$(ARCH).ipk +PKG_IPK_DIR:=$(PKG_BUILD_DIR)/ipkg + +$(DL_DIR)/$(PKG_SOURCE): + $(SCRIPT_DIR)/download.pl $(DL_DIR) $(PKG_SOURCE) $(PKG_MD5SUM) $(PKG_SOURCE_URL) + +$(PKG_BUILD_DIR)/.patched: $(DL_DIR)/$(PKG_SOURCE) + $(PKG_CAT) $(DL_DIR)/$(PKG_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) - + $(PATCH) $(PKG_BUILD_DIR) ./patches + touch $(PKG_BUILD_DIR)/.patched + +$(PKG_BUILD_DIR)/.configured: $(PKG_BUILD_DIR)/.patched + (cd $(PKG_BUILD_DIR); rm -rf config.cache; \ + ac_cv_path_STRIP="$(STRIP)" \ + $(TARGET_CONFIGURE_OPTS) \ + CFLAGS="$(TARGET_CFLAGS)" \ + ./configure \ + --target=$(GNU_TARGET_NAME) \ + --host=$(GNU_TARGET_NAME) \ + --build=$(GNU_HOST_NAME) \ + --prefix=$(CUPS_IPK_DIR)/usr \ + --exec-prefix=/usr \ + --bindir=/usr/bin \ + --sbindir=/usr/sbin \ + --libexecdir=/usr/lib \ + --sysconfdir=/etc \ + --datadir=/usr/share \ + --localstatedir=/var \ + --mandir=/usr/man \ + --infodir=/usr/info \ + --program-prefix="" \ + --with-gnu-ld \ + --with-cups-user=root \ + --with-cups-group=root \ + --without-perl \ + --without-python \ + --without-php \ + --disable-slp \ + --disable-gnutls \ + --disable-openssl \ + --disable-cdsassl \ + --disable-ssl \ + --disable-slp \ + ); + touch $(PKG_BUILD_DIR)/.configured + + +$(PKG_IPK_DIR)/usr/sbin/cupsd: $(PKG_BUILD_DIR)/.configured + $(MAKE) -C $(PKG_BUILD_DIR) + $(MAKE) STRIP=$(STRIP) DSTROOT=$(PKG_IPK_DIR) -C $(PKG_BUILD_DIR) install + cp -a $(PKG_IPK_DIR)/usr/lib/* $(STAGING_DIR)/lib/ + cp -a $(PKG_IPK_DIR)/usr/include/* $(STAGING_DIR)/include/ + +$(PKG_IPK): $(PKG_IPK_DIR)/usr/sbin/cupsd + $(SCRIPT_DIR)/make-ipkg-dir.sh $(PKG_IPK_DIR) $(PKG_NAME).control $(PKG_VERSION)-$(PKG_RELEASE) $(ARCH) + rm -f $(PKG_IPK_DIR)/usr/bin/cups-config + rm -f $(PKG_IPK_DIR)/usr/lib/*.a + rm -f $(PKG_IPK_DIR)/usr/share/doc/cups/* || true + rm -rf $(PKG_IPK_DIR)/usr/share/doc/cups/?? + rm -rf $(PKG_IPK_DIR)/usr/share/locale + rm -rf $(PKG_IPK_DIR)/usr/share/cups/banners + rm -rf $(PKG_IPK_DIR)/usr/share/cups/charsets + rm -rf $(PKG_IPK_DIR)/usr/share/cups/fonts + rm -rf $(PKG_IPK_DIR)/usr/share/cups/model + rm -rf $(PKG_IPK_DIR)/usr/share/cups/data + rm -rf $(PKG_IPK_DIR)/usr/share/cups/templates/?? + rm -rf $(PKG_IPK_DIR)/usr/include + rm -rf $(PKG_IPK_DIR)/var + rm -rf $(PKG_IPK_DIR)/etc/*.d + $(STRIP) $(PKG_IPK_DIR)/usr/bin/* + $(STRIP) $(PKG_IPK_DIR)/usr/lib/cups/backend/* + $(STRIP) $(PKG_IPK_DIR)/usr/lib/cups/cgi-bin/* + $(STRIP) $(PKG_IPK_DIR)/usr/lib/cups/daemon/* + cp -a ./files/* $(PKG_IPK_DIR)/ + $(IPKG_BUILD) $(PKG_IPK_DIR) $(PACKAGE_DIR) + +source: $(DL_DIR)/$(PKG_SOURCE) +prepare: $(PKG_BUILD_DIR)/.patched +compile: $(PKG_IPK) +install: + $(IPKG) install $(PKG_IPK) +clean: + rm -rf $(PKG_BUILD_DIR) diff --git a/openwrt/package/cups/cups.control b/openwrt/package/cups/cups.control new file mode 100644 index 0000000000..b4f1b67c49 --- /dev/null +++ b/openwrt/package/cups/cups.control @@ -0,0 +1,6 @@ +Package: cups +Priority: optional +Section: net +Maintainer: Felix Fietkau +Source: buildroot internal +Description: Common Unix Printing System diff --git a/openwrt/package/cups/files/etc/cups/classes.conf b/openwrt/package/cups/files/etc/cups/classes.conf new file mode 100644 index 0000000000..15afda75a2 --- /dev/null +++ b/openwrt/package/cups/files/etc/cups/classes.conf @@ -0,0 +1,7 @@ +######################################################################## +# # +# This is a sample class configuration file. This file is included # +# from the main configuration file (cups.conf) and lists all of the # +# printer classes known to the system. # +# # +######################################################################## diff --git a/openwrt/package/cups/files/etc/cups/client.conf b/openwrt/package/cups/files/etc/cups/client.conf new file mode 100644 index 0000000000..c8d9f910ed --- /dev/null +++ b/openwrt/package/cups/files/etc/cups/client.conf @@ -0,0 +1,9 @@ +######################################################################## +# # +# This is the CUPS client configuration file. This file is used to # +# define client-specific parameters, such as the default server or # +# default encryption settings. # +# # +######################################################################## + +Encryption Never diff --git a/openwrt/package/cups/files/etc/cups/cupsd.conf b/openwrt/package/cups/files/etc/cups/cupsd.conf new file mode 100644 index 0000000000..e84de453b3 --- /dev/null +++ b/openwrt/package/cups/files/etc/cups/cupsd.conf @@ -0,0 +1,50 @@ +######################################################################## +# # +# This is the CUPS configuration file. If you are familiar with # +# Apache or any of the other popular web servers, we've followed the # +# same format. Any configuration variable used here has the same # +# semantics as the corresponding variable in Apache. If we need # +# different functionality then a different name is used to avoid # +# confusion... # +# # +######################################################################## + + +AccessLog syslog +ErrorLog syslog +LogLevel info +PageLog syslog +PreserveJobHistory No +PreserveJobFiles No +AutoPurgeJobs Yes +MaxJobs 25 +MaxPrinterHistory 10 +#Printcap /etc/printcap +#PrintcapFormat BSD +RequestRoot /tmp/cups +#RemoteRoot remroot +User root +Group root +RIPCache 512k +TempDir /tmp/cups +Port 631 +HostNameLookups Off +KeepAlive On +Browsing On +BrowseProtocols cups + + +AuthType Basic +AuthClass System +Order Allow,Deny +Allow From All + + + +AuthType Basic +AuthClass System + +Order Allow,Deny +Allow From All + + diff --git a/openwrt/package/cups/files/etc/cups/printers.conf b/openwrt/package/cups/files/etc/cups/printers.conf new file mode 100644 index 0000000000..a3bce1d013 --- /dev/null +++ b/openwrt/package/cups/files/etc/cups/printers.conf @@ -0,0 +1,23 @@ + +Info USB Printer +Location +DeviceURI usb:/dev/usb/lp0 +State Idle +Accepting Yes +JobSheets none none +QuotaPeriod 0 +PageLimit 0 +KLimit 0 + + + +Info Parallel Port Printer +Location +DeviceURI usb:/dev/printers/0 +State Idle +Accepting Yes +JobSheets none none +QuotaPeriod 0 +PageLimit 0 +KLimit 0 + diff --git a/openwrt/package/cups/files/etc/init.d/S60cups b/openwrt/package/cups/files/etc/init.d/S60cups new file mode 100755 index 0000000000..8e5fd63c48 --- /dev/null +++ b/openwrt/package/cups/files/etc/init.d/S60cups @@ -0,0 +1,4 @@ +#!/bin/sh +mkdir -p /tmp/cups +mkdir -p /tmp/spool/cups/tmp +exec /usr/sbin/cupsd diff --git a/openwrt/package/cups/files/usr/share/doc/cups/index.html b/openwrt/package/cups/files/usr/share/doc/cups/index.html new file mode 100644 index 0000000000..368f6cf263 --- /dev/null +++ b/openwrt/package/cups/files/usr/share/doc/cups/index.html @@ -0,0 +1,36 @@ + + + Common UNIX Printing System + + + Easy Software Products Home Page + Do Administration Tasks + Manage Printer Classes Status + On-Line Help + Manage Jobs + Manage Printers + Download the Current CUPS Software + + + + +
+Common UNIX Printing System +
+ +

Do Administration Tasks

+

Manage Printer Classes

+

On-Line Help

+

Manage Jobs

+

Manage Printers

+

Download the Current CUPS Software

+ +
+ +

The Common UNIX Printing System, CUPS, and the CUPS logo are the +trademark property of Easy Software +Products. CUPS is copyright 1997-2005 by Easy Software Products, +All Rights Reserved. + + + diff --git a/openwrt/package/cups/patches/100-makefile-targets.patch b/openwrt/package/cups/patches/100-makefile-targets.patch new file mode 100644 index 0000000000..590a304b12 --- /dev/null +++ b/openwrt/package/cups/patches/100-makefile-targets.patch @@ -0,0 +1,11 @@ +--- cups-1.1.23.old/Makefile 2005-01-03 20:29:44.000000000 +0100 ++++ cups-1.1.23/Makefile 2005-03-23 20:15:24.000000000 +0100 +@@ -28,7 +28,7 @@ + # Directories to make... + # + +-DIRS = cups backend berkeley cgi-bin filter man pdftops \ ++DIRS = cups backend berkeley cgi-bin \ + scheduler systemv + + # diff --git a/openwrt/package/cups/patches/110-no-strip-on-install.patch b/openwrt/package/cups/patches/110-no-strip-on-install.patch new file mode 100644 index 0000000000..1addc7593c --- /dev/null +++ b/openwrt/package/cups/patches/110-no-strip-on-install.patch @@ -0,0 +1,12 @@ +diff -urN cups-1.1.23.old/Makedefs.in cups-1.1.23/Makedefs.in +--- cups-1.1.23.old/Makedefs.in 2005-01-03 20:29:44.000000000 +0100 ++++ cups-1.1.23/Makedefs.in 2005-03-23 20:28:06.000000000 +0100 +@@ -47,7 +47,7 @@ + # Installation programs... + # + +-INSTALL_BIN = $(LIBTOOL) $(INSTALL) -m 755 -s ++INSTALL_BIN = $(LIBTOOL) $(INSTALL) -m 755 + INSTALL_DATA = $(INSTALL) -m 644 + INSTALL_DIR = $(INSTALL) -d + INSTALL_LIB = $(LIBTOOL) $(INSTALL) -m 755