aboutsummaryrefslogtreecommitdiffstats
path: root/network/r8125
diff options
context:
space:
mode:
authorDanilo M. <danix@danix.xyz>2026-08-08 13:03:32 +0200
committerDanilo M. <danix@danix.xyz>2026-08-08 13:03:32 +0200
commit25742bd9efc32de82eeeeaba0f4b8976c169e7ce (patch)
tree5dacbf9207123e6e74733e5d474b28ed34888f61 /network/r8125
parent998dbd56e53c8c8c8bc1a425cec16b6ccc752e34 (diff)
downloadsbo-slackbuilds-25742bd9efc32de82eeeeaba0f4b8976c169e7ce.tar.gz
sbo-slackbuilds-25742bd9efc32de82eeeeaba0f4b8976c169e7ce.zip
repo: move packages under their SBo category
Mirror SBo's own <category>/<package>/ layout instead of a flat <package>/ one. The category is now carried by the directory, so there's no separate map to maintain, and a package exports to the SBo repo at the identical relative path. misc: SecLists, exploitdb, nuclei games: UrbanTerror network: feroxbuster, ffuf, gobuster, metasploit-framework-bin, r8125 Categories taken from the synced SBo tree, which is authoritative. This also repairs two things the flat layout had broken: - test-build's category_of() returned "." for every package, since it derives the category from the parent directory name. - post-commit asserted a fixed depth. It now locates a build by the directory holding the .SlackBuild, and names the archive after the package with the package dir at the tarball root, as SBo expects. Drops the exec bit from SecLists.SlackBuild and gobuster.SlackBuild, flagged by sbolint once the pre-commit hook started running: SBo requires 0644 and ships both that way.
Diffstat (limited to 'network/r8125')
-rw-r--r--network/r8125/README56
-rw-r--r--network/r8125/doinst.sh16
-rw-r--r--network/r8125/r8125.SlackBuild113
-rw-r--r--network/r8125/r8125.info10
-rw-r--r--network/r8125/r8125.nvchecker4
-rw-r--r--network/r8125/slack-desc19
6 files changed, 218 insertions, 0 deletions
diff --git a/network/r8125/README b/network/r8125/README
new file mode 100644
index 0000000..e3506a7
--- /dev/null
+++ b/network/r8125/README
@@ -0,0 +1,56 @@
+r8125 is the out-of-tree Linux kernel driver for Realtek RTL8125 and
+RTL8125B 2.5 Gigabit Ethernet controllers with PCI-Express interface.
+It provides complete 2.5Gbps support not available in the in-tree r8169
+driver for this hardware revision.
+
+The resulting package is specific to the kernel it was built against.
+You must rebuild this package whenever you upgrade your kernel.
+
+BUILDING
+--------
+To build for the currently running kernel:
+
+ ./r8125.SlackBuild
+
+To build for a different kernel (e.g. one you have just installed but
+not yet booted):
+
+ KERNEL=6.1.0 ./r8125.SlackBuild
+
+The KERNEL variable must match the directory name under /lib/modules/
+and the kernel build tree must exist at /lib/modules/$KERNEL/build.
+
+LOADING THE MODULE
+------------------
+After installing the package, load the driver without rebooting:
+
+ modprobe r8125
+
+To verify it loaded:
+
+ lsmod | grep r8125
+
+CONFLICT WITH r8169
+-------------------
+The in-tree r8169 driver may also bind to RTL8125 hardware. This package
+installs a blacklist file to prevent r8169 from loading:
+
+ /etc/modprobe.d/r8169_blacklist.conf
+
+If the file already exists and has been modified, the new version will
+be installed as r8169_blacklist.conf.new for you to review and merge.
+
+If r8169 is currently loaded, unload it before loading r8125:
+
+ modprobe -r r8169
+ modprobe r8125
+
+NVCHECKER
+---------
+An nvchecker configuration file is installed alongside this README at:
+
+ /usr/doc/r8125-VERSION/r8125.nvchecker
+
+nvchecker (https://github.com/lilydjwg/nvchecker) is a tool for checking
+new versions of software. Copy or include this file in your nvchecker
+configuration to be notified when Realtek publishes a new r8125 release.
diff --git a/network/r8125/doinst.sh b/network/r8125/doinst.sh
new file mode 100644
index 0000000..cfc59d8
--- /dev/null
+++ b/network/r8125/doinst.sh
@@ -0,0 +1,16 @@
+config() {
+ NEW="$1"
+ OLD="$(dirname $NEW)/$(basename $NEW .new)"
+ if [ ! -r $OLD ]; then
+ mv $NEW $OLD
+ elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
+ rm $NEW
+ fi
+}
+
+config etc/modprobe.d/r8169_blacklist.conf.new
+
+# A good idea whenever kernel modules are added or changed:
+if [ -x sbin/depmod ]; then
+ chroot . /sbin/depmod -a @KERNEL@ 1> /dev/null 2> /dev/null
+fi
diff --git a/network/r8125/r8125.SlackBuild b/network/r8125/r8125.SlackBuild
new file mode 100644
index 0000000..28417ec
--- /dev/null
+++ b/network/r8125/r8125.SlackBuild
@@ -0,0 +1,113 @@
+#!/bin/bash
+
+# Slackware build script for r8125
+
+# Copyright 2026 danix <danix@danix.xyz>
+# 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)
+
+PRGNAM=r8125
+VERSION=${VERSION:-9.018.00}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
+
+KERNEL="${KERNEL:-$(uname -r)}"
+PKGVER="$(printf %s "${VERSION}_$KERNEL" | tr - _)"
+
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i586 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
+
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PRGNAM-$PKGVER-$ARCH-$BUILD$TAG.$PKGTYPE"
+ exit 0
+fi
+
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+if [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
+set -eu
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM-$VERSION
+tar xvf $CWD/$PRGNAM-$VERSION.tar.bz2
+cd $PRGNAM-$VERSION
+chown -R root:root .
+find -L . \
+ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
+ -o -perm 511 \) -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
+ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
+
+(
+ unset ARCH
+ cd /lib/modules/$KERNEL/build
+
+ # Disable DASH: EXTRA_CFLAGS override drops -DENABLE_DASH_SUPPORT but still
+ # builds r8125_dash.o, breaking the build. DASH is out-of-band mgmt, unneeded.
+ make \
+ M="$TMP/$PRGNAM-$VERSION/src" \
+ ENABLE_DASH_SUPPORT=n \
+ EXTRA_CFLAGS="$SLKCFLAGS" \
+ modules
+)
+
+install -Dm0644 src/$PRGNAM.ko \
+ $PKG/lib/modules/$KERNEL/kernel/drivers/net/ethernet/realtek/$PRGNAM.ko
+
+mkdir -p $PKG/etc/modprobe.d
+echo 'blacklist r8169' > $PKG/etc/modprobe.d/r8169_blacklist.conf.new
+
+cd $TMP/$PRGNAM-$VERSION
+mkdir -p $PKG/usr/doc/$PRGNAM-$PKGVER
+chmod 644 README # it's 777 from the tarball
+cp -a README $PKG/usr/doc/$PRGNAM-$PKGVER/
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$PKGVER/$PRGNAM.SlackBuild
+cat $CWD/$PRGNAM.nvchecker > $PKG/usr/doc/$PRGNAM-$PKGVER/$PRGNAM.nvchecker
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+sed "s%@KERNEL@%$KERNEL%" $CWD/doinst.sh > $PKG/install/doinst.sh
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$PKGVER-$ARCH-$BUILD$TAG.$PKGTYPE
diff --git a/network/r8125/r8125.info b/network/r8125/r8125.info
new file mode 100644
index 0000000..a7ddd37
--- /dev/null
+++ b/network/r8125/r8125.info
@@ -0,0 +1,10 @@
+PRGNAM="r8125"
+VERSION="9.018.00"
+HOMEPAGE="https://www.realtek.com/en/component/zoo/category/network-interface-controllers-10-100-1000m-gigabit-ethernet-pci-express-software"
+DOWNLOAD="https://github.com/danixland/r8125/releases/download/9.018.00/r8125-9.018.00.tar.bz2"
+MD5SUM="88d7c3ae81808c95a89c0b0eee1c7256"
+DOWNLOAD_x86_64=""
+MD5SUM_x86_64=""
+REQUIRES=""
+MAINTAINER="danix"
+EMAIL="danix@danix.xyz"
diff --git a/network/r8125/r8125.nvchecker b/network/r8125/r8125.nvchecker
new file mode 100644
index 0000000..d2fafc1
--- /dev/null
+++ b/network/r8125/r8125.nvchecker
@@ -0,0 +1,4 @@
+[r8125]
+source = "jq"
+url = "https://www.realtek.com/Download/ListAllDownloadItem?cate_id=584"
+filter = '.Data.DownloadItems["Unix (Linux)"][] | select(.Name | startswith("r8125")) | .Version'
diff --git a/network/r8125/slack-desc b/network/r8125/slack-desc
new file mode 100644
index 0000000..1f794fd
--- /dev/null
+++ b/network/r8125/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------------------------------------------------------|
+r8125: r8125 (Realtek RTL8125 2.5GbE Linux kernel driver)
+r8125:
+r8125: This is the out-of-tree Linux kernel driver for Realtek RTL8125/
+r8125: RTL8125B 2.5 Gigabit Ethernet controllers with PCI-Express interface.
+r8125: It provides full support for 2.5Gbps operation not found in the
+r8125: in-tree r8169 driver for this hardware revision.
+r8125:
+r8125: Features include EEE (Energy Efficient Ethernet), Wake-on-LAN,
+r8125: jumbo frames up to 9KB, VLAN offloading, and NAPI support.
+r8125:
+r8125: Homepage: https://www.realtek.com/