Re: OpenSSL 1.1 breaks configure and more

Поиск
Список
Период
Сортировка
Искать
От
Alvaro Herrera
Тема
Re: OpenSSL 1.1 breaks configure and more
Дата
Msg-id
20160702002846.GA376611@alvherre.pgsql
Ответ на
Список
Дерево обсуждения
OpenSSL 1.1 breaks configure and more Christoph Berg <myon@debian.org>
Re: OpenSSL 1.1 breaks configure and more Tom Lane <tgl@sss.pgh.pa.us>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Christoph Berg <myon@debian.org>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Michael Paquier <michael.paquier@gmail.com>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Christoph Berg <myon@debian.org>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Alvaro Herrera <alvherre@2ndquadrant.com>
Re: OpenSSL 1.1 breaks configure and more Christoph Berg <myon@debian.org>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Victor Wagner <vitus@wagner.pp.ru>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Heikki Linnakangas <hlinnaka@iki.fi>
Re: OpenSSL 1.1 breaks configure and more Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
Re: OpenSSL 1.1 breaks configure and more Tom Lane <tgl@sss.pgh.pa.us>
Re: OpenSSL 1.1 breaks configure and more Heikki Linnakangas <hlinnaka@iki.fi>
Re: OpenSSL 1.1 breaks configure and more Tom Lane <tgl@sss.pgh.pa.us>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
Re: OpenSSL 1.1 breaks configure and more Heikki Linnakangas <hlinnaka@iki.fi>
Re: OpenSSL 1.1 breaks configure and more Heikki Linnakangas <hlinnaka@iki.fi>
Re: OpenSSL 1.1 breaks configure and more Tom Lane <tgl@sss.pgh.pa.us>
Re: OpenSSL 1.1 breaks configure and more Rémi Zara <remi_zara@mac.com>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Michael Paquier <michael.paquier@gmail.com>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Heikki Linnakangas <hlinnaka@iki.fi>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Tom Lane <tgl@sss.pgh.pa.us>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Michael Paquier <michael.paquier@gmail.com>
Re: OpenSSL 1.1 breaks configure and more Heikki Linnakangas <hlinnaka@iki.fi>
Re: OpenSSL 1.1 breaks configure and more Heikki Linnakangas <hlinnaka@iki.fi>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Heikki Linnakangas <hlinnaka@iki.fi>
Re: OpenSSL 1.1 breaks configure and more Michael Paquier <michael.paquier@gmail.com>
Re: OpenSSL 1.1 breaks configure and more Christoph Berg <myon@debian.org>
Re: OpenSSL 1.1 breaks configure and more Alvaro Herrera <alvherre@2ndquadrant.com>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: OpenSSL 1.1 breaks configure and more Tom Lane <tgl@sss.pgh.pa.us>
Re: OpenSSL 1.1 breaks configure and more Christoph Berg <myon@debian.org>
Re: OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: [HACKERS] OpenSSL 1.1 breaks configure and more Tom Lane <tgl@sss.pgh.pa.us>
Re: [HACKERS] OpenSSL 1.1 breaks configure and more Tom Lane <tgl@sss.pgh.pa.us>
Re: [HACKERS] OpenSSL 1.1 breaks configure and more Andreas Karlsson <andreas@proxel.se>
Re: [HACKERS] OpenSSL 1.1 breaks configure and more Tom Lane <tgl@sss.pgh.pa.us>
Re: OpenSSL 1.1 breaks configure and more Heikki Linnakangas <hlinnaka@iki.fi>
Re: OpenSSL 1.1 breaks configure and more Christoph Berg <myon@debian.org>
Re: OpenSSL 1.1 breaks configure and more Michael Paquier <michael.paquier@gmail.com>
Re: OpenSSL 1.1 breaks configure and more Michael Paquier <michael.paquier@gmail.com>
Re: OpenSSL 1.1 breaks configure and more Magnus Hagander <magnus@hagander.net>
Re: OpenSSL 1.1 breaks configure and more Michael Paquier <michael.paquier@gmail.com>
Re: OpenSSL 1.1 breaks configure and more Magnus Hagander <magnus@hagander.net>
Thanks for this effort.

>  static BIO_METHOD *
>  my_BIO_s_socket(void)
>  {
> -	if (!my_bio_initialized)
> +	if (!my_bio_methods)
>  	{
> -		memcpy(&my_bio_methods, BIO_s_socket(), sizeof(BIO_METHOD));
> -		my_bio_methods.bread = my_sock_read;
> -		my_bio_methods.bwrite = my_sock_write;
> -		my_bio_initialized = true;
> +		BIO_METHOD *biom = (BIO_METHOD *) BIO_s_socket();
> +#if SSLEAY_VERSION_NUMBER >= 0x10100000L
> +		my_bio_methods = BIO_meth_new(BIO_TYPE_SOCKET, "pgsocket");
> +		BIO_meth_set_write(my_bio_methods, my_sock_write);
> +		BIO_meth_set_read(my_bio_methods, my_sock_read);
> +		BIO_meth_set_gets(my_bio_methods, BIO_meth_get_gets(biom));
> +		BIO_meth_set_ctrl(my_bio_methods, BIO_meth_get_ctrl(biom));
> +		BIO_meth_set_create(my_bio_methods, BIO_meth_get_create(biom));
> +		BIO_meth_set_destroy(my_bio_methods, BIO_meth_get_destroy(biom));
> +		BIO_meth_set_callback_ctrl(my_bio_methods, BIO_meth_get_callback_ctrl(biom));
> +#else
> +		my_bio_methods = malloc(sizeof(BIO_METHOD));
> +		memcpy(my_bio_methods, biom, sizeof(BIO_METHOD));
> +		my_bio_methods->bread = my_sock_read;
> +		my_bio_methods->bwrite = my_sock_write;
> +#endif

Generally, version number tests sprinkled all over the place are not
terribly nice.  I think it would be better to get configure to define a
symbol like HAVE_BIO_METH_NEW.  Not sure about the other hunks in this
patch; perhaps HAVE_BIO_SET_DATA, and #define both those macros if not.

-- 
Álvaro Herrera                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


В списке pgsql-hackers по дате отправления
От: Andreas Karlsson
Дата:
От: Andreas Karlsson
Дата:
FAQ