Subject: [Pljava-dev] PL/Java 1.5.0-BETA2 announced (release candidate)

From: Chapman Flack <[email-masked]>
Date: Mon, 22 Feb 2016 20:38:45 -0500

PL/Java brings functions, triggers, and types in Java. 1.5.0, now in second
beta/release candidate, supports latest PostgreSQL and Java versions with a
range of improvements and fixes.

Project site:  http://tada.github.io/pljava/
Release notes: http://tada.github.io/pljava/releasenotes.html

Although PL/Java has historically used numbered betas and not "RC"
releases, this may be considered a 1.5.0 release candidate.

Changes since 1.5.0-BETA1:

* Microsoft Windows builds are now supported using both the Visual Studio
  and the MinGW-w64 toolchains.
* Fixed: two build/install issues on Mac OS X El Capitan (issues 94, 96)
* Fixed: parameter declaration generated for trigger function (issue 92)
* Fixed: source location missing for some annotation errors (issue 95)
* Fixed: pljava-api jar missing from installation jar

Please see the release notes for more details and the cumulative list of
changes.

Many thanks to all the individuals and organizations listed in the release
notes under Credits.
_______________________________________________
Pljava-dev mailing list
[email-masked]
http://lists.pgfoundry.org/mailman/listinfo/pljava-dev

---

From: Peter Brewer <[email-masked]>
Date: Fri, 26 Feb 2016 11:08:20 -0700

First of all... I can't tell you how glad I am to see the work on the 
new release! Thanks to everyone who is making this happen.

I am, however, having a few issues with building. My version info is:

OS : Ubuntu 14.04.4
Maven : 3.0.5
Java : OpenJDK 1.7.0_95 (i386)
PG: 9.3.11
gcc : 4.8.4

As you can see from the attached mvn log, things go pear shaped building 
the PL/Java backend native code.

Any ideas?

Peter

-- 
*********************************
Dr Peter Brewer
Research Associate
Rm 405, Bryant Bannister Building
Laboratory of Tree-Ring Research
1215 E Lowell St
Tucson AZ 85721
USA
Phone: +1 520 621 0753
Fax  : +1 520 621 8229
Email: [email-masked]
Web  : http://ltrr.arizona.edu
*********************************

---

From: Chapman Flack <[email-masked]>
Date: Fri, 26 Feb 2016 13:51:32 -0500

On 02/26/2016 01:08 PM, Peter Brewer wrote:
> First of all... I can't tell you how glad I am to see the work

Thank you!

> Athings go pear shaped building

Yes. :)

Most of what you are seeing there are [-Wsign-conversion]
warnings, and those are a miserable nuisance. It is not
really possible to tweak PL/Java's code to make them go
away, without actually changing .h files that come from
PostgreSQL itself, and when you try to read your log, all
those nuisance warnings get in the way of seeing the one
actual error that determined the shape of the fruit.

That one's on line 791:
[ERROR] /usr/include/postgresql/9.3/server/libpq/libpq-be.h:36:27: fatal
error: gssapi/gssapi.h: No such file or directory

It seems that your PostgreSQL package was build with gssapi
support, but the PL/Java build did not find the gssapi.h file
on your system. The solution may be as simple as finding a
package named gssapi-devel or some such, from your Ubuntu
package manager and installing it.

As far as the nuisance sign-conversion warnings, I recommend
using -Pwnosign on the mvn command line, to turn them off.
It is just easier to spot real problems that way.

After locating gssapi.h, would you be willing to do your
testing on 1.5.0-BETA2 rather than 1.6.0-SNAPSHOT?  It's
extra valuable to have testing focused on the imminent 1.5.0
release; 1.6.0-SNAPSHOT will be where somewhat more vaporous
future work will be happening.

Regards,
-Chap

---

From: Peter Brewer <[email-masked]>
Date: Fri, 26 Feb 2016 13:46:50 -0700

> error: gssapi/gssapi.h: No such file or directory
Looks like installing libkrb5-dev fixed this for me.  Thanks.

> future work will be happening.
Sure.  I've switched to 1.5.0-b2 but have a few more errors.  Logs attached.

Many thanks

Peter

---

From: Chapman Flack <[email-masked]>
Date: Wed, 09 Mar 2016 18:47:43 -0500

> Looks like installing libkrb5-dev fixed this for me.  Thanks.

For those following along at home, where we stand so far on this is:

1. The Ubuntu postgresql build enables GSSAPI, that comes separately from
   the package manager, libkrb5-dev has to be installed.

2. Ubuntu also packages various bits of postgresql libraries a la carte.
   The package libecpg-dev also needs to be installed.

3. As he was building 32-bit, the MAVEN_OPTS=-Xss1m is definitely needed
   for the build.

4. Don't be alarmed by [ERROR] lines in the Maven pljava-so build if
   the build completes and Maven calls it successful. That means the
   messages were warnings. Maven seems to decide, based on seeing the
   string "warning:" in a line from the compiler, whether to call it
   [WARNING] or [ERROR], and gcc tends to emit ~ 4 lines for each warning,
   of which only the first contains the string "warning:" and Maven
   misclassifies the other three as errors. This applies to any build,
   not just Ubuntu, but the question came up so this is the story.

   If it works for you, do use -Pwnosign on the Maven command line
   to suppress the nuisance sign conversion warnings. That *should*
   leave only the ones about unsupported new types of
   transaction/subtransaction listeners, mentioned in the release notes.

5. This is the current obstacle. Peter was using an Ubuntu Trusty 32-bit
   build of OpenJDK 1.7.0_95.

   Something about that build seems to have broken the javax.script
   JavaScript engine (it's Rhino in that version) in rather strange ways,
   for example, s1 + s2 where s1 and s2 are both strings, is not a string
   result any more, it's a sun.org.mozilla.javascript.ConsString and
   doesn't work in contexts where a string would.

   I have confirmed there is no problem building with Red Hat's
   OpenJDK 1.7.0_95 (64-bit), as well as with their OpenJDK 6 and 8
   builds. Peter has seen the error with OpenJDK 6 and 7 on Ubuntu and
   with 32-bit and 64-bit JVMs. It seems to be something Ubuntu related
   that I have not seen elsewhere. The Ubuntu OpenJDK 8 works with no
   problem.

   It now has an Ubuntu bug report and a StackOverflow thread:
   https://bugs.launchpad.net/ubuntu/+source/openjdk-7/+bug/1553654
   http://stackoverflow.com/questions/35713768

   It doesn't appear to affect other platforms. The main build process
   now has (will, as soon as I push it) an easy workaround so the build
   completes. A bad Ubuntu JVM will still fail to run the self-extracting
   jar, but that's only inconvenient; the jar can be extracted the old
   fashioned way and the files moved into place. I'd like to think Ubuntu
   can make new Java releases that fix the problem so it doesn't seem worth
   adding much more complexity to the script to try to work around it.

There is (... will be, once pushed ...) a new Building on Ubuntu page in
the documentation to cover all that.

-Chap