Hello,

Just noticed some issues with my web application package, and not sure what
to do about them, or who to contact. Apologies if these issues have already
been discussed, the other threads seem to focus around upgrading binary
modules (at quick glance).

First, my package triggered the following Lintian warning:

https://lintian.debian.org/tags/web-application-should-not-depend-unconditionally-on-apache2.html

Fair enough, change that depends to depends on "apache2 | httpd".

However, now when I install it, for reasons I don't understand, apt-get
prefers to install apache2-bin over apache2 (thought it should default to
the first item???). This provides httpd and satisfies the depends. apache2
is required for Apache 2.4 configuration, as only it
provides /usr/share/apache2/apache2-maintscript-helper.

(side note: if I change the depends back to apache2, it works fine)

Fine, so my package should install, but without configuring Apache, right?
Not so fast.

I used the something similar to the excerpt from <
https://wiki.debian.org/Apache2Transition#Should_we_support_a_transitional_fallback_configuration_which_allows_web_apps_to_work_with_both_2.2_and_2.4_packages>
to automatically fallback to Apache2.2 configuration if Apache2.4 not
installed (I still need to be able to support wheezy installs):

 if [ -e /usr/share/apache2/apache2-maintscript-helper ] ; then
    . /usr/share/apache2/apache2-maintscript-helper
    apache2_invoke enconf package.conf
elif  dpkg-query -f '${Version}'  -W 'apache2.2-common' > /dev/null 2>&1 ;
then
    # if the configuration uses <IfVersion> uncomment the next line
    # a2enmod -q version
    [ -d /etc/apache2/conf.d/ ] && [ ! -l /etc/apache2/conf.d/package.conf
] && ln -s ../conf-available/package.conf /etc/apache2/conf.d/package.conf
fi

The problem here is that the dpkg-query succeeds if apache2-bin is
installed (it just doesn't print a version):

(sid)root@aquitard:/home/brian/tree/django/karaage/karaage# dpkg-query -f
'${Version}'  -W 'apache2.2-common' && echo successful
successful
(sid)root@aquitard:/home/brian/tree/django/karaage/karaage# dpkg --purge
apache2-bin
(Reading database ... 18140 files and directories currently installed.)
Removing apache2-bin (2.4.10-1) ...
Processing triggers for man-db (2.6.7.1-1) ...
(sid)root@aquitard:/home/brian/tree/django/karaage/karaage# dpkg-query -f
'${Version}'  -W 'apache2.2-common' && echo successful
dpkg-query: no packages found matching apache2.2-common

I don't understand this.

Yes, the above script also checks for the existence
of /etc/apache2/conf.d/, however just
because this directory exists doesn't mean apache2.2 is still installed.


Other issues:

Also still getting Lintian warnings for

* "apache2-reverse-dependency-calls-invoke-rc.d" - due to legacy fall back
code that restarts Apache2.2 automatically.

* "non-standard-apache2-configuration-name" - due to the fact I need to
supply different configuration files for apache2.2 and apache2.4 in
/etc/apache2/conf-available, as the access control requirements have
changed and this was the recommended solution on the debian-python mailing
list.

Probably will have to override these.
-- 
Brian May <br...@microcomaustralia.com.au>

Reply via email to