Skip to content

autoreconf can cause very odd version strings #1994

Closed
@jasontibbitts

Description

@jasontibbitts

While testing some packaging work I found that master -V was showing this rather bizarre string:
cyrus-imapd 2_3_16-6_fc14-112-g5a7ae23-dirty-Fedora-RPM-3.0.1-1.fc27

Turns out that the Fedora package has always run autoreconf, and when that happens it will ignore PACKAGE_VERSION and instead try to find the nearest enclosing git repo and pull the last tag from that. But Fedora package git repos don't really have tags; the only ones in there are from when we converted from CVS many years ago. And that's what gets used.

I ended up changing things so that the package is always built in a fresh git repo with no tags, because that's something our packaging tools do to make it easy to rebase stacks of patches. This results in a version of "unknown" which I guess is a little better.

For now I'm not running autoreconf. That should be fine as long as I don't have some reason to change configure.ac. Is there any way to avoid or override this automatic version determination? (Of course if I have to rerun autoreconf I might as well patch things to not do this, but I'd rather avoid patching if possible.)

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions