also set a priority number for the alternative in the distro config file. This sets it to 50 for debian, and 39 for ubuntu (just under firefox). This addresses the other half of the ubuntu diff.
This commit is contained in:
parent
c11bf52e8c
commit
90842f34dc
6 changed files with 25 additions and 5 deletions
5
debian/changelog
vendored
5
debian/changelog
vendored
|
@ -15,8 +15,11 @@ midori (0.1.7-1) UNRELEASED; urgency=low
|
|||
* change the default-homepage patch to use the files in debian/config/
|
||||
to set the default homepage based on whether it's debian, ubuntu,
|
||||
etc (second half of ubuntu diff)
|
||||
* also set a priority number for the alternative in the distro config
|
||||
file. This sets it to 50 for debian, and 39 for ubuntu (just under
|
||||
firefox). This addresses the other half of the ubuntu diff.
|
||||
|
||||
-- Ryan Niebur <ryanryan52@gmail.com> Thu, 28 May 2009 23:28:24 -0700
|
||||
-- Ryan Niebur <ryanryan52@gmail.com> Fri, 29 May 2009 00:43:08 -0700
|
||||
|
||||
midori (0.1.6-1) experimental; urgency=low
|
||||
|
||||
|
|
1
debian/clean
vendored
1
debian/clean
vendored
|
@ -1 +1,2 @@
|
|||
midori/midori-debian.h
|
||||
debian/midori.postinst
|
||||
|
|
2
debian/config/Debian.h
vendored
2
debian/config/Debian.h
vendored
|
@ -1 +1,3 @@
|
|||
#define DEBIAN_DISTRO_DEFAULT_HOMEPAGE "file:///usr/share/doc/midori/user/midori.html"
|
||||
#define DEBIAN_WWW_ALTERNATIVES_PRIORITY 50
|
||||
|
||||
|
|
2
debian/config/Ubuntu.h
vendored
2
debian/config/Ubuntu.h
vendored
|
@ -1 +1,3 @@
|
|||
#define DEBIAN_DISTRO_DEFAULT_HOMEPAGE "file:///usr/share/ubuntu-artwork/home/index.html"
|
||||
#define DEBIAN_WWW_ALTERNATIVES_PRIORITY 39
|
||||
|
||||
|
|
2
debian/midori.postinst.base
vendored
2
debian/midori.postinst.base
vendored
|
@ -4,7 +4,7 @@ case "$1" in
|
|||
configure)
|
||||
update-alternatives \
|
||||
--install /usr/bin/x-www-browser \
|
||||
x-www-browser /usr/bin/midori 50 \
|
||||
x-www-browser /usr/bin/midori DEBIAN_WWW_ALTERNATIVES_PRIORITY \
|
||||
--slave /usr/share/man/man1/x-www-browser.1.gz \
|
||||
x-www-browser.1.gz /usr/share/man/man1/midori.1.gz
|
||||
;;
|
||||
|
|
18
debian/rules
vendored
18
debian/rules
vendored
|
@ -1,12 +1,16 @@
|
|||
#!/usr/bin/make -f
|
||||
|
||||
CMD=$(shell echo $@ | sed 's/override_//')
|
||||
|
||||
CONFIG_FILE=debian/config/$(shell lsb_release -is).h
|
||||
|
||||
%:
|
||||
dh --with quilt $@
|
||||
|
||||
override_dh_quilt_patch:
|
||||
ln -sf ../debian/config/$(shell lsb_release -is).h midori/midori-debian.h
|
||||
ln -sf ../$(CONFIG_FILE) midori/midori-debian.h
|
||||
test -e midori/midori-debian.h
|
||||
dh_quilt_patch
|
||||
$(CMD)
|
||||
|
||||
override_dh_auto_clean:
|
||||
./waf --nocache distclean
|
||||
|
@ -26,5 +30,13 @@ override_dh_auto_install:
|
|||
./waf --nocache install --destdir debian/tmp
|
||||
rm -f debian/tmp/usr/share/doc/midori/COPYING debian/tmp/usr/share/doc/midori/TRANSLATE
|
||||
|
||||
PRIORITY=$(shell sed -r -e '/DEBIAN_WWW_ALTERNATIVES_PRIORITY/ !d' -e 's/.* ([^ ]*)$$/\1/' $(CONFIG_FILE))
|
||||
|
||||
debian/midori.postinst: debian/midori.postinst.base
|
||||
sed "s/DEBIAN_WWW_ALTERNATIVES_PRIORITY/$(PRIORITY)/g" debian/midori.postinst.base > debian/midori.postinst
|
||||
|
||||
override_dh_installdeb: debian/midori.postinst
|
||||
$(CMD)
|
||||
|
||||
override_dh_strip:
|
||||
dh_strip --dbg-package=midori-dbg
|
||||
$(CMD) --dbg-package=midori-dbg
|
||||
|
|
Loading…
Reference in a new issue