Ticket #1356: ziproxy_trunk_8152.patch

Datei ziproxy_trunk_8152.patch, 18.7 KB (hinzugefügt von M66B, vor 7 Jahren)
  • make/Config.in

     
    193193source make/xpdf/Config.in 
    194194source make/xrelayd/Config.in 
    195195source make/xsltproc/Config.in 
     196source make/ziproxy/Config.in 
    196197endmenu 
    197198 
    198199menu "Web interfaces" 
  • make/libs/giflib/giflib.mk

     
     1$(call PKG_INIT_LIB, 4.1.6) 
     2$(PKG)_LIB_VERSION:=4.1.6 
     3 
     4$(PKG)_SOURCE:=$(pkg)-$($(PKG)_VERSION).tar.bz2 
     5$(PKG)_SOURCE_MD5:=7125644155ae6ad33dbc9fc15a14735f 
     6$(PKG)_SITE:=@SF/$(pkg) 
     7$(PKG)_DIR:=$(SOURCE_DIR)/$(pkg)-$($(PKG)_VERSION) 
     8 
     9 
     10$(PKG)_BINARY:=$($(PKG)_DIR)/lib/.libs/libgif.so.$($(PKG)_LIB_VERSION) 
     11$(PKG)_STAGING_BINARY:=$(TARGET_TOOLCHAIN_STAGING_DIR)/usr/lib/libgif.so.$($(PKG)_LIB_VERSION) 
     12$(PKG)_TARGET_BINARY:=$($(PKG)_TARGET_DIR)/libgif.so.$($(PKG)_LIB_VERSION) 
     13 
     14$(PKG)_CONFIGURE_OPTIONS += --enable-shared 
     15$(PKG)_CONFIGURE_OPTIONS += --enable-static 
     16$(PKG)_CONFIGURE_OPTIONS += --disable-rpath 
     17$(PKG)_CONFIGURE_OPTIONS += --without-libiconv-prefix 
     18$(PKG)_CONFIGURE_OPTIONS += --with-x=no 
     19$(PKG)_CONFIGURE_OPTIONS += --with-xpm=no 
     20$(PKG)_CONFIGURE_OPTIONS += --with-fontconfig=no 
     21 
     22$(call REPLACE_LIBTOOL) 
     23 
     24$(PKG_SOURCE_DOWNLOAD) 
     25$(PKG_UNPACKED) 
     26$(PKG_CONFIGURED_CONFIGURE) 
     27 
     28$($(PKG)_BINARY): $($(PKG)_DIR)/.configured 
     29    $(SUBMAKE) -C $(GIFLIB_DIR) 
     30 
     31$($(PKG)_STAGING_BINARY): $($(PKG)_BINARY) 
     32    $(SUBMAKE) \ 
     33        DESTDIR="$(TARGET_TOOLCHAIN_STAGING_DIR)" \ 
     34        -C $(GIFLIB_DIR) install 
     35    $(PKG_FIX_LIBTOOL_LA) \ 
     36        $(TARGET_TOOLCHAIN_STAGING_DIR)/usr/lib/libgif.la  
     37 
     38$($(PKG)_TARGET_BINARY): $($(PKG)_STAGING_BINARY) 
     39    $(INSTALL_LIBRARY_STRIP) 
     40 
     41$(pkg): $($(PKG)_STAGING_BINARY) 
     42 
     43$(pkg)-precompiled: $($(PKG)_TARGET_BINARY) 
     44 
     45$(pkg)-clean: 
     46    -$(SUBMAKE) -C $(GIFLIB_DIR) clean 
     47    $(RM) -r $(TARGET_TOOLCHAIN_STAGING_DIR)/usr/lib/libgif.* \ 
     48        $(TARGET_TOOLCHAIN_STAGING_DIR)/include/gif_lib.*  
     49 
     50$(pkg)-uninstall: 
     51    $(RM) $(GIFLIB_TARGET_DIR)/libgif*.so* 
     52 
     53$(PKG_FINISH) 
  • make/libs/giflib/Config.in

     
     1config FREETZ_LIB_libgif 
     2    bool "GIF image library (libgif.so)" 
     3    default n 
     4    help 
     5        Giflib is a library for reading and writing gif images. 
     6        It is API and ABI compatible with libungif which was in wide use 
     7        while the LZW compression algorithm was patented. 
     8 
     9        In Freetz, ziproxy depends on giflib. 
  • make/libs/Config.in

     
    9292source make/libs/jpeg/Config.in 
    9393source make/libs/libpng/Config.in 
    9494source make/libs/gd/Config.in 
     95source make/libs/giflib/Config.in 
    9596source make/libs/openjpeg/Config.in 
    9697source make/netpbm/Config.in.libs 
    9798 
  • make/ziproxy/files/.language

     
     1languages 
     2{ de en } 
     3default 
     4{ en } 
     5files 
     6{ 
     7    usr/lib/cgi-bin/ziproxy.cgi 
     8} 
  • make/ziproxy/files/root/usr/lib/cgi-bin/ziproxy.cgi

     
     1#!/bin/sh 
     2 
     3. /usr/lib/libmodcgi.sh 
     4 
     5check "$ZIPROXY_ENABLED" yes:auto inetd "*":man 
     6check "$ZIPROXY_GZIPCOMPRESS" yes:gzipcompress 
     7check "$ZIPROXY_GRAYSCALE" yes:grayscale 
     8check "$ZIPROXY_LOOKCHANGE" yes:lookchange 
     9check "$ZIPROXY_IMAGECOMPRESS" yes:imagecompress 
     10check "$ZIPROXY_MINIFY" yes:minify 
     11check "$ZIPROXY_PREEMPTNAMERES" yes:preemptnameres 
     12check "$ZIPROXY_TRANSPARENTPROXY" yes:transparentproxy 
     13check "$ZIPROXY_ALLOWCONNECT" yes:allowconnect 
     14 
     15sec_begin '$(lang de:"Starttyp" en:"Start type")' 
     16 
     17cat << EOF 
     18<p> 
     19<input id="e1" type="radio" name="enabled" value="yes"$auto_chk><label for="e1"> $(lang de:"Automatisch" en:"Automatic")</label> 
     20<input id="e2" type="radio" name="enabled" value="no"$man_chk><label for="e2"> $(lang de:"Manuell" en:"Manual")</label> 
     21EOF 
     22if [ -e "/etc/default.inetd/inetd.cfg" ]; then 
     23cat << EOF 
     24<input id="e3" type="radio" name="enabled" value="inetd"$inetd_chk><label for="e3"> $(lang de:"Inetd" en:"Inetd")</label> 
     25EOF 
     26fi 
     27cat << EOF 
     28</p> 
     29EOF 
     30 
     31sec_end 
     32sec_begin '$(lang de:"ziproxy" en:"ziproxy")' 
     33 
     34cat << EOF 
     35<table border="0"> 
     36<tr> 
     37    <td>$(lang de:"Port" en:"Port"):</td> 
     38    <td><input type="text" name="port" size="5" maxlength="10" value="$(html "$ZIPROXY_PORT")"></td> 
     39</tr> 
     40<tr> 
     41    <td>$(lang de:"Address" en:"Address"):</td> 
     42    <td><input type="text" name="address" size="25" maxlength="50" value="$(html "$ZIPROXY_ADDRESS")"></td> 
     43</tr> 
     44<tr> 
     45    <td>$(lang de:"Max. connections" en:"Max. connections"):</td> 
     46    <td><input type="text" name="maxconnections" size="5" maxlength="10" value="$(html "$ZIPROXY_MAXCONNECTIONS")"></td> 
     47</tr> 
     48<tr> 
     49    <td>$(lang de:"GZip compression" en:"GZip compression"):</td> 
     50    <td> 
     51        <input type="hidden" name="gzipcompress" value="no"> 
     52        <input id="id_gzipcompress" type="checkbox" name="gzipcompress" value="yes"$gzipcompress_chk> 
     53    </td> 
     54</tr> 
     55<tr> 
     56    <td>$(lang de:"Image quality" en:"Image quality"):</td> 
     57    <td><input type="text" name="imagequality" size="10" maxlength="20" value="$(html "$ZIPROXY_IMAGEQUALITY")"></td> 
     58</tr> 
     59<tr> 
     60    <td>$(lang de:"Max. size" en:"Max. size"):</td> 
     61    <td><input type="text" name="maxsize" size="10" maxlength="20" value="$(html "$ZIPROXY_MAXSIZE")"></td> 
     62</tr> 
     63<tr> 
     64    <td>$(lang de:"Look change" en:"Look change"):</td> 
     65    <td> 
     66        <input type="hidden" name="lookchange" value="no"> 
     67        <input id="id_lookchange" type="checkbox" name="lookchange" value="yes"$lookchange_chk> 
     68    </td> 
     69</tr> 
     70<tr> 
     71    <td>$(lang de:"Grayscale" en:"Grayscale"):</td> 
     72    <td> 
     73        <input type="hidden" name="grayscale" value="no"> 
     74        <input id="id_grayscale" type="checkbox" name="grayscale" value="yes"$grayscale_chk> 
     75    </td> 
     76</tr> 
     77<tr> 
     78    <td>$(lang de:"Compress images" en:"Compress images"):</td> 
     79    <td> 
     80        <input type="hidden" name="imagecompress" value="no"> 
     81        <input id="id_imagecompress" type="checkbox" name="imagecompress" value="yes"$imagecompress_chk> 
     82    </td> 
     83</tr> 
     84<tr> 
     85    <td>$(lang de:"Minify HTML/CSS/JS" en:"Minify HTML/CSS/JS"):</td> 
     86    <td> 
     87        <input type="hidden" name="minify" value="no"> 
     88        <input id="id_minify" type="checkbox" name="minify" value="yes"$minify_chk> 
     89    </td> 
     90</tr> 
     91<tr> 
     92    <td>$(lang de:"Preemptive DNS" en:"Preemptive DNS"):</td> 
     93    <td> 
     94        <input type="hidden" name="preemptnameres" value="no"> 
     95        <input id="id_preemptnameres" type="checkbox" name="preemptnameres" value="yes"$preemptnameres_chk> 
     96    </td> 
     97</tr> 
     98<tr> 
     99    <td>$(lang de:"Preemptive max." en:"Preemptive max."):</td> 
     100    <td><input type="text" name="preemptnameresmax" size="5" maxlength="10" value="$(html "$ZIPROXY_PREEMPTNAMERESMAX")"></td> 
     101</tr> 
     102<tr> 
     103    <td>$(lang de:"Transparent proxy" en:"Transparent proxy"):</td> 
     104    <td> 
     105        <input type="hidden" name="transparentproxy" value="no"> 
     106        <input id="id_transparentproxy" type="checkbox" name="transparentproxy" value="yes"$transparentproxy_chk> 
     107    </td> 
     108</tr> 
     109<tr> 
     110    <td>$(lang de:"Allow CONNECT method" en:"Allow CONNECT method"):</td> 
     111    <td> 
     112        <input type="hidden" name="allowconnect" value="no"> 
     113        <input id="id_allowconnect" type="checkbox" name="allowconnect" value="yes"$allowconnect_chk> 
     114    </td> 
     115</tr> 
     116<tr> 
     117    <td>$(lang de:"Restrict HTTP port" en:"Restrict HTTP port"):</td> 
     118    <td><input type="text" name="restrictporthttp" size="25" maxlength="50" value="$(html "$ZIPROXY_RESTRICTPORTHTTP")"></td> 
     119</tr> 
     120<tr> 
     121    <td>$(lang de:"Restrict CONNECT port" en:"Restrict CONNECT port"):</td> 
     122    <td><input type="text" name="restrictportconnect" size="25" maxlength="50" value="$(html "$ZIPROXY_RESTRICTPORTCONNECT")"></td> 
     123</tr> 
     124<tr> 
     125    <td>$(lang de:"Authentication user" en:"Authentication user"):</td> 
     126    <td><input type="text" name="authuser" size="25" maxlength="60" value="$(html "$ZIPROXY_AUTHUSER")"></td> 
     127</tr> 
     128<tr> 
     129    <td>$(lang de:"Authentication password" en:"Authentication password"):</td> 
     130    <td><input type="password" name="authpasswd" size="25" maxlength="60" value="$(html "$ZIPROXY_AUTHPASSWD")"></td> 
     131</tr> 
     132<tr> 
     133    <td>$(lang de:"URL no processing list" en:"URL no processing list"):</td> 
     134    <td><textarea id="id_urlnoprocessing" style="width: 550px;" name="urlnoprocessing" rows="15" cols="80" wrap="off" >$ZIPROXY_URLNOPROCESSING</textarea></td> 
     135</tr> 
     136<tr> 
     137    <td>$(lang de:"URL deny list" en:"URL deny list"):</td> 
     138    <td><textarea id="id_urldeny" style="width: 550px;" name="urldeny" rows="15" cols="80" wrap="off" >$ZIPROXY_URLDENY</textarea></td> 
     139</tr> 
     140<tr> 
     141    <td><a href="http://www.speedguide.net/tcpoptimizer.php#advanced_qos" target="_blank">$(lang de:"TOS flags" en:"TOS flags")</a>:</td> 
     142    <td><input type="text" name="tosflags" size="5" maxlength="10" value="$(html "$ZIPROXY_TOSFLAGS")"></td> 
     143</tr> 
     144<tr> 
     145    <td>$(lang de:"Error log file" en:"Error log file"):</td> 
     146    <td><input type="text" name="errorlog" size="40" maxlength="255" value="$(html "$ZIPROXY_ERRORLOG")"></td> 
     147</tr> 
     148<tr> 
     149    <td>$(lang de:"Access log file" en:"Access log file"):</td> 
     150    <td><input type="text" name="accesslog" size="40" maxlength="255" value="$(html "$ZIPROXY_ACCESSLOG")"></td> 
     151</tr> 
     152<tr> 
     153    <td>$(lang de:"Extra options" en:"Extra options"):</td> 
     154    <td><textarea id="id_extra" style="width: 550px;" name="extra" rows="15" cols="80" wrap="off" >$ZIPROXY_EXTRA</textarea></td> 
     155</tr> 
     156</table> 
     157 
     158EOF 
     159 
     160sec_end 
  • make/ziproxy/files/root/etc/init.d/rc.ziproxy

    Property changes on: make/ziproxy/files/root/usr/lib/cgi-bin/ziproxy.cgi
    ___________________________________________________________________
    Added: svn:executable
       + *
    
     
     1#!/bin/sh 
     2 
     3DAEMON=ziproxy 
     4DAEMON_CONFIG="/mod/etc/$DAEMON.conf" 
     5 
     6. /etc/init.d/modlibrc 
     7 
     8DAEMON_USER=nobody 
     9DAEMON_GROUP=nobody 
     10 
     11start() { 
     12    if [ -e /usr/sbin/iptables ] && [ "$ZIPROXY_TRANSPARENTPROXY" == "yes" ]; then 
     13        /usr/sbin/iptables -t nat -A PREROUTING -i lan -p tcp --dport 80 -j REDIRECT --to-port $ZIPROXY_PORT 
     14    fi 
     15    modlib_startdaemon $DAEMON -d -c $DAEMON_CONFIG 
     16} 
     17 
     18stop() { 
     19    $DAEMON -k -c $DAEMON_CONFIG 
     20    if [ -e /usr/sbin/iptables ] && /usr/sbin/iptables -t nat -S PREROUTING | grep -q "to-ports $ZIPROXY_PORT" ; then 
     21        /usr/sbin/iptables -t nat -D PREROUTING -i lan -p tcp --dport 80 -j REDIRECT --to-ports $ZIPROXY_PORT 
     22    fi 
     23} 
     24 
     25config() { 
     26    modlib_config 
     27} 
     28 
     29case $1 in 
     30    ""|load) 
     31        modreg cgi 'ziproxy' 'ziproxy' 
     32        modreg daemon $DAEMON 
     33 
     34        modlib_addgroup $DAEMON_GROUP 
     35        modlib_adduser $DAEMON_USER -s /bin/false -D -S -H -G $DAEMON_GROUP -g $DAEMON_GROUP 
     36 
     37        modlib_start $ZIPROXY_ENABLED 
     38        ;; 
     39    unload) 
     40        modunreg daemon $DAEMON 
     41        modunreg cgi $DAEMON 
     42        modlib_stop 
     43        ;; 
     44    start) 
     45        modlib_start 
     46        ;; 
     47    stop) 
     48        modlib_stop 
     49        ;; 
     50    restart) 
     51        modlib_restart 
     52        ;; 
     53    status) 
     54        modlib_status 
     55        ;; 
     56    *) 
     57        echo "Usage: $0 [load|unload|start|stop|restart|status]" 1>&2 
     58        exit 1 
     59        ;; 
     60esac 
     61 
     62exit 0 
  • make/ziproxy/files/root/etc/default.ziproxy/ziproxy.cfg

    Property changes on: make/ziproxy/files/root/etc/init.d/rc.ziproxy
    ___________________________________________________________________
    Added: svn:executable
       + *
    
     
     1export ZIPROXY_ENABLED='no' 
     2export ZIPROXY_PORT='3131' 
     3export ZIPROXY_ADDRESS='' 
     4export ZIPROXY_MAXCONNECTIONS='' 
     5export ZIPROXY_GZIPCOMPRESS='yes' 
     6export ZIPROXY_IMAGEQUALITY='' 
     7export ZIPROXY_MAXSIZE='' 
     8export ZIPROXY_LOOKCHANGE='no' 
     9export ZIPROXY_GRAYSCALE='no' 
     10export ZIPROXY_IMAGECOMPRESS='yes' 
     11export ZIPROXY_MINIFY='no' 
     12export ZIPROXY_PREEMPTNAMERES='no' 
     13export ZIPROXY_PREEMPTNAMERESMAX='' 
     14export ZIPROXY_TRANSPARENTPROXY='no' 
     15export ZIPROXY_ALLOWCONNECT='yes' 
     16export ZIPROXY_RESTRICTPORTHTTP='' 
     17export ZIPROXY_RESTRICTPORTCONNECT='' 
     18export ZIPROXY_AUTHUSER='' 
     19export ZIPROXY_AUTHPASSWD='' 
     20export ZIPROXY_URLNOPROCESSING='' 
     21export ZIPROXY_URLDENY='' 
     22export ZIPROXY_TOSFLAGS='' 
     23export ZIPROXY_ERRORLOG='/var/log/ziproxy.log' 
     24export ZIPROXY_ACCESSLOG='' 
     25export ZIPROXY_EXTRA='' 
  • make/ziproxy/files/root/etc/default.ziproxy/ziproxy.inetd

     
     1. /mod/etc/conf/ziproxy.cfg 
     2[ -n "$ZIPROXY_ADDRESS" ] && local BINDADDRESS="${ZIPROXY_ADDRESS}:" 
     3echo "$BINDADDRESS" | grep "\." -vq && local BINDPROTO=$1 
     4inetdcfg_desc="ziproxy" 
     5inetdcfg_port=${BINDADDRESS}$ZIPROXY_PORT 
     6inetdcfg_sock=stream 
     7inetdcfg_proto=tcp$BINDPROTO 
     8inetdcfg_flags=nowait 
     9inetdcfg_user=root 
     10inetdcfg_exe=/usr/bin/ziproxy 
     11inetdcfg_arg0=ziproxy 
     12inetdcfg_args="-i -c /mod/etc/ziproxy.conf" 
  • make/ziproxy/files/root/etc/default.ziproxy/ziproxy_conf

     
     1#!/bin/sh 
     2 
     3[ -d /var/tmp/ziproxy ] && rm -R /var/tmp/ziproxy 
     4mkdir -p /var/tmp/ziproxy 
     5 
     6echo "Port=$ZIPROXY_PORT" 
     7[ -n "$ZIPROXY_ADDRESS" ] && echo "Address=\"$ZIPROXY_ADDRESS\"" 
     8[ -n "$ZIPROXY_MAXCONNECTIONS" ] && echo "MaxActiveUserConnections=$ZIPROXY_MAXCONNECTIONS" 
     9 
     10[ "$ZIPROXY_ENABLED" != "inet" ] && echo "PIDFile=\"/var/run/ziproxy.pid\"" 
     11cat << EOF 
     12RunAsUser="nobody" 
     13RunAsGroup="nobody" 
     14EOF 
     15 
     16if [ "$ZIPROXY_GZIPCOMPRESS" != "yes" ]; then 
     17cat << EOF 
     18Gzip=false 
     19OverrideAcceptEncoding=false 
     20DecompressIncomingGzipData=false 
     21EOF 
     22fi 
     23 
     24[ -n "$ZIPROXY_IMAGEQUALITY" ] && echo "ImageQuality={$ZIPROXY_IMAGEQUALITY}" 
     25 
     26[ -n "$ZIPROXY_MAXSIZE" ] && echo "MaxSize=$ZIPROXY_MAXSIZE" 
     27 
     28[ "$ZIPROXY_LOOKCHANGE" == "yes" ] && echo "AllowLookChange=true" 
     29[ "$ZIPROXY_GRAYSCALE" == "yes" ] && echo "ConvertToGrayscale=true" 
     30 
     31if [ "$ZIPROXY_IMAGECOMPRESS" != "yes" ]; then 
     32cat << EOF 
     33ProcessJPG=false 
     34ProcessPNG=false 
     35ProcessGIF=false 
     36EOF 
     37fi 
     38 
     39if [ "$ZIPROXY_MINIFY" == "yes" ]; then 
     40cat << EOF 
     41ProcessHTML=true 
     42ProcessCSS=true 
     43ProcessJS=true 
     44EOF 
     45fi 
     46 
     47[ "$ZIPROXY_PREEMPTNAMERES" == "yes" ] && echo "PreemptNameRes=true" 
     48[ -n "$ZIPROXY_PREEMPTNAMERESMAX" ] && echo "PreemptNameResMax=$ZIPROXY_PREEMPTNAMERESMAX" 
     49 
     50if [ "$ZIPROXY_TRANSPARENTPROXY" == "yes" ]; then 
     51cat << EOF 
     52TransparentProxy=true 
     53ConventionalProxy=false 
     54EOF 
     55fi 
     56 
     57[ "$ZIPROXY_ALLOWCONNECT" != "yes" ] && echo "AllowMethodCONNECT=false" 
     58[ -n "$ZIPROXY_RESTRICTPORTHTTP" ] && echo "RestrictOutPortHTTP={$ZIPROXY_RESTRICTPORTHTTP}" 
     59[ -n "$ZIPROXY_RESTRICTPORTCONNECT" ] && echo "RestrictOutPortCONNECT={$ZIPROXY_RESTRICTPORTCONNECT}" 
     60 
     61if [ -n "$ZIPROXY_AUTHUSER" ] && [ -n "$ZIPROXY_AUTHPASSWD" ]; then 
     62    echo "$ZIPROXY_AUTHUSER:$ZIPROXY_AUTHPASSWD" >/var/tmp/ziproxy/http.passwd 
     63cat << EOF 
     64AuthMode=1 
     65AuthPasswdFile="/var/tmp/ziproxy/http.passwd" 
     66EOF 
     67fi 
     68 
     69if [ -n "$ZIPROXY_URLNOPROCESSING" ]; then 
     70    echo "$ZIPROXY_URLNOPROCESSING" >/var/tmp/ziproxy/noprocess.list 
     71    echo "URLNoProcessing=\"/var/tmp/ziproxy/noprocess.list\"" 
     72fi 
     73 
     74if [ -n "$ZIPROXY_URLDENY" ]; then 
     75    echo "$ZIPROXY_URLDENY" >/var/tmp/ziproxy/deny.list 
     76    echo "URLDeny=\"/var/tmp/ziproxy/deny.list\"" 
     77fi 
     78 
     79if [ -n "$ZIPROXY_TOSFLAGS" ]; then 
     80cat << EOF 
     81TOSMarking=true 
     82TOSFlagsDefault=$ZIPROXY_TOSFLAGS 
     83EOF 
     84fi 
     85 
     86echo "ErrorLog=\"$ZIPROXY_ERRORLOG\"" 
     87touch "$ZIPROXY_ERRORLOG" 
     88chown nobody:nobody "$ZIPROXY_ERRORLOG" 
     89 
     90if [ -n "$ZIPROXY_ACCESSLOG" ]; then 
     91    echo "AccessLog=\"$ZIPROXY_ACCESSLOG\"" 
     92    touch "$ZIPROXY_ACCESSLOG" 
     93    chown nobody:nobody "$ZIPROXY_ACCESSLOG" 
     94fi 
     95 
     96echo "$ZIPROXY_EXTRA" 
     97 
     98chown -R nobody:nobody /var/tmp/ziproxy 
  • make/ziproxy/Makefile.in

    Property changes on: make/ziproxy/files/root/etc/default.ziproxy/ziproxy_conf
    ___________________________________________________________________
    Added: svn:executable
       + *
    
     
     1ifeq ($(strip $(FREETZ_PACKAGE_ZIPROXY)),y) 
     2PACKAGES+=ziproxy 
     3endif 
  • make/ziproxy/ziproxy.mk

     
     1$(call PKG_INIT_BIN, 3.2.0) 
     2$(PKG)_SOURCE:=$(pkg)-$($(PKG)_VERSION).tar.bz2 
     3$(PKG)_SITE:=@SF/$(pkg) 
     4$(PKG)_BINARY:=$($(PKG)_DIR)/src/ziproxy 
     5$(PKG)_TARGET_BINARY:=$($(PKG)_DEST_DIR)/usr/bin/ziproxy 
     6 
     7$(PKG)_DEPENDS_ON += jpeg 
     8$(PKG)_DEPENDS_ON += libpng 
     9$(PKG)_DEPENDS_ON += giflib 
     10$(PKG)_DEPENDS_ON += zlib 
     11 
     12ifeq ($(strip $(FREETZ_PACKAGE_ZIPROXY_STATIC)),y) 
     13$(PKG)_LDFLAGS:= -static 
     14endif 
     15 
     16$(PKG)_REBUILD_SUBOPTS += FREETZ_PACKAGE_ZIPROXY_STATIC 
     17 
     18$(PKG)_CONFIGURE_OPTIONS += --with-jasper=no 
     19$(PKG)_CONFIGURE_OPTIONS += --with-sasl2=no 
     20$(PKG)_CONFIGURE_OPTIONS += --sysconfdir=/mod/etc/ziproxy 
     21 
     22$(PKG_SOURCE_DOWNLOAD) 
     23$(PKG_UNPACKED) 
     24$(PKG_CONFIGURED_CONFIGURE) 
     25 
     26$($(PKG)_BINARY): $($(PKG)_DIR)/.configured 
     27    $(SUBMAKE) -C $(ZIPROXY_DIR) \ 
     28        LDFLAGS="$(TARGET_LDFLAGS) $(ZIPROXY_LDFLAGS)" 
     29 
     30$($(PKG)_TARGET_BINARY): $($(PKG)_BINARY) 
     31    $(INSTALL_BINARY_STRIP) 
     32 
     33$(pkg): 
     34 
     35$(pkg)-precompiled: $($(PKG)_TARGET_BINARY) 
     36 
     37$(pkg)-clean: 
     38    -$(SUBMAKE) -C $(ZIPROXY_DIR) clean 
     39    $(RM) $(ZIPROXY_FREETZ_CONFIG_FILE) 
     40 
     41$(pkg)-uninstall: 
     42    $(RM) $(ZIPROXY_TARGET_BINARY) 
     43 
     44$(PKG_FINISH) 
  • make/ziproxy/Config.in

     
     1config FREETZ_PACKAGE_ZIPROXY 
     2    bool "ziproxy 3.2.0" 
     3    select FREETZ_LIB_libjpeg if ! FREETZ_PACKAGE_ZIPROXY_STATIC 
     4    select FREETZ_LIB_libgif if ! FREETZ_PACKAGE_ZIPROXY_STATIC 
     5    select FREETZ_LIB_libpng12 if ! FREETZ_PACKAGE_ZIPROXY_STATIC 
     6    select FREETZ_LIB_libz if ! FREETZ_PACKAGE_ZIPROXY_STATIC 
     7    default n 
     8    help 
     9        Ziproxy is a forwarding HTTP proxy server aimed to speed up low-bandwidth connections.  
     10        It does so by gzipping HTML and using lossy compression of GIF, PNG and JPEG pictures. 
     11 
     12config FREETZ_PACKAGE_ZIPROXY_STATIC 
     13    bool "Statically link libraries" 
     14    depends on FREETZ_PACKAGE_ZIPROXY 
     15    default n 
     16    help 
     17        Build statically linked binary of ZIPROXY 
     18 
     19