I created a RPM package for QOwnNotes.
I know that you already have a RPM SPEC for OBS, but my solution is dedicated to COPR/Koji and supports EL (RHEL, CentOS, Scientific Linux, Oracle Linux) as well as Fedora.
I was thinking about improving the current SPEC for OBS, but unfortunately I'm not very familiar with macros for SUSE/openSUSE.
Here are some tips from me (mainly for Fedora builds):
Use pkgconfig(Qt5Svg) instead of qt5-qtsvg-devel in dependencies. The same applies to other packages.
Don't forget about %post, %postun and %posttrans sections. Provide dependencies for them (Requires(post), Requires(postun), Requires(posttrans)).
Use modern macros: %{autosetup}, %{qmake_qt5}, %{make_build}, %{make_install}, etc.
Remove obsoleted macros and fields: %defattr, BuildRoot.
Use %license macro for license.
Try to use file globbing, especially in %filessection.
GenericName in Desktop file is a generic name of the application, for example "Web Browser", "Text Editor", "Markdown Editor", etc. You shouldn't use the application name here.
It would be nice if you started using unique three-part identifier everywhere you can. This is important mainly for Fedora and Flatpak builds.
Thank you very much for all the information! If you want to improve the OBS builds you can also create pull requests to the templates I use to generate the files on OBS: https://github.com/pbek/QOwnNotes/tree/develop/obs
I created a RPM package for QOwnNotes. I know that you already have a RPM SPEC for OBS, but my solution is dedicated to COPR/Koji and supports EL (RHEL, CentOS, Scientific Linux, Oracle Linux) as well as Fedora. I was thinking about improving the current SPEC for OBS, but unfortunately I'm not very familiar with macros for SUSE/openSUSE.
Here are some tips from me (mainly for Fedora builds):
pkgconfig(Qt5Svg)
instead ofqt5-qtsvg-devel
in dependencies. The same applies to other packages.%post
,%postun
and%posttrans
sections. Provide dependencies for them (Requires(post)
,Requires(postun)
,Requires(posttrans)
).%check
section is also welcome.desktop-file-edit
to edit desktop files.git
!).%{autosetup}
,%{qmake_qt5}
,%{make_build}
,%{make_install}
, etc.%defattr
,BuildRoot
.%license
macro for license.%files
section.GenericName
in Desktop file is a generic name of the application, for example "Web Browser", "Text Editor", "Markdown Editor", etc. You shouldn't use the application name here.See also: