hplip: Update to 3.18.9 7158/head
authorRosen Penev <rosenp@gmail.com>
Mon, 8 Oct 2018 23:37:41 +0000 (16:37 -0700)
committerRosen Penev <rosenp@gmail.com>
Tue, 9 Oct 2018 23:20:32 +0000 (16:20 -0700)
Added patch to fix some glibc-isms.

Added PKG_BUILD_PARALLEL for faster compilation.

Rearranged slightly for consistency between packages.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
utils/hplip/Makefile
utils/hplip/patches/010-libusb_fix.patch
utils/hplip/patches/020-remove_cups_dep_on_scan.patch
utils/hplip/patches/030-replace_unsafe_memcpy_with_memmove.patch
utils/hplip/patches/040-fix_bool.patch
utils/hplip/patches/050-fix-glibcisms.patch [new file with mode: 0644]

index 6c1c853115028a4380671726c8cabaefab8208f3..13499ca4f8152f50d5d5bb68d8c22af0880ef7fb 100644 (file)
@@ -9,17 +9,19 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=hplip
-PKG_VERSION:=3.18.6
+PKG_VERSION:=3.18.9
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=@SF/hplip
-PKG_HASH:=0ecf3e68b09480f602de81798ac00774cf8ffe754692e784bbbe0f9b2e337b7d
+PKG_HASH:=20093830994de16bb36c049c1fdb688569531525fb994f7e605e66266a2d783c
+
 PKG_MAINTAINER:=Luiz Angelo Daros de Luca <luizluca@gmail.com>
 PKG_LICENSE:=GPL-2.0 GPL-2.0+
 PKG_LICENSE_FILES:=COPYING LICENSE
 
-PKG_BUILD_DEPENDS := python libcups
+PKG_BUILD_PARALLEL:=1
+PKG_BUILD_DEPENDS:= python libcups
 PKG_FIXUP:=autoreconf
 
 include $(INCLUDE_DIR)/package.mk
@@ -28,7 +30,7 @@ define Package/hplip/Default
   SECTION:=utils
   CATEGORY:=Utilities
   TITLE:=HP Linux Imaging and Printing
-  URL:=http://sourceforge.net/projects/hplip/
+  URL:=https://sourceforge.net/projects/hplip/
 endef
 
 define Package/hplip/Default/description
@@ -66,6 +68,10 @@ CONFIGURE_ARGS += \
        --disable-pp-build \
        --disable-doc-build \
        --disable-dbus-build \
+       --disable-hpijs-only-build \
+       --disable-hpcups-install \
+       --disable-hpps-install \
+       --disable-cups-drv-install \
        --enable-lite-build
 
 define Package/hplip-common/install
index 004513935d584ac5ee6aa5fd0c23d42baad9d2a8..05ba40060fa30b9c7a2178eb90ffc8a207ffc288 100644 (file)
@@ -1,6 +1,6 @@
 --- a/configure.in
 +++ b/configure.in
-@@ -595,6 +595,10 @@ if test "$class_driver" = "no" && test "
+@@ -598,6 +598,10 @@ if test "$class_driver" = "no" && test "$hpijs_only_build" = "no" && test "$hpcu
     else
        AC_CHECK_LIB([usb-1.0], [libusb_init], [LIBS="$LIBS"], [AC_MSG_ERROR([cannot find libusb 1.0 support], 2)])
        AC_CHECK_HEADERS(libusb-1.0/libusb.h, ,[AC_MSG_ERROR([cannot find libusb-1.0-devel support], 11)])
index bbeb0dc634127908d7dd7d306377e330554fcbcc..3951e3bd23ebd3835c20ecb00a207de908868cdc 100644 (file)
@@ -1,3 +1,14 @@
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -71,7 +71,7 @@ else
+ libsane_hpaio_la_LDFLAGS = -version-info 1:0:0
+ endif
+ # The following is a interlibrary dependency that must be compiled first.
+-libsane_hpaio_la_LIBADD = libhpip.la libhpmud.la libhpipp.la $(DBUS_LIBS) -lcups -ldl
++libsane_hpaio_la_LIBADD = libhpip.la libhpmud.la libhpipp.la $(DBUS_LIBS) -ldl
+ #libsane_hpaio_la_CFLAGS = -DWITH_NONAMESPACES -DSOAP_DEBUG
+ libsane_hpaio_la_CFLAGS = $(DBUS_CFLAGS) -Iprotocol
 --- a/scan/sane/hpaio.c
 +++ b/scan/sane/hpaio.c
 @@ -34,7 +34,6 @@
@@ -6,9 +17,9 @@
  #include <string.h>
 -#include <cups/cups.h>
  #include "hpmud.h"
