Bug 40446 - The autoconf code sample in daemon(7) fails horribly with plain '--with-systemdsystemunitdir'
Summary: The autoconf code sample in daemon(7) fails horribly with plain '--with-syste...
Status: RESOLVED FIXED
Alias: None
Product: systemd
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Lennart Poettering
QA Contact:
URL: http://lists.x.org/archives/xorg-deve...
Whiteboard:
Keywords: patch
Depends on:
Blocks:
 
Reported: 2011-08-28 23:23 UTC by Michał Górny
Modified: 2013-12-28 04:46 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Michał Górny 2011-08-28 23:23:19 UTC
If a project uses the autoconf sample from daemon(7) and it is passed a plain '--with-systemsystemunitdir', the generated Makefile tries to install systemd unit files in $(DESTDIR)yes which doesn't seem like a good location.

I guess the best solution here would be to decide how it should behave and update the code sample so that no more projects will repeat the same mistake.

As I see it, the most correct solution would be to use pkg-config path then, and fail if it is unavailable.
Comment 1 Michał Górny 2011-08-28 23:40:33 UTC
The linked ml thread also appoints a few other issues:
- using CLEANFILES instead of MOSTLYCLEANFILES so that the file will be removed/recreated on configure opt changes,
- default value in the help string.
Comment 2 Simon McVittie 2011-09-16 07:16:25 UTC
Here's the equivalent bug and patch in dbus: https://bugs.freedesktop.org/show_bug.cgi?id=37847#c5
Comment 3 Michał Górny 2011-09-16 07:23:03 UTC
I've also improved the sample for xdm [1], and considering that upstream isn't interested in sharing macros, I created a small macro (and potentially code) bundle called systemd-sdk [2]. It's intended to provide code which can be reused by projects supporting systemd without the need for complete systemd install.

[1]:http://cgit.freedesktop.org/xorg/app/xdm/commit/?id=0782f1c24c65
[2]:https://github.com/mgorny/systemd-sdk/
Comment 4 Zbigniew Jedrzejewski-Szmek 2013-12-28 04:46:39 UTC
I added the macro from xdm to daemon(7) in http://cgit.freedesktop.org/systemd/systemd/commit/?id=5486855.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.