Re: Let's stop with the retail rebuilds of src/port/ files already

2018-09-28 Thread Tom Lane
I wrote: > Now, if we go forward with that solution, there will be issues with > some other things that libpq exports without having defined itself: > src/backend/utils/mb/wchar.c: > pg_utf_mblen > src/backend/utils/mb/encnames.c: > pg_encoding_to_char > pg_char_to_encoding > pg_valid_server_encodi

Re: Let's stop with the retail rebuilds of src/port/ files already

2018-09-28 Thread Andrew Dunstan
On 09/27/2018 03:48 PM, Tom Lane wrote: I wrote: Here's a partial patch for that: it adds the third build variant to src/port/ and teaches libpq to use it. We'd want to likewise modify src/common/ and fix up other callers such as ecpg, but this seems to be enough to test whether the idea wor

Re: Let's stop with the retail rebuilds of src/port/ files already

2018-09-27 Thread Tom Lane
I wrote: > Here's a partial patch for that: it adds the third build variant > to src/port/ and teaches libpq to use it. We'd want to likewise > modify src/common/ and fix up other callers such as ecpg, but this > seems to be enough to test whether the idea works or not. > ... > What I think would

Re: Let's stop with the retail rebuilds of src/port/ files already

2018-09-27 Thread Tom Lane
Michael Paquier writes: >> On September 26, 2018 9:03:05 PM PDT, Tom Lane wrote: >>> # libpgport is needed by some contrib >>> +# currently we don't install libpgport_shlib.a, maybe we should? > Likely you should as this could be used directly by out-of-core things. Maybe, but what things exac

Re: Let's stop with the retail rebuilds of src/port/ files already

2018-09-26 Thread Michael Paquier
On Wed, Sep 26, 2018 at 09:24:48PM -0700, Andres Freund wrote: > On September 26, 2018 9:03:05 PM PDT, Tom Lane wrote: >> What I think would make sense is to push this and see what the >> buildfarm thinks of it. If there are unfixable problems then >> we won't have wasted time fleshing out the co

Re: Let's stop with the retail rebuilds of src/port/ files already

2018-09-26 Thread Andres Freund
Hi, On September 26, 2018 9:03:05 PM PDT, Tom Lane wrote: >Andres Freund writes: >> On 2018-09-26 19:10:40 -0400, Tom Lane wrote: >>> I'm getting tired of having to make fixes like ce4887bd0. I think >>> we should rearrange things so that src/port/ and src/common/ compile >>> all their files

Re: Let's stop with the retail rebuilds of src/port/ files already

2018-09-26 Thread Tom Lane
Andres Freund writes: > On 2018-09-26 19:10:40 -0400, Tom Lane wrote: >> I'm getting tired of having to make fixes like ce4887bd0. I think >> we should rearrange things so that src/port/ and src/common/ compile >> all their files a third time using shared-library-friendly switches, >> put them in

Re: Let's stop with the retail rebuilds of src/port/ files already

2018-09-26 Thread Andres Freund
Hi, On 2018-09-26 19:10:40 -0400, Tom Lane wrote: > I'm getting tired of having to make fixes like ce4887bd0. I think > we should rearrange things so that src/port/ and src/common/ compile > all their files a third time using shared-library-friendly switches, > put them into new .a files, and hav

Let's stop with the retail rebuilds of src/port/ files already

2018-09-26 Thread Tom Lane
I'm getting tired of having to make fixes like ce4887bd0. I think we should rearrange things so that src/port/ and src/common/ compile all their files a third time using shared-library-friendly switches, put them into new .a files, and have libpq and the ecpg libraries just include those libraries