summaryrefslogtreecommitdiffstats
path: root/pam_lastlog2
diff options
context:
space:
mode:
Diffstat (limited to 'pam_lastlog2')
-rw-r--r--pam_lastlog2/Makemodule.am2
-rw-r--r--pam_lastlog2/man/pam_lastlog2.86
-rw-r--r--pam_lastlog2/meson.build36
-rw-r--r--pam_lastlog2/src/Makemodule.am5
4 files changed, 43 insertions, 6 deletions
diff --git a/pam_lastlog2/Makemodule.am b/pam_lastlog2/Makemodule.am
index f33c98b..f17cc09 100644
--- a/pam_lastlog2/Makemodule.am
+++ b/pam_lastlog2/Makemodule.am
@@ -3,6 +3,6 @@ if BUILD_PAM_LASTLOG2
include pam_lastlog2/man/Makemodule.am
include pam_lastlog2/src/Makemodule.am
-EXTRA_DIST += pam_lastlog2/COPYING
+EXTRA_DIST += pam_lastlog2/COPYING pam_lastlog2/meson.build
endif # BUILD_PAM_LASTLOG2
diff --git a/pam_lastlog2/man/pam_lastlog2.8 b/pam_lastlog2/man/pam_lastlog2.8
index 99fd2f5..298dd2b 100644
--- a/pam_lastlog2/man/pam_lastlog2.8
+++ b/pam_lastlog2/man/pam_lastlog2.8
@@ -2,12 +2,12 @@
.\" Title: pam_lastlog2
.\" Author: [see the "AUTHOR(S)" section]
.\" Generator: Asciidoctor 2.0.20
-.\" Date: 2024-03-20
+.\" Date: 2024-05-01
.\" Manual: System Administration
-.\" Source: util-linux 2.40
+.\" Source: util-linux 2.40.1
.\" Language: English
.\"
-.TH "PAM_LASTLOG2" "8" "2024-03-20" "util\-linux 2.40" "System Administration"
+.TH "PAM_LASTLOG2" "8" "2024-05-01" "util\-linux 2.40.1" "System Administration"
.ie \n(.g .ds Aq \(aq
.el .ds Aq '
.ss \n[.ss] 0
diff --git a/pam_lastlog2/meson.build b/pam_lastlog2/meson.build
new file mode 100644
index 0000000..12f3a6b
--- /dev/null
+++ b/pam_lastlog2/meson.build
@@ -0,0 +1,36 @@
+build_pam_lastlog2 = not get_option('build-pam-lastlog2') \
+ .require(build_liblastlog2) \
+ .require(conf.get('HAVE_SECURITY_PAM_MODULES_H').to_string() == '1') \
+ .disabled()
+summary('pam_lastlog2', build_pam_lastlog2 ? 'enabled' : 'disabled', section : 'components')
+
+cc = meson.get_compiler('c')
+pkg = import('pkgconfig')
+lib_pam_lastlog2_sources = '''
+ src/pam_lastlog2.c
+'''.split()
+
+pamlibdir = get_option('pamlibdir')
+if pamlibdir == ''
+ pamlibdir = get_option('libdir') / 'security'
+endif
+
+if build_pam_lastlog2
+ pam_lastlog2_sym = 'src/pam_lastlog2.sym'
+ pam_lastlog2_sym_path = '@0@/@1@'.format(meson.current_source_dir(), pam_lastlog2_sym)
+
+ libpam = cc.find_library('pam')
+
+ pam_lastlog2 = shared_module(
+ 'pam_lastlog2',
+ lib_pam_lastlog2_sources,
+ name_prefix : '',
+ include_directories : [dir_include],
+ link_args : ['-Wl,--version-script=@0@'.format(pam_lastlog2_sym_path)],
+ link_depends : pam_lastlog2_sym,
+ dependencies : [libpam, lastlog2_dep],
+ install : build_liblastlog2,
+ install_dir : pamlibdir,
+ )
+ manadocs += ['pam_lastlog2/man/pam_lastlog2.8.adoc']
+endif
diff --git a/pam_lastlog2/src/Makemodule.am b/pam_lastlog2/src/Makemodule.am
index 9884416..f9a9b6b 100644
--- a/pam_lastlog2/src/Makemodule.am
+++ b/pam_lastlog2/src/Makemodule.am
@@ -10,8 +10,9 @@ EXTRA_pam_lastlog2_la_DEPENDENCIES = \
pam_lastlog2_la_CFLAGS = \
$(AM_CFLAGS) \
$(SOLIB_CFLAGS) \
- -I$(ul_liblastlog2_incdir) \
- -Iliblastlog2/src
+ -I$(ul_liblastlog2_incdir)
+
+pam_lastlog2_la_LIBADD = liblastlog2.la
pam_lastlog2_la_LDFLAGS = $(SOLIB_LDFLAGS) -module -avoid-version -shared
if HAVE_VSCRIPT