Bug 208905

Summary: graphics/opencollada: Fix build with libc++ 3.8.0
Product: Ports & Packages Reporter: Dimitry Andric <dim>
Component: Individual Port(s)Assignee: Kurt Jaeger <pi>
Status: Closed FIXED    
Severity: Affects Some People CC: pi
Priority: --- Flags: pi: maintainer-feedback-
Version: Latest   
Hardware: Any   
OS: Any   
Bug Depends on:    
Bug Blocks: 208158    
Description Flags
Use <cmath> instead of <math.h> to get std::isnan none

Description Dimitry Andric freebsd_committer 2016-04-18 19:33:43 UTC
Created attachment 169451 [details]
Use <cmath> instead of <math.h> to get std::isnan

During the exp-run in bug 208158, it was found that graphics/opencollada gives errors with libc++ 3.8.0 [1]:

/wrkdirs/usr/ports/graphics/opencollada/work/OpenCOLLADA-a59a438/GeneratedSaxParser/src/GeneratedSaxParserUtils.cpp:1559:16: error: no member named 'isnan' in namespace 'std'; did you mean simply 'isnan'?
        return std::isnan(value);

This is because opencollada's GeneratedSaxParserUtils.cpp includes <math.h>, not <cmath>.  The latter defines std::isnan(), so use it instead.

[1] http://package18.nyi.freebsd.org/data/headamd64PR208158-default/2016-03-22_18h30m05s/logs/errors/opencollada-
Comment 1 Kurt Jaeger freebsd_committer 2016-04-30 04:28:44 UTC
testbuilds are fine.
Comment 2 commit-hook freebsd_committer 2016-05-05 19:52:05 UTC
A commit references this bug:

Author: pi
Date: Thu May  5 19:52:01 UTC 2016
New revision: 414660
URL: https://svnweb.freebsd.org/changeset/ports/414660

  graphics/opencollada: Fix build with libc++ 3.8.0

  PR:		208905
  Submitted by:	dim
  Approved by:	mva (maintainer timeout)

Comment 3 Kurt Jaeger freebsd_committer 2016-05-05 19:52:19 UTC
Committed, thanks!