pg.ddx.io  pljava-dev@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Subject: [Pljava-dev] Problems compiling under Mac OS X
Date: Fri, 14 May 2004 12:58:55 +0200
Message-ID: <thhal-0vz+AAa2rClw0+6EGmM3qaXukrWQwAP@mailblocks.com> (raw)
References: <E02918AC-A580-11D8-9A58-0003933F0AB6@mac.com>
	<06f301c439a2$74ee5c80$eb4917ac@cor>

Hi Pascal,
The makefile is easy enough to change. I don't have access to a Mac OS X
based machine though, so it's hard for me to test that the change is
correct. I'd very much like your help. Some suggestions and answers to your
questions:

Instead of adding #ifdef DARWIN to the source code in order to find the
jni.h, I'd suggest that you instead add a -I flag to the CPPFLAGS. I'm a big
fan of controlling the environment through the makefile instead of using
#ifdef whenever possible.

Regarding 'ant'. There are two possibilities. Either the 'depend' task is
defined in the optional.jar (included in the ant distrib) and you don't have
that in your classpath, or you ant version is too old. In any case, I'd
recommend that you uppgrade ant. 1.5.1 whas a while ago...

If you get it up and running, I'd be happy to apply a patch.

Kind regards,

Thomas Hallgren


----- Original Message ----- 
From: "p3consulting" <p3consulting at mac.com>
To: <pljava-dev at gborg.postgresql.org>
Sent: Friday, May 14, 2004 10:29 AM
Subject: [Pljava-dev] Problems compiling under Mac OS X


> Hello,
>
> Here some reports of problems I have got trying compiling pljava under
> Mac OS X:
>
> 1. the jni.h file is in the JavaVM framework
>  This requires a simple modification of the pljva/C/Makefile
>
> #----------------------------------------------------------------------- 
> --
> #
> # Makefile--
> #    Makefile for pljava
> #
> #----------------------------------------------------------------------- 
> --
> NAME := pljava
>
> include $(MODULEROOT)/Makefile.global
>
> ifeq ($(PORTNAME), win32)
>  DLL_BUILD := 1
> else
> ifeq ($(PORTNAME), cygwin)
>  DLL_BUILD := 1
>  override CPPFLAGS := -DCYGWIN $(CPPFLAGS)
> else
> ifeq ($(PORTNAME), darwin)
>  DLL_BUILD := 0
>  override CPPFLAGS := -DDARWIN -framework JavaVM $(CPPFLAGS)
> else
>  JRE_INCL := $(PORTNAME)
>  ifeq ($(host_cpu), i686)
>   JRE_LIB := lib/i386/client
>  else
>   JRE_LIB := lib/$(host_cpu)/client
>  endif
> endif
> endif
> endif
>
>
> 2. every #include <jni.h>
> should be converted to
> #ifdef DARWIN
>          #include <JavaVM/jni.h>
> #else
>          #include <jni.h>
> #endif
>
> 3. ant 1.5.1 is installed by default on Mac OS X
> the build fails with
>
>  BUILD FAILED
>  file:/Volumes/Data2/download_osx/PostgreSQL/org.postgresql.pljava/
> build.xml:30: Could not create task or type of type: depend.
>
>  Ant could not find the task or a class this task relies upon.
>
> Should I have to install another ant version ?
> Another .jar missing ?
>
> Any idea ?
>
> Pascal Pochet
> p3consulting at mac.com
> ----------------------------------
> PGP
> KeyID: 0x208C5DBF
> Fingerprint: 9BFB 245C 5BFE 7F1D 64B7  C473 ABB3 4E83 208C 5DBF
> _______________________________________________
> Pljava-dev mailing list
> Pljava-dev at gborg.postgresql.org
> http://gborg.postgresql.org/mailman/listinfo/pljava-dev
>






view thread (7+ messages)  latest in thread

Message-ID: <thhal-0vz+AAa2rClw0+6EGmM3qaXukrWQwAP@mailblocks.com>
Permalink:  ../thhal-0vz+AAa2rClw0+6EGmM3qaXukrWQwAP@mailblocks.com/
Also on:    postgresql.org/message-id/thhal-0vz+AAa2rClw0+6EGmM3qaXukrWQwAP@mailblocks.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] Problems compiling under Mac OS X
  In-Reply-To: <thhal-0vz+AAa2rClw0+6EGmM3qaXukrWQwAP@mailblocks.com>

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

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