Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 21 Sep 2000 21:53:43 -0500 (CDT)
From:      Mike Meyer <mwm@mired.org>
To:        Archie Cobbs <archie@whistle.com>
Cc:        cvs-all@freebsd.org
Subject:   Re: cvs commit: ports INDEX
Message-ID:  <14794.51639.676162.445187@guru.mired.org>
In-Reply-To: <112230153@toto.iv>

next in thread | previous in thread | raw e-mail | index | archive | help
Archie Cobbs writes:
> This brings up a semi-serious point. There is tons of Java code
> out there that is distributed as JAR files, or maybe JAR files plus
> a native shared library. Just taking one a random example, SableCC:
> http://www.sable.mcgill.ca/sablecc/
> 
> This is an application, but there are also various Java libraries.
> 
> We need to have a standard way of installing this kind of software.
> Better yet, it should work for any of our Java runtimes (JDK, kaffe, ...?)
>
> Thoughts?

Any language that supports externally-locatable modules has similar
problems. That includes Python, probably Ruby, and I'm sure there are
others. Perl is the most interesting, as it is in the system build,
and has modules that are installed in /usr/lib instead of
${PREFIX}/lib. Last time I looked, it was broken with respect to
${PREFIX} because /usr/local was wired into the interpreter and module
builder, so ports with Perl packages always installed them in
/usr/local/lib, no matter what ${PREFIX} says.

With that in mind, I'd propose the following version:

- Ala Java, the default search path for external modules should be
  ${PREFIX}/share/<lang-specific-directory>. The interpreter should
  build to search ${LOCALBASE}/share/<lang-specific-directory>.
  
- Stealing a page from Python & Perl, native libraries go in
  ${PREFIX}/share/<lang-specific-directory>/<arch-specific-directory>. 

- If helper scripts are needed, they should be installed in
  ${PREFIX}/bin. A "wrapper port" that would let a port just do:
  	ln -s ${PREFIX}/bin/java-wrapper ${PREFIX}/bin/MyName
  would probably help make sure the ports get things right (I see a lot
  of shell scripts that are PREFIX-deficient).

As someone who has purposely separated ${LOCALBASE} from things that
aren't ports, I would greatly appreciate a make.conf option
"OTHER_MODULE_DIRS" (or some such) that can be set to a list of
directories that will be added to the Perl (and Python, and Ruby, and
Java) default search paths.

	Thanx,
	<mike


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?14794.51639.676162.445187>