OpenPKG CVS Repository
  http://cvs.openpkg.org/
  ____________________________________________________________________________

  Server: cvs.openpkg.org                  Name:   Ralf S. Engelschall
  Root:   /v/openpkg/cvs                   Email:  [EMAIL PROTECTED]
  Module: openpkg-src                      Date:   01-Dec-2006 14:06:30
  Branch: HEAD                             Handle: 2006120113063000

  Modified files:
    openpkg-src/flowtools   flowtools.patch flowtools.spec

  Log:
    fix tracking of flow-extract and upgrade to latest version

  Summary:
    Revision    Changes     Path
    1.15        +29 -45     openpkg-src/flowtools/flowtools.patch
    1.27        +8  -8      openpkg-src/flowtools/flowtools.spec
  ____________________________________________________________________________

  patch -p0 <<'@@ .'
  Index: openpkg-src/flowtools/flowtools.patch
  ============================================================================
  $ cvs diff -u -r1.14 -r1.15 flowtools.patch
  --- openpkg-src/flowtools/flowtools.patch     9 Oct 2006 08:02:04 -0000       
1.14
  +++ openpkg-src/flowtools/flowtools.patch     1 Dec 2006 13:06:30 -0000       
1.15
  @@ -265,9 +265,9 @@
    
    #endif /* IP_ADD_MEMBERSHIP */
    
  -Index: flowextract-2.5/grammar.y
  ---- flowextract-2.5/grammar.y.orig   2003-04-28 20:22:02 +0200
  -+++ flowextract-2.5/grammar.y        2005-05-15 19:45:32 +0200
  +Index: flow-extract/grammar.y
  +--- flow-extract/grammar.y.orig      2006-11-29 16:55:44 +0100
  ++++ flow-extract/grammar.y   2006-12-01 14:01:56 +0100
   @@ -25,6 +25,9 @@
    #include "timesub.h"
    #include "stdunix.h"
  @@ -278,11 +278,13 @@
    extern int parse_error;
    #define TCPDATA 6
    #define UDPDATA 17
  -@@ -1159,10 +1162,10 @@
  +@@ -1159,15 +1162,15 @@
  +      { (char *)0, 0 }
         };
    
  - void
  +-int
   -yyerror()
  ++void
   +yyerror(char *msg)
    {
   -     fprintf(stderr, "\"%s\", line %d: syntax error.\n",
  @@ -292,10 +294,15 @@
         parse_error = 1;
    }
    
  -Index: flowextract-2.5/hosts.c
  ---- flowextract-2.5/hosts.c.orig     2003-04-28 20:22:02 +0200
  -+++ flowextract-2.5/hosts.c  2005-05-15 19:45:32 +0200
  -@@ -24,7 +24,7 @@
  +-int
  ++unsigned long
  + getmask(unsigned long addr)
  + {
  +      if(IN_CLASSA(addr))
  +Index: flow-extract/hosts.c
  +--- flow-extract/hosts.c.orig        2006-11-28 17:28:54 +0100
  ++++ flow-extract/hosts.c     2006-12-01 13:56:18 +0100
  +@@ -23,7 +23,7 @@
    static int hnc_init = 0;
    static unsigned long hit = 0, miss = 0, coll = 0;
    
  @@ -304,56 +311,33 @@
    {
         printf("Hit/Miss: %lu/%lu, Collisions: %lu\n",
            hit, miss,coll);
  -Index: flowextract-2.5/interp.c
  ---- flowextract-2.5/interp.c.orig    2003-04-28 20:22:02 +0200
  -+++ flowextract-2.5/interp.c 2005-05-15 19:45:32 +0200
  -@@ -9,6 +9,7 @@
  - */
  - #include <stdio.h>
  - #include <sys/types.h>
  -+#include <time.h>
  - #include <sys/time.h>
  - #include <ftlib.h>
  - #include "extract.h"
  -@@ -107,9 +108,11 @@
  +Index: flow-extract/interp.c
  +--- flow-extract/interp.c.orig       2006-11-28 18:24:39 +0100
  ++++ flow-extract/interp.c    2006-12-01 13:56:18 +0100
  +@@ -108,10 +108,11 @@
                   break;
          case TIME:
               if(!rectime){
  -+            time_t t;
  ++                time_t t;
                        ftt = ftltime(genrec->sysUpTime, genrec->unix_secs,
                                      genrec->unix_nsecs, genrec->First);
  --                tmb = localtime(&ftt.secs);
  -+            t = (time_t)ftt.secs;
  +-                /* tmb = localtime(&ftt.secs); */
  +-                tmb = localtime((time_t *)(&ftt.secs));
  ++                t = (time_t)ftt.secs;
   +                tmb = localtime(&t);
                    rectime = tmb->tm_hour*3600 + tmb->tm_min*60 + tmb->tm_sec;
               }
               return rectime;
  -Index: flowextract-2.5/timesub.c
  ---- flowextract-2.5/timesub.c.orig   2003-04-28 20:22:02 +0200
  -+++ flowextract-2.5/timesub.c        2005-05-15 19:45:32 +0200
  -@@ -8,6 +8,7 @@
  - 
  - */
  - #include <sys/types.h>
  -+#include <time.h>
  - #include <sys/time.h>
  - #include "timesub.h"
  - 
  -Index: flowextract-2.5/timeval.c
  ---- flowextract-2.5/timeval.c.orig   2003-04-28 20:22:02 +0200
  -+++ flowextract-2.5/timeval.c        2005-05-15 19:45:32 +0200
  -@@ -1,3 +1,4 @@
  -+#include <time.h>
  - #include <sys/time.h>
  - #include <ftlib.h>
  - 
  -@@ -6,8 +7,10 @@
  +Index: flow-extract/timeval.c
  +--- flow-extract/timeval.c.orig      2006-11-28 19:36:11 +0100
  ++++ flow-extract/timeval.c   2006-12-01 13:56:18 +0100
  +@@ -7,8 +7,10 @@
    {
         struct tm *tm;
         static char buf[50];
   +     time_t t;
    
  --     tm = localtime(&tp.secs);
  +-     tm = localtime((time_t *)(&tp.secs));
   +     t = (time_t)tp.secs;
   +     tm = localtime(&t);
    
  @@ .
  patch -p0 <<'@@ .'
  Index: openpkg-src/flowtools/flowtools.spec
  ============================================================================
  $ cvs diff -u -r1.26 -r1.27 flowtools.spec
  --- openpkg-src/flowtools/flowtools.spec      13 Oct 2006 17:28:03 -0000      
1.26
  +++ openpkg-src/flowtools/flowtools.spec      1 Dec 2006 13:06:30 -0000       
1.27
  @@ -24,7 +24,7 @@
   
   #   package versions
   %define       V_flowtools   0.68
  -%define       V_flowextract 2.5
  +%define       V_flowextract 2.61
   %define       V_cflow       1.053
   
   #   package information
  @@ -38,7 +38,7 @@
   Group:        Auditing
   License:      BSD
   Version:      %{V_flowtools}
  -Release:      20061013
  +Release:      20061201
   
   #   package options
   %option       with_fsl   yes
  @@ -48,7 +48,7 @@
   
   #   list of sources
   Source0:      
ftp://ftp.eng.oar.net/pub/flow-tools/flow-tools-%{V_flowtools}.tar.gz
  -Source1:      
http://security.uchicago.edu/tools/net-forensics/files/flowextract-%{V_flowextract}.cpio.gz
  +Source1:      
http://security.uchicago.edu/tools/net-forensics/files/flow-extract-%{V_flowextract}.tar.gz
   Source2:      http://net.doit.wisc.edu/~plonka/Cflow/Cflow-%{V_cflow}.tar.gz
   Source3:      rc.flowtools
   Source4:      fsl.flowtools
  @@ -57,7 +57,7 @@
   #   build information
   Prefix:       %{l_prefix}
   BuildRoot:    %{l_buildroot}
  -BuildPreReq:  OpenPKG, openpkg >= 20060823, cpio, flex, bison
  +BuildPreReq:  OpenPKG, openpkg >= 20060823, flex, bison
   PreReq:       OpenPKG, openpkg >= 20060823
   BuildPreReq:  zlib
   PreReq:       zlib
  @@ -99,7 +99,7 @@
       prog flowtools:flowextract = {
           version   = %{V_flowextract}
           url       = http://security.uchicago.edu/tools/net-forensics/
  -        regex     = flowextract-(__VER__)\.cpio\.gz
  +        regex     = flow-extract-(__VER__)\.tar\.gz
       }
       prog flowtools:Cflow = {
           version   = %{V_cflow}
  @@ -109,7 +109,7 @@
   
   %prep
       %setup -q -c
  -    %{l_gzip} -d -c %{SOURCE1} | %{l_prefix}/bin/cpio -idmu
  +    %setup -q -D -T -a 1
       %setup -q -D -T -a 2
       %patch -p0
   
  @@ -151,7 +151,7 @@
       ) || exit $?
   
       #   build flow-extract addon
  -    ( cd flowextract-%{V_flowextract}
  +    ( cd flow-extract
         INCLUDES="-I../flow-tools-%{V_flowtools}/lib %{l_cppflags}"
         LIBS="-L../flow-tools-%{V_flowtools}/lib %{l_ldflags} -lft -lz"
         case "%{l_platform -t}" in
  @@ -184,7 +184,7 @@
       ) || exit $?
   
       #   install flow-extract addon
  -    ( cd flowextract-%{V_flowextract}
  +    ( cd flow-extract
         %{l_shtool} install -c -s -m 755 \
             flow-extract $RPM_BUILD_ROOT%{l_prefix}/bin/
         %{l_shtool} install -c -m 644 \
  @@ .
______________________________________________________________________
The OpenPKG Project                                    www.openpkg.org
CVS Repository Commit List                     [email protected]

Reply via email to