Hi every body,

i am Yassine, i am student and i am writing an application that uses tcprewrite 
and tcpreplay what i have done till now is a system call for these 2 binaries  
system("tcpreplay...")
but this method is not sufficient for me (not efficient: the processing time is 
very important for my application and i want not lost time with this system 
calls, and another reason is that's not elegant too).
so instead of going through the source code (which is huge) to take only what i 
need, i thought that creating a static library will be more better.
but unfortunately i could not do it 
what i have done is: 

!/bin/sh
AR="ar"
ARFLAGS="cru"
libtcprewrite_a_AR="$AR $ARFLAGS"
libtcpreplay_a_AR="$AR $ARFLAGS"
libtcprewrite_a_LIBADD=
libtcpreplay_a_LIBADD=
LIBTOOL="libtool"
RANLIB="ranlib"
OBJEXT=" o"

am_libtcprewrite_a_OBJECTS="tcpreplay-tcpreplay.o \
    tcprewrite-tcprewrite_opts.o"

am_libtcpreplay_a_OBJECTS="tcpreplay-send_packets.o \
    tcpreplay-signal_handler.o \
    tcpreplay-sleep.o \
    tcpreplay-tcpreplay_opts.o"

libtcprewrite_a_OBJECTS="$am_libtcprewrite_a_OBJECTS"
libtcpreplay_a_OBJECTS="$am_libtcpreplay_a_OBJECTS"

rm -f libtcprewrite.a
rm -f libtcpreplay.a

$libtcprewrite_a_AR libtcprewrite.a $libtcprewrite_a_OBJECTS 
$libtcprewrite_a_LIBADD
$RANLIB libtcprewrite.a
$libtcpreplay_a_AR libtcpreplay.a $libtcpreplay_a_OBJECTS $libtcpreplay_a_LIBADD
$RANLIB libtcpreplay.a 

and i have rewrite the main of tcpreplay in my application as a function that i 
will use it there (i thought that i have added all headers files and libraries 
that i need  libopts.a libcommon.a libsrtl.a libtcpreplay.a ...) 
but i failed to do it.

so if somebody have an idea or can give me a tip i will be very grateful. i 
hope that i get a quick answer :)
and sorry for my english :D 
 
Thanks!!!

cheers,
Yassine

_________________________________________________________________
Partagez vos souvenirs sur le Web avec les personnes de votre choix.
http://www.microsoft.com/northafrica/windows/windowslive/products/photos-share.aspx?tab=1
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Tcpreplay-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tcpreplay-users
Support Information: http://tcpreplay.synfin.net/trac/wiki/Support

Reply via email to