Compare commits

...

6 Commits

7 changed files with 244 additions and 86 deletions

View File

@ -1,2 +1,2 @@
VERSION=1.25
VERSION=1.26
RELEASE=1mamba

View File

@ -1,13 +1,23 @@
## conversion rules for unpackaged files
format_unpackaged_file_list_common="\
s,^/usr/share/doc/,%{_docdir}/,
# python
s,^/usr/include/python3.3m,%{python3_inc},
# java
s,^/usr/share/java,%{_javadir},
# xdg
s,^/usr/share/metainfo,%{_metainfodir},
# qt5
s,^/usr/include/qt5,%{_qt5_headerdir},
s,^/usr/share/doc/qt5,%{_qt5_docdir},
# qt6
s,^/usr/include/qt6,%{_qt6_headerdir},
s,^/usr/share/doc/qt6,%{_qt6_docdir},
# kde5
s,^/usr/include/KF5,%{_kde5_includedir},
s,^/usr/share/kf5,%{_kde5_datadir}/kf5,
s,^/usr/share/kservicetypes5,%{_kde5_servicetypesdir},
# kf6
s,^/usr/include/KF6,%{_kf6_includedir},
s,^/usr/share/kf6,%{_kf6_datadir}/kf6,
# systemd
s,^/usr/lib/systemd/system,%{_unitdir},
s,^/usr/lib/systemd/user,%{_userunitdir},
@ -29,6 +39,11 @@ s,^/usr/lib/systemd/system-generators,%{_systemdgeneratordir},
s,^/usr/lib/systemd/user-generators,%{_systemdusergeneratordir},
s,^/usr/lib/systemd/system-environment-generators,%{_systemd_system_env_generator_dir},
s,^/usr/lib/systemd/user-environment-generators,%{_systemd_user_env_generator_dir},
# perl
s,^/usr/lib/perl[5-9]/site_perl/[0-9.]*/.*-linux-thread-multi,%{perl_sitearch},
s,^/usr/lib/perl[5-9]/site_perl/[0-9.]*,%{perl_sitelib},
s,^/usr/lib/perl[5-9]/vendor_perl/[0-9.]*/.*-linux-thread-multi,%{perl_vendorarch},
s,^/usr/lib/perl[5-9]/vendor_perl/[0-9.]*,%{perl_vendorlib},
# pam
s,^/etc/security,%{_pam_secconfdir},
s,^/etc/pam.d,%{_pam_confdir},
@ -36,6 +51,7 @@ s,^/usr/share/pam.d,%{_pam_vendordir},
# generic translations
s,^/usr/bin,%{_bindir},
s,^/usr/sbin,%{_sbindir},
s,^/usr/share/doc/,%{_docdir}/,
s,^/usr/share/info,%{_infodir},
s,^/usr/share/man,%{_mandir},
s,^/usr/share,%{_datadir},
@ -52,6 +68,15 @@ format_unpackaged_file_list_i586="\
s,^/usr/lib/cmake/KF5,%{_kde5_libdir}/cmake/KF5,
s,^/usr/lib/libKF5,%{_kde5_libdir}/libKF5,
s,^/usr/lib/qt5/mkspecs/modules/qt_K,%{_kde5_mkspecsdir}/qt_K,
# kde6
s,^/usr/lib/qt6/plugins/kf6,%{_kf6_plugindir},
# qt5
s,^/usr/lib/qt5/plugins,%{_qt5_plugindir},
s,^/usr/lib/qt5,%{_qt5_prefix},
# qt6
s,^/usr/lib/qt6/plugins,%{_qt6_plugindir},
s,^/usr/lib/qt6/qml,%{_qt6_qmldir},
s,^/usr/lib/qt6,%{_qt6_archdatadir},
# python
s,^/usr/lib/python2.7/site-packages,%{python27_sitearch},
s,^/usr/lib/python3.11/site-packages,%{python3_sitearch},
@ -75,6 +100,15 @@ format_unpackaged_file_list_x86_64="\
s,^/usr/lib64/cmake/KF5,%{_kde5_libdir}/cmake/KF5,
s,^/usr/lib64/libKF5,%{_kde5_libdir}/libKF5,
s,^/usr/lib64/qt5/mkspecs/modules/qt_K,%{_kde5_mkspecsdir}/qt_K,
# kde6
s,^/usr/lib64/qt6/plugins/kf6,%{_kf6_plugindir},
# qt5
s,^/usr/lib64/qt5/plugins,%{_qt5_plugindir},
s,^/usr/lib64/qt5,%{_qt5_prefix},
# qt6
s,^/usr/lib64/qt6/plugins,%{_qt6_plugindir},
s,^/usr/lib64/qt6/qml,%{_qt6_qmldir},
s,^/usr/lib64/qt6,%{_qt6_archdatadir},
# python
s,^/usr/lib64/python2.7/site-packages,%{python27_sitearch},
s,^/usr/lib/python2.7/site-packages,%{python27_sitelib},

