autospec/templates/kf6

98 lines
2.6 KiB
Plaintext
Raw Normal View History

%define framework %(echo %name | sed "s|^kf6-||")
%define majver %(echo %version | cut -d. -f1-2)
Name: @pck_name@
Version: @pck_version@
Release: @spec_first_release@@DISTRO_rpm@
Summary: ...
Group: ...
Vendor: @VENDOR@
Distribution: @DISTRO@
Packager: @packager_fullname@ <@packager_email@>
URL: https://kde.org
Source: ...
License: ...
## AUTOBUILDREQ-BEGIN
## note: run 'autospec -u -a6 @pck_name@' to get the list of build requirements.
## AUTOBUILDREQ-END
BuildRequires: cmake
BuildRequires: kf6-rpm-macros
BuildRequires: extra-cmake-modules
Requires: lib%{name} = %{?epoch:%epoch:}%{version}-%{release}
%description
...
## remove the library block if this package does not provide library and development stuff
%package -n lib%{name}
Group: System/Libraries
Summary: Shared libraries for %{name}
%description -n lib%{name}
This package contains shared libraries for %{name}.
%package -n lib%{name}-devel
Group: Development/Libraries
Summary: Development files for %{name}
Requires: lib%{name} = %{?epoch:%epoch:}%{version}-%{release}
%description -n lib%{name}-devel
This package contains libraries and header files for developing applications that use %{name}.
@if:debug_package
%debug_package
@fi:debug_package
%prep
%setup -q
%build
%cmake_kf6
%cmake_build
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%cmake_install
@if:i18n
%find_lang %{name} --with-qt --with-man --with-html --all-name || touch %{name}.lang
@fi:i18n
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
@if:i18n
%files -f %{name}.lang
@else:i18n
%files
@fi:i18n
%defattr(-,root,root)
## note: this list is just an example; modify as required
# %{_kde6_bindir}/%{name}
# %{_kde6_datadir}/%{name}
## note: "man3" pages normally goes to devel package if any
# %{_mandir}/man?/%{name}.*
@standard_docs@
## note: eventually add the remaining documents (if any)
# @standard_docs_devel@
## remove this block if the package does not provide library and development stuff
%files -n lib%{name}
%defattr(-,root,root)
## note: this list is just an example; modify as required
# %{_kde6_libdir}/*.so
%files -n lib%{name}-devel
%defattr(-,root,root)
## note: this list is just an example; modify as required
# %{_kde6_includedir}/<KF5Framework>
# %{_kde6_includedir}/%{name}_version.h
# %{_kde6_libdir}/cmake/<KF5Framework>
# %{_kde6_libdir}/*.so
# %{_kde6_mkspecsdir}/qt_*.pri
%changelog
* @spec_changelog_date@ @packager_fullname@ <@packager_email@> @pck_version@-@spec_first_release@@DISTRO_rpm@
- @spec_changelog_comment@