Re: Problem with server/utils/snapmgr.h - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Problem with server/utils/snapmgr.h
Date
Msg-id 8561.1208823399@sss.pgh.pa.us
Whole thread Raw
In response to Problem with server/utils/snapmgr.h  (Chris Browne <cbbrowne@acm.org>)
List pgsql-hackers
Chris Browne <cbbrowne@acm.org> writes:
> I tried adding an autoconf rule to Slony-I to check for its existence
> (goal then is to do a suitable #define so that we can #ifdef the
> #include, so that we #include this only with versions of PostgreSQL
> that have the file).

The customary way of handling Postgres version differences at
compilation time has been something like

#include "catalog/catversion.h"
#if CATALOG_VERSION_NO >= 200804201
... new code ...
#else
... old code ...
#endif

Seems to me that would do just fine and you don't need autoconf help.

I concur with Alvaro's comment that you're probably wasting your time
to do anything touching snapmgr.h right now, but if you must ...
        regards, tom lane


pgsql-hackers by date:

Previous
From: Simon Riggs
Date:
Subject: Re: MERGE Specification
Next
From: Tom Lane
Date:
Subject: Re: MERGE Specification