-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Description
I followed the instructions here:
https://fpm.readthedocs.io/en/latest/packages/deb.html#sample-usage
i.e.:
wget https://releases.hashicorp.com/terraform/1.0.10/terraform_1.0.10_linux_amd64.zip
fpm -s zip -t deb --prefix /usr/bin -n terraform -v 1.0.10 terraform_1.0.10_linux_amd64.zip
and then extracted the contents of the package and tried parsing the changelog:
dpkg --extract terraform_1.0.10_amd64.deb extracted
dpkg-parsechangelog -l extracted/usr/share/doc/terraform/changelog.gz
which gave me:
dpkg-parsechangelog: warning: extracted/usr/share/doc/terraform/changelog.gz(l2): found end of file where expected first heading
dpkg-parsechangelog: error: fatal error occurred while parsing extracted/usr/share/doc/terraform/changelog.gz
The output isn't terribly helpful but, looking at the raw contents, it's a bit more obvious what's wrong:
$ zcat extracted/usr/share/doc/terraform/changelog.gz
terraform (1.0.10) ; urgency=medium
* Package created with FPM.
-- <ubuntu@JackPC> Sun, 23 Nov 2025 11:11:06 +0100
There is no distribution specified before the semicolon. As soon as I add something before the semicolon, the changelog can be parsed.
It's possible that there's some combination of FPM flags that solves it, but I feel like the default behaviour probably shouldn't lead to the generation of an invalid changelog file. However, I did try the one that seemed most obvious - --deb-dist unstable - and it did not affect the output (i.e. there was still no distribution specified before the semicolon).