Bug 193898

Summary: Review Request: Jython - Java source interpreter
Product: [Fedora] Fedora Reporter: Igor Foox <ifoox>
Component: Package ReviewAssignee: Anthony Green <green>
Status: CLOSED RAWHIDE QA Contact: Fedora Package Reviews List <fedora-package-review>
Severity: medium Docs Contact:
Priority: medium    
Version: rawhideCC: green, overholt, rafaels, rlandman, tromey
Target Milestone: ---Flags: kevin: fedora-cvs+
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-06-01 05:27:41 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 193889, 193896, 193897    
Bug Blocks: 163779    

Description Igor Foox 2006-06-02 19:22:45 UTC
Spec URL: http://people.redhat.com/ifoox/extras/jython.spec
SRPM URL: http://people.redhat.com/ifoox/extras/jython-2.2-0.a0.2jpp_1fc.src.rpm
Description:
Jython is an implementation of the high-level, dynamic, object-oriented
language Python seamlessly integrated with the Java platform. The
predecessor to Jython, JPython, is certified as 100% Pure Java. Jython is
freely available for both commercial and non-commercial use and is
distributed with source code. Jython is complementary to Java and is
especially suited for the following tasks: Embedded scripting - Java
programmers can add the Jython libraries to their system to allow end
users to write simple or complicated scripts that add functionality to the
application. Interactive experimentation - Jython provides an interactive
interpreter that can be used to interact with Java packages or with
running Java applications. This allows programmers to experiment and debug
any Java system using Jython. Rapid application development - Python
programs are typically 2-10X shorter than the equivalent Java program.
This translates directly to increased programmer productivity. The
seamless interaction between Python and Java allows developers to freely
mix the two languages both during development and in shipping products.

I am submitting this package with several other packages (5 in total), and these are my first packages for Extras, so they may need a sponsor.

Comment 1 Igor Foox 2006-06-02 19:28:23 UTC
Adding bug dependencies for all the packages that Jython depends on:
* mysql-connector-java
* ht2html
* libreadline-java

Comment 2 Anthony Green 2006-07-14 07:01:16 UTC
Just some quick comments from looking at parts of the spec file..

- Summary is odd: "Java source interpreter"
- Source lines should be URLs to sources
- Remove Epoch
- Change Group to Development/Libraries
- Make BuildRoot standard	
- Remove these lines...
Distribution:	JPackage
Vendor:		JPackage Project

That's it for now.  Thanks for submitting this.  If nobody picks this up, I'll
do a formal review once the dependencies have been approved.


Comment 3 Anthony Green 2006-07-14 07:18:19 UTC
BTW, I don't think we should be linking libreadline-java with jython since I
believe the licenses are incompatible.  See this thread for discussion and a
potential solution:
http://sourceforge.net/mailarchive/message.php?msg_id=707283


Comment 4 Igor Foox 2006-09-09 00:51:47 UTC
New files:
http://people.redhat.com/ifoox/extras/jython-2.2-0.a0.2jpp_2fc.src.rpm
http://people.redhat.com/ifoox/extras/jython.spec

