Bug 834975 - zipios++ RPM not working; source tarball?
Summary: zipios++ RPM not working; source tarball?
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: zipios++
Version: 16
Hardware: All
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Richard Shaw
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-06-25 03:59 UTC by John Morris
Modified: 2012-06-30 22:11 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-06-30 08:35:35 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
specfile patch: apply Debian's source patch; probably fixes to src/zipinputstreambuf.cpp that are the problem (1.73 KB, patch)
2012-06-26 21:29 UTC, John Morris
no flags Details | Diff

Description John Morris 2012-06-25 03:59:14 UTC
Description of problem:
Using this with the FreeCAD RPM currently undergoing review in RPMFusion.

With this version of the zipios++ RPM, FreeCAD can write model files, but is unable to read model files created with this or working versions of zipios++.  The model files it creates can be read by other versions of zipios++.

I can't tell where this zipios tarball came from.  It is not the packed up version on the sourceforge site, and does not match SVN.  It is also not the version in Ubuntu.  As far as I know, SVN and Ubuntu versions work; haven't tested the released tarball on SF.

Version-Release number of selected component (if applicable):
0.1.5.9-6.fc16

How reproducible:
Always

Steps to Reproduce:
1. Build FreeCAD referenced from RPMFusion review ticket https://bugzilla.rpmfusion.org/show_bug.cgi?id=2300
2. Create a model
3. Save it
4. Close it
5. Attempt to reopen it
  
Actual results:
Error message on console; FreeCAD handles the error badly, appearing to have the file open, but with no model

Expected results:


Additional info:

Comment 1 John Morris 2012-06-25 04:01:32 UTC
I should add, I've been messing with this for a few hours now.  I'm pretty sure if the same specfile + patches are used, but with one of the tarballs pointed to above, the package should start working.

Also, this may be an older version of zipios++.  Compared to Ubuntu and SVN, there are quite a large number of changes.  I'd go with SVN.

Comment 2 Richard Shaw 2012-06-26 14:22:34 UTC
Yeah, zipios is a mess. Upstream seems pretty much dead and FreeCAD made modifications to their bundled version. 

Do you know of a SVN upstream? All I can find on sourceforge is CVS and none of the source files seem recently updated.

I'm wondering if FreeCAD even considers their zipios to be bundled since it's not in the 3rdparty directory. It could be considered a fork...

Comment 3 John Morris 2012-06-26 15:37:23 UTC
(In reply to comment #2)
> Yeah, zipios is a mess. Upstream seems pretty much dead and FreeCAD made
> modifications to their bundled version. 

Are you sure they modified their bundled version, or is it a stale version of zipios++, and the modifications came from upstream?

> Do you know of a SVN upstream? All I can find on sourceforge is CVS and none
> of the source files seem recently updated.

Oops, not sure why I said SVN just a few minutes after using CVS to check out the latest code.  :)

> I'm wondering if FreeCAD even considers their zipios to be bundled since
> it's not in the 3rdparty directory. It could be considered a fork...

They do consider it bundled, since the FreeCAD .dfsg tarball (in the SF files page) unbundles it.  On Debian, they use the system zipios++.

I'd just swap in either the CVS source or the Debian source (the difference is in one file, didn't look carefully to see what it was) and be done with it.

BTW, I looked at using the .dfsg tarball for the FreeCAD RPM, but they also removed some STEP files needed for a different piece.  Werner Mayer said that was to comply with some Debian copyright policies, but it's been cleared up and those files should be included for the next release.  Hopefully there's nothing else missing from the .dfsg tarball and we can just use that next time; it's 10MB smaller.

Comment 4 Richard Shaw 2012-06-26 15:44:45 UTC
To answer your question about where the source came from, I'm pretty sure I got it from debian.

Comment 5 Richard Shaw 2012-06-26 17:24:57 UTC
Ok, I'm getting myself confused trying to comapre cvs with what I have with debian, with ubuntu. I just want to rm -rf it all! 

I got my sources from Debian and the Ubuntu versions seems to be identical. I don't know why this version isn't working...

I pulled the ubuntu source and diff but it produces dpatch's not regular patches but they look to be the same as the ones I got from Debian...

Comment 6 John Morris 2012-06-26 18:49:33 UTC
Well dangit, now it seems like I'm the one who's confused.  I just compared all three versions:  CVS, Debian and Fedora, and they're all three identical.  Sorry about that.

Hold off and I'll go back and retrace my steps.  I'll get back later today, most likely.  My apologies for the confusion.

BTW, so I know whether to question my sanity, have you actually tried saving and re-opening a model from FreeCAD (with the Fedora+RPMFusion RPMs, of course) and confirmed the problem on your side?

    John

