Drop unused symbols from version script after 5263c249495b
LLD 16 enabled --no-undefined-version by default but temporarily
downgraded errors to warnings. LLD 17 now fails to build:
ld: error: version script assignment of 'global' to symbol 'sd_bus_attach_event' failed: symbol not defined
ld: error: version script assignment of 'global' to symbol 'sd_bus_detach_event' failed: symbol not defined
ld: error: version script assignment of 'global' to symbol 'sd_bus_get_event' failed: symbol not defined
build: bump version to 0.2.1
Workaround build failure by -Wpedantic with GCC 12
With GCC 12, even with -std=gnu99, -Wpedantic complains about %m in format
strings, __PRETTY_FUNCTION__, braces inside expressions, etc.; and it
makes some of these into errors.
Signed-off-by: Ismael Luceno <firstname.lastname@example.org>
build: fix whitespace in project()
LLD 13 and GNU ld 2.37 support -z start-stop-gc which allows garbage
collection of C identifier name sections despite the __start_/__stop_
references. Simply set the retain attribute so that GCC 11 (if
configure-time binutils is 2.36 or newer)/Clang 13 will set the
SHF_GNU_RETAIN section attribute to prevent garbage collection.
Without the patch, there are linker errors like the following with -z
ld: error: undefined symbol: __start_SYSTEMD_BUS_ERROR_MAP
>>> referenced by bus-error.c:93 (../src/libsystemd/sd-bus/bus-error.c:93)
>>> sd-bus_bus-error.c.o:(bus_error_name_to_errno) in archive src/libsystemd/libsystemd_static.a
Co-authored-by: Evgeniy Khramtsov <email@example.com>
meson: convert audit option to feature object
features are more idiomatic and ubiquitous
meson: add libcap option
it's better to provide the user with this choice instead of
unconditionally magically depending on it
meson: Link basuctl with libbasu dynamically
This reduces the installed size significantly. I don't know about any
reason for bundling libbasu in basuctl when they both come from the
readme: reference mailing list and issue tracker
readme: update IRC channel
freebsd: Do not use cr_pid from LOCAL_PEERCRED
LOCAL_PEERCRED is used as substitute for SO_PEERCRED on FreeBSD. One of
the fields needed from there is the PID of the peer process. However,
while SO_PEERCRED returns the PID at the time of connect(2),
LOCAL_PEERCRED returns the PID at the time of listen(2). If the dbus
daemon fork(2)'d after listen(2) to daemonize, then the PID returned
will no longer exist, which breaks basu.
Remove the use of cr_pid for now, as it cannot be used.
test: switch to getprogname on FreeBSD
`program_invocation_short_name` is an alias for `__progname` in glibc.
FreeBSD also has `__progname` defined by startup code but (like `environ`)
it's not declared in any system header. Consumers are encouraged to
use `getprogname()` instead.
license: Remove GPL2 text
There are no GPL2 licensed files left in the repository at the time of
this commit, leaving the repo solely LGPL2.1+ licensed.
Delete the GPL2 license text as it no longer has any relevance.
ci: Mount linprocfs on FreeBSD
This allow the credential test to run correctly. This does not mean that
linprocfs is required for basu to work, just that this particular
functionality uses it.
bus-creds: Handle ESRCH from get_process_comm
FreeBSD's linprocfs does not have a comm file, so get_process_comm
returns ESRCH. Handle this gracefully instead of throwing in the towel.
basic/macro: Undef align on FreeBSD
This silences a lot of warnings.
bus-creds: Skip parse caps instead of -ENOTSUP
This means that we just interpret processes as having no capabilities,
rather than causing errors that terminate bus_cred setup.