GNOME Bugzilla – Bug 756633
gnome-session shell wraper fails to expand @libexecdir@
Last modified: 2016-01-05 09:15:24 UTC
In this commit: https://git.gnome.org/browse/gnome-session/commit/?id=39f146e6c5727105a3c88c2290654c6ef83102c5 the gnome-session binary was made a wrapper, however the .in file includes @libexecdir@ which expands to "${exec_prefix}/libexec" which fails because exec_prefix is not set in the environment.
Easiest fix is probably to do the rewrite from the makefile instead: $(AM_V_GEN) $(SED) -e "s|\@libexecdir\@|$(libexecdir)|" $< > $@
Or you could use AS_AC_EXPAND() in the configure.ac, which is made for that.
Created attachment 313365 [details] [review] build-goo: generate shell script wrapper in different way Using configure to generate the wrapper doesn't work unless we switch to AS_AC_EXPAND or something since the libexecdir won't fully expand to an absolute path by default. This commit drops the idea of using configure to generate the wrapper and instead falls back to good old sed.
(In reply to Bastien Nocera from comment #2) > Or you could use AS_AC_EXPAND() in the configure.ac, which is made for that. I can see you had the same first thought I had. I don't want to switch to AS_AC_EXPAND for a brown bag release since we aren't already using it, and introducing the macro definition will add complexity. The sed idiom predates AS_AS_EXPAND by many years so should be fine.
Review of attachment 313365 [details] [review]: ::: gnome-session/Makefile.am @@ +20,3 @@ + $(AM_V_GEN) sed \ + -e "s|\@libexecdir\@|$(libexecdir)|" \ + $< > $@ I'd put that on one line, which would make it more readable to me. g-s-d does that: gnome-settings-daemon-localeexec: gnome-settings-daemon-localeexec.in $(AM_V_GEN) sed -e "s|\@libexecdir\@|$(libexecdir)|" -e "s|\@prefix\@|$(prefix)|" $< > $@.tmp && mv $@.tmp $@ Which ensures that the file is atomically created.
Created attachment 313386 [details] [review] build: generate gnome-session script in different way I used this patch to fix this bug.
how is that different? isn't it the same patch?
git bz screwed up but this is pushed now.