This is most of Al's patch for --with-user and --with-group which tests that
[privoxy.git] / debian / rules
index be5438e..63e4111 100755 (executable)
@@ -15,9 +15,6 @@ DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
 
 DEBDIR=`pwd`/debian/privoxy
 
-DB2HTML=jw -f docbook -b html -d `pwd`/ldpOK.dsl\#html
-
-
 CFLAGS="-O2"
 WITHDEBUG=""
 ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
@@ -25,6 +22,12 @@ ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
        WITHDEBUG="--with-debug"
 endif
 
+# hppa doesn't support -pthread option, so we complety disable pthread
+# on hppa until there is a better solution in configure.
+ifeq "$(DEB_HOST_GNU_TYPE)" "hppa-linux"
+       WITHOUTPTHREAD="--disable-pthread"
+endif
+
 configure: configure-stamp
 configure-stamp:
        dh_testdir
@@ -33,8 +36,8 @@ configure-stamp:
        autoconf
        env CFLAGS=$(CFLAGS) \
                ./configure --prefix=/usr --sysconfdir=/etc \
-               --mandir=/usr/share/man $(WITHDEBUG) \
-               --with-docbook=/usr/share/sgml/docbook/stylesheet/dsssl/modular
+               --mandir=/usr/share/man $(WITHDEBUG) $(WITHOUTPTHREAD) \
+               --with-docbook=no
 
        touch configure-stamp
 
@@ -44,16 +47,6 @@ build-stamp: configure-stamp
 
        $(MAKE)
 
-#      And now we create the documentation (manually):
-       $(MAKE) doc/source/ldpOK.dsl
-       (cd doc/source; \
-        $(DB2HTML) -o faq faq.sgml; \
-        $(DB2HTML) -o user-manual user-manual.sgml; \
-        $(DB2HTML) -o developer-manual developer-manual.sgml; \
-        docbook2txt faq.sgml; \
-        docbook2txt user-manual.sgml; \
-        docbook2txt developer-manual.sgml)
-
        touch build-stamp
 
 clean:
@@ -61,13 +54,11 @@ clean:
        dh_testroot
        rm -f build-stamp configure-stamp
 
-       -$(MAKE) clobber
+       -$(MAKE) clean
+       -$(MAKE) distclean
        rm -f privoxy 
        rm -f configure config.h GNUmakefile 
-       rm -f doc/source/ldpOK.dsl
-       rm -rf doc/source/faq doc/source/user-manual \
-               doc/source/developer-manual
-       rm -f doc/source/*.txt
+       rm -f doc/source/ldp.dsl
 
        dh_clean
 
@@ -80,10 +71,15 @@ install: build
        install -m 0755 privoxy $(DEBDIR)/usr/sbin/privoxy
 
        sed -e 's/^\(\(trust\|proxy\)-info-url\|admin-address\)/#\1/'  \
+           -e 's/^\(enable-\(edit-actions\|remote-toggle\)\)/#\1/' \
            -e 's#^confdir \.#confdir /etc/privoxy#' \
            -e 's#^logdir \.#logdir /var/log/privoxy#' \
+           -e 's/\(Sample Configuration File for Privoxy\).*/\1/' \
+           -e 's/Id: config,v.*/Id: config,v $$/' \
                < config > $(DEBDIR)/etc/privoxy/config
        install -m 0644 default.action $(DEBDIR)/etc/privoxy/default.action
+       install -m 0644 standard.action $(DEBDIR)/etc/privoxy/standard.action
+       install -m 0644 user.action $(DEBDIR)/etc/privoxy/user.action
        install -m 0644 default.filter $(DEBDIR)/etc/privoxy/default.filter
        install -m 0644 trust $(DEBDIR)/etc/privoxy/trust
 
@@ -101,7 +97,7 @@ binary-arch: build install
        dh_testdir
        dh_testroot
 #      dh_installdebconf       
-       dh_installdocs
+       dh_installdocs -XCVS
        dh_installexamples
        dh_installmenu
        dh_installlogrotate