Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 06 Jun 2016 23:55:56 +0000
From:      bugzilla-noreply@freebsd.org
To:        gnome@FreeBSD.org
Subject:   [Bug 209077] net/opal: Fix build with libc++ 3.8.0
Message-ID:  <bug-209077-6497-ZoOQpuFwR7@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-209077-6497@https.bugs.freebsd.org/bugzilla/>
References:  <bug-209077-6497@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D209077

--- Comment #5 from commit-hook@freebsd.org ---
A commit references this bug:

Author: truckman
Date: Mon Jun  6 23:55:08 UTC 2016
New revision: 416491
URL: https://svnweb.freebsd.org/changeset/ports/416491

Log:
  Fix type for abs() calls in net/opal

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

  ../common/mpi.cxx:135:18: error: call to 'abs' is ambiguous
      distance =3D ( abs(MPIs[i].width  - desiredWidth ) *
                   ^~~

  This is because abs() is being called with unsigned arguments.  Fix
  this by casting the arguments to the appropriate signed type.  This
  mimics what happens with older libraries where the only version of
  abs() was the one in <stdlib.h>, which is prototyped:
        int abs(int)
  Correct functioning of this expression relies on how integer overflow
  actually behaves, which is actually undefined in the C++ standard.

  PR:           209077
  Submitted by: dim

Changes:
  head/net/opal/files/patch-plugins_video_common_mpi.cxx

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-209077-6497-ZoOQpuFwR7>