View File

@ -980,6 +980,9 @@ function git.create_tarball() {
if [ "${git_branch/@*}" != "${git_branch}" ]; then
git_commit="${git_branch/*@}"
git_branch="${git_branch/@*}"
if [ ! "${git_commit}" ]; then
notify.error "$FUNCNAME: cannot checkout empty commit"
fi
fi
notify.debug "$FUNCNAME: git_branch = \"$git_branch\""
if [ "${git_commit}" ]; then
@ -1053,7 +1056,11 @@ not the expected package version"" (${NOTE}${today}git${NORM})..."
if [ "${git_commit}" ]; then
cd ${pck_tarball}
git checkout ${git_commit}
git checkout ${git_commit} || {
popd &>/dev/null
rm -fr $tmpgitdir
notify.error $"cannot checkout the specified tag";
}
cd ..
fi

View File

@ -65,8 +65,8 @@ locales: merge-pot-files
$(srcdir)/po/$(pck_catalog_tmpl) && \
echo "[DONE]" || { echo "[FAILED]"; exit 1; }
@echo -n "Checking $(pck_catalog) for untranslated strings... "
@/bin/grep -q 'msgstr[ \t]*\"\"' $(pck_catalog) && \
{ echo "[UNTRASLATED STRING]"; exit 1; } || \
@/bin/grep -q 'msgstr[ \t]*""' $(pck_catalog) && \
{ echo "[UNTRANSLATED STRING]"; exit 1; } || \
echo "[NONE]"
install: $(pck_catalog:.po=.mo)

View File

@ -1,21 +1,3 @@
# Italian translation.
# Copyright (C) 2004-2013 Davide Madrisan
# This file is distributed under the same license as the autospec package.
# Davide Madrisan <davide.madrisan@gmail.com>, 2004-2013.
#
msgid ""
msgstr "Project-Id-Version: autospec 1.16.4\n"
"Report-Msgid-Bugs-To: davide.madrisan@gmail.com\n"
"POT-Creation-Date: 2013-07-13 19:30+0100\n"
"PO-Revision-Date: 2013-07-13 19:30+0100\n"
"Last-Translator: Davide Madrisan <davide.madrisan@gmail.com>\n"
"Language-Team: \n"
"Language: Italian \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
msgid "this script requires bash version 2 or better"
msgstr "questo script richiede bash versione 2 o superiore"
@ -203,8 +185,8 @@ msgid "a new version of \\`${NOTE}$specname${NORM}' is available!"
msgstr "è disponibile una nuova versione di \\`${NOTE}$specname${NORM}'!"
msgid "a newer version of \\`${NOTE}$specname${NORM}' is already installed"
msgstr "è già installata una versione successiva di \\`${NOTE}$specname"
"${NORM}'"
msgstr "è già installata una versione successiva di "
"\\`${NOTE}$specname${NORM}'"
msgid "cannot find a new version of \\`$specname'"
msgstr "impossibile trovare una nuova versione per \\`$specname'"
@ -237,12 +219,12 @@ msgstr "tema di colori sconosciuto \\`$color_scheme': output con colori "
msgid "utility not found"
msgstr "programma non trovato"
msgid "missing mandatory arg"
msgstr "parametro mancante"
msgid "usage error (--ftp/--html)"
msgstr "errato utilizzo (--ftp/--html)"
msgid "missing mandatory arg"
msgstr "parametro mancante"
msgid "'\\\\' characters detected in \\$pck_name"
msgstr "trovato carattere '\\\\' in \\$pck_name"
@ -297,6 +279,9 @@ msgstr "clonazione del repository"
msgid "cannot clone git repository"
msgstr "impossibile clonare il repository git"
msgid "cannot checkout the specified tag"
msgstr "impossibile fare il checkout del tag specificato"
msgid "creating the compressed source tarball"
msgstr "creazione del file sorgente compresso"
@ -518,7 +503,8 @@ msgid "Override packager email"
msgstr "Ridefinisce l'indirizzo mail del packager"
msgid "Override release append tag (predefined: $DISTRO_rpm)"
msgstr "Ridefinisce l'etichetta aggiunta alla release (predefinito: $DISTRO_rpm)"
msgstr "Ridefinisce l'etichetta aggiunta alla release (predefinito: "
"$DISTRO_rpm)"
msgid "action"
msgstr "azione"
@ -586,8 +572,8 @@ msgstr "specfile in formato non supportato"
msgid "release number: unsupported format"
msgstr "numero di release: formato non supportato"
msgid "new release \\`$pck_newrel' must be greater than current one \\`"
"$SPEC_RELEASE'"
msgid "new release \\`$pck_newrel' must be greater than current one "
"\\`$SPEC_RELEASE'"
msgstr "la nuova release \\`$pck_newrel' deve essere maggiore di quella "
"corrente \\`$SPEC_RELEASE'"
@ -724,8 +710,8 @@ msgid "cannot install the needed build requirements"
msgstr "impossibile installare i \"build requirement\" necessari"
msgid "found ${NOTE}missing BuildRequirement${NORM} \\`${NOTE}$f${NORM}'"
msgstr "trovato ${NOTE}BuildRequirement non soddisfatto${NORM} \\`${NOTE}$f"
"${NORM}'"
msgstr "trovato ${NOTE}BuildRequirement non soddisfatto${NORM} "
"\\`${NOTE}$f${NORM}'"
msgid "testing out specfile"
msgstr "esecuzione dei test sullo specfile"
@ -744,7 +730,8 @@ msgstr "Sembra ok ma non dimenticare di eseguire i test di qualità e "
"sicurezza"
msgid "no arch-specific pattern translations for unpackaged files"
msgstr "nessuna corrispondenza di pattern legati all'architettura per i file non pacchetizzati"
msgstr "nessuna corrispondenza di pattern legati all'architettura per i file "
"non pacchetizzati"
msgid "Add the following files in the right %files blocks"
msgstr "Smistare i seguenti file nelle sezioni %files corrispondenti"
@ -767,9 +754,6 @@ msgid "\n"
msgstr "\n"
"Sostituzione del blocco AUTOBUILDREQ e ricreazione del pacchetto SRPM"
msgid "replacing the AUTOBUILDREQ block by:"
msgstr "sostituzione del blocco AUTOBUILDREQ con:"
msgid "rpm exited with error code:"
msgstr "rpm è terminato con il codice di errore:"
@ -779,9 +763,6 @@ msgstr "controllo dello specfile alla ricerca di comuni errori"
msgid "checking packages for common mistakes"
msgstr "controllo dei pacchetti alla ricerca di comuni errori"
msgid "server unreachable"
msgstr "server non raggiungibile"
msgid "you have no read write access to url#$ftp_server_upload_num"
msgstr "accesso in scrittura alla url#$ftp_server_upload_num vietato"
@ -871,8 +852,10 @@ msgstr "specfile per applicazioni web"
msgid "Redirect the output to the file <outfile>"
msgstr "Redirige lo standard output sul file <outfile>"
msgid "Specify a git branch or tag and (optionally) a commit by appending @commit_id"
msgstr "Specifica un branch o un tag git e (opzionalmente) un commit aggiungendo @commit_id"
msgid "Specify a git branch or tag and (optionally) a commit by appending "
"@commit_id"
msgstr "Specifica un branch o un tag git e (opzionalmente) un commit "
"aggiungendo @commit_id"
msgid "Do not remove git files"
msgstr "Non rimuove i file git"
@ -904,9 +887,6 @@ msgstr "impossibile trovare il pacchetto $pck_tarball"
msgid "cannot get the package name, use the \\`-n' option"
msgstr "impossibile ricavare il nome del pacchetto, usa l'opzione \\`-n'"
msgid "invalid version number"
msgstr "numero di versione non valido"
msgid "cannot get the package version, use the \\`-v' option"
msgstr "impossibile ricavare la versione del pacchetto, usa l'opzione \\`-v'"
@ -976,6 +956,22 @@ msgstr "manca almeno una direttiva \\`%defattr'"
msgid "use rpm macros if possible:"
msgstr "utilizzare le macro rpm quando possibile:"
# Italian translation.
# Copyright (C) 2004-2013 Davide Madrisan
# This file is distributed under the same license as the autospec package.
# Davide Madrisan <davide.madrisan@gmail.com>, 2004-2013.
#
msgid ""
msgstr "Project-Id-Version: autospec 1.16.4\n"
"Report-Msgid-Bugs-To: davide.madrisan@gmail.com\n"
"POT-Creation-Date: 2013-07-13 19:30+0100\n"
"PO-Revision-Date: 2013-07-13 19:30+0100\n"
"Last-Translator: Davide Madrisan <davide.madrisan@gmail.com>\n"
"Language-Team: \n"
"Language: Italian \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
msgid "localization files must be packaged via \\`%find_lang'"
msgstr "trovati file di localizzazione non gestiti da \\`%find_lang'"
@ -1103,3 +1099,12 @@ msgid "${NOTE}Security checks: ${#rpmpkg_name[@]} package(s) checked: "
"${NORM}${WARN}$total_issues${NORM}${NOTE} warning(s).${NORM}"
msgstr "${NOTE}Controlli di sicurezza: pacchetti rpm: ${#rpmpkg_name[@]}; "
"problemi riscontrati: ${NORM}${WARN}$total_issues${NORM}"
#~ msgid "replacing the AUTOBUILDREQ block by:"
#~ msgstr "sostituzione del blocco AUTOBUILDREQ con:"
#~ msgid "server unreachable"
#~ msgstr "server non raggiungibile"
#~ msgid "invalid version number"
#~ msgstr "numero di versione non valido"

View File

@ -1,5 +1,5 @@
%define ghc_ver %(ghc --numeric-version)
%define pkgname %(echo %name | sed "s|^ghc-||")
%define pkg_name %(echo %name | sed "s|^ghc-||")
Name: @pck_name@
Version: @pck_version@
@ -9,8 +9,8 @@ Group: Development/Libraries
Vendor: @VENDOR@
Distribution: @DISTRO@
Packager: @packager_fullname@ <@packager_email@>
URL: http://hackage.haskell.org/package/%{pkgname}
Source: http://hackage.haskell.org/package/%{pkgname}-%{version}/%{pkgname}-%{version}.tar.gz
URL: https://hackage.haskell.org/package/%{pkg_name}
Source: https://hackage.haskell.org/package/%{pkg_name}-%{version}/%{pkg_name}-%{version}.tar.gz
License: BSD
## AUTOBUILDREQ-BEGIN
## AUTOBUILDREQ-END
@ -22,59 +22,60 @@ Requires(post): %{__install_info}
Requires(preun): %{__install_info}
@fi:infopages
BuildRequires: ghc
BuildRequires: hscolour
BuildRequires: ghc-rpm-macros
Requires: ghc = %{ghc_ver}
%description
...
%{summary}.
## Remove the following block if there is no binary tool provided
#%package -n %{pkgname}
#Group: Applications/Development
#Summary: ...
#
#%description -n %{pkgname}
#...
%package devel
Summary: Haskell %{pkg_name} library development files
Provides: %{name}-static = %{?epoch:%epoch:}%{version}-%{release}
Provides: %{name}-static%{?_isa} = %{?epoch:%epoch:}%{version}-%{release}
%if %{defined ghc_version}
Requires: ghc = %{ghc_version}
%endif
Requires: %{name}%{?_isa} = %{?epoch:%epoch:}%{version}-%{release}
%description devel
This package provides the Haskell %{pkg_name} library development files.
%if %{with haddock}
%package doc
Summary: Haskell %{pkg_name} library documentation
Requires: ghc-filesystem
%description doc
This package provides the Haskell %{pkg_name} library documentation.
%endif
%prep
%setup -q -n %{pkgname}-%{version}
%build
runghc Setup.hs configure -v2 \\
\ --prefix=%{_prefix} \\
\ --libdir=%{_libdir} \\
\ --libexecdir=%{_libexecdir} \\
\ --docdir=%{_docdir}/%{name}-%{version}
runghc Setup.hs build
runghc Setup.hs haddock --executable --html-location=URL --hyperlink-source
%ghc_lib_build
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
runghc Setup.hs copy --destdir=%{buildroot}
runghc Setup.hs register \\
\ --gen-pkg-config="%{buildroot}%{_libdir}/ghc-%{ghc_ver}/%{pkgname}-%{version}/%{pkgname}-%{version}.conf"
%ghc_lib_install
rm -f %{buildroot}%{_ghclicensedir}/%{name}/LICENSE
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%post
ghc-pkg register %{_libdir}/ghc-%{ghc_ver}/%{pkgname}-%{version}/%{pkgname}-%{version}.conf &>/dev/null || :
%preun
ghc-pkg unregister %{pkgname}-%{version} &>/dev/null || :
%files
%files -f %{name}.files
%defattr(-,root,root)
%{_libdir}/ghc-%{ghc_ver}/%{pkgname}-%{version}
%dir %{_docdir}/%{name}-%{version}
%{_docdir}/%{name}-%{version}/LICENSE
%{_docdir}/%{name}-%{version}/html
%license LICENSE
## Remove the following block if there is no binary tool provided
#%files -n %{pkgname}
#%defattr(-,root,root)
#%{_bindir}/%{pkgname}
%files devel -f %{name}-devel.files
%defattr(-,root,root)
#%doc CHANGELOG.markdown README.markdown
%if %{with haddock}
%files doc -f %{name}-doc.files
%defattr(-,root,root)
%license LICENSE
%endif
%changelog
* @spec_changelog_date@ @packager_fullname@ <@packager_email@> @pck_version@-@spec_first_release@@DISTRO_rpm@

111
templates/kf6 Normal file
View File

@ -0,0 +1,111 @@
%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}"
%post -n lib%{name}
@if:shared_libraries
## remove the following line if no dynamic libraries are provided by this package
/sbin/ldconfig
@fi:shared_libraries
exit 0
%postun -n lib%{name}
@if:shared_libraries
## remove the following line if no dynamic libraries are provided by this package
/sbin/ldconfig
@fi:shared_libraries
exit 0
@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@