Bug 209612 - games/trackballs: Fix build with libc++ 3.8.0
Summary: games/trackballs: Fix build with libc++ 3.8.0
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Ganael LAPLANCHE
Depends on:
Blocks: 208158
  Show dependency treegraph
Reported: 2016-05-18 15:55 UTC by Dimitry Andric
Modified: 2016-05-20 20:29 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (martymac)

Remove hand-rolled abs functions from games/trackballs (1.84 KB, patch)
2016-05-18 15:55 UTC, Dimitry Andric
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dimitry Andric freebsd_committer 2016-05-18 15:55:42 UTC
Created attachment 170451 [details]
Remove hand-rolled abs functions from games/trackballs

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

glHelp.cc:132:13: error: 'abs' is missing exception specification 'throw()'
inline Real abs(Real v) {return v>0.0?v:-v;}

This is because the program is attempting to define its own version of abs(), which conflicts with the one from <cmath>.  Fix it by removing the custom versions of abs().

[1] http://package18.nyi.freebsd.org/data/headamd64PR208158-default/2016-05-01_10h29m48s/logs/errors/trackballs-1.1.4_21.log
Comment 1 commit-hook freebsd_committer 2016-05-20 20:28:42 UTC
A commit references this bug:

Author: martymac
Date: Fri May 20 20:28:30 UTC 2016
New revision: 415575
URL: https://svnweb.freebsd.org/changeset/ports/415575

  Fix build with libc++ 3.8.0 by removing conflicting re-definition of abs().

  PR:		209612
  Submitted by:	dim

Comment 2 Ganael LAPLANCHE freebsd_committer 2016-05-20 20:29:10 UTC
Committed, thanks!