Hello all, again!

net-snmp is compiled fine under freebsd. My errors are related to
cross-compiling and this topic is not for net-snmp list. I am sorry to post
them.

Good day!
Bye!

2010/1/21 Alexander Bubnov <[email protected]>

> Hello, all!
> Does everybody try to build net-snmp under freebsd? If so, Can you please
> help me?
>
> initial configure options are:
> ./configure --host=i686-pc-freebsd7.0 
> --with-sys-contact=a...@localhost--with-logfile=/home/alek/installed/var/log/snmpd.log
> --with-persistent-directory=/home/alek/installed/var/net-snmp
> --with-default-snmp-version=3 --with-sys-location=Unknown
> --disable-perl-cc-checks --disable-embedded-perl
>
> I have tried to build and I have got such errors:
>
> libtool: compile:  i686-pc-freebsd7.0-gcc -I../../include -I. -I../../agent
> -I../../agent/mibgroup -I../../snmplib -g -O2 -Ufreebsd7 -Dfreebsd7=freebsd7
> -c mibII/ipAddr.c  -fPIC -DPIC -o mibII/.libs/ipAddr.o
> mibII/ipAddr.c:153: warning: 'struct in_ifaddr' declared inside parameter
> list
> mibII/ipAddr.c:153: warning: its scope is only this definition or
> declaration, which is probably not what you want
> mibII/ipAddr.c: In function 'var_ipAddrEntry':
> mibII/ipAddr.c:198: error: storage size of 'in_ifaddr' isn't known
> mibII/ipAddr.c:198: error: storage size of 'lowin_ifaddr' isn't known
> mibII/ipAddr.c:232: error: 'interface' undeclared (first use in this
> function)
> mibII/ipAddr.c:232: error: (Each undeclared identifier is reported only
> once
> mibII/ipAddr.c:232: error: for each function it appears in.)
> mibII/ipAddr.c: In function 'Address_Scan_Next':
> mibII/ipAddr.c:376: error: argument 'Retin_ifaddr' doesn't match prototype
> mibII/ipAddr.c:153: error: prototype declaration
> mibII/ipAddr.c:377: error: storage size of 'in_ifaddr' isn't known
> mibII/ipAddr.c:393: error: dereferencing pointer to incomplete type
> mibII/ipAddr.c:406: error: 'struct ifnet' has no member named 'if_next'
> make[2]: *** [mibII/ipAddr.lo] Error 1
> make[2]: Leaving directory
> `/home/alek/download/1/net-snmp-5.5/agent/mibgroup'
> make[1]: *** [subdirs] Error 1
> make[1]: Leaving directory `/home/alek/download/1/net-snmp-5.5/agent'
> make: *** [subdirs] Error 1
>
>
> Below errors occur because netinet/in_var.h is not found by configure
> system:
>     mibII/ipAddr.c:153: warning: 'struct in_ifaddr' declared inside
> parameter list
>     mibII/ipAddr.c:153: warning: its scope is only this definition or
> declaration, which is probably not what you want
>     mibII/ipAddr.c: In function 'var_ipAddrEntry':
>     mibII/ipAddr.c:198: error: storage size of 'in_ifaddr' isn't known
>     mibII/ipAddr.c:198: error: storage size of 'lowin_ifaddr' isn't known
>
> see a part of config.log here:
>
> /usr/toolchain/i686-pc-freebsd7.0_gcc4.2.3_static/lib/gcc/i686-pc-freebsd7.0/4.2.3/../../../../i686-pc-freebsd7.0/sys-include/netinet/in_var.h:46:
> error: field 'ia_ifa' has incomplete type
> In file included from
> /usr/toolchain/i686-pc-freebsd7.0_gcc4.2.3_static/lib/gcc/i686-pc-freebsd7.0/4.2.3/../../../../i686-pc-freebsd7.0/sys-include/netinet/in_var.h:311,
>                  from conftest.c:214:
> /usr/toolchain/i686-pc-freebsd7.0_gcc4.2.3_static/lib/gcc/i686-pc-freebsd7.0/4.2.3/../../../../i686-pc-freebsd7.0/sys-include/netinet6/in6_var.h:99:
> error: field 'ia_ifa' has incomplete type
>
> in_var.h depends on some other header file... It is net/if_var.h, but it is
> not included to the test program by unknown reason. I have fixed it locally
> on my machine.
>
> But what about other errors?:
>
> /bin/bash ../../libtool  --mode=compile i686-pc-freebsd7.0-gcc
> -I../../include -I. -I../../agent -I../../agent/mibgroup -I../../snmplib
> -lgcc_s -Ufreebsd7 -Dfreebsd7=freebsd7  -c -o mibII/ipAddr.lo mibII/ipAddr.c
> libtool: compile:  i686-pc-freebsd7.0-gcc -I../../include -I. -I../../agent
> -I../../agent/mibgroup -I../../snmplib -lgcc_s -Ufreebsd7
> -Dfreebsd7=freebsd7 -c mibII/ipAddr.c  -fPIC -DPIC -o mibII/.libs/ipAddr.o
> mibII/ipAddr.c: In function 'var_ipAddrEntry':
> mibII/ipAddr.c:232: error: 'interface' undeclared (first use in this
> function)
> mibII/ipAddr.c:232: error: (Each undeclared identifier is reported only
> once
> mibII/ipAddr.c:232: error: for each function it appears in.)
> mibII/ipAddr.c: In function 'Address_Scan_Next':
> mibII/ipAddr.c:390: error: 'struct in_ifaddr' has no member named 'ia_next'
> mibII/ipAddr.c:406: error: 'struct ifnet' has no member named 'if_next'
> make[2]: *** [mibII/ipAddr.lo] Error 1
> make[2]: Leaving directory
> `/home/alek/download/net-snmp-5.5/agent/mibgroup'
> make[1]: *** [subdirs] Error 1
> make[1]: Leaving directory `/home/alek/download/net-snmp-5.5/agent'
> make: *** [subdirs] Error 1
>
>
> Or I am not in right way? Is there any path to compile net-snmp5.5 under
> freebsd? What should I do to compile net-snmp?
>
> Thank you in advance.
>
> --
> /BR, Alexander
>



-- 
/BR, Alexander
------------------------------------------------------------------------------
Throughout its 18-year history, RSA Conference consistently attracts the
world's best and brightest in the field, creating opportunities for Conference
attendees to learn about information security's most important issues through
interactions with peers, luminaries and emerging and established companies.
http://p.sf.net/sfu/rsaconf-dev2dev
_______________________________________________
Net-snmp-users mailing list
[email protected]
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to