hi, it seems most of the rpm in 6.1 have the same problems as described in: http://www.mail-archive.com/buildsys@lists.fedoraproject.org/msg00741.html
many src.rpm (i mean many hundreds of packages) in rhel-6.1 when try to rebuild in mock gives such an error: ------------------------------------------------ Executing command: ['bash', '--login', '-c', 'rpmbuild -bs --target i686 --nodeps builddir/build/SPECS/OpenEXR.spec'] error: Macro % has illegal name (%define) error: Macro % has illegal name (%define) error: parse error in expression error: /builddir/build/SPECS/OpenEXR.spec:2: parseExpressionBoolean returns -1 error: Macro % has illegal name (%define) Building target platforms: i686 Building for target i686 Child returncode was: 1 ------------------------------------------------ where the spec contains this line: %if 0%{?fedora} > 7 || 0%{?rhel} >= 6 which seems to good to me. and such problems don't happened with 6.0.
does anybody know the reason for this and even better the solution to build these packages? thanks in advance. regards.
On 05/21/2011 05:09 PM, Farkas Levente wrote:
hi, it seems most of the rpm in 6.1 have the same problems as described in: http://www.mail-archive.com/buildsys@lists.fedoraproject.org/msg00741.html
This is not quite the same error output, and we don't really know what was going on in that earlier thread since the OP never wrote back. However, my reply is the same as before:
Could be an issue in this particular spec, or could be an issue with the rpm version in the chroot (e.g. rhbz#56103).
Can you post the spec? Which version of rpm was in the buildroot?
many src.rpm (i mean many hundreds of packages) in rhel-6.1 when try to rebuild in mock gives such an error:
Executing command: ['bash', '--login', '-c', 'rpmbuild -bs --target i686 --nodeps builddir/build/SPECS/OpenEXR.spec'] error: Macro % has illegal name (%define) error: Macro % has illegal name (%define) error: parse error in expression error: /builddir/build/SPECS/OpenEXR.spec:2: parseExpressionBoolean returns -1 error: Macro % has illegal name (%define) Building target platforms: i686 Building for target i686 Child returncode was: 1
where the spec contains this line: %if 0%{?fedora}> 7 || 0%{?rhel}>= 6 which seems to good to me. and such problems don't happened with 6.0.
If this is really the culprit, then it is probably an rpm bug (for the version of rpm in the chroot, not the build host) similar to 56103. If you really think this is it, then you should be able to create a very simple spec that reproduces the error.
does anybody know the reason for this and even better the solution to build these packages? thanks in advance. regards.
On 05/25/2011 08:30 PM, Mike McLean wrote:
On 05/21/2011 05:09 PM, Farkas Levente wrote:
hi, it seems most of the rpm in 6.1 have the same problems as described in: http://www.mail-archive.com/buildsys@lists.fedoraproject.org/msg00741.html
This is not quite the same error output, and we don't really know what was going on in that earlier thread since the OP never wrote back. However, my reply is the same as before:
Could be an issue in this particular spec, or could be an issue with the rpm version in the chroot (e.g. rhbz#56103).
Can you post the spec? Which version of rpm was in the buildroot?
many src.rpm (i mean many hundreds of packages) in rhel-6.1 when try to rebuild in mock gives such an error:
Executing command: ['bash', '--login', '-c', 'rpmbuild -bs --target i686 --nodeps builddir/build/SPECS/OpenEXR.spec'] error: Macro % has illegal name (%define) error: Macro % has illegal name (%define) error: parse error in expression error: /builddir/build/SPECS/OpenEXR.spec:2: parseExpressionBoolean returns -1 error: Macro % has illegal name (%define) Building target platforms: i686 Building for target i686 Child returncode was: 1
where the spec contains this line: %if 0%{?fedora}> 7 || 0%{?rhel}>= 6 which seems to good to me. and such problems don't happened with 6.0.
If this is really the culprit, then it is probably an rpm bug (for the version of rpm in the chroot, not the build host) similar to 56103. If you really think this is it, then you should be able to create a very simple spec that reproduces the error.
i already wrote a bz about it #706672 but even though it may be an rpm bug too (not just mock) since this shouldn't have to be happened, but at least i now found a workaround for it.
On 05/25/2011 05:26 PM, Farkas Levente wrote:
Can you post the spec? Which version of rpm was in the buildroot?
You did not respond to either of my questions
i already wrote a bz about it #706672 but even though it may be an rpm bug too (not just mock) since this shouldn't have to be happened, but at least i now found a workaround for it.
I doubt it is a mock bug. This is not the sort of failure that mock is likely to cause, though I guess many things are possible. The error is being thrown rpm and that error complains about the spec file, so either the spec file is bad or rpm is parsing it badly. As such, the most likely culprits are: rpm bug, bad spec file.
We won't get anywhere without more details. Could you answer my questions above please? Also, have you been able to craft a simple spec file that reproduces the issue?
On 05/26/2011 05:43 AM, Mike McLean wrote:
On 05/25/2011 05:26 PM, Farkas Levente wrote:
Can you post the spec? Which version of rpm was in the buildroot?
You did not respond to either of my questions
rhel-6.1 and the chroot contains all packages from rhel-6.1. mock-1.1.10 and as you can see from the log it was OpenEXR.spec and the src.rpm comes from rhel-6.1 ie: 6Server/en/os/SRPMS/OpenEXR-1.6.1-8.1.el6.src.rpm
mock -r rhel-6.1-i386 --define "rhel 6.1" --rebuild OpenEXR-1.6.1-8.1.el6.src.rpm will fail while mock -r rhel-6.1-i386 --rebuild OpenEXR-1.6.1-8.1.el6.src.rpm won't.
I doubt it is a mock bug. This is not the sort of failure that mock is likely to cause, though I guess many things are possible. The error is being thrown rpm and that error complains about the spec file, so either the spec file is bad or rpm is parsing it badly. As such, the most likely culprits are: rpm bug, bad spec file.
We won't get anywhere without more details. Could you answer my questions above please? Also, have you been able to craft a simple spec file that reproduces the issue?
from bz it's turn out we can't use define as "rhel 6.1" just "rhel 6", but it's still not clear for me why not install mock ccache in this case. although it's a minor issue now.
On 05/26/2011 10:33 AM, Farkas Levente wrote:
from bz it's turn out we can't use define as "rhel 6.1" just "rhel 6", but it's still not clear for me why not install mock ccache in this case. although it's a minor issue now.
If ccache is being pulled in via build deps, then failure to parse the spec properly could certainly cause it to not be installed. Otherwise, the ccache issue is probably unrelated to the spec parsing issue.
buildsys@lists.fedoraproject.org