summaryrefslogtreecommitdiff
path: root/package/privoxy
diff options
context:
space:
mode:
Diffstat (limited to 'package/privoxy')
-rw-r--r--package/privoxy/Config.in5
-rw-r--r--package/privoxy/Makefile18
-rw-r--r--package/privoxy/files/privoxy.init27
-rw-r--r--package/privoxy/files/privoxy.postinst7
-rw-r--r--package/privoxy/patches/patch-GNUmakefile_in153
-rw-r--r--package/privoxy/patches/patch-configure_in12
6 files changed, 45 insertions, 177 deletions
diff --git a/package/privoxy/Config.in b/package/privoxy/Config.in
index 8132907f4..68a42dfb6 100644
--- a/package/privoxy/Config.in
+++ b/package/privoxy/Config.in
@@ -1,6 +1,7 @@
config ADK_PACKAGE_PRIVOXY
prompt "privoxy........................... web proxy with advanced filtering capabilities"
tristate
+ select ADK_PACKAGE_LIBPTHREAD
default n
help
Privoxy is a web proxy with advanced filtering capabilities for
@@ -11,7 +12,3 @@ config ADK_PACKAGE_PRIVOXY
has application for both stand-alone systems and multi-user networks.
http://www.privoxy.org/
-
- WARNING: no init script is installed at the moment. You must also
- fix file permissions on your own and create a privoxy user. This
- may change in a future revision of this package.
diff --git a/package/privoxy/Makefile b/package/privoxy/Makefile
index 8f19b7b73..0416b5e78 100644
--- a/package/privoxy/Makefile
+++ b/package/privoxy/Makefile
@@ -4,17 +4,18 @@
include ${TOPDIR}/rules.mk
PKG_NAME:= privoxy
-PKG_VERSION:= 3.0.12
+PKG_VERSION:= 3.0.15
PKG_RELEASE:= 1
-PKG_MD5SUM:= c973e608d27b248ef567b47664308da1
+PKG_VARIANT:= beta
+PKG_MD5SUM:= 6571dc9524e945e79c2af62fefe7b107
PKG_DESCR:= web proxy with advanced filtering capabilities
PKG_SECTION:= net
PKG_DEPENDS:= libpthread
PKG_URL:= http://www.privoxy.org
PKG_SITES:= ${MASTER_SITE_SOURCEFORGE:=ijbswa/}
-DISTFILES:= ${PKG_NAME}-${PKG_VERSION}-stable-src.tar.gz
-WRKDIST= ${WRKDIR}/${PKG_NAME}-${PKG_VERSION}-stable
+DISTFILES:= ${PKG_NAME}-${PKG_VERSION}-${PKG_VARIANT}-src.tar.gz
+WRKDIST= ${WRKDIR}/${PKG_NAME}-${PKG_VERSION}-${PKG_VARIANT}
include ${TOPDIR}/mk/package.mk
@@ -22,6 +23,9 @@ $(eval $(call PKG_template,PRIVOXY,${PKG_NAME},${PKG_VERSION}-${PKG_RELEASE},${P
TLDFLAGS+= -pthread
CONFIGURE_STYLE:= gnu
+CONFIGURE_ARGS+= --disable-editor \
+ --disable-jar-files \
+ --sysconfdir=/etc/privoxy
CONFIGURE_ENV+= ac_cv_func_setpgrp_void=no \
ac_cv_lib_nsl_gethostbyname=no
BUILD_STYLE:= auto
@@ -29,11 +33,9 @@ MAKE_FLAGS+= SPECIAL_CFLAGS='${TLDFLAGS}'
MAKE_FILE:= GNUmakefile
INSTALL_STYLE:= auto
-post-extract:
- @find ${WRKBUILD} -name *.rej -delete
-
post-install:
- ${INSTALL_DIR} ${IDIR_PRIVOXY}/usr/sbin
+ ${INSTALL_DIR} ${IDIR_PRIVOXY}/usr/sbin ${IDIR_PRIVOXY}/etc/privoxy
+ ${CP} ${WRKINST}/etc/privoxy/* ${IDIR_PRIVOXY}/etc/privoxy
${INSTALL_BIN} ${WRKINST}/usr/sbin/privoxy ${IDIR_PRIVOXY}/usr/sbin/
include ${TOPDIR}/mk/pkg-bottom.mk
diff --git a/package/privoxy/files/privoxy.init b/package/privoxy/files/privoxy.init
new file mode 100644
index 000000000..ab782e9ef
--- /dev/null
+++ b/package/privoxy/files/privoxy.init
@@ -0,0 +1,27 @@
+#!/bin/sh
+#PKG privoxy
+#INIT 70
+. /etc/rc.conf
+
+case $1 in
+autostop) ;;
+autostart)
+ [[ $privoxy = NO ]] && exit 0
+ exec sh $0 start
+ ;;
+start)
+ [ -f /etc/privoxy/config ] || exit
+ /usr/sbin/privoxy /etc/privoxy
+ ;;
+stop)
+ pkill privoxy
+ ;;
+restart)
+ sh $0 stop
+ sh $0 start
+ ;;
+*)
+ echo "Usage: $0 {start | stop | restart}"
+ ;;
+esac
+exit $?
diff --git a/package/privoxy/files/privoxy.postinst b/package/privoxy/files/privoxy.postinst
new file mode 100644
index 000000000..105b430c2
--- /dev/null
+++ b/package/privoxy/files/privoxy.postinst
@@ -0,0 +1,7 @@
+#!/bin/sh
+. $IPKG_INSTROOT/etc/functions.sh
+
+gid=$(get_next_gid)
+add_user privoxy $(get_next_uid) $gid /etc/privoxy
+add_group privoxy $gid
+add_rcconf privoxy privoxy NO
diff --git a/package/privoxy/patches/patch-GNUmakefile_in b/package/privoxy/patches/patch-GNUmakefile_in
deleted file mode 100644
index ad40c6013..000000000
--- a/package/privoxy/patches/patch-GNUmakefile_in
+++ /dev/null
@@ -1,153 +0,0 @@
-$Id$
---- privoxy-3.0.12-stable.orig/GNUmakefile.in 2009-02-28 09:28:14.000000000 +0100
-+++ privoxy-3.0.12-stable/GNUmakefile.in 2009-04-17 17:47:06.241568604 +0200
-@@ -51,10 +51,6 @@ SNAPVERSION = $(RPM_VERSION)-$(shell d
- # "make install" directories and variables
- #############################################################################
-
--#User Group paras
--USER = @USER@
--GROUP = @GROUP@
--
- datarootdir = @datarootdir@
- prefix = @prefix@
- exec_prefix = @exec_prefix@
-@@ -97,8 +93,6 @@ INSTALL_T = -m $(RA_MODE)
- INSTALL_D = -m $(DIR_MODE) -d
- INSTALL_R = -m $(RWD_MODE)
-
--# install options for superuser install
--#INSTALL_S = -g @GROUP@ -o @USER@
-
- #############################################################################
- # Build tools
-@@ -939,7 +933,7 @@ pcre/chartables.c: pcre/dftables@EXEEX
- pcre/dftables@EXEEXT@ >pcre/chartables.c
-
- pcre/dftables@EXEEXT@: pcre/dftables.c pcre/maketables.c pcre/pcre.h pcre/internal.h pcre/config.h
-- $(CC) -o pcre/dftables@EXEEXT@ $(CFLAGS) pcre/dftables.c
-+ $(HOSTCC) -o pcre/dftables@EXEEXT@ $(HOSTCFLAGS) pcre/dftables.c
-
- # Win32
- w32log.@OBJEXT@: w32log.c errlog.h config.h jcc.h loadcfg.h miscutil.h pcre/pcre.h pcre/pcreposix.h pcrs.h project.h w32log.h w32taskbar.h win32.h
-@@ -1011,13 +1005,6 @@ check_doc:=$(shell if [ ! -d "$(SHARE_DE
- $(ECHO) "0";\
- fi)
-
--# If USER is specified but no GROUP, assume there is a GROUP of same name.
--GROUP_T:=$(shell if [ x$(GROUP) = x ] && [ x$(USER) != x ];then \
-- $(ECHO) "$(USER)" ;\
-- else\
-- $(ECHO) "$(GROUP)";\
-- fi)
--
- install-strip:
- $(MAKE) install STRIP=-s
-
-@@ -1028,16 +1015,7 @@ install-strip:
- # universally reliable (eg Solaris). Group handling could be better.
- # Perhaps the whole user/group validation should be done here, and simplified.
- PROGRAM_V = Privoxy $(VERSION) $(CODE_STATUS)
--install: CONF_DEST LOG_DEST PID_DEST check_doc GROUP_T
-- @# Quick test for valid USER.
-- @if [ -n "$(USER)" ]; then \
-- $(ID) $(USER) >/dev/null || exit 1;\
-- fi
-- @# Test for valid group. FIXME. USER does not have to belong to GROUP
-- @# for file ownership purposes.
--# if [ -n "$(GROUP_T)" ] && [ -n "$(USER)" ] && ! $(GROUPS) $(USER) | $(GREP) "\<$(GROUP_T)\>" >/dev/null; then \
--# $(ECHO) Group $(GROUP_T) for User $(USER) is invalid && exit 1 ;\
--# fi
-+install: CONF_DEST LOG_DEST PID_DEST check_doc
-
- @$(ECHO) "Creating directories, and preparing $(PROGRAM_V) installation"
- $(CHMOD) $(DIR_MODE) $(MKDIR)
-@@ -1106,41 +1084,7 @@ install: CONF_DEST LOG_DEST PID_DEST che
- $(INSTALL) $(INSTALL_T) $$i $(DESTDIR)$(CONF_DEST)/templates ;\
- done
-
-- @# FIXME: group/user validation is overly convoluted.
-- @# If superuser install ... we require a minimum of group ownership
-- @# of those files the daemon writes to, to be non-root owned.
-- @if [ "`$(ID) |sed 's/(.*//' |sed 's/.*=//'`" = "0" ] ;then\
-- if [ x$(USER) = x ] || [ $(USER) = root ]; then \
-- if [ x$(GROUP) = x ] || [ $(GROUP) = root ]; then \
-- if [ "`$(ID) privoxy`" ] && \
-- $(GROUPS) privoxy | $(SED) 's/^.*://' |$(GREP) "\<privoxy\>" >/dev/null; then \
-- $(ECHO) "Warning: Setting group owner to privoxy";\
-- GROUP_T=privoxy ;\
-- else \
-- $(ECHO) "******************************************************************" ;\
-- $(ECHO) " WARNING! WARNING! installing config files as root!" ;\
-- $(ECHO) " It is strongly recommended to run $(PROGRAM) as a non-root user," ;\
-- $(ECHO) " and to install the config files as that user and/or group!" ;\
-- $(ECHO) " Please read INSTALL, and create a privoxy user and group!" ;\
-- $(ECHO) "*******************************************************************" ;\
-- exit 1 ;\
-- fi ;\
-- else \
-- GROUP_T=$(GROUP) ;\
-- fi ;\
-- INSTALL_CONF="$(INSTALL_R) -g $$GROUP_T " ;\
-- else \
-- $(ECHO) "Superuser install, installing config files as $(USER):$(GROUP_T)" ;\
-- INSTALL_CONF="$(INSTALL_R) -o $(USER) -g $(GROUP_T)" ;\
-- GROUP_T=$(GROUP_T) ;\
-- fi ;\
-- else \
-- if [ ! "`id $(USER)`" = "`id`" ] ;then \
-- $(ECHO) "** WARNING ** current install user different from configured user!!" ;\
-- $(ECHO) "Edit may fail." ;\
-- fi ;\
-- INSTALL_CONF="$(INSTALL_R)" ;\
-- fi ;\
-+ INSTALL_CONF="$(INSTALL_R)" ;\
- $(ECHO) Installing configuration files to $(DESTDIR)$(CONF_DEST);\
- for i in $(CONFIGS); do \
- if [ "$$i" = "default.action" ] || [ "$$i" = "default.filter" ] ; then \
-@@ -1162,44 +1106,7 @@ install: CONF_DEST LOG_DEST PID_DEST che
- [ ! -f $(DESTDIR)$(LOG_DEST)/logfile ] && $(ECHO) Creating logfiles in $(DESTDIR)$(LOG_DEST) || \
- $(ECHO) Checking logfiles in $(DESTDIR)$(LOG_DEST) ;\
- $(TOUCH) $(DESTDIR)$(LOG_DEST)/logfile || exit 1 ;\
-- if [ x$$USER != x ]; then \
-- $(CHOWN) $$USER $(DESTDIR)$(LOG_DEST)/logfile || \
-- $(ECHO) "** WARNING ** current install user different from configured user. Logging may fail!!" ;\
-- fi ;\
-- if [ x$$GROUP_T != x ]; then \
-- $(CHGRP) $$GROUP_T $(DESTDIR)$(LOG_DEST)/logfile || \
-- $(ECHO) "** WARNING ** current install user different from configured user. Logging may fail!!" ;\
-- fi ;\
-- $(CHMOD) $(RWD_MODE) $(DESTDIR)$(LOG_DEST)/logfile || exit 1 ;\
-- if [ "$(prefix)" = "/usr/local" ] || [ "$(prefix)" = "/usr" ]; then \
-- if [ -f /etc/slackware-version ] && [ -d /etc/rc.d/ ] && [ -w /etc/rc.d/ ] ; then \
-- $(SED) 's+%PROGRAM%+$(PROGRAM)+' slackware/rc.privoxy.orig | \
-- $(SED) 's+%SBIN_DEST%+$(SBIN_DEST)+' | \
-- $(SED) 's+%CONF_DEST%+$(CONF_DEST)+' | \
-- $(SED) 's+%USER%+$(USER)+' | \
-- $(SED) 's+%GROUP%+$(GROUP_T)+' >slackware/rc.privoxy ;\
-- $(INSTALL) $(INSTALL_P) slackware/rc.privoxy $(DESTDIR)/etc/rc.d/ ;\
-- $(ECHO) "Installing for Slackware." ;\
-- $(ECHO) "Dont forget to add the rc.privoxy to rc.local if you want it started at every boot" ;\
-- elif [ -f /etc/redhat-release ] && [ -d /etc/rc.d/init.d/ ] && [ -w /etc/rc.d/init.d/ ] ; then \
-- $(ECHO) "Installing init script to /etc/rc.d/init.d/privoxy" ;\
-- $(SED) 's,^PRIVOXY_BIN=.*,PRIVOXY_BIN="/usr/local/sbin/$(PROGRAM)",' privoxy.init |\
-- $(SED) 's,^PRIVOXY_CONF=.*,PRIVOXY_CONF="$(CONF_DEST)/config",' |\
-- $(SED) "s,^PRIVOXY_USER=.*,PRIVOXY_USER=$$USER," > init.tmp ;\
-- $(INSTALL) $(INSTALL_P) init.tmp $(DESTDIR)/etc/rc.d/init.d/privoxy && $(RM) init.tmp;\
-- $(MKDIR) $(DESTDIR)/etc/logrotate.d/ ;\
-- $(ECHO) "Installing logrotate script to $(DESTDIR)/etc/logrotate.d/" ;\
-- $(INSTALL) -m 0644 privoxy.logrotate $(DESTDIR)/etc/logrotate.d/privoxy ;\
-- elif [ -d $(DESTDIR)/etc/init.d ] && [ -w $(DESTDIR)/etc/init.d ] ; then \
-- $(ECHO) "Installing generic init script to $(DESTDIR)/etc/init.d/privoxy" ;\
-- $(ECHO) "Please check that the PATHs are correct, and edit if needed." ;\
-- $(INSTALL) $(INSTALL_P) privoxy-generic.init $(DESTDIR)/etc/init.d/privoxy ;\
-- fi ;\
-- else \
-- $(ECHO) "No init script installed, install it manually if needed" ;\
-- fi
-- $(RM) config.base config.tmp
-- @# mmmmm, good.
-+ $(CHMOD) $(RWD_MODE) $(DESTDIR)$(LOG_DEST)/logfile || exit 1 ;
- @$(ECHO) "$(PROGRAM_V) installation succeeded!"
- @$(ECHO) "The Privoxy configuration files have been installed in $(DESTDIR)$(CONF_DEST)"
-
diff --git a/package/privoxy/patches/patch-configure_in b/package/privoxy/patches/patch-configure_in
deleted file mode 100644
index 74770aba6..000000000
--- a/package/privoxy/patches/patch-configure_in
+++ /dev/null
@@ -1,12 +0,0 @@
-$Id$
---- privoxy-3.0.12-stable.orig/configure.in 2009-03-21 11:45:06.000000000 +0100
-+++ privoxy-3.0.12-stable/configure.in 2009-04-17 17:42:04.722725574 +0200
-@@ -693,7 +693,7 @@ dnl Check for user and group validity
- dnl =================================================================
-
-
--if test "$EMXOS2" = yes; then
-+if true test "$EMXOS2" = yes; then
- echo "Skipping user and group validity stuff.";
-
- else