Update package version to 1.7.0

This commit is contained in:
2025-05-11 20:34:13 +03:00
parent 7fb9370590
commit 1bd0cc78ad
3 changed files with 48 additions and 17 deletions
+15
View File
@@ -0,0 +1,15 @@
#!/bin/bash
# Github repository
REPO="linux-pam/linux-pam"
# Get tag name using Github Rest API
TAG_NAME=$(curl -s -L -H "Accept: application/vnd.github+json" -H "X-GitHub-Api-Version: 2022-11-28" https://api.github.com/repos/"$REPO"/releases/latest | jq -r '.tag_name')
# Get version number from tag name
VERSION=$(echo "$TAG_NAME" | rev | cut -d'-' -f1 | rev)
# Trim 'v' character in VERSION variable
VERSION=$(echo "$VERSION" | tr -d 'v')
echo "$VERSION"
+3 -2
View File
@@ -1,8 +1,9 @@
name: pam name: pam
description: Pluggable Authentication Modules for Linux description: Pluggable Authentication Modules for Linux
version: 1.6.0 version: 1.7.0
revision: 5
url: https://github.com/linux-pam/linux-pam url: https://github.com/linux-pam/linux-pam
license: GPL2-or-later license: GPL2-or-later
architecture: any architecture: any
depends: ["glibc","elogind","libnsl","libtirpc","libxcrypt","docbook-xsl-nons"]
make_depends: ["flex","libxslt","meson"]
type: source type: source
+30 -15
View File
@@ -15,29 +15,44 @@ prepare() {
# The build function is executed in the source directory # The build function is executed in the source directory
# This function is used to compile the source code # This function is used to compile the source code
build() { build() {
./configure --prefix=/usr \ mkdir build
--sbindir=/usr/sbin \ cd build
--sysconfdir=/etc \
--libdir=/usr/lib \ meson setup --prefix=/usr \
--enable-securedir=/usr/lib/security \ --buildtype=release \
--docdir=/usr/share/doc/Linux-PAM -Ddocdir=/usr/share/doc/Linux-PAM ..
make meson compile
}
# The check function is executed in the source directory
# This function is used to run tests to verify the package has been compiled correctly
check() {
cd build
meson test
} }
# The package function is executed in the source directory # The package function is executed in the source directory
# This function is used to move the compiled files into the output directory # This function is used to move the compiled files into the output directory
package() { package() {
make DESTDIR="$BPM_OUTPUT" install cd build
chmod -v 4755 "$BPM_OUTPUT"/usr/sbin/unix_chkpwd
mkdir -p "$BPM_OUTPUT"/etc/pam.d/ meson install --destdir="$BPM_OUTPUT"
cp ../system-account "$BPM_OUTPUT"/etc/pam.d/system-account
cp ../system-auth "$BPM_OUTPUT"/etc/pam.d/system-auth # Set uid for unix_chkpwd
cp ../system-session "$BPM_OUTPUT"/etc/pam.d/system-session chmod +s "$BPM_OUTPUT"/usr/sbin/unix_chkpwd
cp ../system-password "$BPM_OUTPUT"/etc/pam.d/system-password
cp ../other "$BPM_OUTPUT"/etc/pam.d/other # Install pam configuration files
install -d "$BPM_OUTPUT"/etc/pam.d/
install -m644 "$BPM_WORKDIR"/system-account "$BPM_OUTPUT"/etc/pam.d/system-account
install -m644 "$BPM_WORKDIR"/system-auth "$BPM_OUTPUT"/etc/pam.d/system-auth
install -m644 "$BPM_WORKDIR"/system-session "$BPM_OUTPUT"/etc/pam.d/system-session
install -m644 "$BPM_WORKDIR"/system-password "$BPM_OUTPUT"/etc/pam.d/system-password
install -m644 "$BPM_WORKDIR"/other "$BPM_OUTPUT"/etc/pam.d/other
# Remove systemd services # Remove systemd services
rm -r "$BPM_OUTPUT"/usr/lib/systemd rm -r "$BPM_OUTPUT"/usr/lib/systemd
# Install package license
install -Dm644 "$BPM_SOURCE"/COPYING "$BPM_OUTPUT"/usr/share/licenses/pam/COPYING install -Dm644 "$BPM_SOURCE"/COPYING "$BPM_OUTPUT"/usr/share/licenses/pam/COPYING
} }