[Spice-devel] [PATCH spice-streaming-agent] build: Do not use top_srcdir if not necessary

Christophe Fergeau cfergeau at redhat.com
Wed Feb 14 14:06:40 UTC 2018


On Mon, Jan 29, 2018 at 05:16:12PM -0500, Frediano Ziglio wrote:
> > 
> > 
> > > On 29 Jan 2018, at 12:00, Frediano Ziglio <fziglio at redhat.com> wrote:
> > > 
> > > Signed-off-by: Frediano Ziglio <fziglio at redhat.com>
> > > ---
> > > Makefile.am | 4 ++--
> > > 1 file changed, 2 insertions(+), 2 deletions(-)
> > > 
> > > diff --git a/Makefile.am b/Makefile.am
> > > index baa9835..74ec16a 100644
> > > --- a/Makefile.am
> > > +++ b/Makefile.am
> > > @@ -6,11 +6,11 @@ SUBDIRS = \
> > > 
> > > # this will start the program for each user session
> > > xdgautostartdir = $(sysconfdir)/xdg/autostart
> > > -xdgautostart_DATA = $(top_srcdir)/data/spice-streaming.desktop
> > > +xdgautostart_DATA = $(srcdir)/data/spice-streaming.desktop
> > 
> > Could you clarify why it helps in the commit message?
> > Did you run into a problem integrating that in a higher-level project?
> > 
> > Seems to be an enhancement for me anyway, so if you explain
> > why this is incorrect in the commit messageā€¦
> > 
> > Acked-by: Christophe de Dinechin <dinechin at redhat.com>
> > 
> > 
> > > # this will start the program for the login session
> > > gdmautostartdir = $(datadir)/gdm/greeter/autostart
> > > -gdmautostart_DATA = $(top_srcdir)/data/spice-streaming.desktop
> > > +gdmautostart_DATA = $(srcdir)/data/spice-streaming.desktop
> > > 
> > > pkgconfigdir = $(libdir)/pkgconfig
> > > pkgconfig_DATA = spice-streaming-agent.pc
> 
> Beside reducing the typing usually I prefer srcdir because you can move
> (like under a subdirectory) the Makefile and the relative files without
> changing the source.

Fwiw, the argument goes both ways, $(top_srcdir) is going to be better
if you want to move the Makefile.am snippet from Makefile.am to
data/Makefile.am without changing anything else.

Christophe
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/spice-devel/attachments/20180214/8ab69f73/attachment.sig>


More information about the Spice-devel mailing list