- #include "hpip.h"
  #include "hp_ipp.h"
-@@ -144,98 +143,6 @@ static int GetUriLine(char *buf, char *u
+ #include "soap.h"
+@@ -145,98 +144,6 @@ static int GetUriLine(char *buf, char *uri, char **tail)
     return i;
  }
  
  static int AddDevice(char *uri)
  {
      struct hpmud_model_attributes ma;
-@@ -264,7 +171,6 @@ static int DevDiscovery(int localOnly)
+@@ -289,7 +196,6 @@ static int DevDiscovery(int localOnly)
      char uri[HPMUD_LINE_SIZE];
      char *tail = message;
      int i, scan_type, cnt=0, total=0, bytes_read;
      char* token = NULL;
      enum HPMUD_RESULT stat;
  
-@@ -279,34 +185,6 @@ static int DevDiscovery(int localOnly)
+@@ -304,34 +210,6 @@ static int DevDiscovery(int localOnly)
          total += AddDevice(uri);
      }
  
  bugout:
     return total;
  }
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -67,7 +67,7 @@ else
- libsane_hpaio_la_LDFLAGS = -version-info 1:0:0
- endif
- # The following is a interlibrary dependency that must be compiled first.
--libsane_hpaio_la_LIBADD = libhpip.la libhpmud.la libhpipp.la $(DBUS_LIBS) -lcups -ldl
-+libsane_hpaio_la_LIBADD = libhpip.la libhpmud.la libhpipp.la $(DBUS_LIBS) -ldl
- #libsane_hpaio_la_CFLAGS = -DWITH_NONAMESPACES -DSOAP_DEBUG
- libsane_hpaio_la_CFLAGS = $(DBUS_CFLAGS) -Iprotocol
index 2babb2b67a85b9768e2d7ea9538086c1865e5045..5a71180da826073263fa39c787ec22c289ac141b 100644 (file)
@@ -4,7 +4,7 @@ memcpy should never be used with overlapping memory regions
 
 --- a/io/hpmud/musb.c
 +++ b/io/hpmud/musb.c
-@@ -775,7 +775,7 @@ static int device_id(int fd, unsigned ch
+@@ -775,7 +775,7 @@ static int device_id(int fd, unsigned char *buffer, int size)
          len = size-1;   /* leave byte for zero termination */
      if (len > 2)
          len -= 2;
index 2f43429f3b08c44b351ffa6de5018756e6795e81..eab984e8c07cd42a24c44063babca9a7aa5c3c87 100644 (file)
@@ -11,7 +11,7 @@ https://bugs.launchpad.net/hplip/+bug/1778626
  
  /* 
  ********************************************* Helper Routines **************************
-@@ -343,7 +343,7 @@ bool PCLmGenerator::addKids(sint32 kidOb
+@@ -343,7 +343,7 @@ bool PCLmGenerator::addKids(sint32 kidObj)
        return(true);
  }
  
@@ -20,7 +20,7 @@ https://bugs.launchpad.net/hplip/+bug/1778626
  {
        FILE *outputFile;
        char outFileName[MAX_FILE_PATH_LEN];
-@@ -1074,7 +1074,7 @@ void PCLmGenerator::writePDFGrammarPage(
+@@ -1074,7 +1074,7 @@ void PCLmGenerator::writePDFGrammarPage(int imageWidth, int imageHeight, int num
  * Limitations:
  *   - 
  *****************************************************************************************/
diff --git a/utils/hplip/patches/050-fix-glibcisms.patch b/utils/hplip/patches/050-fix-glibcisms.patch
new file mode 100644 (file)
index 0000000..e020bd4
--- /dev/null
@@ -0,0 +1,17 @@
+diff --git a/scan/sane/OrbliteScan/LinuxCommon.h b/scan/sane/OrbliteScan/LinuxCommon.h
+index 6605dd9..55c7110 100644
+--- a/scan/sane/OrbliteScan/LinuxCommon.h
++++ b/scan/sane/OrbliteScan/LinuxCommon.h
+@@ -18,10 +18,8 @@ typedef u_int32_t                   UInt32;
+ typedef int32_t                               SInt32;\r
+ //typedef unsigned long                       UInt32;\r
+ //typedef signed long                 SInt32;\r
+-typedef __S64_TYPE                    SInt64;\r
+-typedef __U64_TYPE                    UInt64;\r
+-typedef __S64_TYPE                    int64_t;\r
+-typedef __U64_TYPE                    uint64_t;\r
++typedef int64_t                       SInt64;\r
++typedef uint64_t                      UInt64;\r
\r
+ //typedef unsigned long       ULONG;\r
+ //typedef void*                       LPVOID;\r