Re: Dynamic loading of C functions
От | Tom Lane |
---|---|
Тема | Re: Dynamic loading of C functions |
Дата | |
Msg-id | 911.1150838655@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Re: Dynamic loading of C functions ("Jasbinder Bali" <jsbali@gmail.com>) |
Ответы |
Re: Dynamic loading of C functions
|
Список | pgsql-general |
"Jasbinder Bali" <jsbali@gmail.com> writes: >>> /usr/include/pgsql/server/ is exactly the path where test_func object >>> file resides. Hmmm .... when you say "object file", do you mean it's really named "test_func.o"? If so, that's both the wrong name and the wrong type of file. Postgres is looking for a shared library, eg "test_func.so" (or on some platforms ".sl" or ".dylib"). There's some advice in our manual about the compiler switches to use to create a shared library, or see your compiler documentation. Given AS '/usr/include/pgsql/server/test_func', Postgres will look for both "test_func" and "test_func.so" (not sure which order, try the LOAD reference page for details). It won't look for "test_func.o" though. BTW, most people would say that /usr/include is exactly where NOT to put an executable file ... conventionally this kind of file goes under /usr/lib. That's not what's causing your problem, it's just a question of keeping your filesystem tidy enough to be able to find things again. regards, tom lane
В списке pgsql-general по дате отправления: