[RFC patch iwhd] Add native systemd

Pete Zaitcev zaitcev at redhat.com
Wed Nov 9 23:38:19 UTC 2011


On Wed, 09 Nov 2011 21:42:01 +0100
Jim Meyering <jim at meyering.net> wrote:

> > 1. The unitdir madness. The problem here is that DESTDIR may be empty,
> > and in the same time the prefix set to something. Therefore, unitdir
> > cannot be defined as an absolute path. The _only_ way to stuff this
> > makefile through the "make check" is to use one of the predefined
> > variables that depend on prefix _and_ DESTDIR (which may be non-empty).
> > Ergo, the double-dot over sysconfigdir. Madness.

> > +unitdir = $(sysconfdir)/../lib/systemd/system
> >  .PHONY: install-data-local

I hoped that your experience would suggest some magic trick with
the m4 files somewhere, but oh well.

> The uninstall-local rule would have removed the system's
> copy of /lib/systemd/system/iwhd.service
> when run by root with empty DESTDIR and with a nonempty $(prefix).

>  	  $(DESTDIR)$(sysconfdir)/sysconfig/iwhd \
> -	  $(DESTDIR)/lib/systemd/system/iwhd.service \
> +	  $(DESTDIR)/$(unitdir)/iwhd.service \
>  	  $(logrotate_dir)/iwhd

Right, sorry. This is what I tried previously and that didn't work, but
I forgot to fix the uninstall case. The slash between them is not
necessary, I think.

-- Pete


More information about the iwhd-devel mailing list