I don't use IPV6, so I removed this feature from my DISTRO_FEATURES.
This results in a mangled code in crypto/bio/bss_dgram.c.

The sed command in openssl.inc:

        eval "${@base_contains('DISTRO_FEATURES', 'ipv6', '', 'sed -i -e
"/AF_INET6/,/break/d" ${S}/crypto/bio/bss_dgram.c', d)}"

cuts out following needed code:

bss_dgram.c
>>>>>>
line 344
                else if (data->peer.sa.sa_family == AF_INET6)
                        peerlen = sizeof(data->peer.sa_in6);
#endif
#if defined(NETWARE_CLIB) && defined(NETWARE_BSDSOCK)
                ret=sendto(b->num, (char *)in, inl, 0, &data->peer.sa,
peerlen);
#else
                ret=sendto(b->num, in, inl, 0, &data->peer.sa, peerlen);
#endif
                }

        BIO_clear_retry_flags(b);
        if (ret <= 0)
                {
                if (BIO_dgram_should_retry(ret))
                        {
                        BIO_set_retry_write(b);  
                        data->_errno = get_last_socket_error();

#if 0 /* higher layers are responsible for querying MTU, if necessary */
                        if ( data->_errno == EMSGSIZE)
                                /* retrieve the new MTU */
                                BIO_ctrl(b, BIO_CTRL_DGRAM_QUERY_MTU, 0,
NULL);
#endif
                        }
                }
        return(ret);
        }

static long dgram_ctrl(BIO *b, int cmd, long num, void *ptr)
        {
        long ret=1;
        int *ip;
        struct sockaddr *to = NULL;
        bio_dgram_data *data = NULL;
#if defined(IP_MTU_DISCOVER) || defined(IP_MTU)
        long sockopt_val = 0;
        unsigned int sockopt_len = 0;
#endif
#ifdef OPENSSL_SYS_LINUX
        socklen_t addr_len;
        union   {
                struct sockaddr sa;
                struct sockaddr_in s4;
#if OPENSSL_USE_IPV6
                struct sockaddr_in6 s6;
#endif
                } addr;
#endif

        data = (bio_dgram_data *)b->ptr;

        switch (cmd)
                {
        case BIO_CTRL_RESET:
                num=0;
        case BIO_C_FILE_SEEK:
                ret=0;
                break;
<<<<

do it with sed is strange, but it may be better to use:

   eval "${@base_contains('DISTRO_FEATURES', 'ipv6', '', 'sed -i -e
"/case AF_INET6:/,/break/d" ${S}/crypto/bio/bss_dgram.c', d)}"

May be doing it witch a patch or disable OPENSSL_USE_IPV6 in configure
is the saver solution.

I use the tar ball of 2011.03 release, so I am not able to create a
proper patch from git.

Regards Wolfgang

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel

Reply via email to