]> git.donarmstrong.com Git - lilypond.git/blobdiff - debian/update_doc_packages
Merge tag 'upstream/2.19.48' into debian-experimental
[lilypond.git] / debian / update_doc_packages
index bd625cfc28c7ce7d6f6da6c1390c39c0a6f1d804..d160cf01097c03276329893ef90fd7ccc148fb37 100644 (file)
@@ -10,14 +10,11 @@ use strict;
 
 use IO::File;
 
-my $cf = $ARGV[0];
-my $df = $ARGV[1];
-
 my $cfh = IO::File->new("debian/control",'r') or
-    die "Unable to open $cf for reading: $!";
+    die "Unable to open debian/control for reading: $!";
 
 my $dfh = IO::File->new("debian/doc_languages.txt",'r') or
-    die "Unable to open $df for reading: $!";
+    die "Unable to open debian/doc_languages.txt for reading: $!";
 
 # read in languages
 my %languages;
@@ -66,6 +63,8 @@ Section: doc
 Architecture: all
 Depends: \${misc:Depends}, dpkg (>= 1.15.4) | install-info${depends}${recommends}
 Suggests: lilypond (>= \${source:Version})
+Replaces: lilypond-doc (<< 2.16.2-1~exp+1)
+Breaks: lilypond-doc (<< 2.16.2-1~exp+1)
 Description: LilyPond $uc_type Documentation in $ucfirst_long_lang
  LilyPond is a music typesetter, an automated engraving system.  It
  produces beautiful sheet music using a high level description file as input.
@@ -87,10 +86,35 @@ EOF
        } else {
            print {$install_fh} <<EOF;
 usr/share/doc/lilypond/html/*/*.${lang}.pdf
-usr/share/doc/lilypond/html/*.${lang}.pdf
 EOF
        }
        close($install_fh);
+        my $docbase_fh = IO::File->new("debian/lilypond-doc-$type-${lang}.doc-base-special",'w') or
+            die "Unable to open debian/lilypond-doc-$type-${lang}.doc-base-special for writing: $!";
+       print {$docbase_fh} <<EOF;
+Document: lilypond.${lang}
+Title: GNU LilyPond, the music typesetter
+Author: Various
+Abstract: This documentation describes LilyPond (the GNU Project music
+ typesetter), the LilyPond music input language, and the Mutopia project,
+ a.k.a. "Music To the People."
+Section: Typesetting
+
+EOF
+       if ($type eq 'html') {
+           print {$docbase_fh} <<EOF;
+Format: HTML
+Index: /usr/share/doc/lilypond/html/index.${lang}.html
+Files: /usr/share/doc/lilypond/html/*/*/*.${lang}.html /usr/share/doc/lilypond/html/*/*.${lang}.html /usr/share/doc/lilypond/html/*.${lang}.html
+EOF
+
+       } else {
+           print {$docbase_fh} <<EOF;
+Format: PDF
+Files: /usr/share/doc/lilypond/html/Documentation/*.${lang}.pdf*
+EOF
+       }
+       close ($docbase_fh);
     }
 }