Bug 913929 - cppad: FTBFS in rawhide
cppad: FTBFS in rawhide
Product: Fedora
Classification: Fedora
Component: cppad (Show other bugs)
i686 Unspecified
high Severity low
: ---
: ---
Assigned To: Brad Bell
Fedora Extras Quality Assurance
Depends On:
Blocks: F19FTBFS
  Show dependency treegraph
Reported: 2013-02-22 04:15 EST by Dennis Gilmore
Modified: 2013-02-28 09:25 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2013-02-28 08:35:15 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Dennis Gilmore 2013-02-22 04:15:18 EST
Your package cppad failed to build from source in current rawhide.


Build logs:
root.log: http://kojipkgs.fedoraproject.org/work/tasks/9059/4959059/root.log
build.log: http://kojipkgs.fedoraproject.org/work/tasks/9059/4959059/build.log
state.log: http://kojipkgs.fedoraproject.org/work/tasks/9059/4959059/state.log
NOTE: build logs are cleaned up after 1 week

For details on mass rebuild see https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
Comment 1 Brad Bell 2013-02-25 20:06:57 EST
The following test failed

Here is the log information:
    buildArch (cppad-20130000.1-3.fc19.src.rpm, i686)
         ... snip ...
         ... snip ...
    [ 82%] Built target test_more
    Scanning dependencies of target check_test_more
    abs                 OK
         ... snip ...
    limits              Error

This may be the the same problem that has occurred on the MAC, and seems to be a bug in how complex division is implemented.

I will begin by reproducing the problem on a machine I have access to.
Comment 2 Brad Bell 2013-02-25 21:59:03 EST
The link to the source code above has test_mor where is should be test_more; i.e.,
Comment 3 Brad Bell 2013-02-26 08:58:07 EST
Bug is reproducible as follows:
1. Build a virtual Fedora-18-i686-Live-KDE system
2. fedpkg clone cppad
3. fedpkg mockbuild

contains the text:
    Scanning dependencies of target check_test_more
         ... snip ...
    jacobian            OK
    limits              Error
    Log                 OK

Note the error does not occur in Fedora-18.
Comment 4 Brad Bell 2013-02-26 20:21:14 EST
Using the following command in the setup section of cppad.spec:

sed \
-e '/limits(void)/,/^}/s/ok *&=.*/std::cout << "limits: ok =" << ok << std::endl;\n&/' \
-e '/check_epsilon(void)/,/^\t}/s/ok *&=.*/std::cout << "epsilon: ok =" << ok << std::endl;\n&/' \
-e '/check_min(void)/,/^\t}/s/ok *&=.*/std::cout << "min: ok =" << ok << std::endl;\n&/' \
     -i test_more/limits.cpp

    fedpkg mockbuild
the following output helps to isolate the problem to the check_min routine:
    epsilon: ok =1
    epsilon: ok =1
    limits: ok =1
    ... snip ...
    epsilon: ok =1
    epsilon: ok =1
    limits: ok =1
    min: ok =1
    min: ok =0
    limits: ok =0
Comment 5 Brad Bell 2013-02-27 09:30:45 EST
The g++ 4.8.0 compiler is outsmarting the limits.cpp test by keeping result in higher precision and reusing them, instead of using values stored to memory.

The following code snipet for check_min in limits.cpp sets ok to false:

          tmp[0]     = min[0] / hun[0];
          match[0]   = tmp[0] * hun[0];
          ok        &= abs_geq(match[0]/min[0] - one[0], three[0]*eps[0]);

while the following change sets it to true:

          tmp[0]     = min[0] / hun[0];
          match[0]   = tmp[0] * hun[0];
std::cout << "match / min - 1 = " << match[0] / min[0] - one[0] << std::endl;
          ok        &= abs_geq(match[0]/min[0] - one[0], three[0]*eps[0]);
Comment 6 Brad Bell 2013-02-27 16:43:59 EST
Preliminary testing indicates that this bug is fixed by the changeset

These changes were backported to the 20130000 stable version. A new release of the upstream source, cppad-20130000.2, will be used once this corresponding tarball is automatically generated this evening.
Comment 7 Brad Bell 2013-02-28 08:35:15 EST
This bug was fixed in the upstream CppAD trunk with the changeset

These changes were backported to the current upstream stable version of CppAD

A new upstream release was created; see

A corresponding upstream source tarball was created and uploaded to fedora
      8f764be6e3bcc8b201bc4b7a59717cde  cppad-20130000.2.gpl.tgz

The new upstream source had a successful build; see

Note You need to log in before you can comment on or make changes to this bug.