Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 17350 - [rfc] jakarta-commons.eclass
Summary: [rfc] jakarta-commons.eclass
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All All
: High normal
Assignee: Dylan Carlson (RETIRED)
URL: http://jakarta.apache.org/commons
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-03-12 01:58 UTC by Lim Swee Tat (RETIRED)
Modified: 2003-03-22 14:51 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
java-commons.eclass (java-commons.eclass,3.44 KB, text/plain)
2003-03-12 01:59 UTC, Lim Swee Tat (RETIRED)
Details
commons-beanutils-1.6.1.ebuild (commons-beanutils-1.6.1.ebuild,1.13 KB, text/plain)
2003-03-12 02:00 UTC, Lim Swee Tat (RETIRED)
Details
commons-cli-1.0.ebuild (commons-cli-1.0.ebuild,576 bytes, text/plain)
2003-03-12 02:05 UTC, Lim Swee Tat (RETIRED)
Details
commons-collections-2.1-r2.ebuild (commons-collections-2.1-r2.ebuild,688 bytes, text/plain)
2003-03-12 02:06 UTC, Lim Swee Tat (RETIRED)
Details
commons-dbcp-1.0-r2.ebuild (commons-dbcp-1.0-r2.ebuild,1019 bytes, text/plain)
2003-03-12 02:07 UTC, Lim Swee Tat (RETIRED)
Details
commons-logging-1.0.2-r2.ebuild (commons-logging-1.0.2-r2.ebuild,713 bytes, text/plain)
2003-03-12 02:09 UTC, Lim Swee Tat (RETIRED)
Details
commons-digester-1.4.1.ebuild (commons-digester-1.4.1.ebuild,1.28 KB, text/plain)
2003-03-12 02:10 UTC, Lim Swee Tat (RETIRED)
Details
commons-pool-1.0.1-r3.ebuild (commons-pool-1.0.1-r3.ebuild,922 bytes, text/plain)
2003-03-12 02:15 UTC, Lim Swee Tat (RETIRED)
Details
commons-validator-1.0.1-r1.ebuild (commons-validator-1.0.1-r1.ebuild,1.43 KB, text/plain)
2003-03-12 02:17 UTC, Lim Swee Tat (RETIRED)
Details
commons-fileupload-1.0_beta.ebuild (commons-fileupload-1.0_beta.ebuild,656 bytes, text/plain)
2003-03-12 02:31 UTC, Lim Swee Tat (RETIRED)
Details
commons-discovery-0.1.ebuild (commons-discovery-0.1.ebuild,830 bytes, text/plain)
2003-03-12 02:45 UTC, Lim Swee Tat (RETIRED)
Details
commons-httpclient-2.0_alpha3.ebuild (commons-httpclient-2.0_alpha3.ebuild,700 bytes, text/plain)
2003-03-12 02:47 UTC, Lim Swee Tat (RETIRED)
Details
commons-lang-1.0.1-r1.ebuild (commons-lang-1.0.1-r1.ebuild,772 bytes, text/plain)
2003-03-12 02:54 UTC, Lim Swee Tat (RETIRED)
Details
commons-net-1.0.0.ebuild (commons-net-1.0.0.ebuild,563 bytes, text/plain)
2003-03-12 03:05 UTC, Lim Swee Tat (RETIRED)
Details
updated java-commons.eclass (java-commons.eclass,3.57 KB, text/plain)
2003-03-17 16:14 UTC, Dylan Carlson (RETIRED)
Details
java-commons.eclass (java-commons.eclass,3.17 KB, text/plain)
2003-03-17 19:41 UTC, Lim Swee Tat (RETIRED)
Details
jakarta-commons.eclass (jakarta-commons.eclass,3.85 KB, text/plain)
2003-03-18 17:46 UTC, Dylan Carlson (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 01:58:25 UTC
I have done this eclass for java-commons.  It's really for all the commons in
jakarta.apache.org.  And in so doing, updated the necessary ebuilds for the
commons stuff.

Reproducible: Always
Steps to Reproduce:
Comment 1 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 01:59:53 UTC
Created attachment 9281 [details]
java-commons.eclass

This is the java-commons.eclass.  This is not as elegant as I would want it. 
So if you are a bash guru, just tune it up a little.  The significant portions
that are required by the packages are there.
Comment 2 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 02:00:41 UTC
Created attachment 9282 [details]
commons-beanutils-1.6.1.ebuild

Updated proof of concept for beanutils 1.6.1
Comment 3 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 02:05:53 UTC
Created attachment 9283 [details]
commons-cli-1.0.ebuild

*NEW* commons-cli
Comment 4 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 02:06:37 UTC
Created attachment 9284 [details]
commons-collections-2.1-r2.ebuild

*Updated* to use the java-commons.eclass
Comment 5 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 02:07:44 UTC
Created attachment 9285 [details]
commons-dbcp-1.0-r2.ebuild

*Updated* to use java-commons.eclass
Comment 6 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 02:09:24 UTC
Created attachment 9286 [details]
commons-logging-1.0.2-r2.ebuild

*Updated* to use java-commons.eclass
Comment 7 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 02:10:52 UTC
Created attachment 9287 [details]
commons-digester-1.4.1.ebuild

*Updated* to new version
Comment 8 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 02:15:34 UTC
Created attachment 9288 [details]
commons-pool-1.0.1-r3.ebuild

*Updated* to use java-commons
Comment 9 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 02:17:28 UTC
Created attachment 9289 [details]
commons-validator-1.0.1-r1.ebuild

*Updated* to use java-commons
Comment 10 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 02:31:03 UTC
Created attachment 9290 [details]
commons-fileupload-1.0_beta.ebuild

*NEW* Added this package.
Comment 11 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 02:45:26 UTC
Created attachment 9291 [details]
commons-discovery-0.1.ebuild

*NEW* Added
Comment 12 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 02:47:38 UTC
Created attachment 9292 [details]
commons-httpclient-2.0_alpha3.ebuild

*NEW* Add this now.
Comment 13 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 02:54:27 UTC
Created attachment 9293 [details]
commons-lang-1.0.1-r1.ebuild

*Updated* to use java-commons
Comment 14 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-12 03:05:00 UTC
Created attachment 9294 [details]
commons-net-1.0.0.ebuild

*NEW* Added this one.
Comment 15 Adrian Almenar 2003-03-12 23:49:30 UTC
Im getting this one since i made all the current jakarta-commons ebuilds available.
Comment 16 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-13 01:46:28 UTC
Is there anyway I can help to speed the process up a little to get this in the official portage tree??
Comment 17 Dylan Carlson (RETIRED) gentoo-dev 2003-03-16 21:14:09 UTC
FYI -- I just checked in dev-java/commons-cli for something else I was working on.  
 
Lim:  This is great that these ebuilds have been submitted, but I have to ask: 
What is the reasoning behind making an eclass for commons?  
 
I didn't see any compelling case to make an eclass for either the commons or avalan 
classes.  But maybe I'm missing something. 
Comment 18 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-16 21:24:04 UTC
There is:
a. If you do look at the ebuilds now, they are significantly reduced.
b. It lowers the bar for someone to add yet another package for java-commons. 
c. Certainly, if you look at it, the class can be used for just about _any_ java package, since everything that is on jakarta now uses ant.
d. And since all the src_compile are the same, you really want to flag this as a common installation code.
e. It's just good programming practice.  So that if all the installation process needs to be changed, since it's all in one file, you really want to just use the eclass.
f. On the other hand, why don't you answer the question on why you do not need to make an eclass for the java classes, in and especially since they do share some amount of significant code.

Ciao
ST Lim
Comment 19 Adrian Almenar 2003-03-17 10:36:56 UTC
im testing all the ebuild and the eclass, so sooner it will be available on testing on portage.
Comment 20 Adrian Almenar 2003-03-17 10:51:14 UTC
Dylan, can you take care of commons-cli ebuild so it uses the eclass ?
cause there's a patch you made and i dont have time now on checking it.

im updating all others, and adding the new ones.

Best Regards,

Adrian
Comment 21 Dylan Carlson (RETIRED) gentoo-dev 2003-03-17 16:11:49 UTC
I fixed/hacked away at the eclass a little bit, and it's checked in.

* added a 'makedoc' target so that USE=doc can be implemented for API docs
* changed ${targetlist} --> ${ant_targetlist} because it was breaking the while loops from using the correct targets.

Also checked in dev-java/commons-cli-1.0-r2 which makes use of this eclass... currently masked for testing.

Have not looked at any of these other ebuilds (yet).
Comment 22 Dylan Carlson (RETIRED) gentoo-dev 2003-03-17 16:14:15 UTC
Created attachment 9544 [details]
updated java-commons.eclass

This is in CVS as well...
Comment 23 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-17 19:02:11 UTC
Cool.  You might like to note that:
a. for commons-cli, you can instead of using a patch file, use a command:
   echo "final.name=commons-cli-1.0" >> build.properties
b. for the eclass that is currently in CVS, you might like to change the section for make to use either or dist-jar or jar instead of just using the "jar" target at the moment.  I had used the "dist" target.
c. You can remove the comment in the all build section.

Ciao
ST Lim
Comment 24 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-17 19:12:57 UTC
Oops.  Sorry about the commons-cli.  If you needed to change the name of the file, you do need to use a patch.  Just tested, and build.properties does not work.
Comment 25 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-17 19:41:54 UTC
Created attachment 9546 [details]
java-commons.eclass

You'll probably find that the "dist" target will be more univerally known. 
Most of the projects have a dist target, and do not have a jar target.	This
eclass reflects this change.
Comment 26 Dylan Carlson (RETIRED) gentoo-dev 2003-03-17 19:46:44 UTC
Something better needs to be done in the make section.  I'm thinking about it.  Unfortunately, 'dist' is not a good target because it builds _everything_ and that's not what we want, so to avoid building docs/javadocs if the user doesn't want them.

jar/dojar/dist-jar are all valid depending on which package we're talking about.  It'd be nice if they picked one and standardized on it.

That's one of the problems with the eclass method.  If all commons-* distributables were packaged the same way and had the same build.xml conventions, it would be a no-brainer.

I'll look at this some more tonight maybe and see if I can fix up the make target at least.  
Comment 27 Dylan Carlson (RETIRED) gentoo-dev 2003-03-17 19:47:43 UTC
Comment on attachment 9546 [details]
java-commons.eclass

invalid
Comment 28 Adrian Almenar 2003-03-18 08:28:12 UTC
i think we should change the name of the eclass from java-commons to jakarta-commons, cause its only jakarta stuff so it should be better named.

Any thoughs on renaming the eclass ?
Comment 29 Dylan Carlson (RETIRED) gentoo-dev 2003-03-18 17:44:23 UTC
Adrian:  I agree.  It's been done.  

eclass was renamed to jakarta-commons, functions were renamed to jakarta-commons, and the dev-java/commons-collections and dev-java/commons-cli ebuilds were corrected.
Comment 30 Dylan Carlson (RETIRED) gentoo-dev 2003-03-18 17:46:57 UTC
Created attachment 9574 [details]
jakarta-commons.eclass

Realize that all the other ebuilds attached to this bug will now need to be
changed, and don't forget the function names too.
Comment 31 Adrian Almenar 2003-03-19 09:20:43 UTC
Fine, ill work on these ebuilds ASAP, thanks also for making the eclass change !
Comment 32 Dylan Carlson (RETIRED) gentoo-dev 2003-03-22 07:49:17 UTC
Alrighty.  All the builds are checked in.  Test them out, and open new bugs for whichever ebuilds you do happen to catch bugs in.

On another note:

We will need to do some improving of this eclass.  A few of them don't build jars, just classes.  I didn't expend much thought on this, and hacked around it inside the ebuilds for now.  We'll need a better long-term solution.  If you have any ideas, please send them on.   

Closing.  Cheers
Comment 33 Lim Swee Tat (RETIRED) gentoo-dev 2003-03-22 11:06:41 UTC
Hi,

  I've mentioned that there is no definite target in between packages to get jar files.  The most common target/denominator in this case is really to use the dist target if you want jar files. :)  And this is effective on the other apache based java projects.
  Someone will need to highlight this problem with target standards with either ant or the apache java groups.

Ciao
ST Lim
Comment 34 Dylan Carlson (RETIRED) gentoo-dev 2003-03-22 14:51:38 UTC
This is true, yet 'dist' isn't an acceptable target for us in the larger picture of what we 
want to achieve with Gentoo.  The 'doc' USE flag, in particular should be active in all 
the Java builds, which rules out using the 'dist' target. 
 
I have temporarily worked around this by building jars out of the class files manually, 
but nothing has been integrated into the eclass as of yet. 
 
My basic requirement for any new ebuild (at least ones that I'm working on) is that it 
must be able to accept the 'doc' flag.  Additionally, if compiling from source, it should 
be able to use 'jikes', unless there's some incompatibility that cannot be resolved 
through normal means. 
 
I am reasonably suspect of anything that doesn't compile successfully with Jikes.