agora inbox for pljava-dev@postgresql.org  
help / color / mirror / Atom feed
Subject: [Pljava-dev] Building pl/java on OS/X (Mountain Lion)
Date: Sat, 13 Oct 2012 20:26:12 -0700
Message-ID: <507A30D4.9060300@hogranch.com> (raw)
In-Reply-To: <507A2C86.9070404@hogranch.com>
References: <86510D0E-3824-40CC-B432-944032169D3E@me.com>
	<E4ADE262-FAE2-40EC-B53F-D92F2FA51185@me.com>
	<507A07B7.3040909@hogranch.com>
	<507A0B0A.7030600@hogranch.com>
	<16853424-3367-4ADB-8D21-073B254759B9@me.com>
	<507A2C86.9070404@hogranch.com>

On 10/13/12 8:07 PM, John R Pierce wrote:
> On 10/13/12 7:38 PM, Hal Hildebrand wrote:
>> Was also wondering if there's a more verbose mode for postgres 
>> startup, as what I'm getting is just a non zero exit.  Would be nice 
>> if there was something that gave some idea of what went wrong ;)
>>
>> Again, thanks for the help though.   Appreciated.
>
> it all should be written to the logfiles 

oh. when you get to the stage I was at with AIX last week, my best 
friend was the unix `ldd` command, on OSX I know its something 
different, but there's an equvalent, you give it an executable or a 
shared library (.so aka .dynlib), and it tries to find all the dependent 
libraries and lists them.

postgres would complain it couldn't load such and such a .so, so I'd 
...   ok here's one of my many steps from another thread on this list...


> $ psql -c "SELECT sqlj.install_jar('file:///opt/pljava/examples.jar', 
> 'samples', true);"
> INFO:  JVMJ9VM011W Unable to load jclscar_23: No such file or directory
> ERROR:  Failed to create Java VM 

The error message was misleading, when I did an `ldd` on that 
libjclscar_32.so, it turned out the /real/ error was...

$ ldd /usr/java5_64/jre/bin/libjclscar_23.so
/usr/java5_64/jre/bin/libjclscar_23.so needs:
          ../lib/libc_r.a(shr_64.o)
          ../lib/libpthread.a(shr_xpg5_64.o)
          /usr/java5_64/jre/bin/libjsig.so
          /usr/java5_64/jre/bin/libj9zlib23.so
          /usr/java5_64/jre/bin/libj9thr23.so
Cannot find libjvm.so <<<=====
          /unix
          ../lib/libcrypt.a(shr_64.o)
          ../lib/libc.a(shr_64.o)

and that libjvm.so is in /usr/java5_64/jre/bin/j9vm

so adding /usr/java5_64/jre/bin/j9vm to the dynamic_library_path seems 
to have fixed this.



-- 
john r pierce                            N 37, W 122
santa cruz ca                         mid-left coast





view thread (7+ messages)

Message-ID: <507A30D4.9060300@hogranch.com>
Permalink:  ../507A30D4.9060300@hogranch.com/
Also on:    postgresql.org/message-id/507A30D4.9060300@hogranch.com

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pljava-dev@postgresql.org
  Subject: Re: [Pljava-dev] Building pl/java on OS/X (Mountain Lion)
  In-Reply-To: <507A30D4.9060300@hogranch.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox