[Bug 16931] New: Compile broken in dlls/iphplpapi/ipstats.c on NetBSD

wine-bugs at winehq.org wine-bugs at winehq.org
Wed Jan 14 13:02:45 CST 2009


http://bugs.winehq.org/show_bug.cgi?id=16931

           Summary: Compile broken in dlls/iphplpapi/ipstats.c on NetBSD
           Product: Wine
           Version: 1.1.12
          Platform: PC
        OS/Version: NetBSD
            Status: NEW
          Keywords: patch, source
          Severity: blocker
          Priority: P2
         Component: build-env
        AssignedTo: wine-bugs at winehq.org
        ReportedBy: austinenglish at gmail.com


Created an attachment (id=18694)
 --> (http://bugs.winehq.org/attachment.cgi?id=18694)
ipstats patch

Similar to bug 16661, but not quite a duplicate:

If I apply the patch from bug 16661:

ccache gcc -c -I. -I. -I../../include -I../../include  -D__WINESRC__ 
-D_REENTRANT -fPIC -Wall -pipe -fno-strict-aliasing
-Wdeclaration-after-statement -Wwrite-strings -Wpointer-arith
-I/usr/pkg/include -I/usr/include -I/usr/pkg/include/freetype2
-I/usr/X11R6/include -O2 -I/usr/pkg/include -I/usr/include
-I/usr/pkg/include/freetype2 -I/usr/X11R6/include  -o ipstats.o ipstats.c
ipstats.c:32:25: error: sys/timeout.h: No such file or directory
In file included from ipstats.c:77:
/usr/include/netinet/tcp_var.h:194: error: field 'segq' has incomplete type
/usr/include/netinet/tcp_var.h:303: error: field 'timeq' has incomplete type
ipstats.c: In function 'getArpTable':
ipstats.c:1420: warning: array subscript has type 'char'
ipstats.c:1446: warning: array subscript has type 'char'
ipstats.c:1448: warning: array subscript has type 'char'
*** Error code 1

Stop.
make: stopped in /home/austin/wine-git/dlls/iphlpapi


After a bit of searching, seems that segq/timeq are:
struct ipqehead segq;           /* sequencing queue */
struct ipqehead timeq;          /* time sequenced queue. */

and struct ipqehead is defined inf /usr/include/netinet/ip_var.h:
TAILQ_HEAD(ipqehead, ipqent);
struct ipqent {
        TAILQ_ENTRY(ipqent) ipqe_q;
        union {
                struct ip       *_ip;
                struct tcpiphdr *_tcp;
        } _ipqe_u1;
        struct mbuf     *ipqe_m;        /* point to first mbuf */
        struct mbuf     *ipre_mlast;    /* point to last mbuf */
        u_int8_t        ipqe_mff;       /* for IP fragmentation */
        /*
         * The following are used in TCP reassembly
         */
        TAILQ_ENTRY(ipqent) ipqe_timeq;
        u_int32_t ipqe_seq;
        u_int32_t ipqe_len;

The attached patch, which is the patch from bug 16661, with #include tcp_var.h
moved after including ip_var.h, fixes it for me, but is obviously a hack.
Moving tcp_var after ip_var, however, may be fine, I need to test...


-- 
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
Do not reply to this email, post in Bugzilla using the
above URL to reply.
------- You are receiving this mail because: -------
You are watching all bug changes.



More information about the wine-bugs mailing list