Please log in first.

Clear message

    PaulHowarth/Blog/2012-05-29

Tuesday 29th May 2012

Local Packages

  • Updated ppp to fix ppp-2.4.5-eaptls-mppe-0.99 patch (Bug #817011), and noticed the re-appearance in Rawhide of a similar error to one I'd fixed back in 2010:

  • make[2]: Entering directory `/builddir/build/BUILD/ppp-2.4.5/pppd/plugins/rp-pppoe'
    cc -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4  -m64 -mtune=generic -fPIC -Wall -I../../../include '-DRP_VERSION="3.8p"' -I../../.. -c -o plugin.o -fPIC plugin.c
    In file included from plugin.c:53:0:
    /usr/include/linux/if_pppox.h:84:26: error: field 'pppol2tp' has incomplete type
    /usr/include/linux/if_pppox.h:99:28: error: field 'pppol2tp' has incomplete type
    make[2]: *** [plugin.o] Error 1
  • It appears that some further structure definitions are needed in include/linux/if_pppol2tp.h for IPv6 support, so I updated the patch:

  • --- ppp-2.4.5/include/linux/if_pppol2tp.h
    +++ ppp-2.4.5/include/linux/if_pppol2tp.h
    @@ -32,6 +32,45 @@
            __u16 d_tunnel, d_session;      /* For sending outgoing packets */
     };
     
    +/* Structure used to connect() the socket to a particular tunnel UDP
    + *  * socket over IPv6.
    + *   */
    +struct pppol2tpin6_addr {
    +       __kernel_pid_t  pid;            /* pid that owns the fd.
    +                                        * 0 => current */
    +       int     fd;                     /* FD of UDP socket to use */
    +
    +       __u16 s_tunnel, s_session;      /* For matching incoming packets */
    +       __u16 d_tunnel, d_session;      /* For sending outgoing packets */
    +
    +       struct sockaddr_in6 addr;       /* IP address and port to send to */
    +};
    +
    +/* The L2TPv3 protocol changes tunnel and session ids from 16 to 32
    + * bits. So we need a different sockaddr structure.
    + */
    +struct pppol2tpv3_addr {
    +       pid_t   pid;                    /* pid that owns the fd.
    +                                        * 0 => current */
    +       int     fd;                     /* FD of UDP or IP socket to use */
    +
    +       struct sockaddr_in addr;        /* IP address and port to send to */
    +
    +       __u32 s_tunnel, s_session;      /* For matching incoming packets */
    +       __u32 d_tunnel, d_session;      /* For sending outgoing packets */
    +};
    +
    +struct pppol2tpv3in6_addr {
    +       __kernel_pid_t  pid;            /* pid that owns the fd.
    +                                        * 0 => current */
    +       int     fd;                     /* FD of UDP or IP socket to use */
    +
    +       __u32 s_tunnel, s_session;      /* For matching incoming packets */
    +       __u32 d_tunnel, d_session;      /* For sending outgoing packets */
    +
    +       struct sockaddr_in6 addr;       /* IP address and port to send to */
    +};
    +
     /* Socket options:
      * DEBUG       - bitmask of debug message categories
      * SENDSEQ     - 0 => don't send packets with sequence numbers
  • And with that, it all built again :-)


Recent