~# ebuild /usr/portage/app-games/cube/cube-20021020-r1.ebuild >>> Install cube-20021020-r1 into /var/tmp/portage/cube-20021020-r1/image/ category app-games strip: /var/tmp/portage/cube-20021020-r1/image/usr/games/bin/cube_client /var/tmp/portage/cube-20021020-r1/image/usr/games/bin/cube_server >>> Completed installing into /var/tmp/portage/cube-20021020-r1/image/ tar: Removing leading `/' from member names tar (child): /usr/src/redhat/SOURCES/cube-20021020-r1.tar.gz: Cannot open: No such file or directory tar (child): Error is not recoverable: exiting now (Process waits for input) Making a link from /usr/portage/distfiles to /usr/src/redhat/SOURCES does help this problem, but fails further with >>> Completed installing into /var/tmp/portage/cube-20021020-r1/image/ tar: Removing leading `/' from member names Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.5850 + umask 022 + cd /usr/src/redhat/BUILD /var/tmp/rpm-tmp.5850: line 20: cd: /usr/src/redhat/BUILD: No such file or directory error: Bad exit status from /var/tmp/rpm-tmp.5850 (%prep) RPM build errors: Bad exit status from /var/tmp/rpm-tmp.5850 (%prep) install: cannot stat `/usr/src/redhat/RPMS/i386/cube-20021020-r1.i386.rpm': No such file or directory Creating /usr/src/redhat/RPMS/i386 and /usr/src/redhat/BUILD finally gives a succesfull rpm build. So or we make these directories on the Gentoo system, or we make sure these directories aren't used, but the /var/tmp/blabla is used instead. I would opt for the second one (or create a /usr/portage/packages/RPMS directorie).
The usage of cube is only as an example. The same happens with other packages as libxml, apache or abiword.
do you have alien installed ? what does this all ?
there's no need for RPM in none of the listed ebuilds
man ebuild sais: rpm Builds a RedHat RPM package from the files in the temporary install directory. At the moment, the ebuild's dependency information is not incorporated into the RPM. so I assumed that this was a feature of ebuild (that it could create (binary) rpm's of any package), not restricted to the packages that require it. I do not have alien installed, and it seems like I can't either (404 file not found). I'll check this tomorrowevening with some other mirrors. If it was never the intent of ebuild to be able to build rpm's for all packages, then this can be marked as INVALID. However, do note that, by creating these directories creation of RPMs is succesfull. Always. With all mentioned packages. Even OpenOffice.org :-)
I am having a similar problem and /usr/src/redhat/BUILD and /usr/src/redhat/RPMS/i386 are created. I also merged alien, no help. I remerged rpm, no help. Here's what I'm getting at the end (everything before seems to work fine, no errors, etc.) Processing files: mybackup-0.5.1-r0 Finding Provides: (using /usr/lib/rpm/find-provides)... Finding Requires: (using /usr/lib/rpm/find-requires)... PreReq: rpmlib(PayloadFilesHavePrefix) <= 4.0-1 rpmlib(CompressedFileNames) <= 3.0.4-1 Requires(rpmlib): rpmlib(PayloadFilesHavePrefix) <= 4.0-1 rpmlib(CompressedFileNames) <= 3.0.4-1 Requires: /bin/bash error: /var/tmp/rpm-tmp.96065: Fseek failed: Invalid argument RPM build errors: /var/tmp/rpm-tmp.96065: Fseek failed: Invalid argument install: cannot stat `/usr/src/redhat/RPMS/i386/mybackup-0.5.1-r0.i386.rpm': No such file or directory
Additional I should note that instead of processing the files in /var/tmp/portage/..../install, it is processing my actual .ebuild, files, etc.
This is still broken, dies with a: >>> Completed installing into /var/tmp/portage/openssh-3.7.1_p2/image/ tar: Removing leading `/' from member names -bb: unknown option !!! ERROR: net-misc/openssh-3.7.1_p2 failed. !!! Function dyn_rpm, Line 869, Exitcode 1 !!! Failed to integrate rpm spec file That's because it's running "rpm -bb ..." rather than "rpmbuild -bb ..." like it should be. Change line 869 to be "rpmbuild" and it now produces rpm packages.
Confirmed. ebuild foo.ebuild rpm works, but you must edit /usr/lib/portage/bin/ebuild.sh and change "rpm -bb" to "rpmbuild -bb". Please correct this in portage.
*** Bug 50316 has been marked as a duplicate of this bug. ***
Already made it's way into a .51_pre release...