From: | Martijn van Oosterhout <kleptog(at)svana(dot)org> |
---|---|
To: | Pavel Stehule <pavel(dot)stehule(at)hotmail(dot)com> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: how solve diff of API counstruct_md_array between 8.1 and 8.2? |
Date: | 2006-02-16 19:49:01 |
Message-ID: | 20060216194901.GJ26127@svana.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-patches |
On Thu, Feb 16, 2006 at 08:36:34PM +0100, Pavel Stehule wrote:
> Hello
>
> I use counstruct_md_array function in my Orafunc module. CVS version has
> diff def now. I am findig way for simple solution of maintaince source code
> for both version. I have PG_VERSION variable, but it's unusable. Is there
> way for contrib's autors differentiate PostgreSQL versions? I don't want to
> have two versions of source code.
For my stuff I've generally use CATALOG_VERSION_NO. It's not very easy,
but by looking through CVS you can find when the function was created
and in your code use:
#ifdef CATALOG_VERSION_NO > yyyymmddN
/* New stuff */
#else
/* Old stuff */
#endif
Hope this helps,
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a
> tool for doing 5% of the work and then sitting around waiting for someone
> else to do the other 95% so you can sue them.
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Treat | 2006-02-16 20:09:41 | Re: [HACKERS] Patch Submission Guidelines |
Previous Message | Pavel Stehule | 2006-02-16 19:36:34 | how solve diff of API counstruct_md_array between 8.1 and 8.2? |
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Treat | 2006-02-16 20:09:41 | Re: [HACKERS] Patch Submission Guidelines |
Previous Message | Pavel Stehule | 2006-02-16 19:36:34 | how solve diff of API counstruct_md_array between 8.1 and 8.2? |