X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=dh_installcatalogs;h=b33f897e863985941fe6242ca4237fafbaf7a3c6;hb=fb8f18f4a98669c3b85e1bd7920fbabfc00b886e;hp=16bab813915114f763a4f69661382baf952a70aa;hpb=2da6ed90ff536121b387c93385e1cf652f7bd3aa;p=debhelper.git diff --git a/dh_installcatalogs b/dh_installcatalogs index 16bab81..b33f897 100755 --- a/dh_installcatalogs +++ b/dh_installcatalogs @@ -2,7 +2,7 @@ =head1 NAME -dh_installcatalog - install and register SGML Catalogs +dh_installcatalogs - install and register SGML Catalogs =cut @@ -13,32 +13,39 @@ my $sgmlbasever = "1.17"; =head1 SYNOPSIS -B [S>] [B<-n>] +B [S>] [B<-n>] =head1 DESCRIPTION -dh_registersgmlcatalog is a debhelper program that installs and -registers SGML catalogs. (Note: it will be extended for XML catalog -registration when xml-core is available.) It complies with the Debian -XML/SGML policy. - -The file F.sgmlcatalogs> contains the catalogs to be -installed per package. Each line in that file should be of the form -C, where C indicates where the catalog resides in -the source tree, and C indicates the destination location for -the catalog under the package build area. C should start with -F. +B is a debhelper program that installs and +registers SGML catalogs. It complies with the Debian XML/SGML policy. Catalogs will be registered in a supercatalog, in F.cat>. -This script automatically adds maintainer script snippets for -registering and unregistering the catalogs and "supercatalogs" (unless -B<-n> is used). A dependancy on B will be added to -C<${misc:Depends}>, so be sure your package uses that variable in -F. See L for an explantion of +This command automatically adds maintainer script snippets for +registering and unregistering the catalogs and supercatalogs (unless +B<-n> is used). These snippets are inserted into the maintainer scripts +by B; see L for an explanation of Debhelper maintainer script snippets. +A dependency on B will be added to B<${misc:Depends}>, so be +sure your package uses that variable in F. + +=head1 FILES + +=over 4 + +=item debian/I.sgmlcatalogs + +Lists the catalogs to be installed per package. Each line in that file +should be of the form C I>, where I indicates where the +catalog resides in the source tree, and I indicates the destination +location for the catalog under the package build area. I should +start with F. + +=back + =head1 OPTIONS =over 4 @@ -51,7 +58,7 @@ Do not modify F/F/F scripts. =head1 NOTES -Note that this command is not idempotent. "dh_clean -k" should be +Note that this command is not idempotent. L should be called between invocations of this command. Otherwise, it may cause multiple instances of the same text to be added to maintainer scripts. @@ -74,7 +81,7 @@ foreach my $package (@{$dh{DOPACKAGES}}) { $fulldest =~ s|//|/|g; # beautification if (! -d dirname($fulldest)) { - doit("install","-d","-m755",dirname($dest)); + doit("install","-d","-m755",$tmpdir."/".dirname($dest)); } doit("install","-p","-m644",$source,$fulldest); @@ -85,6 +92,10 @@ foreach my $package (@{$dh{DOPACKAGES}}) { if (@sgmlinstalled) { addsubstvar($package, "misc:Depends", "sgml-base", ">= $sgmlbasever"); + if (! -d "$tmpdir/etc/sgml") { + doit("install","-d","-m755","$tmpdir/etc/sgml"); + } + if (! $dh{NOSCRIPTS}) { my $ordcats = join(" ", @sgmlinstalled); my $centralcat = "/etc/sgml/$package.cat"; @@ -104,7 +115,7 @@ foreach my $package (@{$dh{DOPACKAGES}}) { =head1 SEE ALSO -L +L F