"bad tty" & "file descriptor error" while building RPM on F13
Hi,
I have an FC13 x86_64 server and having trouble building RPMs, but I don't think it's specifically an RPM problem. I think it's a tty management or other type of problem. When spec files have a "%files -f filelist.txt", which contains the list of files for the RPM, it calls the /usr/lib/check-files script, which sorts the files that are supposed to be in the RPM and compares them with the files that are in the built RPM before they are packaged. The trouble is that the sort fails. Here's the trace from the check-files script: + find /root/rpmbuild/BUILDROOT/sed-4.2.1-5.fc13.x86_64 -type f -o -type l + LC_ALL=C + sort + LC_ALL=C + sort sort: stat failed: -: Bad file descriptor + diff -d /tmp/rpmv4Db1s /tmp/rpmPdDsKU The above doesn't show that the output from sort is redirected into those /tmp files. The first sort succeeds because it reads data sent by the "find" in the same shell. The second sort fails because (I think) it cannot read data from stdin for some reason. What could possibly cause this? I've checked various permissions, libraries, even used strace extensively, all of which is inconclusive. This is one of my test server boxes, so this problem is something that I've caused, but I have no idea what. libc controls input and output, correct? Could it somehow be a glibc problem, or a devpts problem? I can run a simple command and pipe it to sort with no problem. It appears to only be related to sub-shells. I also replaced sort with cat and just tried to redirect stdin in that file to a temporary file, and that also fails. I've tried running it with selinux disabled and that has no effect. Ideas greatly appreciated. Thanks, Alex |
Where are you placing filelist.txt ?
|
Quote:
The filelist in this case is "sed.lang", which is generated by the sed.spec %find_lang %{name} macro, and it contains lines like: Code:
%lang(pt) /usr/share/locale/pt/LC_MESSAGES/sed.mo Code:
%files -f %{name}.lang Code:
FILES_DISK=`mktemp $TMPDIR/rpmXXXXXX` I really could use some help. I'd really hate to lose this whole system. I could end up reinstalling and making the same mistake again.. Thanks, Alex |
For some reason (might be http://docs.fedoraproject.org/drafts...n/ch09s05.html can't remember) I'm using "%{_tmppath}" as in '%files -f %{_tmppath}/%{name}_filessection'?
|
Quote:
Processing files: sed-4.2.1-5.fc13.x86_64 error: Could not open %files file /var/tmp/sed.lang: No such file or directory It's not having a problem finding the files because when it is left as "%files -f %{name}.lang" it proceeds, but when using %{_tmppath} it quits, as shown above. When compiling the bash SRPM, I receive a message like: Code:
+ echo /home/alex/rpmbuild/BUILDROOT/bash-4.1.7-1.x86_64/usr/share/man/man1/ulimit.1.gz Code:
+ /bin/sort How does sed and sort receive the data to stdin from the rpm process? Thanks, Alex |
Interesting. Could you post your complete spec in BB code tags please?
|
2 Attachment(s)
Quote:
I think given that it's the spec included with the rpm package, chances are very good it's not a problem with how the spec is created. Note specifically the sort and "sh: no job control" errors. Thanks, Alex Code:
Summary: hello -- hello, world rpm Code:
# -*- compilation -*- |
Quote:
|
All times are GMT -5. The time now is 04:32 AM. |