Re: PLUGINS Functionlity in Win32 build scripts

From: MUHAMMAD ASIF <anaeem(dot)it(at)hotmail(dot)com>
To: <robertmhaas(at)gmail(dot)com>
Cc: <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: PLUGINS Functionlity in Win32 build scripts
Date: 2008-12-17 20:56:29
Message-ID: BLU110-W254F570331FEA4257A569AFFF20@phx.gbl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Pldebugger uses its own PLUGIN implementation that is ok for make utility but when we try to compile the code on Windows Perl build scripts fail because it don’t understand Makefile without pgxs.mk variables. If we add plugin logic in pgxs.mk and windows Perl build scripts , it would be simple to add a plugin module as contrib without much effort. Actually pldebugger gave us this idea that there should be some built in logic to build plugins in postgresql code. You can find pldebugger latest code at http://pgfoundry.org/frs/?group_id=1000175. PLUGINS logic is a partial thing, There are some other steps involved to build pldebugger on linux and windows if you like I can send you the more details on that. Thanks.

> From: anaeem(dot)it(at)hotmail(dot)com
> To: robertmhaas(at)gmail(dot)com
> CC: pgsql-hackers(at)postgresql(dot)org
> Subject: Re: [HACKERS] PLUGINS Functionlity in Win32 build scripts
> Date: Thu, 18 Dec 2008 00:24:46 +0500
>
>
> Purpose of this Plugins change is to add support in postgresql source to build plugin and install in (install dir)/lib/plugins. We made these changes for a plugin module i.e. pldebugger and we found this a useful feature that can help postgresql in adding plugins easily.
> Attached file (foo.zip) is a test contrib module code that can be used to test PLUGINS logic ( patches.zip patch I have sent you in the last email). Following are the steps to build foo.zip i.e
> a. Apply patches plugins_make.patch and plugins_msvc.patch.
> b. Unzip and copy the foo directory in the contrib directory
> c. Build and Install the system
> It will build foo library and place it in lib/plugins directory.You can test it on both windows and linux/unix platforms.Thanks.
>
> Best Regards,
> Asif Naeem
>
>> Date: Tue, 9 Dec 2008 23:36:42 -0500
>> From: robertmhaas(at)gmail(dot)com
>> To: anaeem(dot)it(at)hotmail(dot)com
>> Subject: Re: [HACKERS] PLUGINS Functionlity in Win32 build scripts
>> CC: pgsql-hackers(at)postgresql(dot)org
>>
>>>> I've been assigned to review this patch, but I confess I'm a little
>>>> murky on what problem it's trying to solve. Can you explain what I
>>>> need to do to recreate the problem?
>>> In postgreSQL, Plugin modules should be installed in (Installation
>>> dir)lib/plugins to run properly. There is logic in src/makefiles/pgxs.mk for
>>> handling shared objects implemented as e.g. "Modules" variable that are
>>> installed in (Installation dir)/lib. There should be some way to handle
>>> plugins as well. We faced this issue during the integration of contrib
>>> module pldebugger ( http://pgfoundry.org/frs/?group_id=1000175 ) with the
>>> edb-postgresql code. pldebugger/Makefile handles plugins by itself,
>>> Unix/Linux don't mind it because it build through make. On windows, perl
>>> scripts are used to build the system that relies on Makefiles that uses
>>> pgxs.mk variables e.g "Modules" etc. It fails to build pldebugger that
>>> implements its own plugin build logic in its Makefile. Right now for us
>>> there is only one plugin module but in future there may be more.Instead of
>>> any workaround we come up to a better solution to handle plugins
>>> automatically by pgxs.mk as other shared objects are being handled on Unix
>>> and Windows. We added PLUGIN logic in pgxs.mk and windows perl build scripts
>>> so that there is no need to handle plugins separately by new contrib
>>> modules.
>>
>> I am a bit dubious about the idea of adding supposedly generic
>> functionality to cater to a single client, but the bigger problem is
>> that even after reading this I still don't really know what I'm
>> supposed to be looking at. I think you're saying that pldebugger
>> contains some code that could be made simpler and less easily broken
>> if this patch were applied. Is that correct? If so, please tell me
>> where to download the pldebugger code and which file(s) to look in for
>> the code that could be improved.
>>
>> ...Robert
>>
>> --
>> Sent via pgsql-hackers mailing list (pgsql-hackers(at)postgresql(dot)org)
>> To make changes to your subscription:
>> http://www.postgresql.org/mailpref/pgsql-hackers
>
> _________________________________________________________________
> Discover the new Windows Vista
> http://search.msn.com/results.aspx?q=windows+vista&mkt=en-US&form=QBRE

_________________________________________________________________
Explore the seven wonders of the world
http://search.msn.com/results.aspx?q=7+wonders+world&mkt=en-US&form=QBRE

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Simon Riggs 2008-12-17 21:26:12 Preventing index scans for non-recoverable index AMs
Previous Message Simon Riggs 2008-12-17 20:55:26 Re: Latest version of Hot Standby patch