[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [PATCH] Warn for unknown info files in packages



Hi!

Thanks for the patches.

On Sat, 2023-05-06 at 04:11:05 +0900, Simon Richter wrote:
> Debian Policy forbids info files not mentioned in Policy, except if their
> names start with an underscore to flag them as non-critical.

I think you might be mixing up .deb ar members with entries in the
control member in the .deb?

> diff --git a/src/main/unpack.c b/src/main/unpack.c
> index 9048f6fb0..446f8d4c5 100644
> --- a/src/main/unpack.c
> +++ b/src/main/unpack.c
> @@ -496,9 +496,23 @@ pkg_infodb_update_file(const char *filename, const char *filetype)
>  static void
>  pkg_infodb_update(struct pkginfo *pkg, char *cidir, char *cidirrest)
>  {
> +  char const *const known_info_names[] =
> +  {
> +    "conffiles",
> +    "control",
> +    "preinst",
> +    "prerm",
> +    "postinst",
> +    "postrm",
> +    "triggers"
> +  };

And in any case even if the Debian policy said something to that
effect (which I don't think it does), this could not be applied at
the dpkg level, as it is both non-exhaustive (missing control files
handled by the dpkg suite like shlibs, symbols, md5sums, which is
easily fixable) but in any case it cannot ever be, as we need to
support external parties shipping unknown control files (such as
config, templates for debconf, clilibs for mono (AFAIR), or starlibs
(no clue about that one)), or make allowances for future control
file additions.

If there's ever a need for something like this, I think that would
belong in a linter.

So, I'm not planning on merging this one.

Thanks,
Guillem


Reply to: