From: | Kyotaro HORIGUCHI <horiguchi(dot)kyotaro(at)lab(dot)ntt(dot)co(dot)jp> |
---|---|
To: | amit(dot)kapila16(at)gmail(dot)com |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Retain dynamic shared memory segments for postmaster lifetime |
Date: | 2014-02-04 06:55:09 |
Message-ID: | 20140204.155509.07674685.horiguchi.kyotaro@lab.ntt.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hello, Now I got workable dll thanks for your advice.
> I think both the problems are related and the reason is that dsm_demo.dll
> is not built properly.
> Let us first try to solve your second problem, because I think if
> that is solved, you will not face problem-1.
Thank you for kindness. I got the situation after successfully
getting correct dll by using .def file after your advice. cl
needs __declspec(dllexport) in the symbol definitions to reveal
them externally, without using .def file.
PostgreSQL platform(?) seems offering a macro PGDLLEXPORT for
such use. I suppose this should be used in extension module dlls
to expose symbols, like this,
- void _PG_init(void);
- Datum dsm_demo_create(PG_FUNCTION_ARGS);
- Datum dsm_demo_read(PG_FUNCTION_ARGS);
===
+ PGDLLEXPORT void _PG_init(void);
+ PGDLLEXPORT Datum dsm_demo_create(PG_FUNCTION_ARGS);
+ PGDLLEXPORT Datum dsm_demo_read(PG_FUNCTION_ARGS);
# This hardly seems to be used commonly...
I followed this instruction to make build environemnt,
http://blog.2ndquadrant.com/compiling-postgresql-extensions-visual-studio-windows/
And the change above enables us to build this module without .def file.
regards,
--
Kyotaro Horiguchi
NTT Open Source Software Center
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2014-02-04 07:07:08 | Re: could not create IPv6 socket (AI_ADDRCONFIG) |
Previous Message | Craig Ringer | 2014-02-04 06:43:41 | Re: Row-security on updatable s.b. views |