automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Archives and/or Java


From: Simon Richter
Subject: Re: Archives and/or Java
Date: Wed, 5 Feb 2003 21:46:37 +0100
User-agent: Mutt/1.5.3i

Alexandre,

On Tue, Feb 04, 2003 at 08:00:07PM +0100, Alexandre Duret-Lutz wrote:
> >>> "Simon" == Simon Richter <address@hidden> writes:

[Archives as directories]

>  Simon> ... Hrm, that would go in the direction of generic archive target
>  Simon> support, and one would have to think about files in subdirectories of
>  Simon> archives as well ("propertiesdir = $(foo_jardir)/properties"? Ick.).

> Ouch.

Jup, my first thought as well, but I cannot think of a better solution
currently.

> data_ARCHIVES = foo.tar.gz bar.zip baz.jar

> Automake can match suffixes like it does in _SOURCES to
> select a compiler.

Sounds good.

> BTW, an item on the TODO list is to merge _LIBRARIES and _LTLIBRARIES.
> We can decide wether the user want to build a libtool library
> or a plain static library by looking at the suffix.

> Your $(propertiesdir) example apart, _ARCHIVES and _LIBRARIES do
> not look very different, do they?

Indeed, but I think that subdirectories are a definite must for
archives, while they would complicate building of libraries if they were
handled similarly. While jar files are, technically speaking, libraries,
they may also contain arbitrary files that are added to the
interpreter's visible filespace; it would be difficult to express in
which subdirectory such files should reside in (.class files are easy).

The question is basically: Should jar files be treated as libraries,
losing the ability to stuff application data into them, or should they
be treated as to-be-implemented archives, which can contain anything.
I'd vote for the latter choice, because it doesn't add to the complexity
of _LIBRARIES (which will eventually be a good thing in light of the
_LTLIBRARIES merge), gives us an important feature (additional members
in the jar) without being an evil hack and also gives us the archive
feature (which isn't too important standalone).

>  Simon> To do for archives: Files installed in archives need to
>  Simon> be installed at build time,

> I guess this is required to support things like $(propertiesdir).
> Is this still true if subdirectories are not used? (Like when
> we build _LIBRARIES.)

Hrm, I believe there is no point in throwing _LIBRARIES and _ARCHIVES
together. _LIBRARIES are built from _SOURCES, the intermediate objects
are basically nameless (never mentioned in the Makefile.am). _ARCHIVES'
members have names, and those are important at runtime, so there is no
point in using _SOURCES; also they can be anything, from data over
programs to other archives, so it makes sense IMO to allow the other
primaries here (with some sanity checks -- there is no point in
including _LTLIBRARIES or _PROGRAMS unless static).

   Simon

-- 
GPG Fingerprint: 040E B5F7 84F1 4FBC CEAD  ADC6 18A0 CC8D 5706 A4B4

Attachment: pgpW1GjK3Feqi.pgp
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]