X-Original-To: pgsql-interfaces-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id D6DED564E0 for ; Thu, 10 Mar 2005 04:50:13 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 72236-10 for ; Thu, 10 Mar 2005 04:50:05 +0000 (GMT) Received: from floppy.pyrenet.fr (news.pyrenet.fr [194.250.190.2]) by svr1.postgresql.org (Postfix) with ESMTP id B36CD5638F for ; Thu, 10 Mar 2005 04:50:04 +0000 (GMT) Received: by floppy.pyrenet.fr (Postfix, from userid 106) id 6CC4E30AF3; Thu, 10 Mar 2005 05:50:04 +0100 (MET) From: Christopher Browne X-Newsgroups: pgsql.interfaces Subject: Re: Using PL/R with 8.0 Date: Wed, 09 Mar 2005 22:55:12 -0500 Organization: cbbrowne Computing Inc Lines: 47 Message-ID: References: <20050309033614.GR5165@varlena.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Complaints-To: usenet@news.hub.org X-message-flag: Outlook is rather hackable, isn't it? X-Home-Page: http://www.cbbrowne.com/info/ X-Affero: http://svcs.affero.net/rm.php?r=cbbrowne User-Agent: Gnus/5.1007 (Gnus v5.10.7) XEmacs/21.4 (Jumbo Shrimp, linux) Cancel-Lock: sha1:mUzFvjs1GIKLBp6t6EB15LgsNkM= To: pgsql-interfaces@postgresql.org X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.353 tagged_above=0 required=5 tests=AWL, INFO_TLD X-Spam-Level: X-Archive-Number: 200503/44 X-Sequence-Number: 5373 Quoth elein@varlena.com (elein): > I'm trying to get plr up and running on an 8.0.1 > pg installation. I'm running Debian unstable. > > I have R_HOME as /usr/lib/R > libR.so is in /usr/lib/R/lib/libR.so > and has rw-r--r-- permissions. > > /u/local/pgsql80/lib/plr.so is rwxr-xr-x. > > I've (re)built pg --with-plr and --with-libs=/usr/lib/R/ (just in case) > > I've (re)built plr. > > When I load plr.sql it complains: > ERROR: could not load library "/u/local/pgsql80/lib/plr.so": libR.so: cannot open shared object file: No such file or directory > > Please tell me that there is something stupid > and obvious that I've forgotten to set? > (And what that thing is :) There's a tendancy for R builds to not bother building the sharable libR.so library. The key to figuring it out is to check what's missing in library linkages. Two options ought to be helpful: 1. ldd /u/local/pgsql80/lib/plr.so 2. ldd /usr/lib/R/lib/libR.so On my Debian/unstable system... cbbrowne@wolfe> ldd /usr/lib/postgresql/lib/plr.so libR.so => not found libc.so.6 => /lib/tls/libc.so.6 (0x40022000) /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000) It may suffice to figure out where libR.so is, and add that directory in via LD_LIBRARY_PATH... -- let name="cbbrowne" and tld="gmail.com" in String.concat "@" [name;tld];; http://linuxdatabases.info/info/slony.html "The idea that Bill Gates has appeared like a knight in shining armour to lead all customers out of a mire of technological chaos neatly ignores the fact that it was he who, by peddling second-rate technology, led them into it in the first place." - Douglas Adams in Guardian, 25-Aug-95