provide lighttpd-dev package

Bug #326899 reported by Stepan Koltsov on 2009-02-08
6
Affects Status Importance Assigned to Milestone
lighttpd (Debian)
Fix Released
Unknown
lighttpd (Ubuntu)
Wishlist
Unassigned

Bug Description

Binary package hint: lighttpd

Please, provide lighttpd-dev package built from lighttpd sources.

Package should contain:

config.h src/*.h installed in /usr/lib/lighttpd/
lighttpd.pc (pkg-config) installed in /usr/lib/pkg-config/

lighttpd-dev package is must have to build lighttpd modules outside lighttpd source tree. We have several modules, and we have hacked lighttpd source package.

lighttpd.pc.in we use:

===
# lighttpd pkg-config file

prefix=@prefix@
exec_prefix=@exec_prefix@
libdir=@libdir@
includedir=@includedir@

Name: lighttpd
Description: lighttpd
Version: @VERSION@
Requires:
Conflicts:
Libs:
Cflags: -I${includedir} -DHAVE_CONFIG_H @CPPFLAGS@
===

To generate lighttpd.pc string "lighttpd.pc" should be added to configure.in into AC_CONFIG_FILES and following lines should be added to Makefile.am:

===
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = lighttpd.pc
===

Related branches

Daniel Hahler (blueyed) on 2009-02-08
Changed in lighttpd:
importance: Undecided → Wishlist
status: New → Triaged
Andreas Moog (ampelbein) wrote :

Sent to Debian and provided a patch there.
Also, I have prepared a debdiff, please consider it.

Andreas Moog (ampelbein) wrote :

lighttpd (1.4.19-5ubuntu8) jaunty; urgency=low

  * debian/control
    - add lighttpd-dev package
    - add misc-depends to clear lintian-warnings
  * debian/patches
    - add build-dev-package.patch to include pkg-config files for lighttpd
    - add autoconf-update.patch after changing Makefile.Am
  * debian/
    - add lighttpd-dev.install

 -- Andreas Moog <email address hidden> Sun, 29 Mar 2009 14:53:46 +0200

Changed in lighttpd:
status: Unknown → New
Daniel Hahler (blueyed) wrote :

Thank you very much for your effort, Andreas.
It is too late for Jaunty and I hope that Debian will accept it, so we can easily merge/integrate it into Ubuntu, too.

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package lighttpd - 1.4.22-1ubuntu2

---------------
lighttpd (1.4.22-1ubuntu2) karmic; urgency=low

  * Introduce patches to introduce a -dev package for lighttpd. Closes
    (LP: #326899). Should merge seamlessly in the future.

  [ Andreas Moog ]
  * debian/control
    - add lighttpd-dev package
  * debian/patches
    - add build-dev-package.patch to include pkg-config files for lighttpd
  * debian/
    - add lighttpd-dev.install

  [ Morten Kjeldgaard ]
  * debian/rules: add DEB_AUTO_UPDATE_* variables to ensure autotool
    files get updated with our patches.
  * Minor cleanups and update Andreas' patches to version 1.4.22.

 -- Morten Kjeldgaard <email address hidden> Thu, 18 Jun 2009 14:57:10 +0200

Changed in lighttpd (Ubuntu):
status: Triaged → Fix Released
Morten Kjeldgaard (mok0) wrote :

Hi Andreas,

I sponsored your lighttpd patch into karmic. IMHO it is definitely a packaging error not to include a -dev package. However, I had to change a few things in your patches. I see from the debbug that you are asking for feedback, so here it is (public so others can benefit):

It is not correct to patch the Makefile.in's like you have done. You have correctly patched configure.in and Makefile.am, but then you need to rerun the autotools (libtool, aclocal, autoconf, autoheader, automake) to regenerate configure and the Makefiles. This has to be done before running configure, and it's a bit inconvenient with CDBS that this package uses. But it can be done with some variables.

It can be debated if it's a bit overkill to invoke the autotools system just to produce the lighttpd.pc file with the proper values set. Another way would be to put the .pc file in debian and just copy it to the destination using the .install file. Much simpler and merges better, but of course you need to hardwire the version number and remember to update it.

Cheers, & thx for your work!

Changed in lighttpd (Debian):
status: New → Incomplete
Changed in lighttpd (Debian):
status: Incomplete → Fix Released
Stefan Bühler (stbuehler) wrote :

Morten Kjeldgaard (mok0) wrote:
> I sponsored your lighttpd patch into karmic. IMHO it is definitely a
> packaging error not to include a -dev package.

This is certainly not true for most programs, so you should have
provided some reasons why a -dev package is missing for lighttpd.

So here is why this is wrong:
If another package uses this -dev package to link a 3rd party module,
it will never get the correct dependencies.

Even a small lighttpd update might break the binary API, and there
will be no so bump nor package rename as there is no library package.

Right now 3rd party modules should be patched into the upstream
sources to compile them, and distributed as one "package".
(Splitting is fine as long as you have strict dependencies)

I think providing a -dev package is possible, you probably need to:
* link the core as a library, to link plugins against
* put this library into a library package
* review changes whether they break the api and do so bumps accordingly

Imho this is not worth the effort, and I don't think anyone will
maintain such solution.
Also upstream won't support it.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.