packaging: add launcher
authorPhilippe Coval <philippe.coval@open.eurogiciel.org>
Wed, 14 May 2014 10:33:51 +0000 (12:33 +0200)
committerTomasz Olszak <olszak.tomasz@gmail.com>
Mon, 9 Nov 2015 17:27:21 +0000 (18:27 +0100)
Change-Id: I65551527e8b0b82ee9353167d09c2edd568a2eef
Signed-off-by: Philippe Coval <philippe.coval@open.eurogiciel.org>
packaging/qt5-qtdeclarative-examples.desktop [new file with mode: 0644]
packaging/qt5-qtdeclarative-examples.sh [new file with mode: 0644]
packaging/qt5-qtdeclarative.spec

diff --git a/packaging/qt5-qtdeclarative-examples.desktop b/packaging/qt5-qtdeclarative-examples.desktop
new file mode 100644 (file)
index 0000000..111872e
--- /dev/null
@@ -0,0 +1,4 @@
+[Desktop Entry]
+Name=Qt Declarative examples
+Type=Application
+Exec=/usr/bin/qt5-qtdeclarative-examples.sh
diff --git a/packaging/qt5-qtdeclarative-examples.sh b/packaging/qt5-qtdeclarative-examples.sh
new file mode 100644 (file)
index 0000000..647568b
--- /dev/null
@@ -0,0 +1,2 @@
+#!/bin/sh
+qml /usr/share/qt5/qt5-qtdeclarative/examples/quick/demos/samegame/samegame.qml
index 27543e650a6c0a59b612123ee351bbe45eb46d9f..e958ff879de0e47089277e87238d41bb1fd7a568 100644 (file)
@@ -32,6 +32,8 @@ License:    LGPL-2.1+ or GPL-3.0
 URL:        http://qt.digia.com
 Source0:    %{name}-%{version}.tar.bz2
 Source1001: %{name}.manifest
+Source1010: %{name}-examples.sh
+Source1011: %{name}-examples.desktop
 BuildRequires:  qt5-qtcore-devel
 BuildRequires:  qt5-qtgui-devel
 BuildRequires:  qt5-qtnetwork-devel
@@ -273,11 +275,17 @@ This package contains QML debugging and development tools
 Summary:    QML and Qt Quick Examples
 Group:      Base/Libraries
 Requires:   %{name} = %{version}-%{release}
+Requires:   qt5-plugin-imageformat-jpeg
+Requires:   qt5-qtdeclarative-import-multimedia
+Requires:   qt5-qtdeclarative-import-particles2
+Requires:   qt5-qtdeclarative-import-qtquick2plugin
+Requires:   qt5-qtdeclarative-qmlscene
 
 %description examples
 This package contains QML and Qt Quick Examples for developers.
-Those can run using qmlscene interperter :
-ie: qmlscene ./examples/quick/tutorials/samegame/samegame4/samegame.qml
+Those can run used with luncher script or using interperter :
+ie: qml ./examples/quick/demos/*/*.qml
+
 
 
 #### Build section
@@ -316,7 +324,10 @@ cp lib/libQt5QmlDevTools.a %{buildroot}%{_libdir}
 # Manually copy examples
 install -d "%{buildroot}%{_datadir}/qt5/%{name}/"
 cp -rf examples "%{buildroot}%{_datadir}/qt5/%{name}/"
-
+install -d "%{buildroot}%{_bindir}/"
+install %{SOURCE1010} "%{buildroot}%{_bindir}/"
+install -d "%{buildroot}%{_datadir}/applications/"
+install %{SOURCE1011} "%{buildroot}%{_datadir}/applications/"
 
 #### Pre/Post section
 
@@ -514,6 +525,8 @@ cp -rf examples "%{buildroot}%{_datadir}/qt5/%{name}/"
 %files examples
 %defattr(-,root,root,-)
 %manifest %{name}.manifest
+%{_bindir}/%{name}-examples.sh
+%{_datadir}/applications/%{name}-examples.desktop
 %{_datadir}/qt5/%{name}/examples/*