Summary: | lang/erlang-wx: can not link the wx driver, wx will NOT be useable | ||
---|---|---|---|
Product: | Ports & Packages | Reporter: | Dave Cottlehuber <dch> |
Component: | Individual Port(s) | Assignee: | Dave Cottlehuber <dch> |
Status: | Closed FIXED | ||
Severity: | Affects Some People | CC: | olgeni |
Priority: | --- | Flags: | bugzilla:
maintainer-feedback?
(olgeni) |
Version: | Latest | ||
Hardware: | Any | ||
OS: | Any | ||
URL: | https://bugs.erlang.org/browse/ERL-590 | ||
Attachments: |
Description
Dave Cottlehuber
2018-02-27 13:34:34 UTC
Created attachment 191052 [details]
poudriere log on 12.0-CURRENT
Created attachment 191055 [details]
configure log from in-tree make
with help from zi@ we see some interesting things in config.log. It's not failing
to find the header, its failing on compiling due to a clash between who defines exit:
configure:6661: checking for wx/stc/stc.h
configure:6680: c++ -c -g -Wall -O2 -fPIC -O2 -pipe -fno-omit-frame-pointer -fstack-protector -fno-strict-aliasing -Wno-deprecated-declarations -fomit-frame-pointer -fno-strict-aliasing -isystem /usr/local/include -D_GNU_SOURCE -D_THREAD_SAFE -D_REENTRANT -I/usr/local/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/local/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -pthread -D_THREAD_SAFE -isystem /usr/local/include -D_GNU_SOURCE -D_THREAD_SAFE -D_REENTRANT conftest.cc >&5
In file included from conftest.cc:34:
In file included from /usr/local/include/wx-2.8/wx/wx.h:16:
In file included from /usr/local/include/wx-2.8/wx/object.h:20:
In file included from /usr/local/include/wx-2.8/wx/memory.h:16:
In file included from /usr/local/include/wx-2.8/wx/string.h:43:
In file included from /usr/include/c++/v1/stdlib.h:94:
/usr/include/stdlib.h:97:1: error: function declared '[[noreturn]]' after its first declaration
_Noreturn void exit(int);
^
/usr/include/sys/cdefs.h:280:22: note: expanded from macro '_Noreturn'
#define _Noreturn [[noreturn]]
^
conftest.cc:9:6: note: declaration missing '[[noreturn]]' attribute is here
void exit (int);
^
In file included from conftest.cc:34:
In file included from /usr/local/include/wx-2.8/wx/wx.h:16:
In file included from /usr/local/include/wx-2.8/wx/object.h:20:
In file included from /usr/local/include/wx-2.8/wx/memory.h:16:
In file included from /usr/local/include/wx-2.8/wx/string.h:43:
In file included from /usr/include/c++/v1/stdlib.h:94:
/usr/include/stdlib.h:97:17: error: declaration of 'exit' has a different language linkage
_Noreturn void exit(int);
^
conftest.cc:9:6: note: previous declaration is here
void exit (int);
^
2 errors generated.
configure:6686: $? = 1
configure: failed program was:
| /* confdefs.h. */
|
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
| #define PACKAGE_BUGREPORT ""
| #ifdef __cplusplus
| void exit (int);
| #endif
| #define STDC_HEADERS 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define SIZEOF_VOID_P 8
| #define HAVE_GL_GL_H 1
| #define HAVE_GL_GLU_H 1
| #define HAVE_GLINTPTR 1
| #define HAVE_GLINTPTRARB 1
| #define HAVE_GLCHAR 1
| #define HAVE_GLCHARARB 1
| #define HAVE_GLHALFARB 1
| #define HAVE_GLINT64EXT 1
| /* end confdefs.h. */
| #ifdef WIN32
| # include <windows.h>
| #endif
| #include "wx/wx.h"
|
| #include <wx/stc/stc.h>
configure:6710: result: no
configure:6720: WARNING: Can not find wx/stc/stc.h -g -Wall -O2 -fPIC -O2 -pipe -fno-omit-frame-pointer -fstack-protector -fno-strict-aliasing -Wno-deprecated-declarations -fomit-frame-pointer -fno-strict-aliasing -isystem /usr/local/include -D_GNU_SOURCE -D_THREAD_SAFE -D_REENTRANT -I/usr/local/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/local/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -pthread -D_THREAD_SAFE
which clashes with that already defined in /usr/include/stdlib.h
reported upstream as https://bugs.erlang.org/browse/ERL-590 Progress - either use: 1. use devel/llvm50 to compile against 2. regenerate the otp build tools which gives a newer check for wx that doesn't fail. I've asked the OTP team if that's something they need to do in next release, or us. diffs attached for both sets of changes. olgeni: can you let me know which is preferred from your end, and I'll submit patches for all the lang/erlang-* ports in phab to fix this. Created attachment 191691 [details]
require LLVM50 compiler so that wx detection works again
Created attachment 191697 [details]
extracted from changes in `./otp_build autoconf` in $ERL_TOP
alternative to locking compiler version to LLVM50. Upstream will probably update their autoconf version in their build system at least for OTP 21 and higher.
(In reply to Dave Cottlehuber from comment #6) I think changing 'configure' would be the easiest way (and less build-intensive). Looking into it... A commit references this bug: Author: olgeni Date: Tue Apr 10 13:14:43 UTC 2018 New revision: 466962 URL: https://svnweb.freebsd.org/changeset/ports/466962 Log: lang/erlang{,-wx,-runtime19,-runtime20}: regenerate the 'configure' script for WX so that it doesn't fail on 12.x. PR: 226241 Submitted by: dch Changes: head/lang/erlang/files/patch-lib_wx_configure head/lang/erlang-runtime19/files/patch-lib_wx_configure head/lang/erlang-runtime20/files/patch-lib_wx_configure head/lang/erlang-wx/files/patch-lib_wx_configure thanks olgeni works for me. |