You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

94 lines
2.5 KiB

  1. #
  2. # Copyright (C) 2006-2012 OpenWrt.org
  3. # Copyright (C) 2017-2018 Luiz Angelo Daros de Luca <luizluca@gmail.com>
  4. #
  5. # This is free software, licensed under the GNU General Public License v2.
  6. # See /LICENSE for more information.
  7. #
  8. include $(TOPDIR)/rules.mk
  9. PKG_NAME:=cups
  10. PKG_VERSION:=2.2.12
  11. PKG_RELEASE:=1
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-source.tar.gz
  13. PKG_SOURCE_URL:=https://github.com/apple/cups/releases/download/v$(PKG_VERSION)/
  14. PKG_HASH:=0f61ab449e4748a24c6ab355b481ff7691247a140d327b2b7526fce34b7f9aa8
  15. PKG_MAINTAINER:=Luiz Angelo Daros de Luca <luizluca@gmail.com>
  16. PKG_LICENSE:=GPL-2.0
  17. PKG_LICENSE_FILES:=LICENSE.txt
  18. PKG_CPE_ID:=cpe:/a:apple:cups
  19. include $(INCLUDE_DIR)/package.mk
  20. define Package/libcups/Default
  21. URL:=http://www.cups.org/
  22. SUBMENU:=Printing
  23. endef
  24. define Package/libcups
  25. $(call Package/cups/Default)
  26. SECTION:=libs
  27. CATEGORY:=Libraries
  28. DEPENDS:=+zlib +libpthread +libpng +libjpeg +libusb-1.0
  29. TITLE:=Common UNIX Printing System - Core library
  30. endef
  31. define Package/libcups/description
  32. Common UNIX Printing System - Core library
  33. endef
  34. TARGET_LDFLAGS+=-Wl,-rpath-link=$(STAGING_DIR)/usr/lib
  35. CONFIGURE_ARGS+=--with-cups-user="nobody" \
  36. --with-cups-group="nogroup" \
  37. --with-components="core" \
  38. --with-pdftops="none" \
  39. --without-perl \
  40. --without-python \
  41. --without-php \
  42. --enable-shared \
  43. --enable-image \
  44. --enable-libusb \
  45. --disable-acl \
  46. --disable-dbus \
  47. --disable-dnssd \
  48. --disable-launchd \
  49. --disable-ldap \
  50. --disable-pam \
  51. --disable-slp \
  52. --disable-gnutls \
  53. --disable-openssl \
  54. --disable-cdsassl \
  55. --disable-ssl \
  56. --disable-gssapi \
  57. --disable-tiff \
  58. UNAME="Linux" \
  59. LIBS="$(TARGET_LDFLAGS) -lz -lpng -ljpeg"
  60. define Build/Compile
  61. $(MAKE) -C $(PKG_BUILD_DIR)/cups \
  62. $(TARGET_CONFIGURE_OPTS) \
  63. DSTROOT="$(PKG_INSTALL_DIR)" \
  64. STRIP="/bin/true" \
  65. libcups.so.2 install-libs install-headers
  66. $(MAKE) -C $(PKG_BUILD_DIR)/filter \
  67. $(TARGET_CONFIGURE_OPTS) \
  68. DSTROOT="$(PKG_INSTALL_DIR)" \
  69. STRIP="/bin/true" \
  70. libcupsimage.so.2 install-libs install-headers
  71. $(INSTALL_DIR) $(PKG_INSTALL_DIR)/usr/bin
  72. $(INSTALL_BIN) $(PKG_BUILD_DIR)/cups-config $(PKG_INSTALL_DIR)/usr/bin
  73. endef
  74. define Build/InstallDev
  75. $(INSTALL_DIR) $(2)/usr/bin
  76. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/cups-config $(2)/usr/bin/
  77. $(INSTALL_DIR) $(1)/usr/include
  78. $(CP) $(PKG_INSTALL_DIR)/usr/include/cups $(1)/usr/include/
  79. $(INSTALL_DIR) $(1)/usr/lib
  80. $(CP) $(PKG_INSTALL_DIR)/usr/lib*/libcups*.so* $(1)/usr/lib/
  81. endef
  82. $(eval $(call BuildPackage,libcups))