summaryrefslogtreecommitdiffstats
path: root/source/a/ndctl/ndctl.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'source/a/ndctl/ndctl.SlackBuild')
-rwxr-xr-xsource/a/ndctl/ndctl.SlackBuild49
1 files changed, 23 insertions, 26 deletions
diff --git a/source/a/ndctl/ndctl.SlackBuild b/source/a/ndctl/ndctl.SlackBuild
index d125ff988..98631aa53 100755
--- a/source/a/ndctl/ndctl.SlackBuild
+++ b/source/a/ndctl/ndctl.SlackBuild
@@ -1,7 +1,7 @@
#!/bin/bash
# Copyright 2020 Robby Workman, Tuscaloosa, Alabama, USA
-# Copyright 2020 Patrick J. Volkerding, Sebeka, Minnesota, USA
+# Copyright 2020, 2022 Patrick J. Volkerding, Sebeka, Minnesota, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -25,7 +25,7 @@ cd $(dirname $0) ; CWD=$(pwd)
PKGNAM=ndctl
VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
-BUILD=${BUILD:-4}
+BUILD=${BUILD:-1}
# Automatically determine the architecture we're building on:
if [ -z "$ARCH" ]; then
@@ -87,37 +87,34 @@ find . \
-exec chmod 644 {} \+
# Configure, build, and install:
-if [ ! -r configure ]; then
- if [ -x ./autogen.sh ]; then
- NOCONFIGURE=1 ./autogen.sh
- else
- autoreconf -vif
- fi
-fi
-CFLAGS="$SLKCFLAGS" \
-CXXFLAGS="$SLKCFLAGS" \
-./configure \
+export CFLAGS="$SLKCFLAGS"
+export CXXFLAGS="$SLKCFLAGS"
+mkdir meson-build
+cd meson-build
+meson setup \
--prefix=/usr \
- --libdir=/usr/lib${LIBDIRSUFFIX} \
+ --libdir=lib${LIBDIRSUFFIX} \
+ --libexecdir=/usr/libexec \
+ --bindir=/usr/bin \
+ --sbindir=/usr/sbin \
+ --includedir=/usr/include \
+ --datadir=/usr/share \
+ --mandir=/usr/man \
--sysconfdir=/etc \
--localstatedir=/var \
- --disable-static \
- --mandir=/usr/man \
- --docdir=/usr/doc/$PKGNAM-$VERSION \
- --without-systemd \
- --disable-asciidoctor \
- --with-bash=no \
- --build=$ARCH-slackware-linux || exit 1
-make $NUMJOBS || make || exit 1
-make install DESTDIR=$PKG || exit 1
-
-# Don't ship .la files:
-rm -f $PKG/{,usr/}lib${LIBDIRSUFFIX}/*.la
+ --buildtype=release \
+ -Dsystemd=disabled \
+ .. || exit 1
+ "${NINJA:=ninja}" $NUMJOBS || exit 1
+ DESTDIR=$PKG $NINJA install || exit 1
+cd ..
mkdir $PKG/lib
mv $PKG/etc/modprobe.d $PKG/lib
-mv $PKG/etc/ndctl/monitor.conf $PKG/etc/ndctl/monitor.conf.new
+for file in $PKG/etc/ndctl.conf.d/ndctl.conf $PKG/etc/ndctl.conf.d/monitor.conf $PKG/etc/daxctl.conf.d/daxctl.example.conf ; do
+ mv $file ${file}.new
+done
# We ship bash-completion in /extra, so this won't build using --with-bash=yes
# since it isn't available on a default installation. No matter, we'll just