[libconfig-model-dpkg-perl] 14/19: scanner: assume all source files are utf-8

dod at debian.org dod at debian.org
Sun Jan 3 11:44:19 UTC 2016


This is an automated email from the git hooks/post-receive script.

dod pushed a commit to branch master
in repository libconfig-model-dpkg-perl.

commit c3dbd1a90d32bc9dd6a19555ff7d4ca8309110f0
Author: Dominique Dumont <dod at debian.org>
Date:   Sat Jan 2 19:41:37 2016 +0100

    scanner: assume all source files are utf-8
---
 lib/Dpkg/Copyright/Scanner.pm | 23 ++++++++++++++++++++++-
 1 file changed, 22 insertions(+), 1 deletion(-)

diff --git a/lib/Dpkg/Copyright/Scanner.pm b/lib/Dpkg/Copyright/Scanner.pm
index c37ec12..806d07f 100644
--- a/lib/Dpkg/Copyright/Scanner.pm
+++ b/lib/Dpkg/Copyright/Scanner.pm
@@ -106,7 +106,7 @@ sub scan_files ( %args ) {
     else {
         foreach my $opts ( ('--skipped', q! -c '(?i:readme|license|copying).*'!)) {
             my $pipe = IO::Pipe->new();
-            $pipe->reader("licensecheck --copyright -m -r $opts .");
+            $pipe->reader("licensecheck --encoding utf8 --copyright -m -r $opts .");
             binmode($pipe, ":encoding(UTF-8)");
             push @lines, $pipe->getlines;
             $pipe->close;
@@ -652,6 +652,27 @@ Extracting license and copyright data from unstructured comments is not reliable
 User must check manually the files when no copyright info is found or when the
 license is unknown.
 
+Source files are assumed to be utf8 (or ascii). Using files with other encoding
+will lead to garbled names of copyright owner. In this case, you can:
+
+=over
+
+=item *
+
+Path source files to use utf-8 encoding.
+
+=item *
+
+Use the "fill copyright blank" mechanism described above with
+C<copyright-override> to provide an owner name with the correct
+encoding.
+
+=item *
+
+File a bug against licensecheck of devscript package to find a better solution.
+
+=back
+
 =head1 SEE ALSO
 
 L<licensecheck>, C<licensecheck2dep5> from C<cdbs> package

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libconfig-model-dpkg-perl.git



More information about the Pkg-perl-cvs-commits mailing list