Bug 590122 - Error in generate-tarball.sh script
Error in generate-tarball.sh script
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: calibre (Show other bugs)
13
All Linux
low Severity medium
: ---
: ---
Assigned To: Kevin Fenzi
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-05-07 14:54 EDT by P. A. López-Valencia
Modified: 2010-05-22 01:35 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-05-22 01:35:23 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description P. A. López-Valencia 2010-05-07 14:54:07 EDT
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 14:59:46 EDT
Hmm... Latest version is 0.6.52 already. A moving target if any!
Comment 2 Fedora Admin XMLRPC Client 2010-05-13 00:25:08 EDT
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 01:35:23 EDT
Fixed in rawhide. 

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

Thanks for the report!

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