You are not logged in.

#1 2018-12-30 04:24:52

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 5,231
Website

Get Lintian to recognize a different distro name.

This is probably as much for my own reference as anything, but anyone running lintian on a newly build deb package might get an error tag bad-distribution-in-changes-file if the deb is for BunsenLabs Helium, or any other distro except Debian, Ubuntu or Kali.

It took a  lot of searching, but this bug report showed that the key, along with the documented "profiles" feature, was the files /usr/share/lintian/data/changes-file/known-dists and /usr/share/lintian/vendors/{ubuntu,kali}/main/data/changes-file/known-dists where the permitted distro names are recorded.

It works to add files in /usr/share/lintian, but ~/.local/share/lintian is also checked, so no need for root.

The fix:
1) Declare a BunsenLabs profile. Create ~/.local/share/lintian/profiles/bunsenlabs/main.profile with this content:

Profile: bunsenlabs/main
Extends: debian/main

2) Declare the permitted BL distribution names. Create ~/.local/share/lintian/vendors/bunsenlabs/main/data/changes-file/known-dists with this content:

# Bunsenlabs distributions

hydrogen
helium
lithium

Now, if you are running lintian on a BunsenLabs system, then lintian will automatically detect the profile and the "bad distribution" error will no longer appear. Just as important, lintian will return success, which is useful if you're using it as a check in some kind of automated build process.

If you're not running BL, then pass the option '--profile bunsenlabs'.


John
--------------------
( a boring Japan blog , Japan Links, idle twitterings  and GitStuff )
In case you forget, the rules.

Offline

Board footer

Powered by FluxBB