Comment 7 Richard Shaw 2012-06-26 18:52:26 UTC
(In reply to comment #6)
> Well dangit, now it seems like I'm the one who's confused.  I just compared
> all three versions:  CVS, Debian and Fedora, and they're all three
> identical.  Sorry about that.

Well at least I'm not going crazy! :)


> Hold off and I'll go back and retrace my steps.  I'll get back later today,
> most likely.  My apologies for the confusion.
> 
> BTW, so I know whether to question my sanity, have you actually tried saving
> and re-opening a model from FreeCAD (with the Fedora+RPMFusion RPMs, of
> course) and confirmed the problem on your side?

Not yet. If I have time I'll try tonight but I just got back from vacation and we badly need groceries :)

Comment 8 John Morris 2012-06-26 21:29:01 UTC
Created attachment 594602 [details]
specfile patch:  apply Debian's source patch; probably fixes to src/zipinputstreambuf.cpp that are the problem

(In reply to comment #7)
> Well at least I'm not going crazy! :)

Nope, as expected it's all me.

Turns out that the package you grabbed from me had a 'special' (I'm being kind to myself) tarball.  Apparently (am I innocent if I don't remember?) I grabbed the Debian tarball and unpacked it, then applied the Debian patch, and *then* repacked it all up as though it were original.  I know all about and am all for the 'pristine sources' objective, so I'm clueless why I would've done that, unless I found the tarball somewhere else (in which case I'm just as guilty because I didn't document it).

Attaching a patch to the specfile that should fix this.

> Not yet. If I have time I'll try tonight but I just got back from vacation
> and we badly need groceries :)

'Vacation'?  What is this thing, 'vacation', that you speak of?  Is it delicious?  I'm not sure I've ever had one of those!

Comment 9 Richard Shaw 2012-06-27 13:05:29 UTC
I have reproduced the bug. It seems (as I think your mention) that the file is created correctly. I could even open it in Archive Manger and see the files contained within, but it could not open the file.

I tried gdb, but since there wasn't an actual "crash" it didn't produce any output. I also tried strace which did find that there were seek errors in the file. I think that means that it's having trouble seeking within the zip stream. Since I'm using the latest available sources from Debian, where do we go from here? 

I'll post on the FreeCAD forums and see if they can help.

Comment 10 Richard Shaw 2012-06-27 15:35:53 UTC
Ok, although I did post to the forum, I found the answer on my own.

While comparing the Debian source and package diff I finally noticed that instead of creating a patch, the diff directly patches zipinputstreambuffer.cpp!!!

I didn't know that was acceptable but I guess it is. I have creating a patch from it and installed a local build. I had to test it over X11 Forwarding so the model wouldn't actually display (Coin issue) it didn't produce any console output so I think that's got it!

I'll start builds shortly.

Comment 11 Fedora Update System 2012-06-27 16:01:07 UTC
zipios++-0.1.5.9-7.fc16 has been submitted as an update for Fedora 16.
https://admin.fedoraproject.org/updates/zipios++-0.1.5.9-7.fc16

Comment 12 Fedora Update System 2012-06-27 16:01:17 UTC
zipios++-0.1.5.9-7.fc17 has been submitted as an update for Fedora 17.
https://admin.fedoraproject.org/updates/zipios++-0.1.5.9-7.fc17

Comment 13 John Morris 2012-06-27 16:13:15 UTC
Heh, you missed my comment #8!  Sorry Richard, of course it was my doing.  Thanks for the help.

Comment 14 Richard Shaw 2012-06-27 16:21:42 UTC
(In reply to comment #13)
> Heh, you missed my comment #8!  Sorry Richard, of course it was my doing. 
> Thanks for the help.

Yup, didn't catch what you meant at the time! Everything makes more sense once you already have the answer :)

Comment 15 Richard Shaw 2012-06-27 16:23:21 UTC
Almost forgot! When the builds make it into testing, please try installing them and if it fixes the problem (it should), go give it karma on bodhi so I can push it to stable quicker.

Comment 16 Fedora Update System 2012-06-28 03:30:56 UTC
Package zipios++-0.1.5.9-7.fc17:
* should fix your issue,
* was pushed to the Fedora 17 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing zipios++-0.1.5.9-7.fc17'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-9996/zipios++-0.1.5.9-7.fc17
then log in and leave karma (feedback).

Comment 17 John Morris 2012-06-28 06:27:24 UTC
Great, this fixes it.  Karma left on bodhi.

(In reply to comment #14)
> (In reply to comment #13)
> > Heh, you missed my comment #8!  Sorry Richard, of course it was my doing. 
> > Thanks for the help.
> 
> Yup, didn't catch what you meant at the time! Everything makes more sense
> once you already have the answer :)

Ha, the attached patch would've explained everything, but I must've drowned it out with all the blabber.  Hope it didn't cost you too much time to figure it out again.

Thanks again!  I guess this can be closed?

Comment 18 Richard Shaw 2012-06-28 13:05:55 UTC
Nah, Bodhi will close it once it hits the stable repos.

Comment 19 Fedora Update System 2012-06-30 08:35:35 UTC
zipios++-0.1.5.9-7.fc17 has been pushed to the Fedora 17 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 20 Fedora Update System 2012-06-30 22:11:24 UTC
zipios++-0.1.5.9-7.fc16 has been pushed to the Fedora 16 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.