Subject: [2006Q3] Alternatives
To: pkgsrc users <pkgsrc-users@netbsd.org>
From: Nico, Ryoko et Anna <nicolas.pelletier3@ebony.plala.or.jp>
List: pkgsrc-users
Date: 11/20/2006 10:15:33
Hello pkgsrc-users,
I am updating the SWI Prolog package from the 5.6.17 version of SWI
Prolog to its latest and greatest 5.6.23 version. Since the package
makefile does not list a maintainer (the e-mail address is this list's)
and I need SWI Prolog on NetBSD anyway, I rolled up my sleeves and took
a go at updating packages' Makefiles. I will submit the diffs to the
sagacity of more experimented users once I have updated what I wanted to.
SWI Prolog comes in 3 packages in pkgsrc: swi-prolog-lite which installs
the compiler and basic interactive environment (no add-ons, no
graphics); the swi-prolog-packages which installs the add-ons and
graphical environment; and swi-prolog which just builds both others.
For now, I have updated the Makefile, distinfo etc... for
swi-prolog-lite, but I am stuck with the following problem while trying
to update swi-prolog-packages: there is one add-on called jpl which
allows interaction between Java and Prolog. This add-on requires the
presence of a Java compiler, which its configure script calls javac.
Pkgsrc comes with several Java compilers, and not all of them are called
javac. For example, I have jikes installed here, which seems to
understand the same options as Sun's javac, but is not called javac.
Jikes' package directory includes an ALTERNATIVES file whose contents
make me think they allow to call jikes as javac from the build
environment of another package. However, the doc/pkgsrc.txt which proved
a faithful help until now does not have a section on the alternatives'
framework. Looking at other packages with ALTERNATIVES files and the
alternative.mk Makefile did not ring a bell either. Simply adding
ALTERNATIVES_SRC to my Makefile makes pkglint complain I am trying yo
write to a variable I shouldn't. And I suspect my Makefile should just
list somehow a dependency to a tool called javac and not directly jikes
anyway.
Could a knowledgeable person lend me a helpful hand, please ?
Thanks in advance,
--
Nicolas