Opened 3 years ago

Closed 3 years ago

#14170 closed defect (fixed)

Build broken on any platform lacking systemd

Reported by: Sebastian Owned by:
Priority: Medium Milestone: Tor: 0.2.6.x-final
Component: Core Tor/Tor Version:
Severity: Keywords:
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:


a8999acc3bca05f1aaa23399c7d5f7a5e51789a4 which was supposed to fix building of the systemd watchdog broke building on any platform without systemd. Just reverting that commit for now seems like the wrong idea, however, because the underlying issue still exists which isn't being addressed at all - the systemd configure check fails. I have a patch in branch systemd209 in my repo, but building that on my systemd-enabled jessie produces linking errors at the very end. I'm not too well versed in the systemd world, our entire detection magic needs to be checked for all cases because right now we even get the non-corner cases wrong.

This was first reported by Toralf Förster <toralf.foerster@…> on #tor-dev as indicated in my commit msg

Child Tickets

Change History (6)

comment:1 Changed 3 years ago by Sebastian

Status: newneeds_review

aha, the issue is that -lsystemd is missing from the link flags. I've added it in a fixup commit to my branch. I'm not sure if that is the right way to go about this tho, or if more checking is needed whether -lsystemd is actually required or available. This works for me on jessie with systemd as well as OSX.

comment:2 Changed 3 years ago by yancm

I can confirm build is broken on NetBSD 6.1_Stable i386 (non-systemd architecture):

checking host system type... i386-unknown-netbsdelf6.1.
checking for pkg-config... /usr/pkg/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for SYSTEMD... no
checking for SYSTEMD209... no
configure: error: Package requirements (systemd >= 209) were not met:

No package 'systemd' found

Consider adjusting the PKG_CONFIG_PATH environment variable if you
installed software in a non-standard prefix.

Alternatively, you may set the environment variables SYSTEMD209_CFLAGS
and SYSTEMD209_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.
*** Error code 1

make: stopped in /usr/local/src/tor

comment:3 Changed 3 years ago by nickm

Resolution: fixed
Status: needs_reviewclosed

70b3937 should fix this. Thanks, all!

comment:4 Changed 3 years ago by Sebastian

Well, it fixes the build. It does not, however, fix systemd detection on jessie for me, and reintroduces the old bug that was supposed to be fixed with the patch that broke the build. Please see my first two comments in this bug.

comment:5 Changed 3 years ago by Sebastian

Resolution: fixed
Status: closedreopened

comment:6 Changed 3 years ago by nickm

Resolution: fixed
Status: reopenedclosed

Should be fixed for real now with b0c32106b3559b4ee9fabfb1a49e2e328c850305

Note: See TracTickets for help on using tickets.