cpluspluscheck vs vpath

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

cpluspluscheck vs vpath

Andres Freund
Hi,

right now cpluspluscheck doesn't work with vpath builds. That's pretty
annoying, because it does require cloning the git tree into a separate
directory + doing configure there just to run cpluspluscheck.

Attached is a small patch allowing cpluspluscheck to run from different
directories. I needs the src and build directories for that,
unsurprisingly.

As that makes it more complicated to invoke, I added a makefile target
(in the top level) for it.

Seems we could round the edges a good bit further than what's done in
the attached (argument checking, for example). But I think this would
already be an improvement?

Greetings,

Andres Freund


Reply | Threaded
Open this post in threaded view
|

Re: cpluspluscheck vs vpath

Andres Freund
Hi,

On 2019-05-30 15:02:44 -0700, Andres Freund wrote:

> right now cpluspluscheck doesn't work with vpath builds. That's pretty
> annoying, because it does require cloning the git tree into a separate
> directory + doing configure there just to run cpluspluscheck.
>
> Attached is a small patch allowing cpluspluscheck to run from different
> directories. I needs the src and build directories for that,
> unsurprisingly.
>
> As that makes it more complicated to invoke, I added a makefile target
> (in the top level) for it.
>
> Seems we could round the edges a good bit further than what's done in
> the attached (argument checking, for example, but also using the C++
> compiler from configure). But I think this would already be an
> improvement?
Ugh, sent the previous email too early.

Greetings,

Andres Freund

0001-integrate-cpluspluscheck-a-bit-more.patch (2K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: cpluspluscheck vs vpath

Alvaro Herrera-9
On 2019-May-30, Andres Freund wrote:

> On 2019-05-30 15:02:44 -0700, Andres Freund wrote:
>
> > Seems we could round the edges a good bit further than what's done in
> > the attached (argument checking, for example, but also using the C++
> > compiler from configure). But I think this would already be an
> > improvement?

+1  I've stumbled upon this too.

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


Reply | Threaded
Open this post in threaded view
|

Re: cpluspluscheck vs vpath

Tom Lane-2
In reply to this post by Andres Freund
Andres Freund <[hidden email]> writes:
> Attached is a small patch allowing cpluspluscheck to run from different
> directories. I needs the src and build directories for that,
> unsurprisingly.

No objection to changing this, but you could reduce the surprise
factor for existing workflows with a couple of defaults for the
arguments --- allow srcdir to default to "." and builddir to default
to the same as srcdir.

                        regards, tom lane


Reply | Threaded
Open this post in threaded view
|

Re: cpluspluscheck vs vpath

Andres Freund
Hi,

On 2019-05-31 09:56:45 -0400, Tom Lane wrote:
> Andres Freund <[hidden email]> writes:
> > Attached is a small patch allowing cpluspluscheck to run from different
> > directories. I needs the src and build directories for that,
> > unsurprisingly.
>
> No objection to changing this, but you could reduce the surprise
> factor for existing workflows with a couple of defaults for the
> arguments --- allow srcdir to default to "." and builddir to default
> to the same as srcdir.

Pushed, with that modification.

Would be kinda nice to do the check in parallel...

- Andres