!6 同步最新版本到22.03-LTS-Next
From: @peijiankang Reviewed-by: @tanyulong2021 Signed-off-by: @tanyulong2021
This commit is contained in:
commit
2ae7d73482
40
0001-Fix-the-version-of-kylin-photo-viewer.patch
Normal file
40
0001-Fix-the-version-of-kylin-photo-viewer.patch
Normal file
@ -0,0 +1,40 @@
|
||||
From 9e00da4394cc3159edec55b95019e172772ecea0 Mon Sep 17 00:00:00 2001
|
||||
From: peijiankang <peijiankang@kylinos.cn>
|
||||
Date: Thu, 9 Jun 2022 11:34:59 +0800
|
||||
Subject: [PATCH] Fix the version of kylin-photo-viewer
|
||||
|
||||
---
|
||||
src/view/menumodule.cpp | 17 +++++++++++++++++
|
||||
1 file changed, 17 insertions(+)
|
||||
|
||||
diff --git a/src/view/menumodule.cpp b/src/view/menumodule.cpp
|
||||
index a974db7..28e7aaa 100644
|
||||
--- a/src/view/menumodule.cpp
|
||||
+++ b/src/view/menumodule.cpp
|
||||
@@ -207,6 +207,23 @@ QHBoxLayout* menuModule::initTitleBar(){
|
||||
|
||||
QVBoxLayout* menuModule::initBody(){
|
||||
m_appVersion = VERSION_NEM;
|
||||
+ QProcess proc;
|
||||
+ QStringList options;
|
||||
+ options << "-qa" << "|" << "grep" << "kylin-photo-viewer";
|
||||
+ proc.start("rpm", options);
|
||||
+ proc.waitForFinished();
|
||||
+ QString dpkgInfo = proc.readAll();
|
||||
+ QStringList infoList = dpkgInfo.split("\n");
|
||||
+ for (int n = 0; n < infoList.size(); n++) {
|
||||
+ QString strInfoLine = infoList[n];
|
||||
+ if (strInfoLine.contains("kylin-photo-viewer")) {
|
||||
+ QStringList lineInfoList = strInfoLine.split(QRegExp("-"));
|
||||
+ if (lineInfoList.size() >= 3) {
|
||||
+ m_appVersion = lineInfoList[3];
|
||||
+ }
|
||||
+ break;
|
||||
+ }
|
||||
+ }
|
||||
// QLabel* bodyIcon = new QLabel();
|
||||
QPushButton *bodyIcon = new QPushButton();
|
||||
bodyIcon->setFixedSize(MICON_SIZEB);
|
||||
--
|
||||
2.33.0
|
||||
|
||||
BIN
kylin-photo-viewer-1.0.2.tar.gz
Normal file
BIN
kylin-photo-viewer-1.0.2.tar.gz
Normal file
Binary file not shown.
85
kylin-photo-viewer.spec
Normal file
85
kylin-photo-viewer.spec
Normal file
@ -0,0 +1,85 @@
|
||||
%define debug_package %{nil}
|
||||
Name: kylin-photo-viewer
|
||||
Version: 1.0.2
|
||||
Release: 4
|
||||
Summary: kylin-photo-viewer
|
||||
License: BSL-1.0 and Libpng and zlib and GPL-2.0-or-later
|
||||
URL: https://github.com/UbuntuKylin/kylin-photo-viewer
|
||||
Source0: %{name}-%{version}.tar.gz
|
||||
Patch01: 0001-Fix-the-version-of-kylin-photo-viewer.patch
|
||||
|
||||
BuildRequires: qt5-qtbase-devel
|
||||
BuildRequires: qtchooser
|
||||
BuildRequires: qt5-qtscript-devel
|
||||
BuildRequires: qt5-qttools-devel
|
||||
BuildRequires: qt5-linguist
|
||||
BuildRequires: opencv
|
||||
BuildRequires: qt5-qtsvg-devel
|
||||
BuildRequires: giflib-devel
|
||||
BuildRequires: libpng-devel
|
||||
BuildRequires: freeimage-devel
|
||||
BuildRequires: qt5-qtx11extras-devel
|
||||
BuildRequires: kf5-kwindowsystem-devel
|
||||
BuildRequires: gsettings-qt-devel
|
||||
BuildRequires: ukui-interface
|
||||
BuildRequires: glib2-devel
|
||||
BuildRequires: peony libpeony-dev
|
||||
|
||||
%description
|
||||
Photo viewer, support to view, zoom and rotate images of various formats
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch1 -p1
|
||||
|
||||
|
||||
%build
|
||||
export PATH=%{_qt5_bindir}:$PATH
|
||||
mkdir qmake-build
|
||||
pushd qmake-build
|
||||
%{qmake_qt5} ..
|
||||
%{make_build}
|
||||
popd
|
||||
|
||||
%install
|
||||
pushd qmake-build
|
||||
%{make_install} INSTALL_ROOT=%{buildroot}
|
||||
popd
|
||||
|
||||
mkdir -p %{buildroot}/usr/share/kylin-user-guide/data/guide
|
||||
|
||||
cp -r %{_builddir}/%{name}-%{version}/data/pictures %{buildroot}/usr/share/kylin-user-guide/data/guide/
|
||||
|
||||
%files
|
||||
%{_bindir}/kylin-photo-viewer
|
||||
%{_includedir}/kylin_image_codec/kylinimagecodec.h
|
||||
%{_includedir}/kylin_image_codec/kylinimagecodec_global.h
|
||||
%{_includedir}/kylin_image_codec/loadmovie.h
|
||||
%{_includedir}/kylin_image_codec/savemovie.h
|
||||
%{_includedir}/kylin_image_codec/stb_image.h
|
||||
%{_includedir}/kylin_image_codec/stb_image_write.h
|
||||
%{_prefix}/lib/libkylinimagecodec.so
|
||||
%{_prefix}/lib/libkylinimagecodec.so.1
|
||||
%{_prefix}/lib/libkylinimagecodec.so.1.0
|
||||
%{_prefix}/lib/libkylinimagecodec.so.1.0.0
|
||||
%{_libdir}/cmake/Qt5Gui/Qt5Gui_ApngImagePlugin.cmake
|
||||
%{_libdir}/qt5/plugins/imageformats/libqapng.so
|
||||
%{_datadir}/applications/kylin-photo-viewer.desktop
|
||||
%{_datadir}/glib-2.0/schemas/org.kylin.photo.viewer.gschema.xml
|
||||
%{_datadir}/glib-2.0/schemas/org.ukui.log4qt.kylin-photo-viewer.gschema.xml
|
||||
%{_datadir}/kylin-photo-viewer/translations/kylin-photo-viewer_zh_CN.qm
|
||||
%{_datadir}/pixmaps/kyview_logo.png
|
||||
%{_datadir}/kylin-user-guide/data/guide/
|
||||
|
||||
%changelog
|
||||
* Thu Jun 9 2022 peijiankang <peijiankang@kylinos.cn> - 1.0.2-4
|
||||
- add kylin-user-guide file
|
||||
|
||||
* Thu Jun 9 2022 peijiankang <peijiankang@kylinos.cn> - 1.0.2-3
|
||||
- Fix the version of kylin-photo-viewer
|
||||
|
||||
* Thu May 26 2022 peijiankang <peijiankang@kylinos.cn> - 1.0.2-2
|
||||
- remove {%if 0 and %endif}
|
||||
|
||||
* Fri May 20 2022 peijiankang <peijiankang@kylinos.cn> - 1.0.2-1
|
||||
- Init kylin-photo-viewer package for openEuler
|
||||
4
kylin-photo-viewer.yaml
Normal file
4
kylin-photo-viewer.yaml
Normal file
@ -0,0 +1,4 @@
|
||||
version_control: github
|
||||
src_repo: UbuntuKylin/kylin-photo-viewer
|
||||
tag_prefix: ""
|
||||
separator: "."
|
||||
Loading…
x
Reference in New Issue
Block a user