Ok I am using the "-x none" as the --with-ldflags option and I have applied the
patches to the Makefile.in files as you have recommended. The "error stray"
errors are now gone, but I am now receiving the following linker errors:
/bin/sh ../libtool --mode=compile mipsel-uclibc-g++ -I../include
-I/export/home/rosent1/vegasCC/1.97/buildsys/A506/netsnmp/include -I.
-I../agent -I/export/home/rosent1/vegasCC/1.97/buildsys/A506/netsnmp/agent
-I../agent/mibgroup
-I/export/home/rosent1/vegasCC/1.97/buildsys/A506/netsnmp/agent/mibgroup
-I../snmplib -I/export/home/rosent1/vegasCC/1.97/buildsys/A506/netsnmp/snmplib
-x c -Ulocalhost -Dlocalhost=localhost -c -o snmpd.lo snmpd.c
mipsel-uclibc-g++ -I../include
-I/export/home/rosent1/vegasCC/1.97/buildsys/A506/netsnmp/include -I.
-I../agent -I/export/home/rosent1/vegasCC/1.97/buildsys/A506/netsnmp/agent
-I../agent/mibgroup
-I/export/home/rosent1/vegasCC/1.97/buildsys/A506/netsnmp/agent/mibgroup
-I../snmplib -I/export/home/rosent1/vegasCC/1.97/buildsys/A506/netsnmp/snmplib
-x c -Ulocalhost -Dlocalhost=localhost -c snmpd.c -o snmpd.o
snmpd.c: In function `main':
snmpd.c:948: warning: assignment discards qualifiers from pointer target type
/bin/sh ../libtool --mode=link mipsel-uclibc-g++ -x c -Ulocalhost
-Dlocalhost=localhost -x none -o snmpd snmpd.lo libnetsnmpmibs.la
libnetsnmpagent.la helpers/libnetsnmphelpers.la ../snmplib/libnetsnmp.la -ldl
-lm
mipsel-uclibc-g++ -x c -Ulocalhost -Dlocalhost=localhost -x none -o snmpd
snmpd.o ./.libs/libnetsnmpmibs.a ./.libs/libnetsnmpagent.a
helpers/.libs/libnetsnmphelpers.a ../snmplib/.libs/libnetsnmp.a -ldl -lm
./.libs/libnetsnmpmibs.a(at.o): In function `ARP_Scan_Init':
mibgroup/mibII/at.c:(.text+0xe30): undefined reference to
`netsnmp_access_interface_index_find'
./.libs/libnetsnmpmibs.a(interfaces.o): In function `getIfSpeed':
mibgroup/mibII/interfaces.c:(.text+0x130c): undefined reference to
`netsnmp_linux_interface_get_if_speed'
./.libs/libnetsnmpmibs.a(ipAddr.o): In function `Address_Scan_Next':
mibgroup/mibII/ipAddr.c:(.text+0xe68): undefined reference to
`netsnmp_access_interface_index_find'
./.libs/libnetsnmpmibs.a(var_route.o): In function `Route_Scan_Reload':
mibgroup/mibII/var_route.c:(.text+0xea4): undefined reference to
`netsnmp_access_interface_index_find'
./.libs/libnetsnmpmibs.a(arp_linux.o): In function `_load_v4':
mibgroup/ip-mib/data_access/arp_linux.c:(.text+0x574): undefined reference to
`netsnmp_access_interface_index_find'
./.libs/libnetsnmpmibs.a(route_linux.o): In function `_load_ipv4':
mibgroup/ip-forward-mib/data_access/route_linux.c:(.text+0x5b0): undefined
reference to `netsnmp_access_interface_ioctl_ifindex_get'
./.libs/libnetsnmpmibs.a(ipaddress_ioctl.o): In function
`_netsnmp_ioctl_ipaddress_container_load_v4':
mibgroup/ip-mib/data_access/ipaddress_ioctl.c:(.text+0xb10): undefined
reference to `netsnmp_access_interface_ioctl_ifindex_get'
collect2: ld returned 1 exit status
make[2]: *** [snmpd] Error 1
make[2]: Leaving directory
`/export/home/rosent1/vegasCC/1.97/buildsys/A506/netsnmp/agent'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory
`/export/home/rosent1/vegasCC/1.97/buildsys/A506/netsnmp'
make: *** [net-snmp-make] Error 2
Any ideas what these could be?
Magnus Fromreide <[EMAIL PROTECTED]> wrote: On Fri, Jun 29, 2007 at 09:17:59AM
+0100, Dave Shield wrote:
> On 28/06/07, Need Help wrote:
> > 3) We also noticed this interesting bit as well. We started from scratch
> > by uncompressing Net-SNMP-v5.4 and then performed a "./configure" (with the
> > options shown in the post below). We then looked into the "config.log" file
> > and noticed the same type errors were seen (see below), so we get these
> > errors before doing a "make" at all:
> >
> > part of the "config.log" file:
> >
> > configure:7263: mipsel-uclibc-g++ -o conftest -x c conftest.c conftstm.o
> > >&5
> > conftstm.o:1: error: stray '\177' in program
> > conftstm.o:1: error: stray '\1' in program
>
> > Any ideas what is goign on here? Any recommendations you can make for our
> > build team here to look into? We are using the "mips-uclibc-g++" compiler
> > so perhaps this could be a problem?
>
> That's certainly my immediate reaction.
In a way it is true, but the main problem is that he tries to use a
C++ compiler to build C source.
Consider a classic hello.c.
This gives a working binary:
g++ -x c hello.c
This gives similar errors to NeedHelps:
g++ -x c -c hello.c
g++ -x c hello.o
The problem is that in the link step you tell the compiler to treat hello.o as
a C file. That fails.
I have already given NeedHelp a solution/workaround in the thread
"Configure "-x c" options with "--with-cflags" does not work for me."
/MF
---------------------------------
We won't tell. Get more on shows you hate to love
(and love to hate): Yahoo! TV's Guilty Pleasures list.
---------------------------------
Don't be flakey. Get Yahoo! Mail for Mobile and
always stay connected to friends.
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders