Bug 590122

Summary: Error in generate-tarball.sh script
Product: [Fedora] Fedora Reporter: P. A. López-Valencia <palopezv>
Component: calibreAssignee: Kevin Fenzi <kevin>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 13CC: ionut
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-05-22 05:35:23 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:

Description P. A. López-Valencia 2010-05-07 18:54:07 UTC
Description of problem:

The script tries to extract a tar.gz file forcing bzip2 decompression, failing in the attempt. Then it tries to compress a non-existent extracted directory

This is the original script:

#!/bin/sh

VERSION=$1

tar -xvjf calibre-$VERSION.tar.gz
rm -f calibre/resources/fonts/liberation/*
rm -f calibre/resources/fonts/prs500/*

tar -cvjf calibre-$VERSION-nofonts.tar.bz2 calibre


Version-Release number of selected component (if applicable):
0.6.47 (btw current upstream is 0.6.51 at the time of this report).

How reproducible:

Always

Steps to Reproduce:
1. Try to produce nofonts tarball by hand.
2. It fails.
3.
  
Actual results:
It does nothing but create a bogus tarball

Expected results:

Extract original tar.gz 

Additional info:


A parsimonious fix: Let GNU tar figure out the actual compression scheme automatically based on file extensions (this works with GNU tar since F11 if memory serves me right), by using the a switch:


#!/bin/sh

VERSION=$1

tar -xvaf calibre-$VERSION.tar.gz
rm -f calibre/resources/fonts/liberation/*
rm -f calibre/resources/fonts/prs500/*

tar -cvaf calibre-$VERSION-nofonts.tar.bz2 calibre

Comment 1 P. A. López-Valencia 2010-05-07 18:59:46 UTC
Hmm... Latest version is 0.6.52 already. A moving target if any!

Comment 2 Fedora Admin XMLRPC Client 2010-05-13 04:25:08 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 3 Kevin Fenzi 2010-05-22 05:35:23 UTC
Fixed in rawhide. 

I'll push it to other branches when I'm able to update them. ;) 

Thanks for the report!