From: Joshua Nichols <nichoj@gentoo.org>
To: gentoo-java@lists.gentoo.org
Subject: [gentoo-java] ideas for packages which use maven to build
Date: Wed, 14 Dec 2005 12:05:20 -0500 [thread overview]
Message-ID: <1134579920.4739.23.camel@francisco-repilado.nfic.com> (raw)
I have been thinking recently, and I think I came up with a viable
solution for packaging this that use maven for building.
The first problem is that maven will attempt to download jar
dependencies from a remote repository. This can be avoided by calling
maven with -o, for offline mode.
This leads to the question of where, then, to get the jars from. I had
first thought at build time, we could populate a local repository with
symlinks to jars that we provide from packages. This would work, and
could be automated to some extent, but I think it would be tedious to
maintain a list of jars that each package needs.
So, today I came up with the idea of maintaining a package, like maven-
repo or something, that basically installs a local repository populated
with every jar from the repository... except they would actually be
symlinks to the jars provided by a package. For example:
/usr/share/maven-repo/commons-validator/jars/commons-validator-1.0.2.jar
--> /usr/share/commons-validator/lib/commons-validator.jar
This package would need a good amount of maintenance though, but I still
think it would be the simplest way to provide a maven repository for
building packages.
The next thing would be an eclass to support maven-built packages, like
java-maven.eclass perhaps. This would add a dependency of the most up-
to-date version of maven-repo (~dev-java/maven-repo), and a wrapper for
maven to force offline mode and to use our local repo
at /usr/share/maven-repo/, ie:
emaven() {
maven -Dmaven.repo.local=/usr/share/maven-repo -o "$@" || die "emaven
failed"
}
Additionally, it could do some sanity checks, by parsing the project.xml
and:
make sure that all of its dependencies are in /usr/share/maven-repo
make sure that the symlinks aren't broken, ie the package they point to
is installed
make sure the packages used in maven-repo are in DEPEND/RDEPEND
Once we have this framework in place, then we can also begin getting
maven built from source.
Regards,
Josh
--
gentoo-java@gentoo.org mailing list
next reply other threads:[~2005-12-14 17:06 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-12-14 17:05 Joshua Nichols [this message]
2005-12-14 18:39 ` [gentoo-java] ideas for packages which use maven to build Karl Trygve Kalleberg
2005-12-14 19:54 ` Greg Tassone
2005-12-14 20:00 ` Petteri Räty
2005-12-15 1:14 ` Joshua Nichols
[not found] ` <306bf010512220039y6a1a0ba7q@mail.gmail.com>
2005-12-30 7:23 ` Joshua Nichols
2005-12-14 22:26 ` [gentoo-java] " Jörg Schaible
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1134579920.4739.23.camel@francisco-repilado.nfic.com \
--to=nichoj@gentoo.org \
--cc=gentoo-java@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox