]> git.ipfire.org Git - thirdparty/systemd.git/commit
shared/cryptsetup-util: build problematic code only in developer mode
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Tue, 28 Nov 2023 16:28:06 +0000 (17:28 +0100)
committerLuca Boccassi <luca.boccassi@gmail.com>
Tue, 28 Nov 2023 20:23:45 +0000 (20:23 +0000)
commit25757715feb586d43388a035592fdedaac75c1db
treeab6d594f5c324e631b3567c567115675266c81cc
parent51219be99295eee3dbfc3d546fdb75cd29ce5f29
shared/cryptsetup-util: build problematic code only in developer mode

This code doesn't link when gcc+lld is used:

$ LDFLAGS=-fuse-ld=lld meson setup build-lld && ninja -C build-lld udevadm
...
ld.lld: error: src/shared/libsystemd-shared-255.a(libsystemd-shared-255.a.p/cryptsetup-util.c.o):
  symbol crypt_token_external_path@@ has undefined version
collect2: error: ld returned 1 exit status

As a work-around, restrict it to developer mode.

Closes https://github.com/systemd/systemd/issues/30218.
docs/ENVIRONMENT.md
src/shared/cryptsetup-util.c