In trying to build gtk+extra from:
rpm generates a '\r \n' at the end of the temporary shell script produced
to do the build.
rpm -tb gtk+extra-0.99.5.tar.gz
The last part of the shell script ( /var/tmp/rpm-tmp.16823 ) looks like
[ `/usr/bin/id -u` = '0' ] && /bin/chown -Rhf root .
[ `/usr/bin/id -u` = '0' ] && /bin/chgrp -Rhf root .
/bin/chmod -Rf a+rX,g-w,o-w .
Dumping it with od -c:
0001440 h f r o o t . \n / b i n / c
0001460 h m o d - R f a + r X , g -
0001500 w , o - w . \n \r \n \n e x i t
Notice the \n \r (CR LF). When rpm runs "sh -e /var/tmp/rpm-tmp.16823",
the CR LF is treated as a "command" by the shell, which of course it
++ /usr/bin/id -u
+ [ 0 = 0 ]
+ /bin/chgrp -Rhf root .
+ /bin/chmod -Rf a+rX,g-w,o-w .
: command not found823:
As an asside, I tried to debug build a a debuging version of rpm and figure
out what is going wrong. When I ran "make check" many of the tests failed.
I am running a stock 6.2J system.
This is almost certainly a configuration problem rather than an rpm problem.
RPM has never used (and probably never will) or needed CR.
Check your macro configuration files (and the spec file itself) for lurking
Simply building rpm will give you a "-g" unstripped binary for debugging. Get
the binary from the build, not from the output package, as the spec file
strips the executables.
The make check examines components of packages, and is "noisy" when comparing
package specific information like build host, build time, inode numbers, modify
Duh. Why I went to all the effort to check everything but the spec file is
beyond me. od -c on it turned up \r on every line. Arrrg. I have vi`d it, but
these did not show up. Oh well, a quick tr -d `\r` on the spec file fixed it.
As for the make check. It definately does fail. The tests that fail are:
As it is 3:30am, I am problably doing something equally stupid, so I'll leave it
at that. Thanks for the quick response.