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

Re: packaging a new qt application with 2 components

2011/2/22 Steven <redalert.commander@gmail.com>:
> Yes, looking in the directory, I see a single .a file, starting with
> 'lib' (also the largest file in there). I guess this means it would be
> easiest to create 2 separate packages, while changing the *.pro file for
> the gui?

If you want to keep them separate, that would be the easiest. If the
'kernel' is named libfoo.a, make a package called foo-dev or
libfoo-dev containing it and the necessary headers, then make sure the
gui package Build-Depends: on it. (No need to have it around at

> Thus only linking to the 'kernel' instead of making a single binary.

Linking to a static library (.a) in fact will produce a single binary:
elements of the library are copied at link time.

(You could build a shared library out of the 'kernel' library, but
that's not for the faint-of-heart.)

> Changing the build procedures shouldn't be a problem for upstream.

I'm a bit confused here. Is upstream distributing everything in a
single package, or in two packages?

In the former case, you'd want to build both the library (assuming
it's generally useful) and the GUI from the single upstream package.
In any case, there's no need for upstream to modify anything; just
skip the top-level makefile in the debian/rules script using the
--sourcedir argument to debhelper and point to the library in /usr/lib
instead of in the source directory.

Reply to: