Upgraded CUPS to 2.4.0

This commit is contained in:
dslm4515
2022-01-13 01:23:49 -06:00
parent 76f3eaf3fb
commit 80134ff1e4
3 changed files with 25 additions and 87 deletions

View File

@ -1,7 +1,7 @@
#! /bin/bash
# CUPS
# Source: https://github.com/OpenPrinting/cups/releases/download/v2.3.3op2/cups-2.3.3op2-source.tar.gz
# Source: https://github.com/OpenPrinting/cups/releases/download/v2.4.0/cups-2.4.0-source.tar.gz
#
# $BUILD = Directory to temporarily install
# $PKGS = Directory to store built packages
@ -12,9 +12,9 @@
# Optional: Avahi, libpaper, MIIT Kerberos, OpenJDK, PHP, Python2
# Optional: Gutenprint(post-install)
patch -Np1 -i ../patches/cups-alpine/cups-no-export-ssllibs.patch
#patch -Np1 -i ../patches/cups-alpine/cups-no-export-ssllibs.patch
patch -Np1 -i ../patches/cups-alpine/default-config-no-gssapi.patch
patch -Np1 -i ../patches/cups-alpine/cups-nostrip.patch
#patch -Np1 -i ../patches/cups-alpine/cups-nostrip.patch
sudo -S useradd -c "Print Service User" -d /var/spool/cups -g lp -s /bin/false -u 9 lp &&
sudo -S groupadd -g 19 lpadmin &&
@ -25,17 +25,22 @@ CC=gcc CXX=g++ \
--disable-systemd \
--with-rcdir=/tmp/cupsinit \
--with-system-groups=lpadmin \
--with-docdir=/usr/share/cups/doc-2.3.3op2 $BUILDTRUPLE &&
--with-docdir=/usr/share/cups/doc-2.4.0 $BUILDTRUPLE &&
read -p "Compile?" && make -j2 &&
sudo -S make DESTDIR=$BUILD install &&
#sudo -S rm -rf /tmp/cupsinit &&
sudo -S mkdir -pv ${BUILD}/usr/share/doc &&
sudo -S ln -svnf ../cups/doc-2.3.3 ${BUILD}/usr/share/doc/cups-2.3.3 &&
sudo -S ln -svnf ../cups/doc-2.4.0 ${BUILD}/usr/share/doc/cups-2.4.0 &&
echo "ServerName /run/cups/cups.sock" > /tmp/client.conf &&
sudo -S mkdir -pv ${BUILD}/etc/cups &&
sudo -S mv -v /tmp/client.conf ${BUILD}/etc/cups/client.conf &&
sudo -S mkdir -pv /BMAN/install
sudo -S mkdir -pv /BMAN/usr/share
sudo -S mv $BUILD/usr/share/doc /BMAN/usr/share/
sudo -S mv $BUILD/usr/share/man /BMAN/usr/share/
cd $BUILD && sudo -S mkdir -v ${BUILD}/install &&
cat > /tmp/slack-desc << "EOF"
# HOW TO EDIT THIS FILE:
@ -61,12 +66,25 @@ EOF
sudo -S mv -v /tmp/slack-desc install/ &&
sudo -S rm -rvf usr/share/cups/banners/* \
usr/share/cups/data/testprint &&
sudo -S makepkg -l y -c n $PKGS/cups-2.3.3op2-$(uname -m)-mlfs.txz &&
sudo -S makepkg -l y -c n $PKGS/cups-2.4.0-$(uname -m)-mlfs.txz &&
cp -v install/doinst.sh /tmp/ &&
cat >> /tmp/doinst.sh << "EOF"
useradd -c "Print Service User" -d /var/spool/cups -g lp -s /bin/false -u 9 lp
groupadd -g 19 lpadmin
EOF
sudo -S mv -v /tmp/doinst.sh install/ &&
sudo -S makepkg -l y -c n $PKGS/cups-2.3.3op2-$(uname -m)-mlfs.txz &&
sudo -S makepkg -l y -c n $PKGS/cups-2.4.0-$(uname -m)-mlfs.txz &&
cd /BMAN
cat > /tmp/slack-desc << "EOF"
cups-doc: Manuals for CUPS (Common UNIX Printing System)
cups-doc:
cups-doc: The Common Unix Printing System (CUPS) is a print spooler
cups-doc: and associated utilities. It is based on the "Internet
cups-doc: Printing Protocol" and provides printing services to most
cups-doc: PostScript and raster printers
cups-doc:
EOF
sudo -S mv -v /tmp/slack-desc install/ &&
sudo -S makepkg -l y -c n $PKGS/cups-doc-2.4.0-noarch-mlfs.txz
sudo -S rm -rf /BMAN/*
sudo -S rm -rf ${BUILD}/*

View File

@ -1,12 +0,0 @@
diff -up cups-1.5b1/config-scripts/cups-ssl.m4.no-export-ssllibs cups-1.5b1/config-scripts/cups-ssl.m4
--- cups-1.6.2/config-scripts/cups-ssl.m4.no-export-ssllibs 2011-05-11 02:52:08.000000000 +0200
+++ cups-1.6.2/config-scripts/cups-ssl.m4 2011-05-23 17:47:27.000000000 +0200
@@ -180,7 +180,7 @@
AC_SUBST(SSLFLAGS)
AC_SUBST(SSLLIBS)
-EXPORT_SSLLIBS="$SSLLIBS"
+EXPORT_SSLLIBS=""
AC_SUBST(EXPORT_SSLLIBS)
dnl

View File

@ -1,68 +0,0 @@
diff -ru a/config-scripts/cups-compiler.m4 b/config-scripts/cups-compiler.m4
--- a/config-scripts/cups-compiler.m4 2020-04-27 14:04:29.000000000 -0400
+++ b/config-scripts/cups-compiler.m4 2021-08-06 20:53:29.316010169 -0400
@@ -9,9 +9,6 @@
dnl Clear the debugging and non-shared library options unless the user asks
dnl for them...
-INSTALL_STRIP=""
-AC_SUBST(INSTALL_STRIP)
-
AC_ARG_WITH(optim, [ --with-optim set optimization flags ],
OPTIM="$withval",
OPTIM="")
@@ -25,8 +22,6 @@
dnl For debugging, keep symbols, otherwise strip them...
if test x$enable_debug = xyes -a "x$OPTIM" = x; then
OPTIM="-g"
-else
- INSTALL_STRIP="-s"
fi
dnl Debug printfs can slow things down, so provide a separate option for that
diff -ru a/configure b/configure
--- a/configure 2020-04-27 14:04:29.000000000 -0400
+++ b/configure 2021-08-06 20:54:01.585892266 -0400
@@ -694,7 +694,6 @@
ARCHFLAGS
UNITTESTS
OPTIM
-INSTALL_STRIP
LIBTOOL_INSTALL
LIBTOOL_CXX
LIBTOOL_CC
@@ -6662,7 +6661,6 @@
-INSTALL_STRIP=""
@@ -6698,8 +6696,6 @@
if test x$enable_debug = xyes -a "x$OPTIM" = x; then
OPTIM="-g"
-else
- INSTALL_STRIP="-s"
fi
if test x$enable_debug_printfs = xyes; then
diff -ru a/Makedefs.in b/Makedefs.in
--- a/Makedefs.in 2020-04-27 14:04:29.000000000 -0400
+++ b/Makedefs.in 2021-08-06 20:53:42.565961754 -0400
@@ -45,12 +45,12 @@
# Installation programs...
#
-INSTALL_BIN = @LIBTOOL_INSTALL@ $(INSTALL) -c -m @CUPS_EXE_FILE_PERM@ @INSTALL_STRIP@
+INSTALL_BIN = @LIBTOOL_INSTALL@ $(INSTALL) -c -m @CUPS_EXE_FILE_PERM@
INSTALL_COMPDATA = $(INSTALL) -c -m 444 @INSTALL_GZIP@
INSTALL_CONFIG = $(INSTALL) -c -m @CUPS_CONFIG_FILE_PERM@
INSTALL_DATA = $(INSTALL) -c -m 444
INSTALL_DIR = $(INSTALL) -d
-INSTALL_LIB = @LIBTOOL_INSTALL@ $(INSTALL) -c -m @CUPS_EXE_FILE_PERM@ @INSTALL_STRIP@
+INSTALL_LIB = @LIBTOOL_INSTALL@ $(INSTALL) -c -m @CUPS_EXE_FILE_PERM@
INSTALL_MAN = $(INSTALL) -c -m 444
INSTALL_SCRIPT = $(INSTALL) -c -m @CUPS_EXE_FILE_PERM@