From 422239f0c501fb73a2884fa34435b9d045cca8e3 Mon Sep 17 00:00:00 2001 From: Yves-Alexis Perez Date: Wed, 3 Nov 2010 14:33:29 +0100 Subject: [PATCH] * debian/rules: - remove waf stuff, midori waf has been updated so it's no longer needed to dynamically patch waf for HPPA. - install $(DISTRO)-config to /etc/xdg/midori to tune the default homepage * debian/{Ubuntu,Debian}-config added, with default homepage setting. * debian/patches: - add-debian-search refreshed. - fix-serial-build dropped thanks to waf upgrade in midori. * debian/control: - drop quilt build-dep, useless now. --- data/search | 14 ++++ debian/Debian-config | 3 + debian/Ubuntu-config | 2 + debian/changelog | 12 +++- debian/control | 4 +- debian/patches/add-debian-searches | 6 +- debian/patches/default-homepage | 28 -------- debian/patches/fix-serial-build | 13 ---- debian/patches/series | 2 - debian/rules | 37 +++-------- debian/runner-append | 100 ----------------------------- 11 files changed, 44 insertions(+), 177 deletions(-) create mode 100644 debian/Debian-config create mode 100644 debian/Ubuntu-config delete mode 100644 debian/patches/default-homepage delete mode 100644 debian/patches/fix-serial-build delete mode 100644 debian/runner-append diff --git a/data/search b/data/search index c7938290..2cd3cbc5 100644 --- a/data/search +++ b/data/search @@ -26,3 +26,17 @@ text=Dictionary, Encyclopedia and Thesaurus uri=http://www.thefreedictionary.com/%s icon= token=fd + +[Debian Packages] +name=Debian Packages +text=Search Debian Packages +uri=http://packages.debian.org/%s +icon= +token=d + +[Debian Bugs] +name=Debian Bugs +text=Debian Bugs Search +uri=http://bugs.debian.org/%s +icon= +token=dbs diff --git a/debian/Debian-config b/debian/Debian-config new file mode 100644 index 00000000..9638ea81 --- /dev/null +++ b/debian/Debian-config @@ -0,0 +1,3 @@ +[settings] + +homepage=file:///usr/share/doc/midori/user/midori.html diff --git a/debian/Ubuntu-config b/debian/Ubuntu-config new file mode 100644 index 00000000..79bb6e61 --- /dev/null +++ b/debian/Ubuntu-config @@ -0,0 +1,2 @@ +[settings] +homepage=file:///usr/share/ubuntu-artwork/home/index.html diff --git a/debian/changelog b/debian/changelog index 89e308f7..7527e62e 100644 --- a/debian/changelog +++ b/debian/changelog @@ -7,8 +7,18 @@ midori (0.2.9-1) UNRELEASED; urgency=low - pick {C,LD}FLAGS from dpkg-buildflags. - add -Wl,-z,defs -Wl,--as-needed to LDFLAGS. - add hardening flags to {C,LD}FLAGS. + * debian/rules: + - remove waf stuff, midori waf has been updated so it's no longer needed + to dynamically patch waf for HPPA. + - install $(DISTRO)-config to /etc/xdg/midori to tune the default homepage + * debian/{Ubuntu,Debian}-config added, with default homepage setting. + * debian/patches: + - add-debian-search refreshed. + - fix-serial-build dropped thanks to waf upgrade in midori. + * debian/control: + - drop quilt build-dep, useless now. - -- Yves-Alexis Perez Mon, 18 Oct 2010 11:26:48 +0200 + -- Yves-Alexis Perez Tue, 02 Nov 2010 22:42:48 +0100 midori (0.2.7-1.1) unstable; urgency=low diff --git a/debian/control b/debian/control index a409a6d2..91da76aa 100644 --- a/debian/control +++ b/debian/control @@ -4,7 +4,6 @@ Priority: optional Maintainer: Ryan Niebur Uploaders: Yves-Alexis Perez Build-Depends: debhelper (>= 7.0.50), - quilt (>= 0.46-7), lsb-release, libgtk2.0-dev (>= 2.10), libglib2.0-dev, @@ -26,7 +25,8 @@ Build-Depends: debhelper (>= 7.0.50), xvfb, xauth, xfonts-base, - hardening-includes + hardening-includes, + libxss-dev # Disabled optional dependencies: Build-Conflicts: gtk-doc-tools, libgtksourceview2.0-dev (>= 2.0), diff --git a/debian/patches/add-debian-searches b/debian/patches/add-debian-searches index 7cfddf7a..2cacfb08 100644 --- a/debian/patches/add-debian-searches +++ b/debian/patches/add-debian-searches @@ -1,8 +1,8 @@ -Fix #520381 - add a Debian search to the default search list. -and #525991 - Adding debian bugs search to pre-installed searches +diff --git a/data/search b/data/search +index c793829..2cd3cbc 100644 --- a/data/search +++ b/data/search -@@ -19,3 +19,17 @@ +@@ -26,3 +26,17 @@ text=Dictionary, Encyclopedia and Thesaurus uri=http://www.thefreedictionary.com/%s icon= token=fd diff --git a/debian/patches/default-homepage b/debian/patches/default-homepage deleted file mode 100644 index 63ee2726..00000000 --- a/debian/patches/default-homepage +++ /dev/null @@ -1,28 +0,0 @@ -Some users install a web browser to look at HTML documentation when -they are offline. In this case, it is not nice to have the default -page be a site that will time out. Instead, we should use a local -"launch" page, similar to what Konqueror and Iceweasel do already. - -Unfortunately there is no generic page of that sort, and I can't be -bothered writing one. So for now, I will just make the homepage -Midori's user documentation. This is similar to what Dillo did/does. - ---- a/midori/midori-websettings.c -+++ b/midori/midori-websettings.c -@@ -10,6 +10,7 @@ - */ - - #include "midori-websettings.h" -+#include "midori-debian.h" - - #include "sokoke.h" - -@@ -623,7 +624,7 @@ - "homepage", - _("Homepage:"), - _("The homepage"), -- "http://www.google.com", -+ DEBIAN_DISTRO_DEFAULT_HOMEPAGE, - flags)); - - /** diff --git a/debian/patches/fix-serial-build b/debian/patches/fix-serial-build deleted file mode 100644 index 306ca5db..00000000 --- a/debian/patches/fix-serial-build +++ /dev/null @@ -1,13 +0,0 @@ -fix building in Serial mode (on HPPA) - ---- a/wscript -+++ b/wscript -@@ -490,7 +490,7 @@ - obj.source = 'data/' + APPNAME + '.desktop.in' - obj.install_path = appdir - obj.flags = ['-d', '-c'] -- bld.install_files (appdir, 'data/' + APPNAME + '.desktop') -+ bld.install_files (appdir, blddir + '/default/data/' + APPNAME + '.desktop') - else: - folder = os.path.abspath (blddir + '/default/data') - Utils.check_dir (folder) diff --git a/debian/patches/series b/debian/patches/series index 3d526d8c..5367257f 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -1,3 +1 @@ -fix-serial-build -default-homepage add-debian-searches diff --git a/debian/rules b/debian/rules index 27fcdeba..e1a2b320 100755 --- a/debian/rules +++ b/debian/rules @@ -21,16 +21,9 @@ ifneq (0, $(shell test -e $(CONFIG_FILE); echo "$$?")) endif %: - dh --with quilt $@ + dh $@ -override_dh_quilt_patch: - ln -sf ../$(CONFIG_FILE) midori/midori-debian.h - test -e midori/midori-debian.h - $(CMD) - -#WAF=/usr/bin/waf -BASE_WAF=./waf -WAF=env WAFDIR=debian/ $(BASE_WAF) +WAF=./waf debian/presubj: debian/presubj.in @echo "presubj parameters:" @@ -44,44 +37,32 @@ debian/presubj: debian/presubj.in override_dh_install: debian/presubj $(CMD) --fail-missing -WAFADMIN_FILE=debian/wafadmin/Runner.py -WAFADMIN_APPEND=debian/runner-append - -override_dh_auto_clean: $(WAFADMIN_FILE) +override_dh_auto_clean: $(WAF) --nocache distclean rm -rf _build_ + rm -rf .waf* -override_dh_auto_configure: $(WAFADMIN_FILE) +override_dh_auto_configure: $(WAF) --nocache configure --prefix /usr -override_dh_auto_build: $(WAFADMIN_FILE) +override_dh_auto_build: $(WAF) build --nocache --debug full -#override_dh_auto_test: $(WAFADMIN_FILE) +#override_dh_auto_test: # xvfb-run $(WAF) --nocache check -override_dh_auto_install: $(WAFADMIN_FILE) +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 rm -f debian/tmp/usr/share/midori/res/mootools.js ln -s /usr/share/javascript/mootools/mootools.js debian/tmp/usr/share/midori/res/mootools.js + install debian/$(DISTRO)-config debian/tmp/etc/xdg/midori/config 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 -$(WAFADMIN_FILE): $(BASE_WAF) $(WAFADMIN_APPEND) - rm -fr debian/wafadmin/ .waf-* - $(BASE_WAF) --help >/dev/null - cp -a ./.waf-*/wafadmin debian/ - rm -fr .waf-* - cat $(WAFADMIN_APPEND) >> $(WAFADMIN_FILE) - -override_dh_clean: - rm -fr debian/wafadmin - $(CMD) - override_dh_installdeb: debian/midori.postinst $(CMD) diff --git a/debian/runner-append b/debian/runner-append deleted file mode 100644 index 17a4eeb8..00000000 --- a/debian/runner-append +++ /dev/null @@ -1,100 +0,0 @@ -# curl "http://bugs.debian.org/cgi-bin/bugreport.cgi?msg=43;filename=xmms2-hppa.diff;att=1;bug=558983" | grep ^+ | grep -v ^+++ | sed 's/^+//' > debian/runner-append - -class Serial(object): - - def __init__(self, bld, j=1): - self.manager = bld.task_manager - self.outstanding = [] - - # progress bar - self.total = self.manager.total() - self.processed = 0 - self.error = 0 - - self.switchflag = 1 # postpone - - self.consumers = None - - # warning, this one is recursive .. - def get_next(self): - if self.outstanding: - t = self.outstanding.pop(0) - self.processed += 1 - return t - - # handle case where only one wscript exist - # that only install files - if not self.manager.groups: - return None - - (_, self.outstanding) = self.manager.get_next_set() - if not self.outstanding: return None - - return self.get_next() - - def postpone(self, tsk): - self.processed -= 1 - self.switchflag *= -1 - # this actually shuffle the list - if self.switchflag>0: self.outstanding.insert(0, tsk) - else: self.outstanding.append(tsk) - - def start(self): - debug('runner: Serial start called') - while 1: - # get next Task - tsk = self.get_next() - if tsk is None: break - - if Logs.verbose: debug('runner: retrieving %r' % tsk) - - st = tsk.runnable_status() - if st == ASK_LATER: - debug('runner: postponing %r' % tsk) - self.postpone(tsk) - continue - - #continue - if st == SKIP_ME: - tsk.hasrun = SKIPPED - self.manager.add_finished(tsk) - continue - - tsk.position = (self.processed, self.total) - - # display the command that we are about to run - tsk.generator.bld.printout(tsk.display()) - - # run the command - if tsk.__class__.stat: ret = tsk.__class__.stat(tsk) - else: ret = tsk.run() - self.manager.add_finished(tsk) - - # non-zero means something went wrong - if ret: - self.error = 1 - tsk.hasrun = CRASHED - tsk.err_code = ret - if Options.options.keep: continue - else: return -1 - - try: - tsk.post_run() - except OSError: - self.error = 1 - tsk.hasrun = MISSING - if Options.options.keep: continue - else: return -1 - else: - tsk.hasrun = SUCCESS - - if self.error: - return -1 - -import subprocess -print "== Using patched Runner.py for HPPA ==" -p = subprocess.Popen(['dpkg', '--print-architecture'], stdout=subprocess.PIPE) -arch = p.stdout.read().strip() -p.wait() -if arch == 'hppa': - Parallel = Serial