[complement-svn] SF.net SVN: complement: [1849] trunk/complement/explore/app/SMTP-tools/ DoSclient
Status: Pre-Alpha
Brought to you by:
complement
From: <com...@us...> - 2008-04-23 05:45:09
|
Revision: 1849 http://complement.svn.sourceforge.net/complement/?rev=1849&view=rev Author: complement Date: 2008-04-22 22:45:02 -0700 (Tue, 22 Apr 2008) Log Message: ----------- compiled with current libxmt Modified Paths: -------------- trunk/complement/explore/app/SMTP-tools/DoSclient/Makefile trunk/complement/explore/app/SMTP-tools/DoSclient/doscl.cc Property Changed: ---------------- trunk/complement/explore/app/SMTP-tools/DoSclient/ Property changes on: trunk/complement/explore/app/SMTP-tools/DoSclient ___________________________________________________________________ Name: svn:ignore + obj Modified: trunk/complement/explore/app/SMTP-tools/DoSclient/Makefile =================================================================== --- trunk/complement/explore/app/SMTP-tools/DoSclient/Makefile 2008-04-23 05:42:33 UTC (rev 1848) +++ trunk/complement/explore/app/SMTP-tools/DoSclient/Makefile 2008-04-23 05:45:02 UTC (rev 1849) @@ -1,28 +1,30 @@ -# -*- Makefile -*- Time-stamp: <03/10/07 18:28:29 ptr> -# $Id: Makefile,v 1.2 2004/06/16 14:29:20 ptr Exp $ +# -*- Makefile -*- Time-stamp: <08/04/23 09:38:04 ptr> -SRCROOT := ../../../../extern/complement -# SRCROOT := /export/home/ptr/island/workshop/explore -COMPILER_NAME := gcc +SRCROOT := ../../.. include Makefile.inc -include ${SRCROOT}/Makefiles/top.mak +include ${SRCROOT}/Makefiles/gmake/top.mak +LIBMT_DIR = ${CoMT_DIR}/lib/mt +LIBSOCKIOS_DIR = ${CoMT_DIR}/lib/sockios +LIBMISC_DIR = ${CoMT_DIR}/lib/misc +# LIBUTF_DIR = ${CoMT_DIR}/../extern/custom/boost/libs/test/unit_test_framework +# LIBEXAM_DIR = ${CoMT_DIR}/lib/exam +# LIBFS_DIR = ${CoMT_DIR}/../extern/custom/boost/libs/filesystem DEFS += -D_NO_TEST INCLUDES += -I$(SRCROOT)/include -I$(STLPORT_INCLUDE_DIR) -I$(BOOST_INCLUDE_DIR) -release-shared: LDSEARCH = -L${STLPORT_LIB_DIR} -L${CoMT_LIB_DIR} -stldbg-shared: LDSEARCH = -L${STLPORT_LIB_DIR} -L${CoMT_LIB_DIR_STLDBG} -dbg-shared: LDSEARCH = -L${STLPORT_LIB_DIR} -L${CoMT_LIB_DIR_DBG} +release-shared: LDSEARCH += -L${LIBMT_DIR}/${OUTPUT_DIR} -L${LIBSOCKIOS_DIR}/${OUTPUT_DIR} -L${LIBMISC_DIR}/${OUTPUT_DIR} +dbg-shared: LDSEARCH += -L${LIBMT_DIR}/${OUTPUT_DIR_DBG} -L${LIBSOCKIOS_DIR}/${OUTPUT_DIR_DBG} -L${LIBMISC_DIR}/${OUTPUT_DIR_DBG} +ifndef WITHOUT_STLPORT +stldbg-shared: LDSEARCH += -L${LIBMT_DIR}/${OUTPUT_DIR_STLDBG} -L${LIBSOCKIOS_DIR}/${OUTPUT_DIR_STLDBG} -L${LIBMISC_DIR}/${OUTPUT_DIR_STLDBG} +endif -ifeq ($(OSNAME),sunos) -release-shared : LDLIBS = -lstlport_gcc -lrt -stldbg-shared : LDLIBS = -lstlport_gcc_stldebug -lrt -dbg-shared : LDLIBS = -lstlport_gcc -lrt -else -release-shared : LDLIBS = -lstlport_gcc -lxmt_gcc -lsockios_gcc -lmisc_gcc -stldbg-shared : LDLIBS = -lstlport_gcc_stldebug -lxmt_gcc_stl-g -lsockios_gcc_stl-g -lmisc_gcc_stl-g -dbg-shared : LDLIBS = -lstlport_gcc -lxmt_gcc-g -lsockios_gcc-g -lmisc_gcc-g +release-shared : LDLIBS = -lxmt -lsockios -lmisc +dbg-shared : LDLIBS = -lxmtg -lsockiosg -lmiscg +ifndef WITHOUT_STLPORT +stldbg-shared : LDLIBS = -lxmtstlg -lsockiosstlg -lmiscstlg endif + Modified: trunk/complement/explore/app/SMTP-tools/DoSclient/doscl.cc =================================================================== --- trunk/complement/explore/app/SMTP-tools/DoSclient/doscl.cc 2008-04-23 05:42:33 UTC (rev 1848) +++ trunk/complement/explore/app/SMTP-tools/DoSclient/doscl.cc 2008-04-23 05:45:02 UTC (rev 1849) @@ -1,22 +1,15 @@ // -*- C++ -*- Time-stamp: <04/01/21 18:04:57 ptr> -#ifdef __unix -# ifdef __HP_aCC -#pragma VERSIONID "@(#)$Id: doscl.cc,v 1.2 2004/06/16 14:29:20 ptr Exp $" -# else -#ident "@(#)$Id: doscl.cc,v 1.2 2004/06/16 14:29:20 ptr Exp $" -# endif -#endif - #include <iostream> #include <string> #include <sstream> #include <sockios/sockstream> -#include <mt/xmt.h> +#include <mt/date_time> +#include <mt/thread> #include <misc/args.h> using namespace std; -using namespace __impl; +using namespace std::tr2; int command_whole_timeout_test( iostream& s, const string& hello_host, int delay ) { @@ -27,12 +20,8 @@ cout << rline << endl; - timespec t; - t.tv_sec = delay; - t.tv_nsec = 0; + this_thread::sleep( seconds( delay ) ); - Thread::delay( &t ); - s << "EHLO " << hello_host << "\r" << endl; getline( s, rline ); @@ -57,16 +46,12 @@ cout << rline << endl; - timespec t; - t.tv_sec = delay; - t.tv_nsec = 0; - stringstream sstr; sstr << "EHLO " << hello_host << "\r" << endl; string greeting( sstr.str() ); for ( string::iterator i = greeting.begin(); i != greeting.end(); ++i ) { - Thread::delay( &t ); + this_thread::sleep( seconds( delay ) ); s << *i; s.flush(); (cout << *i).flush(); @@ -90,7 +75,7 @@ { try { Argv arg; - arg.copyright( "Copyright (C) K sky Lab, 2003" ); + arg.copyright( "Copyright (C) Petr Ovtchenkov 2003, 2008" ); arg.brief( "test for SMTP GW project" ); arg.option( "-h", false, "print this help message" ); arg.option( "-s", string( "" ), "host with SMTP GW server" ); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |