Learn more about these different git repos.
Other Git URLs
My auotomatic changelog is evaluated to:
%changelog * Pá dub 10 2020 John Doe <packager@example.com> - 0.2.2-1.fc32 - local build
The date would better be in English.
https://pagure.io/Fedora-Infra/rpmautospec/pull-request/106
Commit 61152d8 fixes this issue
This still happens with fedpkg:
[rust-ammonia (rawhide)]$ export LANG=C.utf-8 [rust-ammonia (rawhide)]$ fedpkg srpm setting SOURCE_DATE_EPOCH=1626652800 Wrote: /home/churchyard/rpmbuild/fedora-scm/rust-ammonia/rust-ammonia-3.1.2-2.fc35.src.rpm [rust-ammonia (rawhide)]$ rpm -q --changelog rust-ammonia-3.1.2-2.fc35.src.rpm * Mon Jul 19 2021 Miro Hrončok <miro@hroncok.cz> 3.1.2-2 - test * Thu Jul 08 2021 Fabio Valentini <decathorpe@gmail.com> 3.1.2-1 - Update to version 3.1.2; Fixes RHBZ#1980546 ... [rust-ammonia (rawhide)]$ export LANG=cs_CZ.utf-8 [rust-ammonia (rawhide)]$ fedpkg srpm chyba: špatný datum v %changelog: Po čec 19 2021 Miro Hrončok <miro@hroncok.cz> 3.1.2-2 Zapsáno: /home/churchyard/rpmbuild/fedora-scm/rust-ammonia/rust-ammonia-3.1.2-2.fc35.src.rpm [rust-ammonia (rawhide)]$ rpm -q --changelog rust-ammonia-3.1.2-2.fc35.src.rpm (empty)
"chyba: špatný datum" means "error: wrong date".
Metadata Update from @churchyard: - Issue status updated to: Open (was: Closed)
Could you please take a look at this? It is a very annoying thing.
Sorry, didn't get around to working on rpmautospec much lately…
Considering that fedpkg srpm doesn't use the locally installed macro, the previous fix won't help here – this needs to be done in the Python code which preprocesses the spec file.
fedpkg srpm
Metadata Update from @nphilipp: - Issue assigned to nphilipp
Metadata Update from @nphilipp: - Issue set to the milestone: So you call this production ready?
alias fedpkg="LANG=C fedpkg" works, of course. But fedpkg should distinguish between (localized) user facing output and hopefully invariant srpms and such which it produces.
alias fedpkg="LANG=C fedpkg"
rpmlint complains about these non-existing dates.
rpmlint
To add to the confusion, rpm --changelog apparantly converts the dates to LANG (or rather the resulting LC_TIME) when it produces user facing output, which is arguably "correct" but not the verbatim content of the changelog in the rpm/spec. I.e., spec dates are really "date data" used as a locale-independent base for formatting locale-dependent output.
rpm --changelog
LANG
LC_TIME
Heh, it looks like rpmautospec generate-changelog on its own does "the right thing by accident", because it doesn't set the locale at all, i.e. masking this bug by not having a feature. :grinning:
rpmautospec generate-changelog
I've implemented a fix, for now this is queued here: https://pagure.io/fork/nphilipp/fedora-infra/rpmautospec/commits/main--random-fixes-and-additions
Any update on this? I fought for hours trying to figure out why SOURCE_DATE_EPOCH was not set.
Commit 17e2e68 fixes this issue
Login to comment on this ticket.