Bug 208526 - databases/portgresql-plv8js: Fix build with libc++ 3.8.0
Summary: databases/portgresql-plv8js: 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: Kurt Jaeger
URL:
Keywords:
Depends on:
Blocks: 208158
  Show dependency treegraph
 
Reported: 2016-04-04 18:55 UTC by Dimitry Andric
Modified: 2016-04-30 04:35 UTC (History)
1 user (show)

See Also:
pi: maintainer-feedback+


Attachments
Remove C++ keyword overriding defines from databases/postgresql-plv8js (3.67 KB, patch)
2016-04-04 18: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-04-04 18:55:35 UTC
Created attachment 168979 [details]
Remove C++ keyword overriding defines from databases/postgresql-plv8js

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

In file included from plv8.cc:21:
In file included from /usr/local/include/postgresql/server/access/xact.h:17:
In file included from /usr/local/include/postgresql/server/access/xlog.h:16:
In file included from /usr/local/include/postgresql/server/datatype/timestamp.h:18:
/usr/include/c++/v1/math.h:331:1: error: unknown type name 'typename_'; did you mean 'typename'?
typename std::enable_if<std::is_arithmetic<_A1>::value, bool>::type
^
plv8.cc:15:18: note: expanded from macro 'typename'
#define typename        typename_
                        ^

This is because several .cc files in this package attempt to redefine C++ keywords such as delete, namespace, typename etc with different identifiers.  I have no idea why this weirdness was added, but deleting all those #defines makes the port compile just fine.

[1] http://package18.nyi.freebsd.org/data/headamd64PR208158-default/2016-03-22_18h30m05s/logs/errors/postgresql93-plv8js-1.4.4.log
Comment 1 Kurt Jaeger freebsd_committer 2016-04-30 04:34:36 UTC
Committed, thanks!
Comment 2 commit-hook freebsd_committer 2016-04-30 04:35:02 UTC
A commit references this bug:

Author: pi
Date: Sat Apr 30 04:34:35 UTC 2016
New revision: 414328
URL: https://svnweb.freebsd.org/changeset/ports/414328

Log:
  databases/postgresql-plv8js: Fix build with libc++ 3.8.0

  PR:		208526
  Submitted by:	dim
  Approved by:	vanilla (maintainer)

Changes:
  head/databases/postgresql-plv8js/files/patch-plv8.cc
  head/databases/postgresql-plv8js/files/patch-plv8_func.cc
  head/databases/postgresql-plv8js/files/patch-plv8_type.cc