<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>


Yes, I know: it is very clever to do that on Windows, but it is just for
testing purpose.
<p>I want to add some user-defined functions to postgis, mainly to deal
with geometries (adding some operators, maybe trying gpc on polygons).
<p>I succeeded in compiling a very simple dll with a C function in it,
and declare it in Postgresql.
<br>Now, I want to handle a function getting a geometry as parameter. I
took an example from the Postgis sources.
<br>I can successfully compile my (very basic) source code, but the linking
fails:
<br>I have an Unresolved External Symbol: _CurrentMemoryContext.
<br>I'm liking with libpostgres.a, which should define this symbol (a looked
inside libpostgis.a and found a __imp_CurrentMemoryContext definition).
<p>I saw in palloc.h, a header file contained in the utils folder of the
posgresql sources, the definition for CurrentMemoryContext with a DLLIMPORT
keyword behind:
<br><tt>extern DLLIMPORT MemoryContext CurrentMemoryContext;</tt><tt></tt>
<p>I recompiled libpostgis.a without this DLLIMPORT macro, but it does
not solve the problem.
<p>I'm running Postgresql/postgis on cygwin (windows NT).
<p>Any help would be greatly appreciated.
<p>Thanx.
<br>Nicolas.
<br>

<!-- |**|begin egp html banner|**| -->

<table border=0 cellspacing=0 cellpadding=2>
<tr bgcolor=#FFFFCC>
<td align=center><font size="-1" color=#003399><b>Yahoo! Groups Sponsor</b></font></td>
</tr>
<tr bgcolor=#FFFFFF>
<td align=center width=470><a href="http://rd.yahoo.com/M=215839.1778785.3296727.1261774/D=egroupweb/S=1705007183:HM/A=868540/R=0/*http://zappos.zappos.com/bin/zapposset?ref=yahoogroups2"><img src="http://us.a1.yimg.com/us.yimg.com/a/za/zappos/zap_468x60winterboots.gif" height=60 width=468></a></td>
</tr>
<tr><td><img alt="" width=1 height=1 src="http://us.adserver.yahoo.com/l?M=215839.1778785.3296727.1261774/D=egroupmail/S=1705007183:HM/A=868540/rand=538545683"></td></tr>
</table>

<!-- |**|end egp html banner|**| -->


<br>
<tt>
To unsubscribe from this group, send an email to:<BR>
postgis-unsubscribe@yahoogroups.com<BR>
<BR>
</tt>
<br>

<br>
<tt>Your use of Yahoo! Groups is subject to the <a href="http://docs.yahoo.com/info/terms/">Yahoo! Terms of Service</a>.</tt>
</br>

</html>