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

[SCM] Debian package checker branch, master, updated. 2.2.0-20-g386f467



The following commit has been merged in the master branch:
commit 386f467fc70b4aa6355929a995e26e369d8d3da4
Author: Russ Allbery <rra@debian.org>
Date:   Fri Jan 30 23:50:11 2009 -0800

    Some improvements to duplicate-font-file
    
    Add a test suite and changelog entry for duplicate-font-file.  Improve
    the tag description and change the certainty to possible.  Also fix the
    tag issued for font-in-non-font-package, which I broke due to an
    incorrect merge.

diff --git a/checks/files b/checks/files
index 8d7739f..7e72da9 100644
--- a/checks/files
+++ b/checks/files
@@ -734,10 +734,10 @@ foreach my $file (sort keys %{$info->index}) {
 	if ($file =~ m,/([\w-]+\.(?:[to]tf|pfb|pcf))$,i) {
 	    my $font = lc $1;
 	    if ($font_packages->known($font)) {
-		tag 'duplicate-font-file', "$file=$font_packages->value($font)"
+		tag 'duplicate-font-file', "$file also in ", $font_packages->value($font)
 		    if ($pkg ne $font_packages->value($font));
 	    } elsif ($pkg !~ m/^[ot]tf-/) {
-		tag 'font-file-not-in-font-package', $file;
+		tag 'font-in-non-font-package', $file;
 	    }
 	}
 
diff --git a/checks/files.desc b/checks/files.desc
index 823d56c..cfcdcb7 100644
--- a/checks/files.desc
+++ b/checks/files.desc
@@ -945,7 +945,9 @@ Info: This package contains a *.ttf or *.otf file, file extensions
 
 Tag: duplicate-font-file
 Severity: normal
-Certainty: certain
-Info: This package appears to be shipping a font file that is already provided
- by another package, on which it should depend and symlink the font, if
- necessary.
+Certainty: possible
+Info: This package appears to include a font file that is already provided
+ by another package in Debian.  It should instead depend on the relevant
+ font package.  If the application in this package loads the font file by
+ name, you may need to include a symlink pointing to the file name of the
+ font in its Debian package.
diff --git a/debian/changelog b/debian/changelog
index 1087b49..2184727 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,7 @@ lintian (2.2.1) UNRELEASED; urgency=low
 
   * Summary of tag changes:
     + Added
+      - duplicate-font-file
       - font-in-non-font-package
 
   * checks/fields:
@@ -11,6 +12,9 @@ lintian (2.2.1) UNRELEASED; urgency=low
   * checks/files{,.desc}:
     + [RA] Add check for fonts in non-font packages.  Thanks, Paul Wise
       and Raphael Geissert.  (Closes: #513650)
+    + [RA] Add check for fonts that duplicate already packaged fonts.
+      Patch from Raphael Geissert.  Thanks to Paul Wise for analysis and
+      data.  (Partly addresses #298545)
   * checks/shared-libs.desc:
     + [RA] Add references to the UsingSymbolsFiles wiki page in the tags
       requesting generation of a symbols file.
diff --git a/t/tests/files-fonts/debian/VeraBd.ttf b/t/tests/files-fonts/debian/VeraBd.ttf
new file mode 100644
index 0000000..61b21c2
--- /dev/null
+++ b/t/tests/files-fonts/debian/VeraBd.ttf
@@ -0,0 +1,3 @@
+This isn't actually Bitstream Vera (since I don't want to paste the
+license for it into Lintian).  The current test is based on the file
+name and doesn't care.
diff --git a/t/tests/files-fonts/debian/debian/files-fonts.install b/t/tests/files-fonts/debian/debian/files-fonts.install
new file mode 100644
index 0000000..0523f69
--- /dev/null
+++ b/t/tests/files-fonts/debian/debian/files-fonts.install
@@ -0,0 +1,3 @@
+font.otf usr/share/fonts/truetype
+font.ttf usr/share/fonts/truetype
+VeraBd.ttf usr/share/fonts/truetype
diff --git a/t/tests/files-fonts/debian/debian/install b/t/tests/files-fonts/debian/debian/install
deleted file mode 100644
index 1597f56..0000000
--- a/t/tests/files-fonts/debian/debian/install
+++ /dev/null
@@ -1,2 +0,0 @@
-font.otf usr/share/fonts/truetype
-font.ttf usr/share/fonts/truetype
diff --git a/t/tests/files-fonts/debian/debian/ttf-files-fonts.install b/t/tests/files-fonts/debian/debian/ttf-files-fonts.install
new file mode 100644
index 0000000..0523f69
--- /dev/null
+++ b/t/tests/files-fonts/debian/debian/ttf-files-fonts.install
@@ -0,0 +1,3 @@
+font.otf usr/share/fonts/truetype
+font.ttf usr/share/fonts/truetype
+VeraBd.ttf usr/share/fonts/truetype
diff --git a/t/tests/files-fonts/tags b/t/tests/files-fonts/tags
index fdd1efb..f459358 100644
--- a/t/tests/files-fonts/tags
+++ b/t/tests/files-fonts/tags
@@ -1,2 +1,4 @@
 I: files-fonts: font-in-non-font-package usr/share/fonts/truetype/font.otf
 I: files-fonts: font-in-non-font-package usr/share/fonts/truetype/font.ttf
+W: files-fonts: duplicate-font-file usr/share/fonts/truetype/VeraBd.ttf also in  ttf-bitstream-vera
+W: ttf-files-fonts: duplicate-font-file usr/share/fonts/truetype/VeraBd.ttf also in  ttf-bitstream-vera

-- 
Debian package checker


Reply to: