Bug 689 - tmpfiles.d configuration on non-rpm/deb-based distros
tmpfiles.d configuration on non-rpm/deb-based distros
Status: RESOLVED FIXED
Product: Sudo
Classification: Unclassified
Component: Configure
1.8.13
PC Linux
: low enhancement
Assigned To: Todd C. Miller
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2015-03-21 18:12 MDT by Evangelos Foutras
Modified: 2015-07-17 09:25 MDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Evangelos Foutras 2015-03-21 18:12:01 MDT
Regarding the following change in Sudo 1.8.13:

"The sudo timestamp directory is now created at boot time on platforms that use systemd." [1]

Would it be possible to install tmpfiles.d configuration on distros that use systemd but are not rpm/deb-based? As it currently stands, the file doesn't get created on Arch Linux, though I've been manually installing one since Sudo 1.8.10. [2]

Perhaps the code in sudo.pp could only check for the existence of /usr/lib/tmpfiles.d and not if the OS platform is rpm/deb?

[1] http://www.sudo.ws/repos/sudo/rev/532dc61e7bb7
[2] https://projects.archlinux.org/svntogit/packages.git/commit/trunk?h=packages/sudo&id=fb11fbf
Comment 1 Todd C. Miller 2015-03-21 19:13:24 MDT
Sure, that should not be a problem.
Comment 2 Todd C. Miller 2015-04-07 09:29:31 MDT
/usr/lib/tmpfiles.d/sudo.conf is now installed as part of "make install".  This file is not packaged for rpm/deb since we need to determine whether systemd is really being used in the postinstall script.

http://www.sudo.ws/repos/sudo/rev/522666bc079f
Comment 3 Evangelos Foutras 2015-04-07 12:33:09 MDT
A couple of small issues:

1) Running 'make install' with more than one job (-j2 and greater) fails with:

===============
/bin/sh: line 1: (destdir)/usr/lib/tmpfiles.d/sudo.conf: No such file or directory
/bin/sh: line 2: (destdir)/usr/lib/tmpfiles.d/sudo.conf: No such file or directory
Makefile:155: recipe for target 'install-rc' failed
===============

I believe this can be solved by either making 'install-dirs' a prerequisite of 'install-rc', or creating the directory in 'install-rc'.

2) $(DESTDIR) shouldn't be included in the directory paths defined inside tmpfiles.d/sudo.conf -- that file should only use $(rundir).
Comment 4 Todd C. Miller 2015-04-07 16:35:47 MDT
http://www.sudo.ws/repos/sudo/rev/930983f88927

I reorganized things a bit which should solve those two issues.
Comment 5 Evangelos Foutras 2015-04-08 02:30:45 MDT
init.d/sudo.conf.in is missing from the repo but other than that it seems to work fine.
Comment 6 Todd C. Miller 2015-04-08 09:04:58 MDT
Fixed.  I was testing release tarballs and not checkouts so I didn't notice the missing file :-)
Comment 7 Todd C. Miller 2015-07-17 09:25:30 MDT
Fixed in sudo 1.8.14, available now.