<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
12.09.2011 19:57, TASAKA Mamoru wrote:
<blockquote cite="mid:4E6E2BF2.1030109@fedoraproject.org"
type="cite">Pavel Alexeev (aka Pahan-Hubbitus) wrote, at
09/11/2011 01:01 AM +9:00:
<br>
<br>
<blockquote type="cite">Now I change it on:
<br>
%if %( php -r "echo (version_compare(PHP_VERSION, '5.3.0',
'>=') ? 1 : 0);" &>/dev/null || echo 0 )
<br>
but on make srpm got error:
<br>
error:
/home/pasha/SOFT/git/php-pecl-runkit/master/php-pecl-runkit.spec:74:
parseExpressionBoolean returns -1
<br>
error: query of specfile
/home/pasha/SOFT/git/php-pecl-runkit/master/php-pecl-runkit.spec
failed, can't parse
<br>
Could not make an srpm: Could not parse the spec, exited 1
<br>
</blockquote>
Because this php command succeeds (perhaps) and return status (of
php) is 0. Then php -r prints
<br>
the result "1" to stdout but this is redirected to /dev/null. The
latter || echo 0 is not
<br>
evaluated because php -r succeeds. So (with php installed) this is
%if (empty) , and
<br>
rpmbuild cannot parse it.
<br>
</blockquote>
Oh, indeed it just my inattention. Thank you.<span
class="Apple-style-span" style="color: rgb(51, 51, 51);
font-family: arial, sans-serif; font-size: 24px; font-style:
normal; font-variant: normal; font-weight: normal; letter-spacing:
normal; line-height: normal; orphans: 2; text-align: -webkit-auto;
text-indent: 0px; text-transform: none; white-space: normal;
widows: 2; word-spacing: 0px; -webkit-text-decorations-in-effect:
none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width:
0px; background-color: rgb(245, 245, 245); "></span>
</body>
</html>