diff --git a/.fmf/version b/.fmf/version new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/.fmf/version @@ -0,0 +1 @@ +1 diff --git a/.gitignore b/.gitignore index 6c742bd..74e651a 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,14 @@ /po4a-0.60.tar.gz /po4a-0.61.tar.gz /po4a-0.63.tar.gz +/po4a-0.64.tar.gz +/po4a-0.65.tar.gz +/po4a-0.66.tar.gz +/po4a-0.67.tar.gz +/po4a-0.68.tar.gz +/po4a-0.69.tar.gz +/po4a-0.70.tar.gz +/po4a-0.71.tar.gz +/po4a-0.72.tar.gz +/po4a-0.73.tar.gz +/po4a-0.74.tar.gz diff --git a/.packit.yaml b/.packit.yaml new file mode 100644 index 0000000..1f3f5d8 --- /dev/null +++ b/.packit.yaml @@ -0,0 +1,33 @@ +specfile_path: po4a.spec + +# name in upstream package repository or registry (e.g. in PyPI) +upstream_package_name: po4a +upstream_project_url: https://github.com/mquinson/po4a +upstream_tag_template: v{version} +# downstream (Fedora) RPM package name +downstream_package_name: po4a +issue_repository: https://src.fedoraproject.org/rpms/po4a + +upload_sources: true + +actions: + changelog-entry: + - bash -c 'echo "- New release ${PACKIT_PROJECT_VERSION}"' + +jobs: + - job: pull_from_upstream + trigger: release + dist_git_branches: + - fedora-rawhide + + - job: koji_build + trigger: commit + allowed_pr_authors: ["packit", "sergiomb"] + allowed_committers: ["packit", "sergiomb"] + dist_git_branches: + - fedora-all + + - job: bodhi_update + trigger: commit + dist_git_branches: + - fedora-all # rawhide updates are created automatically diff --git a/README.packit b/README.packit new file mode 100644 index 0000000..d2b528d --- /dev/null +++ b/README.packit @@ -0,0 +1,3 @@ +This repository is maintained by packit. +https://packit.dev/ +The file was generated using packit 0.97.1.post1.dev6+gc8c0314a. diff --git a/gating.yaml b/gating.yaml new file mode 100644 index 0000000..2c7ed80 --- /dev/null +++ b/gating.yaml @@ -0,0 +1,6 @@ +--- !Policy +product_versions: + - rhel-* +decision_context: osci_compose_gate +rules: + - !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional} diff --git a/plans.fmf b/plans.fmf new file mode 100644 index 0000000..39e69d8 --- /dev/null +++ b/plans.fmf @@ -0,0 +1,11 @@ +summary: Run all smoke tests +discover: + how: fmf +prepare: + how: install + package: + - bash + - coreutils + - grep +execute: + how: tmt diff --git a/po4a.spec b/po4a.spec index 46b4174..60be350 100644 --- a/po4a.spec +++ b/po4a.spec @@ -1,20 +1,24 @@ Name: po4a -Version: 0.63 -Release: 1%{?dist} +Version: 0.74 +Release: 3%{?dist} Summary: A tool maintaining translations anywhere -License: GPL+ + +# Note: source is imprecise about 2.0-only vs 2.0-or-later +# https://github.com/mquinson/po4a/issues/434 +License: GPL-2.0-or-later URL: https://po4a.org/ Source0: https://github.com/mquinson/po4a/archive/v%{version}/%{name}-%{version}.tar.gz BuildArch: noarch -BuildRequires: %{_bindir}/xsltproc +BuildRequires: /usr/bin/xsltproc BuildRequires: coreutils BuildRequires: docbook-style-xsl BuildRequires: findutils BuildRequires: grep # Requires a pod2man which supports --utf8 # Seemingly added in perl-5.10.1 +BuildRequires: glibc-all-langpacks BuildRequires: perl-interpreter >= 4:5.10.1 BuildRequires: perl-generators BuildRequires: perl(lib) @@ -29,8 +33,8 @@ BuildRequires: perl(Module::Build) BuildRequires: perl(Pod::Man) # Run-time: -BuildRequires: %{_bindir}/nsgmls BuildRequires: gettext +BuildRequires: opensp BuildRequires: perl(Carp) BuildRequires: perl(Config) BuildRequires: perl(Cwd) @@ -64,14 +68,15 @@ BuildRequires: perl(Text::WrapI18N) BuildRequires: perl(Unicode::GCString) # Required by the tests: +BuildRequires: perl(Syntax::Keyword::Try) BuildRequires: perl(Test::More) +BuildRequires: perl(Test::Pod) BuildRequires: perl(YAML::Tiny) -Requires: %{_bindir}/nsgmls -Requires: %{_bindir}/xsltproc +Requires: /usr/bin/xsltproc Requires: gettext -Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) +Requires: opensp # hope texlive-kpseas-bin missing deps was fixed # epel7 doesn't have /usr/share/texlive/texmf-dist/web2c/texmf.cnf Requires: texlive-kpathsea @@ -96,12 +101,10 @@ chmod +x scripts/* %build export PO4AFLAGS="-v -v -v" -LANG=C.utf8 %{__perl} ./Build.PL installdirs=vendor ./Build %install -LANG=C.utf8 ./Build install destdir=$RPM_BUILD_ROOT create_packlist=0 find $RPM_BUILD_ROOT -type d -depth -exec rmdir {} 2>/dev/null ';' @@ -109,8 +112,7 @@ find $RPM_BUILD_ROOT -type d -depth -exec rmdir {} 2>/dev/null ';' %find_lang %{name} %check -LANG=C.utf8 -#./Build test +./Build test || : %files -f %{name}.lang @@ -133,6 +135,99 @@ LANG=C.utf8 %{_mandir}/*/man7/po4a.7* %changelog +* Fri Jul 25 2025 Fedora Release Engineering - 0.74-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild + +* Wed Jul 23 2025 Steven A. Falco - 0.74-2 +- Convert from STI to TMT + +* Sat Jul 12 2025 Steven A. Falco - 0.74-1 +- Update to 0.74 + +* Sat Jan 18 2025 Fedora Release Engineering - 0.73-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild + +* Fri Jul 19 2024 Fedora Release Engineering - 0.73-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild + +* Mon Jun 17 2024 Packit - 0.73-1 +- New release 0.73 + +* Sun May 26 2024 Packit - 0.72-1 +- New release 0.72 + +* Thu May 09 2024 Richard W.M. Jones - 0.71-4 +- Fix "Malformed encoding" error with newest Perl + (https://github.com/mquinson/po4a/issues/494) + +* Mon Mar 11 2024 Sérgio Basto - 0.71-3 +- Disable tests again, randomly they fail with Charset "CHARSET" is not a + portable encoding name. Message conversion to user's charset might not work. + +* Mon Mar 04 2024 Sérgio Basto - 0.71-2 +- Add upstream patch Fix the --translate-only option + +* Sat Mar 02 2024 Packit - 0.71-1 +- New release 0.71 + +* Sun Feb 25 2024 Sérgio Basto - 0.70-2 +- Fix the parsing of nested simple and double quotes +- Enable build tests + +* Sun Feb 18 2024 Sérgio M. Basto - 0.70-1 +- New release 0.70 + +* Thu Jan 25 2024 Fedora Release Engineering - 0.69-5 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + +* Sun Jan 21 2024 Fedora Release Engineering - 0.69-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + +* Thu Oct 12 2023 Yaakov Selkowitz - 0.69-3 +- Fix path-based dependencies + +* Fri Jul 21 2023 Fedora Release Engineering - 0.69-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild + +* Mon Jan 23 2023 Sérgio Basto - 0.69-1 +- Update po4a to 0.69 (#2157762) + +* Fri Jan 20 2023 Fedora Release Engineering - 0.68-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild + +* Wed Sep 28 2022 Sérgio Basto - 0.68-1 +- Update po4a to 0.68 (#2124178) + +* Wed Aug 03 2022 Sérgio Basto - 0.67-1 +- Update po4a to 0.67 (#2107698) + +* Fri Jul 22 2022 Fedora Release Engineering - 0.66-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild + +* Wed Jun 01 2022 Jitka Plesnikova - 0.66-3 +- Perl 5.36 rebuild + +* Fri Jan 21 2022 Fedora Release Engineering - 0.66-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild + +* Sat Jan 15 2022 Sérgio Basto - 0.66-1 +- Update po4a to 0.66 (#2036534) + +* Sun Dec 12 2021 Sérgio Basto - 0.65-1 +- Update po4a to 0.65 (#2023095) + +* Mon Nov 01 2021 Sérgio Basto - 0.64-1 +- Update po4a to 0.64 (#2003502) + +* Mon Sep 20 2021 Richard W.M. Jones - 0.63-4 +- Add gating tests for RHEL 9 + +* Fri Jul 23 2021 Fedora Release Engineering - 0.63-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild + +* Sat May 22 2021 Jitka Plesnikova - 0.63-2 +- Perl 5.34 rebuild + * Tue Feb 23 2021 Sérgio Basto - 0.63-1 - Update po4a to 0.63 (#1905315) diff --git a/sources b/sources index 65a767e..13db246 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (po4a-0.63.tar.gz) = 6dc86ed655c8ed0398ef68f5abb50e68da307b56044e051819221f94dfb79187c2c9ac1f42db858b867514f66227617701d75671496d2138a27d49de35a4e06d +SHA512 (po4a-0.74.tar.gz) = 0af7099ea25ac3bc8667c84acf0e0b3c9bbcfd45661dc9befe88b2f3363d6c6c428699ca740a470eaefbe1bf9d55fb218844e0e69104a424fbde71eb240cbdd4 diff --git a/tests/basic-test.sh b/tests/basic-test.sh new file mode 100755 index 0000000..b15af6d --- /dev/null +++ b/tests/basic-test.sh @@ -0,0 +1,41 @@ +#!/bin/bash - + +set -e +set -x + +po4a --help + +# Write a test POD (Perl doc) file to the local directory. +cat >test.pod < +EOF + +cp test.pod local.pod + +# Try to compile it into a POT file using po4a-gettextize: +po4a-gettextize -f pod -M utf-8 -L utf-8 \ + --package-name hello \ + --package-version 1.0 \ + --msgid-bugs-address noone@example.com \ + --copyright-holder "Red Hat Inc." \ + -p output.pot -m test.pod -l local.pod + +cat output.pot + +# Check for some expected strings in the output. +grep 'msgid "DESCRIPTION"' output.pot + +grep 'msgid "This is the hello world documentation"' output.pot + +# Clean up. +rm output.pot test.pod local.pod diff --git a/tests/main.fmf b/tests/main.fmf new file mode 100644 index 0000000..b2e5e98 --- /dev/null +++ b/tests/main.fmf @@ -0,0 +1,2 @@ +summary: Smoke test +test: ./basic-test.sh