(In reply to comment #2)
> Just some quick comments from looking at parts of the spec file..
> 
> - Summary is odd: "Java source interpreter"
Fixed
> - Source lines should be URLs to sources
The source appears to be a CVS snapshot, but I'll check to make sure whether
it's not downloaded.
> - Remove Epoch
Fixed.
> - Change Group to Development/Libraries
Fixed.
> - Make BuildRoot standard	
Fixed.
> - Remove these lines...
> Distribution:	JPackage
> Vendor:		JPackage Project
Fixed. 

Also fixed:
- Add dist tag.
- Fix compile line to use the system Python libraries instead of the python2.2
source.
- Remove Source1 (python2.2 library).
- Move buildroot removal from prep to install.
- Use libedit (EditLine) instead of GNU readline.



(In reply to comment #3)
> BTW, I don't think we should be linking libreadline-java with jython since I
> believe the licenses are incompatible.  See this thread for discussion and a
> potential solution:
> http://sourceforge.net/mailarchive/message.php?msg_id=707283

I've built the latest version of libreadline-java against libedit (EditLine)
instead of GNU readline, libedit is LGPL, and is what the poster in the thread
you mention proposes. So this should be fine.  See bug #193896.

There are still many issues to resolve with this package, I will try to resolve
most of them tomorrow. But I have a few questions which hopefully someone can
answer. 

1. rpmlint gives me errors like this when running it on the main rpm:
E: jython non-executable-script /usr/share/jython/Lib/Cookie.py 0644
It doesn't give it for all the .py files in that directory, even though they all
have the same permissions. Should these be 755, or should these files be moved
to /usr/lib instead?

2. What should be the group for jython-demo?
I put it in Development/Documentation along with the manual and javadoc, but I'm
not sure this is right.

Comment 5 Anthony Green 2006-09-09 02:40:15 UTC
(In reply to comment #4)
> > - Change Group to Development/Libraries
> Fixed.

I'm sorry.  This was another mistake of mine.  It should be "System
Environment/Libraries".

> 1. rpmlint gives me errors like this when running it on the main rpm:
> E: jython non-executable-script /usr/share/jython/Lib/Cookie.py 0644
> It doesn't give it for all the .py files in that directory, even though they all
> have the same permissions. Should these be 755, or should these files be moved
> to /usr/lib instead?

I think staying in /usr/share is fine.  I don't know why it's complaining.
 
> 2. What should be the group for jython-demo?
> I put it in Development/Documentation along with the manual and javadoc, but I'm
> not sure this is right.

Actually, FE has no Development/Documentation group.  It should just be
Documentation.  I can't think of a better place for the demos.


Comment 6 Igor Foox 2006-09-09 17:33:29 UTC
(In reply to comment #5)
> (In reply to comment #4)
> > > - Change Group to Development/Libraries
> > Fixed.
> 
> I'm sorry.  This was another mistake of mine.  It should be "System
> Environment/Libraries".

Seems like System/Environment/Libraries is less appropriate for jython than
Development/Libraries or even Development/Languages. Why do you say that
System/Environment/Libraries is the correct one?


Comment 7 Anthony Green 2006-09-09 17:39:15 UTC
(In reply to comment #6)
> Seems like System/Environment/Libraries is less appropriate for jython than
> Development/Libraries or even Development/Languages. 

Development/Libraries doesn't really apply to Java, since it's for .so files and
other things you would only use at build-time.  I think you're right about
Development/Languages though.  Let's use that one.




Comment 8 Igor Foox 2006-09-09 18:19:20 UTC
(In reply to comment #7)
>I think you're right about
> Development/Languages though.  Let's use that one.
OK. 

Another important issue which I'm not sure how to address is the license. The
license file calls it the 'Jython license'
(http://www.jython.org/Project/license.html), but there is not equivalent
appropriate license that rpmlint likes. What do we do in a case like this?

Comment 9 Igor Foox 2006-09-09 18:33:52 UTC
New files:
http://people.redhat.com/ifoox/extras/jython-2.2-0.a0.2jpp_3fc.src.rpm
http://people.redhat.com/ifoox/extras/jython.spec

There are currently 3 issues remaining with the package (that I know of)
1. License (comment #8):
W: jython invalid-license Modified CNRI Open Source License

2. Copying files from python:
For some reason the jython buildsystem copies some files from the python
standard library into it's own directory. Since I made it use the system python
instead of the python2.2 that was previously included, we now have duplication.
These are the files that also produce permission errors from rpmlint:
E: jython non-executable-script /usr/share/jython/Lib/uu.py 0644
This is because they are not executable but contain a #!. I'll try to figure out
why jython copies these files and if we can make it use the ones in
%{_libdir}/python2.4/site-packages instead. If not I'll see if I can symlink
them instead of copying.

3. Missing jar manifest in one of the demo jars:
E: jython-demo no-jar-manifest /usr/share/jython/Demo/jreload/example.jar
I'm not sure whether this is an important issue since this is just a demo jar,
which will probably function without the manifest file anyway.

I'll try to resolve issue 2 (and maybe 3) today and tomorrow, but any
suggestions are welcome. But I'm really not sure what to do about issue 1.

Comment 10 Anthony Green 2006-09-10 04:50:06 UTC
(In reply to comment #9)
> There are currently 3 issues remaining with the package (that I know of)
> 1. License (comment #8):
> W: jython invalid-license Modified CNRI Open Source License

I think we can ignore this.

Comment 11 Igor Foox 2006-09-22 14:09:29 UTC
New files:
http://people.redhat.com/ifoox/extras/jython.spec
http://people.redhat.com/ifoox/extras/jython-2.2-0.a0.2jpp_4fc.src.rpm

I've fixed the problem with the non-executable scripts by bringing back jython's
copy of python2.2 which was carried in the srpm, since it doesn't actually work
when I link it against python 2.4. I think that the no-manifest issue can be
ignored since the example jar works fine anyway. If you think that that the
license issue is OK then I think this is pretty much done.

Comment 12 Igor Foox 2006-09-22 14:29:23 UTC
New files:
http://people.redhat.com/ifoox/extras/jython.spec
http://people.redhat.com/ifoox/extras/jython-2.2-0.a0.2jpp_5fc.src.rpm

Minor fix, removing redundant patch.

Comment 13 Igor Foox 2006-09-28 23:25:53 UTC
Anthony,
Any chance you could take a look at this soon?

Comment 14 Anthony Green 2006-10-21 18:02:06 UTC
Sorry for the long delay.

Where did you get the source tarball from?  If we're not using an upstream
release, then the spec file should explain where the sources are from and how to
get them.


Comment 15 Anthony Green 2006-10-21 18:05:17 UTC
Building with 'mock' fails like so...

+ /usr/lib/rpm/check-buildroot
Binary file
/var/tmp/jython-2.2-0.a0.2jpp_5fc.fc6-root-mockbuild/usr/lib/debug/usr/lib/gcj/jython/jreload.so.debug
matches
Found '/var/tmp/jython-2.2-0.a0.2jpp_5fc.fc6-root-mockbuild' in installed files;
aborting
error: Bad exit status from /var/tmp/rpm-tmp.37933 (%install)



Comment 16 Andrew Overholt 2006-11-16 18:30:51 UTC
I've taken this over from Igor.  I made a few changes and updated to 2.2a1. 
I've also fixed the mock error you were seeing, Anthony, and added a script to
fetch the tarball and explain how to do it.

http://people.redhat.com/overholt/jython.spec
http://people.redhat.com/overholt/jython-2.2-0.a1.1jpp_1fc.fc7.src.rpm

and the differences between my spec and Igor's latest:

http://people.redhat.com/overholt/jython.spec.diff

Comment 17 Igor Foox 2006-11-17 04:15:00 UTC
Andrew, thanks for taking care of this. Unfortunately I couldn't find the time to deal with it lately.

Comment 18 Anthony Green 2006-12-04 19:53:13 UTC
(In reply to comment #16)
> I've taken this over from Igor.  I made a few changes and updated to 2.2a1. 
> I've also fixed the mock error you were seeing, Anthony, and added a script to
> fetch the tarball and explain how to do it.

Sorry I missed the update on this.  I'm rerunning it in mock and will go through
the formal review assuming there are no problems.

Thanks


Comment 19 Anthony Green 2006-12-04 20:59:16 UTC
Andrew - the package naming goes against current package naming rules...

http://fedoraproject.org/wiki/PackagingDrafts/JavaPackageNaming

I've simply been removing the "jpp" part from my packages (see itext, for instance).


Comment 20 Andrew Overholt 2006-12-19 19:56:40 UTC
Newly updated spec and SRPM without jpp:

http://people.redhat.com/overholt/jython.spec
http://people.redhat.com/overholt/jython-2.2-0.a1.1.src.rpm

Comment 21 Andrew Overholt 2006-12-19 20:07:23 UTC
Newly updated spec and SRPM with correct release:

http://people.redhat.com/overholt/jython.spec
http://people.redhat.com/overholt/jython-2.2-0.1.a1.src.rpm

Comment 22 Anthony Green 2006-12-20 13:33:44 UTC
Thanks Andrew.  Here's the full review.  I only have two comments.  One seems
easy and the other looks like a little more work.  Look for the lines starting
in 'X'.

* package meets and packaging guidelines.
* specfile is properly named, is cleanly written and uses macros consistently.
* dist tag is present.
* build root is correct.
* license field matches the actual license.
* license is open source-compatible.
* License text included in package.
* source files match upstream (extracted from upstream cvs so no md5sum available.)
* latest version is being packaged.
* BuildRequires are proper.
* package builds in mock.

* rpmlint jython-2.2-0.1.a1.fc6.i386.rpm
W: jython invalid-license Modified CNRI Open Source License
We can ignore this.

rpmlint jython-demo-2.2-0.1.a1.fc6.i386.rpm
W: jython-demo invalid-license Modified CNRI Open Source License
E: jython-demo no-jar-manifest /usr/share/jython/Demo/jreload/example.jar
We can ignore these.

rpmlint jython-javadoc-2.2-0.1.a1.fc6.i386.rpm
W: jython-javadoc invalid-license Modified CNRI Open Source License
We can ignore this.

rpmlint jython-2.2-0.1.a1.fc6.src.rpm
W: jython invalid-license Modified CNRI Open Source License
We can ignore this.

X are these final provides and requires are sane?:
jython-2.2-0.1.a1.fc6.i386.rpm
  jython-2.2.jar.so
  jython = 2.2-0.1.a1.fc6
==
  java-gcj-compat >= 1.0.31
  jpackage-utils >= 0:1.5
  oro
  python >= 2.4
  servlet

Don't we need to Require libreadline-java and mysql-connector-java?

* shared libraries are present, but no ldconfig required.
* package is not relocatable.
* owns the directories it creates.
* doesn't own any directories it shouldn't.
* no duplicates in %files.
* file permissions are appropriate.
* %clean is present.
* %check is not present
* scriptlets OK
* code, not content.
X ht2html generated documentation isn't being generated even
  though we require ht2html.
  I think build.xml needs one more if="full-build" removed, and
  then these docs should probably go in a documentation package.
* %docs are not necessary for the proper functioning of the package.
* no headers.
* no pkgconfig files.
* no libtool .la droppings.
* not a GUI app (no .desktop file required).
* not a web app.


Comment 23 Andrew Overholt 2007-01-11 23:02:59 UTC
Okay, I've (finally!) taken care of the two issues above.  Here's the new spec
and SRPM:

http://people.redhat.com/overholt/jython.spec
http://people.redhat.com/overholt/jython-2.2-0.2.a1.src.rpm

Here's a diff from the most recently reviewed spec and the one above:

http://people.redhat.com/overholt/jython.spec.patch

Thanks!

Comment 24 Anthony Green 2007-01-22 02:08:23 UTC
(In reply to comment #23)
> Okay, I've (finally!) taken care of the two issues above.  Here's the new spec
> and SRPM:

rpmlint now complains about the explicit libreadline-java dependency, but I
think this must be a bug in rpmlint.  So... APPROVED!  

Be sure to close this bug once you've pushed the package out.  Thanks!

Comment 25 Andrew Overholt 2007-02-10 17:27:41 UTC
*** Bug 227078 has been marked as a duplicate of this bug. ***

Comment 26 Kevin Fenzi 2007-06-01 05:27:41 UTC
This package seems to have been imported and built a while back. 
Closing this review bug now. 

Comment 27 Ruediger Landmann 2010-07-27 00:29:11 UTC
Package Change Request
=======================
Package Name: jython
New Branches: EL-5
Owners: rlandmann
InitialCC: 

I have discussed this with Andrew Overholt, the package owner, and he is happy for me to maintain this branch.

Comment 28 Kevin Fenzi 2010-07-30 19:49:52 UTC
CVS done (by process-cvs-requests.py).