From 8587721dc4abbac61cc5d495edc3a90b9f1ee772 Mon Sep 17 00:00:00 2001 From: Patrick J Volkerding Date: Wed, 11 Oct 2023 22:22:40 +0000 Subject: Wed Oct 11 22:22:40 UTC 2023 patches/packages/libcaca-0.99.beta20-x86_64-1_slack15.0.txz: Upgraded. Fixed a crash bug (a crafted file defining width of zero leads to divide by zero and a crash). Seems to be merely a bug rather than a security issue, but I'd been meaning to get beta20 building so this was a good excuse. Thanks to marav. For more information, see: https://www.cve.org/CVERecord?id=CVE-2022-0856 (* Security fix *) --- patches/source/libcaca/70.patch | 84 +++++++++ .../libcaca-0.99.beta20-CVE-2022-0856.patch | 38 +++++ patches/source/libcaca/libcaca.SlackBuild | 163 ++++++++++++++++++ patches/source/libcaca/libcaca.autoconf.ver.patch | 10 ++ patches/source/libcaca/libcaca.git.20211207.patch | 188 +++++++++++++++++++++ patches/source/libcaca/libcaca.url | 1 + patches/source/libcaca/slack-desc | 19 +++ patches/source/nghttp2/nghttp2.SlackBuild | 152 +++++++++++++++++ patches/source/nghttp2/nghttp2.url | 2 + patches/source/nghttp2/slack-desc | 19 +++ patches/source/samba/samba.url | 4 +- 11 files changed, 678 insertions(+), 2 deletions(-) create mode 100644 patches/source/libcaca/70.patch create mode 100644 patches/source/libcaca/libcaca-0.99.beta20-CVE-2022-0856.patch create mode 100755 patches/source/libcaca/libcaca.SlackBuild create mode 100644 patches/source/libcaca/libcaca.autoconf.ver.patch create mode 100644 patches/source/libcaca/libcaca.git.20211207.patch create mode 100644 patches/source/libcaca/libcaca.url create mode 100644 patches/source/libcaca/slack-desc create mode 100755 patches/source/nghttp2/nghttp2.SlackBuild create mode 100644 patches/source/nghttp2/nghttp2.url create mode 100644 patches/source/nghttp2/slack-desc (limited to 'patches/source') diff --git a/patches/source/libcaca/70.patch b/patches/source/libcaca/70.patch new file mode 100644 index 000000000..eacf75824 --- /dev/null +++ b/patches/source/libcaca/70.patch @@ -0,0 +1,84 @@ +From afacac2cf7dfad8015c059a96046d9c2fa34632f Mon Sep 17 00:00:00 2001 +From: Johannes Kauffmann +Date: Sun, 18 Sep 2022 17:31:19 +0200 +Subject: [PATCH 1/3] common-image: avoid implicit function declaration +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +common-image.c: In function ‘load_image’: +common-image.c:164:18: warning: implicit declaration of function ‘_caca_alloc2d’ [-Wimplicit-function-declaration] + 164 | im->pixels = _caca_alloc2d(im->w, im->h, depth); + | ^~~~~~~~~~~~~ +--- + src/common-image.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/src/common-image.c b/src/common-image.c +index 7059bf40..d40eba12 100644 +--- a/src/common-image.c ++++ b/src/common-image.c +@@ -22,6 +22,7 @@ + #endif + + #include "caca.h" ++#include "caca_internals.h" + + #include "common-image.h" + + +From f57b0d65cfaac5f1fbdc75458170e102f57a8dfa Mon Sep 17 00:00:00 2001 +From: Johannes Kauffmann +Date: Sun, 18 Sep 2022 17:52:40 +0200 +Subject: [PATCH 2/3] caca: avoid nested externs +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +common-image.c:164:18: warning: nested extern declaration of ‘_caca_alloc2d’ [-Wnested-externs] +--- + caca/caca.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/caca/caca.c b/caca/caca.c +index 327a8f9f..a9f461d8 100644 +--- a/caca/caca.c ++++ b/caca/caca.c +@@ -284,7 +284,7 @@ char const * caca_get_version(void) + * XXX: The following functions are private. + */ + +-extern void *_caca_alloc2d(size_t width, size_t height, size_t elem_size) ++void *_caca_alloc2d(size_t width, size_t height, size_t elem_size) + { + if (width == 0 || height == 0 || elem_size == 0 || SIZE_MAX / width / height < elem_size) + return NULL; + +From 9683d1f7efe316b1e6113b65c6fff40671d35632 Mon Sep 17 00:00:00 2001 +From: Johannes Kauffmann +Date: Sun, 18 Sep 2022 18:01:31 +0200 +Subject: [PATCH 3/3] caca_internals: export _caca_alloc2d + +It is used by the image viewer: + +/usr/bin/ld: img2txt-common-image.o: in function `load_image': +../../src/common-image.c:164: undefined reference to `_caca_alloc2d' + +Fixes #59. +--- + caca/caca_internals.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/caca/caca_internals.h b/caca/caca_internals.h +index 7b74b9e9..0bd7f6c8 100644 +--- a/caca/caca_internals.h ++++ b/caca/caca_internals.h +@@ -268,7 +268,7 @@ extern int _caca_pop_event(caca_display_t *, caca_privevent_t *); + extern void _caca_set_term_title(char const *); + + /* Internal memory function */ +-extern void *_caca_alloc2d(size_t width, size_t height, size_t elem_size); ++__extern void *_caca_alloc2d(size_t width, size_t height, size_t elem_size); + + /* Profiling functions */ + #if defined PROF diff --git a/patches/source/libcaca/libcaca-0.99.beta20-CVE-2022-0856.patch b/patches/source/libcaca/libcaca-0.99.beta20-CVE-2022-0856.patch new file mode 100644 index 000000000..092af0643 --- /dev/null +++ b/patches/source/libcaca/libcaca-0.99.beta20-CVE-2022-0856.patch @@ -0,0 +1,38 @@ +From d33a9ca2b7e9f32483c1aee4c3944c56206d456b Mon Sep 17 00:00:00 2001 +From: Josef Moellers +Date: Fri, 18 Mar 2022 11:52:22 +0100 +Subject: [PATCH] Prevent a divide-by-zero by checking for a zero width or + height. + +--- + src/img2txt.c | 10 ++++++++-- + 1 file changed, 8 insertions(+), 2 deletions(-) + +diff --git a/src/img2txt.c b/src/img2txt.c +index b8a25899..b9d5ba24 100644 +--- a/src/img2txt.c ++++ b/src/img2txt.c +@@ -177,7 +177,13 @@ int main(int argc, char **argv) + } + + /* Assume a 6×10 font */ +- if(!cols && !lines) ++ if(!i->w || !i->h) ++ { ++ fprintf(stderr, "%s: image size is 0\n", argv[0]); ++ lines = 0; ++ cols = 0; ++ } ++ else if(!cols && !lines) + { + cols = 60; + lines = cols * i->h * font_width / i->w / font_height; +@@ -214,7 +220,7 @@ int main(int argc, char **argv) + export = caca_export_canvas_to_memory(cv, format?format:"ansi", &len); + if(!export) + { +- fprintf(stderr, "%s: Can't export to format '%s'\n", argv[0], format); ++ fprintf(stderr, "%s: Can't export to format '%s'\n", argv[0], format?format:"ansi"); + } + else + { diff --git a/patches/source/libcaca/libcaca.SlackBuild b/patches/source/libcaca/libcaca.SlackBuild new file mode 100755 index 000000000..499c43a98 --- /dev/null +++ b/patches/source/libcaca/libcaca.SlackBuild @@ -0,0 +1,163 @@ +#!/bin/bash + +# Copyright 2006, 2007, 2008, 2009, 2010, 2017, 2018, 2023 Patrick J. Volkerding, Sebeka, MN, USA +# All rights reserved. +# +# Redistribution and use of this script, with or without modification, is +# permitted provided that the following conditions are met: +# +# 1. Redistributions of this script must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; +# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +cd $(dirname $0) ; CWD=$(pwd) + +PKGNAM=libcaca +VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z* | rev | cut -f 3- -d . | cut -f 1 -d - | rev)} +BUILD=${BUILD:-1_slack15.0} + +# Automatically determine the architecture we're building on: +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) export ARCH=i586 ;; + arm*) export ARCH=arm ;; + # Unless $ARCH is already set, use uname -m for all other archs: + *) export ARCH=$( uname -m ) ;; + esac +fi + +# If the variable PRINT_PACKAGE_NAME is set, then this script will report what +# the name of the created package would be, and then exit. This information +# could be useful to other scripts. +if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then + echo "$PKGNAM-$VERSION-$ARCH-$BUILD.txz" + exit 0 +fi + +NUMJOBS=${NUMJOBS:-" -j$(expr $(nproc) + 1) "} + +TMP=${TMP:-/tmp} +PKG=$TMP/package-${PKGNAM} +rm -rf $PKG +mkdir -p $TMP $PKG + +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "s390" ]; then + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" + LIBDIRSUFFIX="64" +else + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" +fi + +cd $TMP +rm -rf ${PKGNAM}-${VERSION} +tar xvf $CWD/${PKGNAM}-$VERSION.tar.?z* || exit 1 +cd ${PKGNAM}-$VERSION || exit 1 + +# Make sure ownerships and permissions are sane: +chown -R root:root . +find . \ + \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \ + -exec chmod 755 {} \+ -o \ + \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ + -exec chmod 644 {} \+ + +# Fix build failure: +cat $CWD/libcaca.git.20211207.patch | patch -p1 --verbose || exit 1 +cat $CWD/70.patch | patch -p1 --verbose || exit 1 + +# Fix crash bug: +cat $CWD/libcaca-0.99.beta20-CVE-2022-0856.patch | patch -p1 --verbose || exit 1 + +# WHY +cat $CWD/libcaca.autoconf.ver.patch | patch -p1 --verbose || exit 1 + +# Configure: +autoreconf -vif +CFLAGS="$SLKCFLAGS" \ +./configure \ + --prefix=/usr \ + --libdir=/usr/lib${LIBDIRSUFFIX} \ + --sysconfdir=/etc \ + --mandir=/usr/man \ + --program-prefix= \ + --program-suffix= \ + --disable-doc \ + --disable-imlib2 \ + --disable-ruby \ + --disable-python \ + --disable-static \ + --enable-slang \ + --enable-ncurses \ + --enable-x11 \ + --build=$ARCH-slackware-linux || exit 1 + +# Build and install: +make $NUMJOBS || make || exit 1 +make install DESTDIR=$PKG || exit 1 + +# Don't ship .la files: +rm -f $PKG/{,usr/}lib${LIBDIRSUFFIX}/*.la + +cd python + # python2 dropped dropped as obsolete. + #python setup.py install --root=$PKG || exit 1 + python3 setup.py install --root=$PKG || exit 1 +cd - + +# Strip binaries: +find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \ + | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null + +# Compress and link manpages, if any: +if [ -d $PKG/usr/man ]; then + ( cd $PKG/usr/man + for manpagedir in $(find . -type d -name "man*") ; do + ( cd $manpagedir + for eachpage in $( find . -type l -maxdepth 1) ; do + ln -s $( readlink $eachpage ).gz $eachpage.gz + rm $eachpage + done + gzip -9 *.* + ) + done + ) +fi + +# Compress info files, if any: +if [ -d $PKG/usr/info ]; then + ( cd $PKG/usr/info + rm -f dir + gzip -9 * + ) +fi + +# Add a documentation directory: +mkdir -p $PKG/usr/doc/${PKGNAM}-$VERSION +cp -a \ + AUTHORS COPYING* NEWS NOTES README* THANKS \ + $PKG/usr/doc/${PKGNAM}-$VERSION +rm -rf $PKG/usr/share/doc + +mkdir -p $PKG/install +cat $CWD/slack-desc > $PKG/install/slack-desc + +cd $PKG +/sbin/makepkg -l y -c n $TMP/${PKGNAM}-$VERSION-$ARCH-$BUILD.txz + diff --git a/patches/source/libcaca/libcaca.autoconf.ver.patch b/patches/source/libcaca/libcaca.autoconf.ver.patch new file mode 100644 index 000000000..1ff6bd319 --- /dev/null +++ b/patches/source/libcaca/libcaca.autoconf.ver.patch @@ -0,0 +1,10 @@ +--- ./configure.ac.orig 2021-10-19 08:53:47.000000000 -0500 ++++ ./configure.ac 2023-10-11 15:01:28.582192640 -0500 +@@ -1,6 +1,6 @@ + + AC_INIT([libcaca],[0.99.beta20]) +-AC_PREREQ([2.71]) ++AC_PREREQ([2.69]) + AC_CONFIG_AUX_DIR(.auto) + AC_CANONICAL_TARGET + AM_INIT_AUTOMAKE([foreign no-define tar-ustar silent-rules subdir-objects]) diff --git a/patches/source/libcaca/libcaca.git.20211207.patch b/patches/source/libcaca/libcaca.git.20211207.patch new file mode 100644 index 000000000..404369e43 --- /dev/null +++ b/patches/source/libcaca/libcaca.git.20211207.patch @@ -0,0 +1,188 @@ +diff -u -r --new-file libcaca-0.99.beta20.orig/caca/caca_internals.h libcaca-0.99.beta20/caca/caca_internals.h +--- libcaca-0.99.beta20.orig/caca/caca_internals.h 2021-10-19 08:58:30.000000000 -0500 ++++ libcaca-0.99.beta20/caca/caca_internals.h 2021-12-07 03:03:53.000000000 -0600 +@@ -26,6 +26,13 @@ + # define MAX_DIRTY_COUNT 8 + #endif + ++#undef __extern ++#if defined CACA_ENABLE_VISIBILITY ++# define __extern extern __attribute__((visibility("default"))) ++#else ++# define __extern extern ++#endif ++ + struct caca_frame + { + /* Frame size */ +@@ -116,7 +123,7 @@ + int conio_install(caca_display_t *); + #endif + #if defined(USE_GL) +-int gl_install(caca_display_t *); ++__extern int gl_install(caca_display_t *); + #endif + #if defined(USE_NCURSES) + int ncurses_install(caca_display_t *); +@@ -133,7 +140,7 @@ + int win32_install(caca_display_t *); + #endif + #if defined(USE_X11) +-int x11_install(caca_display_t *); ++__extern int x11_install(caca_display_t *); + #endif + + /* Timer structure */ +@@ -252,8 +259,9 @@ + /* Internal event functions */ + extern void _caca_handle_resize(caca_display_t *); + #if defined(USE_SLANG) || defined(USE_NCURSES) || defined(USE_CONIO) || defined(USE_GL) +-extern void _push_event(caca_display_t *, caca_privevent_t *); +-extern int _pop_event(caca_display_t *, caca_privevent_t *); ++/* Expose this with ‘__extern’ because the GL driver uses it */ ++__extern void _caca_push_event(caca_display_t *, caca_privevent_t *); ++extern int _caca_pop_event(caca_display_t *, caca_privevent_t *); + #endif + + /* Internal window functions */ +@@ -269,4 +277,6 @@ + extern void _caca_fini_stat(struct caca_stat *); + #endif + ++#undef __extern ++ + #endif /* __CACA_INTERNALS_H__ */ +diff -u -r --new-file libcaca-0.99.beta20.orig/caca/driver/conio.c libcaca-0.99.beta20/caca/driver/conio.c +--- libcaca-0.99.beta20.orig/caca/driver/conio.c 2021-10-19 08:58:30.000000000 -0500 ++++ libcaca-0.99.beta20/caca/driver/conio.c 2021-12-07 03:03:53.000000000 -0600 +@@ -151,7 +151,7 @@ + + release = *ev; + release.type = CACA_EVENT_KEY_RELEASE; +- _push_event(dp, &release); ++ _caca_push_event(dp, &release); + + return 1; + } +diff -u -r --new-file libcaca-0.99.beta20.orig/caca/driver/gl.c libcaca-0.99.beta20/caca/driver/gl.c +--- libcaca-0.99.beta20.orig/caca/driver/gl.c 2021-10-19 08:58:30.000000000 -0500 ++++ libcaca-0.99.beta20/caca/driver/gl.c 2021-12-07 03:03:53.000000000 -0600 +@@ -374,7 +374,7 @@ + + if(dp->drv.p->mouse_clicked) + { +- _push_event(dp, ev); ++ _caca_push_event(dp, ev); + ev->type = CACA_EVENT_MOUSE_PRESS; + ev->data.mouse.button = dp->drv.p->mouse_button; + dp->drv.p->mouse_clicked = 0; +diff -u -r --new-file libcaca-0.99.beta20.orig/caca/driver/ncurses.c libcaca-0.99.beta20/caca/driver/ncurses.c +--- libcaca-0.99.beta20.orig/caca/driver/ncurses.c 2021-10-19 08:58:30.000000000 -0500 ++++ libcaca-0.99.beta20/caca/driver/ncurses.c 2021-12-07 03:03:53.000000000 -0600 +@@ -482,9 +482,9 @@ + switch(mevent.bstate) + { + #define PRESS(x) ev->data.mouse.button = x; \ +- ev->type = CACA_EVENT_MOUSE_PRESS; _push_event(dp, ev) ++ ev->type = CACA_EVENT_MOUSE_PRESS; _caca_push_event(dp, ev) + #define RELEASE(x) ev->data.mouse.button = x; \ +- ev->type = CACA_EVENT_MOUSE_RELEASE; _push_event(dp, ev) ++ ev->type = CACA_EVENT_MOUSE_RELEASE; _caca_push_event(dp, ev) + #define CLICK(x) PRESS(x); RELEASE(x) + case BUTTON1_PRESSED: PRESS(1); break; + case BUTTON1_RELEASED: RELEASE(1); break; +@@ -530,7 +530,7 @@ + } + + if(dp->mouse.x == mevent.x && dp->mouse.y == mevent.y) +- return _pop_event(dp, ev); ++ return _caca_pop_event(dp, ev); + + dp->mouse.x = mevent.x; + dp->mouse.y = mevent.y; +diff -u -r --new-file libcaca-0.99.beta20.orig/caca/driver/slang.c libcaca-0.99.beta20/caca/driver/slang.c +--- libcaca-0.99.beta20.orig/caca/driver/slang.c 2021-10-19 08:58:30.000000000 -0500 ++++ libcaca-0.99.beta20/caca/driver/slang.c 2021-12-07 03:03:53.000000000 -0600 +@@ -403,12 +403,12 @@ + + ev->data.mouse.button = button; + ev->type = CACA_EVENT_MOUSE_PRESS; +- _push_event(dp, ev); ++ _caca_push_event(dp, ev); + ev->type = CACA_EVENT_MOUSE_RELEASE; +- _push_event(dp, ev); ++ _caca_push_event(dp, ev); + + if(dp->mouse.x == x && dp->mouse.y == y) +- return _pop_event(dp, ev); ++ return _caca_pop_event(dp, ev); + + dp->mouse.x = x; + dp->mouse.y = y; +diff -u -r --new-file libcaca-0.99.beta20.orig/caca/event.c libcaca-0.99.beta20/caca/event.c +--- libcaca-0.99.beta20.orig/caca/event.c 2021-10-19 08:58:30.000000000 -0500 ++++ libcaca-0.99.beta20/caca/event.c 2021-12-07 03:03:53.000000000 -0600 +@@ -380,7 +380,7 @@ + && dp->events.autorepeat_ticks > AUTOREPEAT_THRESHOLD + && dp->events.autorepeat_ticks > AUTOREPEAT_RATE) + { +- _push_event(dp, ev); ++ _caca_push_event(dp, ev); + dp->events.autorepeat_ticks -= AUTOREPEAT_RATE; + *ev = dp->events.last_key_event; + return 1; +@@ -403,7 +403,7 @@ + && (dp->events.last_key_ticks > AUTOREPEAT_THRESHOLD + || (ev->type & CACA_EVENT_KEY_PRESS))) + { +- _push_event(dp, ev); ++ _caca_push_event(dp, ev); + *ev = dp->events.last_key_event; + ev->type = CACA_EVENT_KEY_RELEASE; + dp->events.last_key_event.type = CACA_EVENT_NONE; +@@ -425,7 +425,7 @@ + static int _lowlevel_event(caca_display_t *dp, caca_privevent_t *ev) + { + #if defined(USE_SLANG) || defined(USE_NCURSES) || defined(USE_CONIO) +- int ret = _pop_event(dp, ev); ++ int ret = _caca_pop_event(dp, ev); + + if(ret) + return ret; +@@ -435,7 +435,7 @@ + } + + #if defined(USE_SLANG) || defined(USE_NCURSES) || defined(USE_CONIO) || defined(USE_GL) +-void _push_event(caca_display_t *dp, caca_privevent_t *ev) ++void _caca_push_event(caca_display_t *dp, caca_privevent_t *ev) + { + if(!ev->type || dp->events.queue == EVENTBUF_LEN) + return; +@@ -443,7 +443,7 @@ + dp->events.queue++; + } + +-int _pop_event(caca_display_t *dp, caca_privevent_t *ev) ++int _caca_pop_event(caca_display_t *dp, caca_privevent_t *ev) + { + int i; + +diff -u -r --new-file libcaca-0.99.beta20.orig/configure.ac libcaca-0.99.beta20/configure.ac +--- libcaca-0.99.beta20.orig/configure.ac 2021-10-19 08:58:30.000000000 -0500 ++++ libcaca-0.99.beta20/configure.ac 2021-12-07 03:03:53.000000000 -0600 +@@ -269,7 +269,6 @@ + [ac_cv_my_have_cocoa="yes"]) + CFLAGS="$save_CFLAGS" + if test "${ac_cv_my_have_cocoa}" = "yes"; then +- [[[ "$target_os" =~ [0-9]+ ]]] && darwin_ver="${BASH_REMATCH[[0]]}" + case x${target} in + xpowerpc*darwin*) + # 10.3 needed to link with X11 +@@ -297,6 +296,7 @@ + esac + CC="${CC:-gcc-${GCC_VERSION}}" + CXX="${CXX:-g++-${GCC_VERSION}}" ++ darwin_ver="$(echo "${target_os}" | sed -ne 's/[^0-9]*\([0-9]\+\).*/\1/p')" + if [[ "$darwin_ver" -lt "13" ]]; then + MACOSX_SDK_FRAMEWORKS="${MACOSX_SDK_FRAMEWORKS:--F${MACOSX_SDK}/System/Library/Frameworks}" + CPPFLAGS="${CPPFLAGS} ${ARCH} ${MACOSX_SDK_FRAMEWORKS}" diff --git a/patches/source/libcaca/libcaca.url b/patches/source/libcaca/libcaca.url new file mode 100644 index 000000000..6bb713dea --- /dev/null +++ b/patches/source/libcaca/libcaca.url @@ -0,0 +1 @@ +https://github.com/cacalabs/libcaca diff --git a/patches/source/libcaca/slack-desc b/patches/source/libcaca/slack-desc new file mode 100644 index 000000000..1040c448e --- /dev/null +++ b/patches/source/libcaca/slack-desc @@ -0,0 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. Line +# up the first '|' above the ':' following the base package name, and the '|' on +# the right side marks the last column you can put a character in. You must make +# exactly 11 lines for the formatting to be correct. It's also customary to +# leave one space after the ':'. + + |-----handy-ruler------------------------------------------------------| +libcaca: libcaca (Colour AsCii Art library) +libcaca: +libcaca: The libcaca library is a graphics library that outputs text instead +libcaca: of pixels, so that it can work on older video cards or text terminals. +libcaca: It is not unlike the famous AAlib library. +libcaca: +libcaca: Sam Hocevar is the main author of libcaca. +libcaca: +libcaca: +libcaca: +libcaca: diff --git a/patches/source/nghttp2/nghttp2.SlackBuild b/patches/source/nghttp2/nghttp2.SlackBuild new file mode 100755 index 000000000..47dd04e04 --- /dev/null +++ b/patches/source/nghttp2/nghttp2.SlackBuild @@ -0,0 +1,152 @@ +#!/bin/bash + +# Copyright 2018, 2020 Patrick J. Volkerding, Sebeka, Minnesota, USA +# All rights reserved. +# +# Redistribution and use of this script, with or without modification, is +# permitted provided that the following conditions are met: +# +# 1. Redistributions of this script must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; +# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +cd $(dirname $0) ; CWD=$(pwd) + +PKGNAM=nghttp2 +VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z | rev | cut -f 3- -d . | cut -f 1 -d - | rev)} +BUILD=${BUILD:-1_slack15.0} + +# Automatically determine the architecture we're building on: +if [ -z "$ARCH" ]; then + case "$(uname -m)" in + i?86) ARCH=i586 ;; + arm*) readelf /usr/bin/file -A | grep -E -q "Tag_CPU.*[4,5]" && ARCH=arm || ARCH=armv7hl ;; + # Unless $ARCH is already set, use uname -m for all other archs: + *) ARCH=$(uname -m) ;; + esac + export ARCH +fi + +# If the variable PRINT_PACKAGE_NAME is set, then this script will report what +# the name of the created package would be, and then exit. This information +# could be useful to other scripts. +if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then + echo "$PKGNAM-$VERSION-$ARCH-$BUILD.txz" + exit 0 +fi + +NUMJOBS=${NUMJOBS:-" -j$(expr $(nproc) + 1) "} + +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "i686" ]; then + SLKCFLAGS="-O2 -march=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "s390" ]; then + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" + LIBDIRSUFFIX="64" +elif [ "$ARCH" = "armv7hl" ]; then + SLKCFLAGS="-O3 -march=armv7-a -mfpu=vfpv3-d16" + LIBDIRSUFFIX="" +else + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" +fi + +TMP=${TMP:-/tmp} +PKG=$TMP/package-$PKGNAM + +rm -rf $PKG +mkdir -p $TMP $PKG + +cd $TMP +rm -rf $PKGNAM-$VERSION +tar xvf $CWD/$PKGNAM-$VERSION.tar.?z || exit 1 +cd $PKGNAM-$VERSION || exit 1 + +chown -R root:root . +find . \ + \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \ + -exec chmod 755 {} \+ -o \ + \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ + -exec chmod 644 {} \+ + +if [ ! -r configure ]; then + if [ -x ./autogen.sh ]; then + NOCONFIGURE=1 ./autogen.sh + else + autoreconf -vif + fi +fi + +# Configure: +CFLAGS="$SLKCFLAGS" \ +./configure \ + --prefix=/usr \ + --libdir=/usr/lib${LIBDIRSUFFIX} \ + --sysconfdir=/etc \ + --localstatedir=/var \ + --docdir=/usr/doc/$PKGNAM-$VERSION \ + --mandir=/usr/man \ + --disable-static \ + --enable-lib-only \ + --build=$ARCH-slackware-linux || exit 1 + +# Build and install: +make $NUMJOBS || make || exit 1 +make install DESTDIR=$PKG || exit 1 + +# Don't ship .la files: +rm -f $PKG/usr/lib${LIBDIRSUFFIX}/*.la + +# Strip binaries: +( cd $PKG + find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null + find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null +) + +# Compress manual pages: +find $PKG/usr/man -type f -exec gzip -9 {} \+ +for i in $( find $PKG/usr/man -type l ) ; do + ln -s $( readlink $i ).gz $i.gz + rm $i +done + +# Actually, since we're only packaging the library, the man pages are not +# relevant. Dump them: +rm -rf $PKG/usr/man + +# Add a documentation directory: +mkdir -p $PKG/usr/doc/${PKGNAM}-$VERSION +cp -a \ + AUTHORS* ChangeLog CHANGES COPYING* LICENSE* NEWS* README* THANKS* TODO* \ + $PKG/usr/doc/${PKGNAM}-$VERSION + +# If there's a ChangeLog, installing at least part of the recent history +# is useful, but don't let it get totally out of control: +if [ -r ChangeLog ]; then + DOCSDIR=$(echo $PKG/usr/doc/${PKGNAM}-$VERSION) + cat ChangeLog | head -n 1000 > $DOCSDIR/ChangeLog + touch -r ChangeLog $DOCSDIR/ChangeLog +fi + +mkdir -p $PKG/install +cat $CWD/slack-desc > $PKG/install/slack-desc + +cd $PKG +/sbin/makepkg -l y -c n $TMP/$PKGNAM-$VERSION-$ARCH-$BUILD.txz + diff --git a/patches/source/nghttp2/nghttp2.url b/patches/source/nghttp2/nghttp2.url new file mode 100644 index 000000000..0c81348dc --- /dev/null +++ b/patches/source/nghttp2/nghttp2.url @@ -0,0 +1,2 @@ +https://github.com/nghttp2/nghttp2 +https://github.com/nghttp2/nghttp2/releases/download/v1.57.0/nghttp2-1.57.0.tar.xz diff --git a/patches/source/nghttp2/slack-desc b/patches/source/nghttp2/slack-desc new file mode 100644 index 000000000..5d00cbb4a --- /dev/null +++ b/patches/source/nghttp2/slack-desc @@ -0,0 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. +# Line up the first '|' above the ':' following the base package name, and +# the '|' on the right side marks the last column you can put a character in. +# You must make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':' except on otherwise blank lines. + + |-----handy-ruler------------------------------------------------------| +nghttp2: nghttp2 (HTTP/2 library) +nghttp2: +nghttp2: This is a library that implements the Hypertext Transfer Protocol +nghttp2: version 2. An HPACK encoder and decoder are also available as a +nghttp2: public API. +nghttp2: +nghttp2: Homepage: https://nghttp2.org/ +nghttp2: +nghttp2: +nghttp2: +nghttp2: diff --git a/patches/source/samba/samba.url b/patches/source/samba/samba.url index 997f3a46b..55b79b996 100644 --- a/patches/source/samba/samba.url +++ b/patches/source/samba/samba.url @@ -1,2 +1,2 @@ -https://download.samba.org/pub/samba/stable/samba-4.18.5.tar.gz -https://download.samba.org/pub/samba/stable/samba-4.18.5.tar.asc +https://download.samba.org/pub/samba/stable/samba-4.18.8.tar.gz +https://download.samba.org/pub/samba/stable/samba-4.18.8.tar.asc -- cgit v1.2.3-79-gdb01