[netperf-dev] compile failed with SCTP tests
Hushan Jia
hushan.jia at gmail.com
Sat Apr 16 00:44:09 PDT 2011
On Sat, Apr 16, 2011 at 1:34 AM, Rick Jones <rick.jones2 at hp.com> wrote:
> On Fri, 2011-04-15 at 18:25 +0800, Hushan Jia wrote:
>
>
>> checking whether to include ICSC-EXS tests... no
>> checking for netinet/sctp.h... yes
>> checking for main in -lsctp... yes
>> ...
>> if gcc -DHAVE_CONFIG_H -I. -I. -I.. -g -O2 -MT nettest_bsd.o -MD
>> -MP -MF ".deps/nettest_bsd.Tpo" \
>> -c -o nettest_bsd.o `test -f 'nettest_bsd.c' || echo './'`nettest_bsd.c; \
>> then mv -f ".deps/nettest_bsd.Tpo" ".deps/nettest_bsd.Po"; \
>> else rm -f ".deps/nettest_bsd.Tpo"; exit 1; \
>> fi
>> In file included from nettest_bsd.c:108:
>> /usr/include/netinet/in.h:86: error: expected identifier before numeric constant
>
> An error in a provided include file does not bode well for things
> progressing happily after that.
>
> Is there a define of IPPROTO_SCTP in netinet/sctp.h ? I believe that
> the 2.4.5 version of netperf will include netinet/sctp.h before
> netinet/in.h . The top-of-trunk version has the include of
> netinet/sctp.h after, and I doubt I or someone else made that change on
> a whim :)
>
> rick jones
Thanks Rick, move netinet/sctp.h after resolves the issue.
>
>> nettest_bsd.c: In function ‘protocol_to_str’:
>> nettest_bsd.c:580: error: ‘IPPROTO_SCTP’ undeclared (first use in this function)
>> nettest_bsd.c:580: error: (Each undeclared identifier is reported only once
>> nettest_bsd.c:580: error: for each function it appears in.)
>> nettest_bsd.c: In function ‘complete_addrinfo’:
>> nettest_bsd.c:735: error: ‘IPPROTO_SCTP’ undeclared (first use in this function)
>> nettest_bsd.c: In function ‘create_data_socket’:
>> nettest_bsd.c:1252: error: ‘IPPROTO_SCTP’ undeclared (first use in
>> this function)
>> make[3]: *** [nettest_bsd.o] Error 1
>> make[3]: Leaving directory `/home/program/net/netperf-2.4.5/src'
>> make[2]: *** [all-recursive] Error 1
>> make[2]: Leaving directory `/home/program/net/netperf-2.4.5/src'
>> make[1]: *** [all-recursive] Error 1
>> make[1]: Leaving directory `/home/program/net/netperf-2.4.5'
>> make: *** [all] Error 2
>>
>> in in.h, it IPPROTO_SCTP is defined as a member of enum.
>>
>
>
>
--
Thanks & Regards,
Hushan Jia
More information about the netperf-dev
mailing list