Package: licenserecon

Hi!  I noticed this when converting libtasn1's debian/copyright, which
has this:

Files: *
License: GPL-3+
...

Files: lib/*.y lib/*.c lib/*.h lib/includes/* lib/gl/*.c lib/gl/*.h src/gl/*.c 
src/gl/*.h lib/libtasn1.map lib/libtasn1.pc.in
...
License: LGPL-2.1+

however lintian rightly complains that this is redundant:

P: libtasn1-6 source: redundant-globbing-patterns (lib/*.c lib/gl/*.c) for 
lib/gl/c-ctype.c [debian/copyright:37]

but removing the lib/gl/*.c part makes lrc complain about license
mismatches for lib/gl/c-ctype.c since it is LGPL-2.1+ and not GPL-3+.

Indeed reading DEP5 says:

  Patterns match pathnames that start at the root of the source
  tree. Thus, "Makefile.in" matches only the file at the root of the
  tree, but "*/Makefile.in" matches at any depth.

My interpretation is that a glob 'lib/*.h' matches BOTH lib/foo.c and
lib/bar/foo.c, and that lintian supports this but lrc does not.  This is
a quite weird glob definition, but it seems to be what DEP5 specify.

In passing I note that GitLab .gitlab-ci.yml uses ** to specify
recursive globbing like this, e.g., **/.c, as well as supporting
non-recursive wildcards as in *.c.  It would have been nice if DEP5 used
that approach instead, but I suppose it is too late to change things.

Do you agree with this reading of DEP5?

Is it a bug that licenserecon doesn't support recursive globbing of the
wildcards?

/Simon

Attachment: signature.asc
Description: PGP signature

Reply via email to