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

Future of dh_installtex (was: SVN texlive (new) commit: r2484 - in texlive-new/trunk: all/debian texlive-base/debian texlive-bin/debian texlive-extra/debian texlive-lang/debian)



Florent Rougon <f.rougon@free.fr> wrote:

> Hi,
>
> Norbert Preining <preining@logic.at> wrote:
>
>> Ok ok, but why did I remember this so fiercly, anyway .. thanks a lot
>
> Because the examples in the dh_link manpage use relative file names, in
> the sense that they do *not* start with a slash?

Maybe.  I didn't even check, instead now dh_installtex has this
functionality.  While reading up on how to write a dh_ program, I found
this statement by Joey:

,----
| Add a regression test to debhelper that fails if any debhelper script
| exceeds 150 lines, excluding POD docs. (Done in svn)
`----

We do not aim at being included in debhelper, but still it made me
think.  dh_installtex now has 617 lines including about 200 lines POD
docs.  That makes three to four scripts according to Joey's criteria.

And actually there may be good reasons to do a splitting.  We originally
aimed at "It can do all, and there's more than one way to invoke it"[1],
but this also means that it already has a bunch of commandline options,
probably more than the usual packager wants to use.

What about splitting it into

dh_installtexfile [debhelper options] [-n] [texmftrees=tree[,tree]]

dh_installtexlang [debhelper options] [-n] [--priority=n] \
   [language=lang,pattern[,alternate,...]]  [languagefile=file.cnf[=n]]

dh_installtexfont [debhelper options] [-n] [--priority=n] \
   [--flavor=flavor[,flavor]] [map=MixedMap,file.map] [map=Map,file.map] \
   [mapfile=file.cfg[=n]]

dh_installtexformat [debhelper options] [-n] [--priority=n] \
   [--flavor=flavor[,flavor]] [formatfile=file.cnf[=n]] [-X<formatlink>]


This would it make easier for maintainers to pick the functions they
need, the smaller scripts would be easier to maintain, and the created
maintainer scripts would only includ code that is actually used.  The
only cons I see at the moment are

- The scripts must interact somehow, in particular prevent calling
  mktexlsr too often.  This could be solved by markers in the text in
  postinst.debhelper

- Some code would probably be duplicated.  Well, we can have a Perl
  module for that.

What do you think?  (We should not decide anything before Norbert is
back to a good connection).

Regards, Frank


[1] TMTOWTII ;-)
-- 
Dr. Frank Küster
Single Molecule Spectroscopy, Protein Folding @ Inst. f. Biochemie, Univ. Zürich
Debian Developer (teTeX/TeXLive)



Reply to: