Re: Adding NetBSD and OpenBSD to Postgres CI

Поиск
Список
Период
Сортировка
Искать

Re: Adding NetBSD and OpenBSD to Postgres CI

От:
Peter Eisentraut <peter@eisentraut.org>
Дата:
On 01.11.24 10:17, Nazir Bilal Yavuz wrote:
> NetBSD and OpenBSD Postgres CI images are generated [1] but their tasks 
> are not added to the upstream Postgres yet. The attached patch adds 
> NetBSD and OpenBSD tasks to the Postgres CI.
> 
> I made these tasks triggered manually like MinGW task to save CI credits 
> but a related line is commented out for now to trigger CFBot.

This seems useful to me.  It would add some more testability for 
LibreSSL for example.

I noticed that neither the existing FreeBSD task nor the new OpenBSD one 
find the bsd_auth.h header.  I thought this would be good to get more 
testing of that code.  Do you know why that is?



Re: Adding NetBSD and OpenBSD to Postgres CI

От:
Daniel Gustafsson <daniel@yesql.se>
Дата:
> On 1 Nov 2024, at 12:16, Peter Eisentraut  wrote:
> 
> On 01.11.24 10:17, Nazir Bilal Yavuz wrote:
>> NetBSD and OpenBSD Postgres CI images are generated [1] but their tasks are not added to the upstream Postgres yet. The attached patch adds NetBSD and OpenBSD tasks to the Postgres CI.
>> I made these tasks triggered manually like MinGW task to save CI credits but a related line is commented out for now to trigger CFBot.
> 
> This seems useful to me.  It would add some more testability for LibreSSL for example.

Seconded, I very much look forward to having LibreSSL in CI.

--
Daniel Gustafsson



Re: Adding NetBSD and OpenBSD to Postgres CI

От:
Nazir Bilal Yavuz <byavuz81@gmail.com>
Дата:
Hi,

Thanks for the feedback!

On Fri, 1 Nov 2024 at 14:16, Peter Eisentraut  wrote:
>
> On 01.11.24 10:17, Nazir Bilal Yavuz wrote:
> > NetBSD and OpenBSD Postgres CI images are generated [1] but their tasks
> > are not added to the upstream Postgres yet. The attached patch adds
> > NetBSD and OpenBSD tasks to the Postgres CI.
> >
> > I made these tasks triggered manually like MinGW task to save CI credits
> > but a related line is commented out for now to trigger CFBot.
>
> This seems useful to me.  It would add some more testability for
> LibreSSL for example.
>
> I noticed that neither the existing FreeBSD task nor the new OpenBSD one
> find the bsd_auth.h header.  I thought this would be good to get more
> testing of that code.  Do you know why that is?

The 'bsd_auth.h' file does not exist in FreeBSD.

For the OpenBSD, it exists but its compilation fails with:
'''
/usr/include/bsd_auth.h:93:1: error: unknown type name 'quad_t'
/usr/include/bsd_auth.h:94:1: error: unknown type name 'quad_t
'''

These 'quad_t' types are defined in the 'sys/types.h' file. If I apply
the changes below:
"""
 if cc.check_header('bsd_auth.h', required: bsd_authopt,
-    args: test_c_args, include_directories: postgres_inc)
+    args: test_c_args, prefix: '#include ',
+    include_directories: postgres_inc)
   cdata.set('USE_BSD_AUTH', 1)
   bsd_auth = declare_dependency()
 endif
"""

Then, meson is able to find "bsd_auth.h" in the OpenBSD task and CI
finishes successfully [1]. But I am not sure if this is enough. Do we
need additional changes for the BSD authentication?

[1] https://cirrus-ci.com/task/6516032758611968

--
Regards,
Nazir Bilal Yavuz
Microsoft


Re: Adding NetBSD and OpenBSD to Postgres CI

От:
Peter Eisentraut <peter@eisentraut.org>
Дата:
On 07.11.24 14:40, Nazir Bilal Yavuz wrote:
>> I noticed that neither the existing FreeBSD task nor the new OpenBSD one
>> find the bsd_auth.h header.  I thought this would be good to get more
>> testing of that code.  Do you know why that is?
> 
> The 'bsd_auth.h' file does not exist in FreeBSD.
> 
> For the OpenBSD, it exists but its compilation fails with:
> '''
> /usr/include/bsd_auth.h:93:1: error: unknown type name 'quad_t'
> /usr/include/bsd_auth.h:94:1: error: unknown type name 'quad_t
> '''
> 
> These 'quad_t' types are defined in the 'sys/types.h' file.

Makes sense. The synopsis in https://man.openbsd.org/authenticate.3 is:

#include 
#include 
#include 



Re: Adding NetBSD and OpenBSD to Postgres CI

От:
Andres Freund <andres@anarazel.de>
Дата:
Hi,

On 2024-11-07 16:05:43 +0100, Peter Eisentraut wrote:
> On 07.11.24 14:40, Nazir Bilal Yavuz wrote:
> > > I noticed that neither the existing FreeBSD task nor the new OpenBSD one
> > > find the bsd_auth.h header.  I thought this would be good to get more
> > > testing of that code.  Do you know why that is?
> > 
> > The 'bsd_auth.h' file does not exist in FreeBSD.
> > 
> > For the OpenBSD, it exists but its compilation fails with:
> > '''
> > /usr/include/bsd_auth.h:93:1: error: unknown type name 'quad_t'
> > /usr/include/bsd_auth.h:94:1: error: unknown type name 'quad_t
> > '''
> > 
> > These 'quad_t' types are defined in the 'sys/types.h' file.
> 
> Makes sense. The synopsis in https://man.openbsd.org/authenticate.3 is:
> 
> #include 
> #include 
> #include 

It doesn't really make sense to me - it seems like a bug if system headers
aren't standalone. And the synopsys including a header doesn't seem to
obviously indicate that every user has to do so.

But anyway, we probably just have to deal with the world as it, rather than
how it should be :(

Greetings,

Andres Freund


FAQ