Bug 92444 - bdiff requires unavailable /usr/bin/tempfile
bdiff requires unavailable /usr/bin/tempfile
Product: Red Hat Linux
Classification: Retired
Component: bzip2 (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Jiri Ryska
Ben Levenson
Depends On:
  Show dependency treegraph
Reported: 2003-06-06 05:57 EDT by Jens Hardings
Modified: 2007-04-18 12:54 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2004-12-13 09:29:17 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Jens Hardings 2003-06-06 05:57:10 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3) Gecko/20030312

Description of problem:
bdiff requires /usr/bin/tempfile, which is not in the package requirements

Just trying to diff two bzip2 compressed files gets to the point.

gzip correctly provides a dependency for mktemp and that package is available.
For bzip2, neither is the tempfile available nor is there a dependency on a
package that provides this utility.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. run 'echo 'test1' | bzip2 > test1.bz2; echo 'test2' | bzip2 > test2.bz2'
2. run 'bzdiff file1.bz2 file2.gz2'

Actual Results:  output:
/usr/bin/bzdiff: line 1: tempfile: command not found
cannot create a temporary file

Expected Results:  output:
< test1
> test2

Additional info:

Changing the line in /usr/bin/bzdiff in which tempfile appears to the following

tmp=`mktemp /tmp/bz$$.XXXXXX` || {

But it should be added to the rpm information that this package depends on mktemp.
Comment 1 Miloslav Trmac 2004-02-05 03:06:41 EST
bzcomp has the same problem.
Comment 2 Jesse Brandeburg 2004-03-19 13:12:50 EST
bzdiff as well, and this same problem is in fedora core too.
Comment 3 Jesse Brandeburg 2004-03-19 13:23:14 EST
sorry for the double follow up, but it seems another good solution 
(and more portable) might just be to use

tmp=`mktemp -t bz$$.XXXXXX` || {

as this automatically uses the right temp directory if its set in the 
environment, otherwise falls back to /tmp

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