Re: tydedef extraction - back to the future

From: Peter Eisentraut <peter(at)eisentraut(dot)org>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: tydedef extraction - back to the future
Date: 2024-05-22 11:32:03
Message-ID: 7f7e0760-2c27-4e94-b3de-e8c141a94e98@eisentraut.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 20.05.24 23:11, Andrew Dunstan wrote:
> Attached is an attempt to thread this needle. The core is a new perl
> module that imports the current buildfarm client logic. The intention is
> that once we have this, the buildfarm client will switch to using the
> module (if found) rather than its own built-in logic. There is precedent
> for this sort of arrangement (AdjustUpgrade.pm). Accompanying the new
> module is a standalone perl script that uses the new module, and
> replaces the current shell script (thus making it more portable).

It looks like this code could use a bit of work to modernize and clean
up cruft, such as

+ my $sep = $using_msvc ? ';' : ':';

This can be done with File::Spec.

+ next if $bin =~ m!bin/(ipcclean|pltcl_)!;

Those are long gone.

+ next if $bin =~ m!/postmaster.exe$!; # sometimes a
copy not a link

Also gone.

+ elsif ($using_osx)
+ {
+ # On OS X, we need to examine the .o files

Update the name.

+ # exclude ecpg/test, which pgindent does too
+ my $obj_wanted = sub {
+ /^.*\.o\z/s
+ && !($File::Find::name =~ m!/ecpg/test/!s)
+ && push(@testfiles, $File::Find::name);
+ };
+
+ File::Find::find($obj_wanted, $binloc);
+ }

Not clear why this is specific to that platform.

Also, some instructions should be provided. It looks like this is meant
to be run on the installation tree? A README and/or a build target
would be good.

The code distinguishes between srcdir and bindir, but it's not clear
what the latter is. It rather looks like the installation prefix. Does
this code support out of tree builds? This should be cleared up.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2024-05-22 11:40:27 Re: Pgoutput not capturing the generated columns
Previous Message jian he 2024-05-22 11:22:26 Re: </replaceable> in parentesis is not usual on DOCs