openslide/openslide-java — pull request #14 by bgilbert (2011-10-28 05:07:51+00:00)
Title: [RFC] Convert OpenSlide-Java Makefile to Autotools

I wanted to improve the Makefile to automatically detect include directories and compiler flags, but it became apparent that I was reimplementing Autoconf. So, here is a conversion of OpenSlide-Java to Autotools. Makefile.am is responsible for `make dist` (which we haven't had before) and for building the JNI, and still calls out to Ant for building the jar. All of the stuff from `mingw32-cheatsheet.txt` is handled automatically if `--host` is passed to configure. Tested on Linux and with mingw32 cross-compiles.

TODO:

1. Test native builds with MinGW on Windows. Aside from MSYS /etc/fstab issues, this should (?) be straightforward.

2. Move the jar into `$datadir` and the .so into `$libdir` to make it easier to follow the Debian Java policy.

3. Embed the JNI library path into the jar via a properties file, so that (except on Windows) we can call System.load() without requiring the LD_LIBRARY_PATH to be set.