wok rev 2665

Add: wvdial 1.41
author Dominique Corbex <domcox@users.sourceforge.net>
date Sun Apr 19 12:15:29 2009 +0200 (2009-04-19)
parents 56876e429dfe
children 4c5b551c408e
files wvdial/receipt wvdial/stuff/wvdial-1.41-gcc4.2.diff
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/wvdial/receipt	Sun Apr 19 12:15:29 2009 +0200
     1.3 @@ -0,0 +1,32 @@
     1.4 +# SliTaz package receipt.
     1.5 +
     1.6 +PACKAGE="wvdial"
     1.7 +VERSION="1.41"
     1.8 +CATEGORY="network"
     1.9 +SHORT_DESC="makes modem-based connection to Internet"
    1.10 +MAINTAINER="domcox@slitaz.org"
    1.11 +DEPENDS="ppp"
    1.12 +TARBALL=$PACKAGE"_"$VERSION".tar.gz"
    1.13 +WEB_SITE="http://alumnit.ca/wiki/?WvDial"
    1.14 +WGET_URL="http://archive.debian.org/debian/dists/potato/main/source/comm/$TARBALL"
    1.15 +
    1.16 +# Rules to configure and make the package.
    1.17 +compile_rules()
    1.18 +{
    1.19 +	cd $src
    1.20 +	! grep -q DESTDIR Makefile && patch -p1 < ../stuff/wvdial-1.41-gcc4.2.diff
    1.21 +	make && make DESTDIR=$PWD/_pkg install
    1.22 +}
    1.23 +
    1.24 +# Rules to gen a SliTaz package suitable for Tazpkg.
    1.25 +genpkg_rules()
    1.26 +{
    1.27 +	mkdir -p $fs/usr/bin
    1.28 +	cp -a $_pkg/usr/bin/wvdial* $fs/usr/bin
    1.29 +	cp -a $_pkg/etc $fs
    1.30 +}
    1.31 +
    1.32 +post_remove()
    1.33 +{
    1.34 +	rm -rf /etc/ppp/peers/wvdial
    1.35 +}
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/wvdial/stuff/wvdial-1.41-gcc4.2.diff	Sun Apr 19 12:15:29 2009 +0200
     2.3 @@ -0,0 +1,336 @@
     2.4 +--- wvdial-1.41/Makefile	Sat Oct  3 05:40:30 1998
     2.5 ++++ wvdial-1.41+dom/Makefile	Thu Mar 19 20:56:27 2009
     2.6 +@@ -1,10 +1,11 @@
     2.7 + TOPDIR=$(shell if [ "$$PWD" != "" ]; then echo $$PWD; else pwd; fi)
     2.8 + 
     2.9 + DEBUG=0
    2.10 +-PREFIX=/usr/local
    2.11 +-BINDIR=${PREFIX}/bin
    2.12 +-MANDIR=${PREFIX}/man
    2.13 +-PPPDIR=/etc/ppp/peers
    2.14 ++
    2.15 ++PREFIX=/usr
    2.16 ++BINDIR=${DESTDIR}/${PREFIX}/bin
    2.17 ++MANDIR=${DESTDIR]/${PREFIX}/man
    2.18 ++PPPDIR=${DESTDIR}/etc/ppp/peers
    2.19 + 
    2.20 + export TOPDIR DEBUG CC CXX
    2.21 + include rules.mk
    2.22 +--- wvdial-1.41/configfile/wvconf.cc	Sun Nov 28 20:39:33 1999
    2.23 ++++ wvdial-1.41+dom/configfile/wvconf.cc	Thu Mar 19 20:56:27 2009
    2.24 +@@ -130,7 +130,7 @@
    2.25 + 	    // it must be an element for the current section *sect.
    2.26 + 	    p = parse_value(from_file);
    2.27 + 	    if (!p)
    2.28 +-		p = "";		// allow empty entries
    2.29 ++		  p = (char*)"";		// allow empty entries
    2.30 + 
    2.31 + 	    from_file = trim_string(from_file);
    2.32 + 	    if (from_file[0])	// nonblank option name
    2.33 +--- wvdial-1.41/rules.mk	Thu Mar 19 21:04:33 2009
    2.34 ++++ wvdial-1.41+dom/rules.mk	Thu Oct 21 00:37:00 1999
    2.35 +@@ -47,7 +47,7 @@
    2.36 + CFLAGS += -g -O6 -DDEBUG=0 -DNDEBUG
    2.37 + #CFLAGS += -fomit-frame-pointer  # really evil
    2.38 + #CXXFLAGS += -fno-implement-inlines  # causes trouble with egcs 1.0
    2.39 +-CXXFLAGS += -fno-rtti -fno-exceptions
    2.40 ++CXXFLAGS += -fno-rtti -fno-exceptions -fno-strict-aliasing
    2.41 + LDFLAGS += -g
    2.42 + endif
    2.43 + 
    2.44 +--- wvdial-1.41/streams/wvlog.cc	Sat Jul 10 21:36:45 1999
    2.45 ++++ wvdial-1.41+dom/streams/wvlog.cc	Thu Mar 19 20:56:27 2009
    2.46 +@@ -14,16 +14,16 @@
    2.47 + WvLogRcvBase *WvLog::default_receiver = NULL;
    2.48 + 
    2.49 + char *WvLogRcv::loglevels[WvLog::NUM_LOGLEVELS] = {
    2.50 +-    "Crit",
    2.51 +-    "Err",
    2.52 +-    "Warn",
    2.53 +-    "Notice",
    2.54 +-    "Info",
    2.55 +-    "*1",
    2.56 +-    "*2",
    2.57 +-    "*3",
    2.58 +-    "*4",
    2.59 +-    "*5",
    2.60 ++  (char*)"Crit",
    2.61 ++  (char*)"Err",
    2.62 ++  (char*)"Warn",
    2.63 ++  (char*)"Notice",
    2.64 ++  (char*)"Info",
    2.65 ++  (char*)"*1",
    2.66 ++  (char*)"*2",
    2.67 ++  (char*)"*3",
    2.68 ++  (char*)"*4",
    2.69 ++  (char*)"*5",
    2.70 + };
    2.71 + 
    2.72 + 
    2.73 +--- wvdial-1.41/streams/wvlog.h	Wed Mar 24 04:41:37 1999
    2.74 ++++ wvdial-1.41+dom/streams/wvlog.h	Thu Mar 19 20:56:27 2009
    2.75 +@@ -25,7 +25,7 @@
    2.76 + // or transmits log messages.
    2.77 + class WvLogRcvBase
    2.78 + {
    2.79 +-    friend WvLog;
    2.80 ++    friend class WvLog;
    2.81 + protected:
    2.82 +     const char *appname(const WvLog *log) const;
    2.83 +     virtual void log(const WvLog *source, int loglevel,
    2.84 +@@ -43,7 +43,7 @@
    2.85 + // to all registered WvLogRcv's.
    2.86 + class WvLog : public WvStream
    2.87 + {
    2.88 +-    friend WvLogRcvBase;
    2.89 ++    friend class WvLogRcvBase;
    2.90 + public:
    2.91 +     enum LogLevel {
    2.92 + 	Critical = 0,
    2.93 +--- wvdial-1.41/streams/wvstream.cc	Thu Oct 21 00:37:04 1999
    2.94 ++++ wvdial-1.41+dom/streams/wvstream.cc	Thu Mar 19 20:56:27 2009
    2.95 +@@ -9,6 +9,7 @@
    2.96 +  * for each stream.
    2.97 +  */
    2.98 + #include "wvstream.h"
    2.99 ++#include <time.h>
   2.100 + #include <sys/time.h>
   2.101 + #include <sys/types.h>
   2.102 + #include <errno.h>
   2.103 +--- wvdial-1.41/streams/wvtimestream.h	Wed Mar 24 04:41:37 1999
   2.104 ++++ wvdial-1.41+dom/streams/wvtimestream.h	Thu Mar 19 20:56:27 2009
   2.105 +@@ -40,7 +40,7 @@
   2.106 +     virtual bool test_set(SelectInfo &si);
   2.107 +     
   2.108 +     // notify timestream that we have "ticked" once
   2.109 +-    void WvTimeStream::tick();
   2.110 ++    virtual void tick();
   2.111 +     virtual void execute();
   2.112 + };
   2.113 + 
   2.114 +--- wvdial-1.41/utils/base64.cc	Wed Mar 24 04:41:38 1999
   2.115 ++++ wvdial-1.41+dom/utils/base64.cc	Thu Mar 19 20:56:27 2009
   2.116 +@@ -16,7 +16,7 @@
   2.117 + #include "base64.h"
   2.118 + #include <string.h>
   2.119 + 
   2.120 +-static char * alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"
   2.121 ++const char * alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"
   2.122 + 			 "0123456789+/=";
   2.123 + 
   2.124 + char * base64_encode( char * str )
   2.125 +--- wvdial-1.41/utils/base64.h	Wed Mar 24 04:41:38 1999
   2.126 ++++ wvdial-1.41+dom/utils/base64.h	Thu Mar 19 20:56:27 2009
   2.127 +@@ -12,4 +12,4 @@
   2.128 + extern char * base64_encode( char * str );
   2.129 + extern char * base64_decode( char * str );
   2.130 + 
   2.131 +-#endif __BASE64_H
   2.132 ++#endif // __BASE64_H
   2.133 +--- wvdial-1.41/utils/wvbuffer.h	Sun Jun 20 21:45:55 1999
   2.134 ++++ wvdial-1.41+dom/utils/wvbuffer.h	Thu Mar 19 20:56:27 2009
   2.135 +@@ -10,6 +10,7 @@
   2.136 + #define __WVBUFFER_H
   2.137 + 
   2.138 + #include "wvlinklist.h"
   2.139 ++#include <string.h>
   2.140 + 
   2.141 + class WvMiniBuffer
   2.142 + {
   2.143 +--- wvdial-1.41/utils/wvhashtable.h	Thu Oct 14 23:33:38 1999
   2.144 ++++ wvdial-1.41+dom/utils/wvhashtable.h	Thu Mar 19 20:56:27 2009
   2.145 +@@ -139,7 +139,7 @@
   2.146 +     _type_##List *sl()							\
   2.147 + 	{ return (_type_##List *)slots; }				\
   2.148 +     									\
   2.149 +-    ~##_classname_()							\
   2.150 ++    ~_classname_()							\
   2.151 +         { shutdown(); delete[] sl(); }					\
   2.152 +     									\
   2.153 +     void add(_type_ *data, bool auto_free)				\
   2.154 +--- wvdial-1.41/utils/wvlinklist.h	Thu Oct 14 23:33:38 1999
   2.155 ++++ wvdial-1.41+dom/utils/wvlinklist.h	Thu Mar 19 20:56:27 2009
   2.156 +@@ -126,7 +126,7 @@
   2.157 +     _newname_()						\
   2.158 + 	{ setup(); }					\
   2.159 + 							\
   2.160 +-    ~##_newname_() 					\
   2.161 ++    ~_newname_() 					\
   2.162 + 	{ shutdown(); _zap(); }				\
   2.163 + 							\
   2.164 +     void zap()						\
   2.165 +--- wvdial-1.41/wvdial/wvdialer.cc	Fri Nov 19 06:14:46 1999
   2.166 ++++ wvdial-1.41+dom/wvdial/wvdialer.cc	Thu Mar 19 20:56:27 2009
   2.167 +@@ -21,26 +21,26 @@
   2.168 + 
   2.169 + 
   2.170 + static char *	init_responses[] = {
   2.171 +-	"ok",
   2.172 +-	"error",
   2.173 ++  (char*)"ok",
   2.174 ++  (char*)"error",
   2.175 + 	NULL
   2.176 + };
   2.177 + 
   2.178 + static char *	dial_responses[] = {
   2.179 +-	"connect",
   2.180 +-	"no carrier",
   2.181 +-	"no dialtone",
   2.182 +-	"no dial tone",
   2.183 +-	"busy",
   2.184 +-	"error",
   2.185 +-	"voice",
   2.186 +-	"fclass",
   2.187 ++  (char*)"connect",
   2.188 ++  (char*)"no carrier",
   2.189 ++  (char*)"no dialtone",
   2.190 ++  (char*)"no dial tone",
   2.191 ++  (char*)"busy",
   2.192 ++  (char*)"error",
   2.193 ++  (char*)"voice",
   2.194 ++  (char*)"fclass",
   2.195 + 	NULL
   2.196 + };
   2.197 + 
   2.198 + static char *	prompt_strings[] = {
   2.199 +-	"}!}",
   2.200 +-	"!}!",
   2.201 ++  (char*)"}!}",
   2.202 ++  (char*)"!}!",
   2.203 + 	NULL
   2.204 + };
   2.205 + 
   2.206 +@@ -51,7 +51,7 @@
   2.207 + //       WvDialer Public Functions
   2.208 + //**************************************************
   2.209 + 
   2.210 +-WvDialer::WvDialer( WvConf &_cfg, WvStringList *_sect_list, bool _chat_mode = false )
   2.211 ++WvDialer::WvDialer( WvConf &_cfg, WvStringList *_sect_list, bool _chat_mode )
   2.212 + /********************************************************/
   2.213 + : WvStreamClone( (WvStream **)&modem ),
   2.214 +     cfg(_cfg), log( "WvDial", WvLog::Debug ),
   2.215 +@@ -360,40 +360,40 @@
   2.216 + {
   2.217 +     OptInfo opts[] = {
   2.218 +     // string options:
   2.219 +-    	{ "Modem",           &options.modem,        NULL, "/dev/modem",     0 },
   2.220 +-    	{ "Init1",           &options.init1,        NULL, "ATZ",            0 },
   2.221 +-    	{ "Init2",           &options.init2,        NULL, "",               0 },
   2.222 +-    	{ "Init3",           &options.init3,        NULL, "",               0 },
   2.223 +-    	{ "Init4",           &options.init4,        NULL, "",               0 },
   2.224 +-    	{ "Init5",           &options.init5,        NULL, "",               0 },
   2.225 +-    	{ "Init6",           &options.init6,        NULL, "",               0 },
   2.226 +-    	{ "Init7",           &options.init7,        NULL, "",               0 },
   2.227 +-    	{ "Init8",           &options.init8,        NULL, "",               0 },
   2.228 +-    	{ "Init9",           &options.init9,        NULL, "",               0 },
   2.229 +-    	{ "Phone",           &options.phnum,        NULL, "",               0 },
   2.230 +-    	{ "Dial Prefix",     &options.dial_prefix,  NULL, "",               0 },
   2.231 +-    	{ "Area Code",       &options.areacode,     NULL, "",               0 },
   2.232 +-    	{ "Dial Command",    &options.dial_cmd,     NULL, "ATDT",           0 },
   2.233 +-    	{ "Username",        &options.login,        NULL, "",               0 },
   2.234 +-    	{ "Login Prompt",    &options.login_prompt, NULL, "",               0 },
   2.235 +-    	{ "Password",        &options.password,     NULL, "",               0 },
   2.236 +-    	{ "Password Prompt", &options.pass_prompt,  NULL, "",               0 },
   2.237 +-    	{ "PPPD Path",       &options.where_pppd,   NULL, "/usr/sbin/pppd", 0 },
   2.238 +-    	{ "Force Address",   &options.force_addr,   NULL, "",               0 },
   2.239 +-    	{ "Remote Name",     &options.remote,       NULL, "*",              0 },
   2.240 +-    	{ "Default Reply",   &options.default_reply,NULL, "ppp",	    0 },
   2.241 +-    	{ "ISDN",	     &options.isdn,	    NULL, "",		    0 },
   2.242 ++	  { (char*)"Modem",           &options.modem,        NULL, (char*)"/dev/modem",     0 },
   2.243 ++	  { (char*)"Init1",           &options.init1,        NULL, (char*)"ATZ",            0 },
   2.244 ++	  { (char*)"Init2",           &options.init2,        NULL, (char*)"",               0 },
   2.245 ++	  { (char*)"Init3",           &options.init3,        NULL, (char*)"",               0 },
   2.246 ++	  { (char*)"Init4",           &options.init4,        NULL, (char*)"",               0 },
   2.247 ++	  { (char*)"Init5",           &options.init5,        NULL, (char*)"",               0 },
   2.248 ++	  { (char*)"Init6",           &options.init6,        NULL, (char*)"",               0 },
   2.249 ++	  { (char*)"Init7",           &options.init7,        NULL, (char*)"",               0 },
   2.250 ++	  { (char*)"Init8",           &options.init8,        NULL, (char*)"",               0 },
   2.251 ++	  { (char*)"Init9",           &options.init9,        NULL, (char*)"",               0 },
   2.252 ++	  { (char*)"Phone",           &options.phnum,        NULL, (char*)"",               0 },
   2.253 ++	  { (char*)"Dial Prefix",     &options.dial_prefix,  NULL, (char*)"",               0 },
   2.254 ++	  { (char*)"Area Code",       &options.areacode,     NULL, (char*)"",               0 },
   2.255 ++	  { (char*)"Dial Command",    &options.dial_cmd,     NULL, (char*)"ATDT",           0 },
   2.256 ++	  { (char*)"Username",        &options.login,        NULL, (char*)"",               0 },
   2.257 ++	  { (char*)"Login Prompt",    &options.login_prompt, NULL, (char*)"",               0 },
   2.258 ++	  { (char*)"Password",        &options.password,     NULL, (char*)"",               0 },
   2.259 ++	  { (char*)"Password Prompt", &options.pass_prompt,  NULL, (char*)"",               0 },
   2.260 ++	  { (char*)"PPPD Path",       &options.where_pppd,   NULL, (char*)"/usr/sbin/pppd", 0 },
   2.261 ++	  { (char*)"Force Address",   &options.force_addr,   NULL, (char*)"",               0 },
   2.262 ++	  { (char*)"Remote Name",     &options.remote,       NULL, (char*)"*",              0 },
   2.263 ++	  { (char*)"Default Reply",   &options.default_reply,NULL, (char*)"ppp",	        0 },
   2.264 ++	  { (char*)"ISDN",	     	  &options.isdn,	     NULL, (char*)"",		        0 },
   2.265 + 
   2.266 +     // int/bool options
   2.267 +-    	{ "Baud",            NULL, &options.baud,          "", DEFAULT_BAUD },
   2.268 +-    	{ "Carrier Check",   NULL, &options.carrier_check, "", true         },
   2.269 +-    	{ "Stupid Mode",     NULL, &options.stupid_mode,   "", false        },
   2.270 +-    	{ "New PPPD",	     NULL, &options.new_pppd, 	   "", true         },
   2.271 +-    	{ "Auto Reconnect",  NULL, &options.auto_reconnect,"", true	    },
   2.272 +-    	{ NULL,		     NULL, NULL,                   "", 0            }
   2.273 ++	  { (char*)"Baud",            NULL, &options.baud,          (char*)"", DEFAULT_BAUD },
   2.274 ++	  { (char*)"Carrier Check",   NULL, &options.carrier_check, (char*)"", true         },
   2.275 ++	  { (char*)"Stupid Mode",     NULL, &options.stupid_mode,   (char*)"", false        },
   2.276 ++	  { (char*)"New PPPD",	      NULL, &options.new_pppd, 	    (char*)"", true         },
   2.277 ++	  { (char*)"Auto Reconnect",  NULL, &options.auto_reconnect,(char*)"", true  	    },
   2.278 ++	  { NULL,		     		  NULL, NULL,                   (char*)"", 0            }
   2.279 +     };
   2.280 + 
   2.281 +-    char *	d = "Dialer Defaults";
   2.282 ++    char *	d = (char*)"Dialer Defaults";
   2.283 + 
   2.284 +     for( int i=0; opts[i].name != NULL; i++ ) {
   2.285 +     	if( opts[i].str_member == NULL ) {
   2.286 +--- wvdial-1.41/wvdial/wvmodemscan.cc	Mon Sep 13 22:07:35 1999
   2.287 ++++ wvdial-1.41+dom/wvdial/wvmodemscan.cc	Thu Mar 19 20:56:27 2009
   2.288 +@@ -19,9 +19,9 @@
   2.289 + // startup at atz atq0 atv1 ate1 ats0 carrier dtr fastdial
   2.290 + // baudstep reinit done
   2.291 + static char *commands[WvModemScan::NUM_STAGES] = {
   2.292 +-    NULL, "Q0 V1 E1", "Z", "S0=0",
   2.293 +-    "&C1", "&D2", "S11=55", "+FCLASS=0", NULL,
   2.294 +-    NULL, "", NULL
   2.295 ++  NULL, (char*)"Q0 V1 E1", (char*)"Z", (char*)"S0=0",
   2.296 ++  (char*)"&C1", (char*)"&D2", (char*)"S11=55", (char*)"+FCLASS=0", NULL,
   2.297 ++  NULL, (char*)"", NULL
   2.298 + };
   2.299 + 
   2.300 + 
   2.301 +--- wvdial-1.41/wvdial/wvpapchap.cc	Sun Jun  6 19:08:49 1999
   2.302 ++++ wvdial-1.41+dom/wvdial/wvpapchap.cc	Thu Mar 19 20:56:27 2009
   2.303 +@@ -25,16 +25,16 @@
   2.304 + 
   2.305 +     // PAP secrets:
   2.306 +     nuke_contents();
   2.307 +-    load_file( PAP_SECRETS );
   2.308 ++    load_file( (char*)PAP_SECRETS );
   2.309 +     do_secret( username, password, remote );
   2.310 +-    if( write_file( PAP_SECRETS ) == false )
   2.311 ++    if( write_file( (char*)PAP_SECRETS ) == false )
   2.312 + 	pap_success = false;
   2.313 + 
   2.314 +     // CHAP secrets:
   2.315 +     nuke_contents();
   2.316 +-    load_file( CHAP_SECRETS );
   2.317 ++    load_file( (char*)CHAP_SECRETS );
   2.318 +     do_secret( username, password, remote );
   2.319 +-    if( write_file( CHAP_SECRETS ) == false )
   2.320 ++    if( write_file( (char*)CHAP_SECRETS ) == false )
   2.321 + 	chap_success = false;
   2.322 + }
   2.323 + 
   2.324 +--- wvdial-1.41/wvdial/wvpapchap.h	Wed Mar 24 04:41:42 1999
   2.325 ++++ wvdial-1.41+dom/wvdial/wvpapchap.h	Thu Mar 19 20:56:27 2009
   2.326 +@@ -43,4 +43,4 @@
   2.327 + 		    const char * remote );
   2.328 + };
   2.329 + 
   2.330 +-#endif __WVPAPCHAP_H
   2.331 ++#endif // __WVPAPCHAP_H
   2.332 +--- wvdial-1.41/wvver.h	Fri Jan  7 03:55:50 2000
   2.333 ++++ wvdial-1.41+dom/wvver.h	Thu Mar 19 20:56:27 2009
   2.334 +@@ -28,4 +28,4 @@
   2.335 + #define TUNNELV_VER		0x00020000
   2.336 + #define TUNNELV_VER_STRING	"2.00"
   2.337 + 
   2.338 +-#endif __WVDEFS_H
   2.339 ++#endif // __WVDEFS_H