diff options
Diffstat (limited to 'source/a/aaa_libraries')
-rwxr-xr-x | source/a/aaa_libraries/aaa_libraries.SlackBuild | 134 | ||||
-rwxr-xr-x | source/a/aaa_libraries/display_orphans.sh | 44 | ||||
-rw-r--r-- | source/a/aaa_libraries/slack-desc | 19 | ||||
-rw-r--r-- | source/a/aaa_libraries/symlinks-to-tracked-libs | 93 | ||||
-rw-r--r-- | source/a/aaa_libraries/symlinks-to-tracked-libs-tmp | 12 | ||||
-rw-r--r-- | source/a/aaa_libraries/tracked-files | 11 | ||||
-rw-r--r-- | source/a/aaa_libraries/tracked-files-tmp | 5 |
7 files changed, 318 insertions, 0 deletions
diff --git a/source/a/aaa_libraries/aaa_libraries.SlackBuild b/source/a/aaa_libraries/aaa_libraries.SlackBuild new file mode 100755 index 000000000..d6b331636 --- /dev/null +++ b/source/a/aaa_libraries/aaa_libraries.SlackBuild @@ -0,0 +1,134 @@ +#!/bin/bash +# Copyright 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2015, 2018, 2020, 2021 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=aaa_libraries +VERSION=${VERSION:-15.0} +BUILD=${BUILD:-1} + +# 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 + +if [ "$ARCH" = "x86_64" ]; then + LIBDIRSUFFIX="64" +else + LIBDIRSUFFIX="" +fi + +TMP=${TMP:-/tmp} +PKG=$TMP/package-${PKGNAM} +rm -rf $PKG +mkdir -p $TMP $PKG + +if [ -x /sbin/ldconfig ]; then + /sbin/ldconfig +fi + +cd $PKG +cat $CWD/symlinks-to-tracked-libs \ + | grep -v "^#" | grep -v "^$" \ + | sed -e "s#^/lib/#/lib${LIBDIRSUFFIX}/#" \ + -e "s#^/usr/lib/#/usr/lib${LIBDIRSUFFIX}/#" \ + | while read library ; do + ( [ ! -e $library ] && exit 0 + echo "Adding $library" + mkdir -p $(dirname $library | cut -b2- ) + cd $(dirname $library | cut -b2- ) + rm -f $(basename $library) + cp -a $library . + rm -f $(readlink $library) + cp -a $(dirname $library)/$(readlink $library) . + ) +done + +cat $CWD/tracked-files \ + | grep -v "^#" | grep -v "^$" \ + | sed -e "s#^/lib/#/lib${LIBDIRSUFFIX}/#" \ + -e "s#^/usr/lib/#/usr/lib${LIBDIRSUFFIX}/#" \ + | while read library ; do + ( [ ! -e $library ] && exit 0 + echo "Adding $library" + mkdir -p $(dirname $library | cut -b2- ) + cd $(dirname $library | cut -b2- ) + rm -f $(basename $library) + cp -a $library . + ) +done + +cat $CWD/symlinks-to-tracked-libs-tmp \ + | grep -v "^#" | grep -v "^$" \ + | sed -e "s#^/lib/#/lib${LIBDIRSUFFIX}/#" \ + -e "s#^/usr/lib/#/usr/lib${LIBDIRSUFFIX}/#" \ + | while read library ; do + ( [ ! -e $library ] && exit 0 + echo "Adding $library" + mkdir -p $(dirname $library | cut -b2- ) + cd $(dirname $library | cut -b2- ) + rm -f $(basename $library) + cp -a $library . + rm -f $(readlink $library) + cp -a $(dirname $library)/$(readlink $library) . + ) +done + +cat $CWD/tracked-files-tmp \ + | grep -v "^#" | grep -v "^$" \ + | sed -e "s#^/lib/#/lib${LIBDIRSUFFIX}/#" \ + -e "s#^/usr/lib/#/usr/lib${LIBDIRSUFFIX}/#" \ + | while read library ; do + ( [ ! -e $library ] && exit 0 + echo "Adding $library" + mkdir -p $(dirname $library | cut -b2- ) + cd $(dirname $library | cut -b2- ) + rm -f $(basename $library) + cp -a $library . + ) +done + +# Make sure shared libraries are executable: +chmod 755 $PKG/lib${LIBDIRSUFFIX}/lib*.so.* $PKG/usr/lib${LIBDIRSUFFIX}/lib*.so.* + +# Don't ship symlinks in aaa_libraries... it's just asking for trouble. +# installpkg will create them if needed by running ldconfig. +find $PKG -type l -exec rm --verbose "{}" \+ + +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/source/a/aaa_libraries/display_orphans.sh b/source/a/aaa_libraries/display_orphans.sh new file mode 100755 index 000000000..32bd570bd --- /dev/null +++ b/source/a/aaa_libraries/display_orphans.sh @@ -0,0 +1,44 @@ +#!/bin/sh +# +# Copyright 2015 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. +# + +# Show libraries that are only present in the aaa_elflibs that is currently +# installed on the system. + +cleanup() { + rm -r $TMPDIR +} + +trap 'cleanup' 2 14 15 # trap CTRL+C and kill + +TMPDIR="$(mktemp -d /tmp/find-aaaelfliborphans.XXXXXX)" + +cp -a /var/log/packages/* $TMPDIR +rm -f $TMPDIR/aaa_elflibs-* +cat /var/log/packages/aaa_elflibs-* | grep -v -e PACKAGE -e aaa_elflibs: -e FILE -e '^\./$' -e install/ | grep -v '/$' | while read file ; do + if ! grep -q $file $TMPDIR/* ; then + echo $file + fi +done + +cleanup + diff --git a/source/a/aaa_libraries/slack-desc b/source/a/aaa_libraries/slack-desc new file mode 100644 index 000000000..344346843 --- /dev/null +++ b/source/a/aaa_libraries/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------------------------------------------------------| +aaa_libraries: aaa_libraries (shared libraries needed by many programs) +aaa_libraries: +aaa_libraries: This is a collection of shared libraries needed to run Linux programs. +aaa_libraries: These libraries are gathered from other Slackware packages and are +aaa_libraries: intended to give a minimal initial set of libraries. +aaa_libraries: +aaa_libraries: +aaa_libraries: +aaa_libraries: +aaa_libraries: +aaa_libraries: diff --git a/source/a/aaa_libraries/symlinks-to-tracked-libs b/source/a/aaa_libraries/symlinks-to-tracked-libs new file mode 100644 index 000000000..303f92975 --- /dev/null +++ b/source/a/aaa_libraries/symlinks-to-tracked-libs @@ -0,0 +1,93 @@ +# This file lists shared library symlinks for libraries we would +# like to keep copies of in the aaa_symlinks package. + +/lib/libacl.so.1 +/lib/libaio.so.1 +/lib/libattr.so.1 +/lib/libbz2.so.1 +/lib/libbz2.so.1.0 +/lib/libcap.so.2 +/lib/libdm.so.0 +/lib/libelf.so.1 +/lib/libfuse.so.2 +/lib/libgpm.so.2 +/lib/libkeyutils.so.1 +/lib/libkrb5support.so.0 +/lib/libkrb5.so.3 +/lib/libk5crypto.so.3 +/lib/libgssapi_krb5.so.2 +/lib/liblzma.so.5 +/lib/libncurses.so.5 +/lib/libncurses.so.6 +/lib/libncursesw.so.5 +/lib/libncursesw.so.6 +/lib/libnsl.so.1 +/lib/libnsl.so.2 +/lib/libpcre.so.1 +/lib/libpcreposix.so.0 +/lib/libpopt.so.0 +/lib/libsigsegv.so.2 +/lib/libsysfs.so.2 +/lib/libtermcap.so.2 +/lib/libtinfo.so.6 +/lib/libtirpc.so.3 +/lib/libudev.so.1 +/lib/libz.so.1 +/usr/lib/libasound.so.2 +/usr/lib/libatomic.so.1 +/usr/lib/libcurl.so.4 +/usr/lib/libexpat.so.1 +/usr/lib/libffi.so.6 +/usr/lib/libffi.so.7 +/usr/lib/libform.so.5 +/usr/lib/libform.so.6 +/usr/lib/libformw.so.5 +/usr/lib/libformw.so.6 +/usr/lib/libgdbm.so.4 +/usr/lib/libgdbm.so.6 +/usr/lib/libglib-2.0.so.0 +/usr/lib/libgmodule-2.0.so.0 +/usr/lib/libgobject-2.0.so.0 +/usr/lib/libgomp.so.1 +/usr/lib/libgthread-2.0.so.0 +/usr/lib/libhistory.so.6 +/usr/lib/libhistory.so.7 +/usr/lib/libhistory.so.8 +/usr/lib/libidn.so.12 +/usr/lib/libidn2.so.0 +/usr/lib/libjpeg.so.62 +/usr/lib/libjson-c.so.4 +/usr/lib/libturbojpeg.so.0 +/usr/lib/liblber-2.4.so.2 +/usr/lib/libldap-2.4.so.2 +/usr/lib/libltdl.so.7 +/usr/lib/libmenu.so.5 +/usr/lib/libmenu.so.6 +/usr/lib/libmenuw.so.5 +/usr/lib/libmenuw.so.6 +/usr/lib/libmm.so.14 +/usr/lib/libpanel.so.5 +/usr/lib/libpanel.so.6 +/usr/lib/libpanelw.so.5 +/usr/lib/libpanelw.so.6 +/usr/lib/libpcre2-8.so.0 +/usr/lib/libpng.so.14 +/usr/lib/libpng14.so.14 +/usr/lib/libpng16.so.16 +/usr/lib/libpsl.so.5 +/usr/lib/libreadline.so.6 +/usr/lib/libreadline.so.7 +/usr/lib/libreadline.so.8 +/usr/lib/libslang.so.1 +/usr/lib/libslang.so.2 +/usr/lib/libssh2.so.1 +/usr/lib/libstdc++.so.5 +/usr/lib/libstdc++.so.6 +/usr/lib/libtdb.so.1 +/usr/lib/libtiffxx.so.5 +/usr/lib/libtiff.so.5 +/usr/lib/libusb-0.1.so.4 +/usr/lib/libusb-1.0.so.0 +/usr/lib/libvga.so.1 +/usr/lib/libvgagl.so.1 +/usr/lib/libzstd.so.1 diff --git a/source/a/aaa_libraries/symlinks-to-tracked-libs-tmp b/source/a/aaa_libraries/symlinks-to-tracked-libs-tmp new file mode 100644 index 000000000..bf2e2e0ef --- /dev/null +++ b/source/a/aaa_libraries/symlinks-to-tracked-libs-tmp @@ -0,0 +1,12 @@ +# This file lists shared library symlinks for libraries we would +# like to keep copies of temporarily until we can recompile +# everything that's still using them. Once that happens, they'll +# be dropped from this package. +# +# We need these libraries here or we won't be able to recompile gcc +# after any of them get a shared library .so-version bump: +/usr/lib/libisl.so.23 +/usr/lib/libmpc.so.3 +/usr/lib/libmpfr.so.6 +/usr/lib/libgmp.so.10 +/usr/lib/libgmpxx.so.4 diff --git a/source/a/aaa_libraries/tracked-files b/source/a/aaa_libraries/tracked-files new file mode 100644 index 000000000..7ee005943 --- /dev/null +++ b/source/a/aaa_libraries/tracked-files @@ -0,0 +1,11 @@ +# This is a list of files (usually libraries) that we want to include +# in aaa_elflibs but which don't have a shared library symlink pointing +# at them. + +/lib/libdb-4.4.so +/lib/libdb-4.8.so +/lib/libdevmapper.so.1.02 +/usr/lib/libargon2.so.1 +/usr/lib/libcups.so.2 +/usr/lib/libcupsimage.so.2 +/usr/lib/libgcc_s.so.1 diff --git a/source/a/aaa_libraries/tracked-files-tmp b/source/a/aaa_libraries/tracked-files-tmp new file mode 100644 index 000000000..58b6c36d1 --- /dev/null +++ b/source/a/aaa_libraries/tracked-files-tmp @@ -0,0 +1,5 @@ +# This is a list of files (usually libraries) that we want to keep +# copies of temporarily until we can recompile everything that's +# still using them. Once that happens, they'll be dropped from +# this package. + |