[gnome-initial-setup/shell/4765: 9/362] Fix gnome-welcome-tour install location and hardcoding
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-initial-setup/shell/4765: 9/362] Fix gnome-welcome-tour install location and hardcoding
- Date: Thu, 19 Mar 2015 01:21:49 +0000 (UTC)
commit b28ca0b38cbe97ad8c66bc4d0837a48196319bfd
Author: Cosimo Cecchi <cosimo endlessm com>
Date: Fri Nov 1 14:30:32 2013 -0700
Fix gnome-welcome-tour install location and hardcoding
- install gnome-welcome-tour in $(bindir), since it's going to be called
from eos-shell as well
- don't hardcode /usr/libexec but generate the correct $(libexecdir),
since Debian-based distros don't use /usr/libexec
- remove call to yelp, since we don't want it (yet?)
data/Makefile.am | 15 ++++++++++---
data/gnome-welcome-tour | 34 ---------------------------------
data/gnome-welcome-tour.desktop.in.in | 2 +-
data/gnome-welcome-tour.in | 19 ++++++++++++++++++
4 files changed, 31 insertions(+), 39 deletions(-)
---
diff --git a/data/Makefile.am b/data/Makefile.am
index f9a9e12..c95ef81 100644
--- a/data/Makefile.am
+++ b/data/Makefile.am
@@ -5,11 +5,16 @@ edit = $(AM_V_GEN) sed \
-e 's|@SYSCONFDIR[ ]|$(sysconfdir)|g' \
-e 's|@LIBDIR[ ]|$(libdir)|g' \
-e 's|@LIBEXECDIR[ ]|$(libexecdir)|g' \
- -e 's|@LOCALSTATEDIR[ ]|$(localstatedir)|g'
+ -e 's|@LOCALSTATEDIR[ ]|$(localstatedir)|g' \
+ -e 's|@DATADIR[ ]|$(datadir)|g'
%.desktop.in: %.desktop.in.in Makefile
$(edit) $< >$@
+gnome-welcome-tour: gnome-welcome-tour.in Makefile
+ $(edit) $< >$@
+ chmod +x $@
+
@INTLTOOL_DESKTOP_RULE@
rulesdir = $(datadir)/polkit-1/rules.d
@@ -29,13 +34,13 @@ desktop_DATA = \
EXTRA_DIST = \
20-gnome-initial-setup.rules \
- gnome-welcome-tour \
setup-shell.desktop \
gnome-welcome-tour.desktop.in.in \
gnome-initial-setup-first-login.desktop.in.in \
gnome-initial-setup.desktop.in.in \
gnome-initial-setup-copy-worker.desktop.in.in \
gnome-initial-setup.session \
+ gnome-welcome-tour.in \
initial-setup.json \
$(NULL)
@@ -47,6 +52,7 @@ CLEANFILES = \
gnome-initial-setup-first-login.desktop \
gnome-welcome-tour.desktop.in \
gnome-welcome-tour.desktop \
+ gnome-welcome-tour \
$(NULL)
autostartdir = $(sysconfdir)/xdg/autostart
@@ -56,5 +62,6 @@ autostart_DATA = \
gnome-initial-setup-first-login.desktop \
$(NULL)
-libexec_SCRIPTS = \
- gnome-welcome-tour
+bin_SCRIPTS = \
+ gnome-welcome-tour \
+ $(NULL)
diff --git a/data/gnome-welcome-tour.desktop.in.in b/data/gnome-welcome-tour.desktop.in.in
index b6972de..244316d 100644
--- a/data/gnome-welcome-tour.desktop.in.in
+++ b/data/gnome-welcome-tour.desktop.in.in
@@ -1,6 +1,6 @@
[Desktop Entry]
Type=Application
Name=Welcome
-Exec= LIBEXECDIR@/gnome-welcome-tour
+Exec=gnome-welcome-tour
AutostartCondition=if-exists run-welcome-tour
OnlyShowIn=GNOME;
diff --git a/data/gnome-welcome-tour.in b/data/gnome-welcome-tour.in
new file mode 100644
index 0000000..cd4c243
--- /dev/null
+++ b/data/gnome-welcome-tour.in
@@ -0,0 +1,19 @@
+#! /bin/sh
+
+cfgdir=${XDG_CONFIG_DIR:-$HOME/.config}
+prefix= DATADIR@/EndlessOS/getting-started
+suffix=endless-getting-started.mov
+full_locale=$LANG
+locale=`echo $full_locale | sed -e 's/\..*//'`
+lang=`echo $locale | sed -e 's/_.*//'`
+
+rm -f $cfgdir/run-welcome-tour
+
+for name in $locale $lang 'C'; do
+ if test -f "$prefix/$name/$suffix" ; then
+ intro_path="$prefix/$name/$suffix"
+ break;
+ fi
+done
+
+ LIBEXECDIR@/gnome-initial-setup-player $intro_path
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]