[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Building from tar ball without a version string?



I'm having trouble with a simple function.

I CAN "rpmbuild -tb $name-$version.tar.gz"

I would like to  "rpmbuild -tb $name.tar.gz" because this is how my CVS repo
packages them up.   Currently I have to pull the source, grep the version
out of the specfile, rename the directory, tar it up with the version in the
name, then I can build it.   Not bad, but when your packing up a 30 meg
complier this can take 10 minutes to download, unpack, rename, repack, then
let rpmbuild unpack....It would be sweet if I could just say "grab the tar
ball of a branch and work on that"


Here's my example


tree demo
demo
|-- demo.spec
|-- makefile
`-- src
    `-- demo.c     

Name: demo
Version: 8
Release: 1
Source0: %{name}.tar.gz

rpmbuild -tb demo.tar.gz
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.35145
+ umask 022
+ cd /home/zelston/rpm/BUILD
+ cd /home/zelston/rpm/BUILD
+ rm -rf demo-8
+ /usr/bin/gzip -dc /home/zelston/test/demo.tar.gz
+ tar -xf -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd demo-8
/var/tmp/rpm-tmp.35145: line 28: cd: demo-8: No such file or directory
error: Bad exit status from /var/tmp/rpm-tmp.35145 (%prep)


RPM build errors:
    Bad exit status from /var/tmp/rpm-tmp.35145 (%prep)

It fails because my tar.gz doesn't unpack to a $name-$version/ which is what
I want.
Any ideas on how to tell rpmbuild to NOT demand a $version?

Thanks

-zaq     


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]