X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:date:from:mime-version:to:subject :references:in-reply-to:content-type:content-transfer-encoding; q=dns; s=default; b=O7s9tBcrfWytqVe23NJXmchtdoT17b4xGAGCqQaEGVQ JF/6SS2VoOhxZuXYTxKsKxVR/l7JFVLpHyUkaIMRE8dRgLTlJt+cFCVljHebEiPj jJlpfxpyYWuffja0V14O70XUejo5N6IvfZAN4vjMjRGePvtkGuXBH+3GouR5I1zE = DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:date:from:mime-version:to:subject :references:in-reply-to:content-type:content-transfer-encoding; s=default; bh=PbIKtxNipGPJcFScjlbHCkceHnk=; b=hMv2+juGYAogoz8in 1dQtsLxKpTU7hYeO9PjO1fU4ZpS0J3QbrPSUmFI5fgvFtmPoikT4a6fPDvPANGwq CQ8wqwS+o13Hno91t05AySl8pVLnpTxmy4X9Hw+R3LjF2j54roJlJzX/RoKvXINg AdHjlZY2UtKB61oCn1rK/G591M= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM,FREEMAIL_REPLY,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=no version=3.3.2 X-HELO: mail-ve0-f182.google.com X-Received: by 10.52.77.38 with SMTP id p6mr38023vdw.60.1382627994649; Thu, 24 Oct 2013 08:19:54 -0700 (PDT) Message-ID: <52693A98.3080902@gmail.com> Date: Thu, 24 Oct 2013 17:19:52 +0200 From: marco atzeri User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.0.1 MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: 'pgplsh' on Cygwin References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Il 10/24/2013 4:17 PM, sbremal AT hotmail DOT com ha scritto: > 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 some info more about how you built pgplsh ? trying to load a static lib looks wrong... > > --- > > $ 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