commit 5d1b994ba9fe936e266b238ff3a07efbbdab5b5ccb971fe57779f0f415e1747d Author: Dirk Stoecker Date: Tue Oct 13 12:57:28 2015 +0000 Accepting request 338440 from home:alois Lightweight Qt-based hex editor. OBS-URL: https://build.opensuse.org/request/show/338440 OBS-URL: https://build.opensuse.org/package/show/X11:Utilities/qhexedit2?expand=0&rev=1 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/qhexedit.desktop b/qhexedit.desktop new file mode 100644 index 0000000..ee53cda --- /dev/null +++ b/qhexedit.desktop @@ -0,0 +1,8 @@ +[Desktop Entry] +Type=Application +Exec=qhexedit +Name=QHexEdit +Icon=qhexedit +GenericName=Binary Editor +Terminal=false +Categories=Development;Debugger diff --git a/qhexedit2-0.7.4.tar.gz b/qhexedit2-0.7.4.tar.gz new file mode 100644 index 0000000..e0e67b7 --- /dev/null +++ b/qhexedit2-0.7.4.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cd0b4e209955d0fe96db00fd0fd042175b362eb7a89e063084091e636fd504b0 +size 300328 diff --git a/qhexedit2.changes b/qhexedit2.changes new file mode 100644 index 0000000..f614c63 --- /dev/null +++ b/qhexedit2.changes @@ -0,0 +1,5 @@ +------------------------------------------------------------------- +Sun Oct 11 17:38:51 UTC 2015 - aloisio@gmx.com + +- Initial version 0.7.4 + diff --git a/qhexedit2.spec b/qhexedit2.spec new file mode 100644 index 0000000..756e338 --- /dev/null +++ b/qhexedit2.spec @@ -0,0 +1,177 @@ +# +# spec file for package qhexedit2 +# +# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany. +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# + + +Name: qhexedit2 +Version: 0.7.4 +Release: 0 +Summary: Qt-based hex editor +License: LGPL-2.0 +Group: Development/Tools/Other +Url: https://github.com/Simsys/qhexedit2 +Source0: https://github.com/Simsys/%{name}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz +Source1: qhexedit.desktop +BuildRequires: ImageMagick +BuildRequires: fdupes +BuildRequires: pkg-config +BuildRequires: update-desktop-files +%if 0%{?suse_version} > 1110 +BuildRequires: pkgconfig(Qt5Core) +BuildRequires: pkgconfig(Qt5Widgets) +%else +BuildRequires: desktop-file-utils +BuildRequires: libqt4-devel +BuildRoot: %{_tmppath}/%{name}-%{version}-build +%endif +Requires: lib%{name} = %{version}-%{release} + +%description +QHexEdit is a hex editor widget written in C++ for the Qt framework. +It is a simple editor for binary data, just like QPlainTextEdit is for text +data. + +%package devel +Summary: Development files for %{name} +Group: Development/Libraries/C and C++ +Requires: lib%{name} = %{version}-%{release} + +%description devel +The %{name}-devel package contains libraries and header files for +developing applications that use %{name}. + +%package doc +Summary: Documentation and examples for %{name} +Group: Documentation/HTML: +%if 0%{?suse_version} > 1110 +BuildArch: noarch +%endif +Requires: %{name} = %{version}-%{release} + +%description doc +The %{name}-doc package contains the documentation and examples for %{name}. + +%package -n lib%{name} +%if 0%{?suse_version} > 1110 +Summary: Qt5 %{name} library +%else +Summary: Qt %{name} library +%endif +Group: System/Libraries + +%description -n lib%{name} +%if 0%{?suse_version} > 1110 +Qt5 library for %{name}. +%else +Qt library for %{name}. +%endif + +%prep +%setup -q + +%build +mkdir build-lib +pushd build-lib +%if 0%{?suse_version} >1110 +qmake-qt5 QMAKE_CXXFLAGS="%{optflags}" ../src/qhexedit.pro +%else +qmake QMAKE_CXXFLAGS="%{optflags}" ../src/qhexedit.pro +%endif +make %{?_smp_mflags} +popd + +# Build application +mkdir build-example +pushd build-example +%if 0%{?suse_version} > 1110 +qmake-qt5 QMAKE_CXXFLAGS="%{optflags}" ../example/qhexedit.pro +%else +qmake QMAKE_CXXFLAGS="%{optflags}" ../example/qhexedit.pro +%endif +make %{?_smp_mflags} +popd + + +%install +# Library and headers +install -d %{buildroot}%{_includedir}/%{name} +cp -a src/*.h %{buildroot}%{_includedir}/%{name} +install -d %{buildroot}%{_libdir} +chmod 0755 build-lib/*.so.*.* +cp -a build-lib/*.so* %{buildroot}%{_libdir} + +# pkg-config files +install -d %{buildroot}%{_libdir}/pkgconfig/ + +cat > %{buildroot}%{_libdir}/pkgconfig/%{name}.pc < 1110 +%post +%desktop_database_post + +%postun +%desktop_database_postun +%endif + +%post -n lib%{name} -p /sbin/ldconfig + +%postun -n lib%{name} -p /sbin/ldconfig + + +%files +%defattr(-,root,root) +%doc readme.md src/license.txt +%{_bindir}/qhexedit +%{_datadir}/applications/qhexedit.desktop +%{_datadir}/pixmaps/qhexedit.png + +%files doc +%defattr(-,root,root) +%doc doc/html readme.md src/license.txt + +%files -n lib%{name} +%defattr(-,root,root) +%doc doc/release.txt src/license.txt +%{_libdir}/libqhexedit.so.2* + +%files devel +%defattr(-,root,root) +%{_includedir}/%{name}/ +%{_libdir}/libqhexedit.so +%{_libdir}/pkgconfig/%{name}.pc + +%changelog