[Cflowd] Redhat Linux 8.0 Compile Issues: Resolved

From: Rockwell, John (jrockwell@ChoiceOneCom.Com)
Date: Tue Dec 10 2002 - 15:26:15 PST

  • Next message: gab jones: "Re: [Cflowd] Redhat Linux 8.0 Compile Issues: Resolved"

        It has long been a pet peeve of mine that when people ask a question on
    a mailing list and figure out the answer to that question that they post the
    answer to benefit the rest of us... so here goes...
     
        There were a number of twists and turns in resolving my arts++ and
    cflowd compile issues... Not all of these steps may be necessary, but
    they're the ones that I used.
     
     
    Compiler Issues:
        
        It seems that gcc-3.x simply does not like to compile arts++ or cflowd
    (at least not under my configuration), so I went ahead and installed a copy
    of gcc-2.95.3. An excellent FAQ on how to run multiple revisions of gcc
    concurrently can be found at ...
     
    http://gcc.gnu.org/faq.html#multiple <http://gcc.gnu.org/faq.html#multiple>
     
        I tried using the program-suffix method, but in the end the
    --prefix=/usr/local/gcc2 solution worked best for me. Since I had a
    pre-installed copy of gcc-3.x I simply searched out all copies of gcc, g++,
    c++, and g77, mv'ed them over to another filename, and added symbolic links
    in their place pointing to the corresponding 2.95.3 versions of those
    applications (/usr/local/gcc2/bin/...). Use 'gcc --version' to be sure that
    you're running the correct version. If at some point you need to use
    gcc-3.x as your compiler, simply rm those symlinks and copy the old files
    back over.
     
     
    Flex Issues:
     
        It seems that something about flex2.5.4a is broken and requires patching
    in order for arts++/cflowd to be installed properly. That patch can be
    found at ...
     
    http://pkgcvs.turbolinux.co.jp/cgi-bin/cvsweb.cgi/flex/2.5.4a/flex-2.5.4a-gc
    c31.patch#rev1.2
    <http://pkgcvs.turbolinux.co.jp/cgi-bin/cvsweb.cgi/flex/2.5.4a/flex-2.5.4a-g
    cc31.patch#rev1.2>
     
        However, I did run into a bit of a snag when it attempted to patch
    skel.c, and that hunk was rejected. I manually added that hunk of the
    patch. The patched section of skel.c looks like (everything after "%+", is
    new) ...
     
      "#include <stdlib.h>",
      "%+",
      "#include <iostream>",
      "using namespace std;",
     
        I also had to copy FlexLexer.h from /usr/local/include to /usr/include
    once the install was complete.
     
     
        Frome there I installed Dave Plonka's cflowd patch so that I could run
    FlowScan on the generated flows ...
     
    http://net.doit.wisc.edu/~plonka/cflowd/?M=D
    <http://net.doit.wisc.edu/~plonka/cflowd/?M=D>
     
        Everything from there on went pretty smoothly... Dave's FlowScan
    Install FAQ was of great assistance along the way as it touches upon the
    install of all of the required packages...
     
    http://net.doit.wisc.edu/~plonka/FlowScan/INSTALL.html
    <http://net.doit.wisc.edu/~plonka/FlowScan/INSTALL.html>
     
     
        Hope this saves someone a bit of hairloss...
     
     
    John E. Rockwell
    Network Engineer, Data Level II Operations
    Choice One Communications
    100 Chestnut Street
    Rochester, New York 14604
    585-697-2162 (Office)
    585-452-3604 (Pager)
     
     
     
     
     

    -----Original Message-----
    From: Rockwell, John
    Sent: Friday, December 06, 2002 5:00 PM
    To: ' cflowd@caida <mailto:cflowd@caida.org'> .org'
    Cc: 'jrockwel@rochester.rr.com'
    Subject: Compile Issue: Can't compile cflowd

        I'm currently experiencing an issue compiling cflowd. I've also tried
    compiling after patching with cflowd-2-1-b1-djp.patch, but that yields the
    same results. arts++ installation was similarly miserable, but I was able
    to install the binary distribution. The binary distribution for cflowd also
    works fine, but won't allow me to run flowscan.
     
     
    Configure runs fine.
     
    Here's what I get from 'make':
     
    [root@demon cflowd-2-1-b1]# make
    cd snmp++; make
    make[1]: Entering directory `/home/cflowd/cflowd-2-1-b1/snmp++'
    cd classes; make
    make[2]: Entering directory `/home/cflowd/cflowd-2-1-b1/snmp++/classes'
    cd src; make
    make[3]: Entering directory `/home/cflowd/cflowd-2-1-b1/snmp++/classes/src'
    g++ -D__unix__ -I../include/snmp++ -I./ -g -O2 -c oid.cpp -o oid.o
    In file included from /usr/include/c++/3.2/backward/iostream.h:31,
                     from ../include/snmp++/smival.h:49,
                     from ../include/snmp++/oid.h:62,
                     from oid.cpp:59:
    /usr/include/c++/3.2/backward/backward_warning.h:32:2: warning: #warning
    This file
     includes at least one deprecated or antiquated header. Please consider
    using one
    of the 32 headers found in section 17.4.1.2 of the C++ standard. Examples
    include
    substituting the <X> header for the <X.h> header for C++ includes, or
    <sstream> in
    stead of the deprecated header <strstream.h>. To disable this warning use
    -Wno-dep
    recated.
    In file included from oid.cpp:59:
    ../include/snmp++/oid.h:181: `vector' was not declared in this scope
    ../include/snmp++/oid.h:181: parse error before `>' token
    oid.cpp:503: `vector' was not declared in this scope
    id.cpp:503: parse error before `>' token
    oid.cpp: In member function `void Oid::get_oid(...) const':
    oid.cpp:505: `outVect' undeclared (first use this function)
    oid.cpp:505: (Each undeclared identifier is reported only once for each
       function it appears in.)
    make[3]: *** [oid.lo] Error 1
    make[3]: Leaving directory `/home/cflowd/cflowd-2-1-b1/snmp++/classes/src'
    make[2]: *** [all] Error 2
    make[2]: Leaving directory `/home/cflowd/cflowd-2-1-b1/snmp++/classes'
    make[1]: *** [classes/lib/libsnmp++.a] Error 2
    make[1]: Leaving directory `/home/cflowd/cflowd-2-1-b1/snmp++'
    make: *** [all] Error 2
     
     
    System Information:
     
    [root@demon cflowd-2-1-b1]# uname -a
    Linux demon 2.4.18-14 #1 Wed Sep 4 13:35:50 EDT 2002 i686 i686 i386
    GNU/Linux
     
    [root@demon cflowd-2-1-b1]# gcc --version
    gcc (GCC) 3.2 20020903 (Red Hat Linux 8.0 3.2-7)

     
    [root@demon cflowd-2-1-b1]# flex --version
    flex version 2.5.4
     
    [root@demon cflowd-2-1-b1]# bison --version
    bison (GNU Bison) 1.35
     
    arts++-1-1-a8 installed
     
        I scoured the archives and found a person who was experiencing a similar
    issue, but the solution provided was to update gcc. As you can see, I'm
    running a pretty recent version of gcc.
    http://www.caida.org/dynamic/archives/cflowd/0621.html
    <http://www.caida.org/dynamic/archives/cflowd/0621.html>
     
        Any help would be greatly appreciated!
     
     
    P.S. Please reply to all as I'm not currently subscribed to this mailing
    list.
     
     
     
    John E. Rockwell
    Network Engineer, Data Level II Operations
    Choice One Communications
    100 Chestnut Street
    Rochester, New York 14604
    585-697-2162 (Office)
    585-452-3604 (Pager)
     

    _______________________________________________
    Cflowd mailing list
    Cflowd@caida.org
    http://login.caida.org/mailman/listinfo/cflowd



    This archive was generated by hypermail 2.1.4 : Tue Dec 10 2002 - 15:31:17 PST