This is the mail archive of the
cygwin
mailing list for the Cygwin project.
'pgplsh' on Cygwin
- From: <sbremal at hotmail dot com>
- To: "cygwin at cygwin dot com" <cygwin at cygwin dot com>
- Date: Thu, 24 Oct 2013 14:17:48 +0000
- Subject: 'pgplsh' on Cygwin
- Authentication-results: sourceware.org; auth=none
Hello
I am getting 'pgplsh' run under Cygwin PostgreSQL. After minor adjustments to the makefile the library compiles, however I am facing the following error when 'loading' the function definitions in the database:
$ psql -d postgres -U SYSTEM -f /usr/local/share/pgplsh/createlang_pgplsh.sql
psql:/usr/local/share/pgplsh/createlang_pgplsh.sql:3: ERROR: could not load
library "/usr/local/lib/pgplsh/pgplsh.a": Exec format error
psql:/usr/local/share/pgplsh/createlang_pgplsh.sql:7: ERROR: could not load
library "/usr/local/lib/pgplsh/pgplsh.a": Exec format error
psql:/usr/local/share/pgplsh/createlang_pgplsh.sql:11: ERROR: function
pg_catalog.plsh_handler() does not exist
$ file /usr/local/lib/pgplsh/pgplsh.a
/usr/local/lib/pgplsh/pgplsh.a: current ar archive
$ file /usr/local/lib/pgplsh/pgplsh.la
/usr/local/lib/pgplsh/pgplsh.la: libtool library file,
Could someone tide me over this issue? Thanks!
Cheers
Balazs
---
$ cat /usr/local/share/pgplsh/createlang_pgplsh.sql
CREATE FUNCTION pg_catalog.plsh_handler() RETURNS language_handler
AS '/usr/local/lib/pgplsh/pgplsh.a'
LANGUAGE C;
CREATE FUNCTION pg_catalog.plsh_validator(oid) RETURNS void
AS '/usr/local/lib/pgplsh/pgplsh.a'
LANGUAGE C;
CREATE LANGUAGE plsh
HANDLER pg_catalog.plsh_handler
VALIDATOR pg_catalog.plsh_validator;
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple