[MacPorts] #66886: clang-devel seems to be broken on macOS 12

MacPorts noreply at macports.org
Fri Feb 10 16:45:09 UTC 2023


#66886: clang-devel seems to be broken on macOS 12
--------------------+-------------------------
 Reporter:  catap   |      Owner:  (none)
     Type:  defect  |     Status:  new
 Priority:  Normal  |  Milestone:
Component:  ports   |    Version:
 Keywords:          |       Port:  clang-devel
--------------------+-------------------------
 An attempt to compile a trivial program:
 {{{
 #include <iostream>

 int main() {
     std::cout << "Hello World!";
     return 0;
 }
 }}}
 fails as:
 {{{
 √ /tmp % /opt/local/libexec/llvm-devel/bin/clang++ test.cc
 In file included from test.cc:1:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/iostream:43:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/ios:220:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__ios/fpos.h:14:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/iosfwd:100:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__mbstate_t.h:29:
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/wchar.h:143:77: error:
 use of undeclared identifier 'wcschr'
 wchar_t* __libcpp_wcschr(const wchar_t* __s, wchar_t __c) {return
 (wchar_t*)wcschr(__s, __c);}
 ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/wchar.h:150:87: error:
 use of undeclared identifier 'wcspbrk'
 wchar_t* __libcpp_wcspbrk(const wchar_t* __s1, const wchar_t* __s2)
 {return (wchar_t*)wcspbrk(__s1, __s2);}
 ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/wchar.h:157:78: error:
 use of undeclared identifier 'wcsrchr'; did you mean 'wcschr'?
 wchar_t* __libcpp_wcsrchr(const wchar_t* __s, wchar_t __c) {return
 (wchar_t*)wcsrchr(__s, __c);}
 ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/wchar.h:145:16: note:
 'wcschr' declared here
 const wchar_t* wcschr(const wchar_t* __s, wchar_t __c) {return
 __libcpp_wcschr(__s, __c);}
                ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/wchar.h:164:86: error:
 use of undeclared identifier 'wcsstr'; did you mean 'wcschr'?
 wchar_t* __libcpp_wcsstr(const wchar_t* __s1, const wchar_t* __s2) {return
 (wchar_t*)wcsstr(__s1, __s2);}
 ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/wchar.h:147:16: note:
 'wcschr' declared here
       wchar_t* wcschr(      wchar_t* __s, wchar_t __c) {return
 __libcpp_wcschr(__s, __c);}
                ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/wchar.h:164:86: error:
 no matching function for call to 'wcschr'
 wchar_t* __libcpp_wcsstr(const wchar_t* __s1, const wchar_t* __s2) {return
 (wchar_t*)wcsstr(__s1, __s2);}
 ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/wchar.h:147:16: note:
 candidate disabled: <no message provided>
       wchar_t* wcschr(      wchar_t* __s, wchar_t __c) {return
 __libcpp_wcschr(__s, __c);}
                ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/wchar.h:164:93: error:
 cannot initialize a parameter of type 'wchar_t *' with an lvalue of type
 'const wchar_t *'
 wchar_t* __libcpp_wcsstr(const wchar_t* __s1, const wchar_t* __s2) {return
 (wchar_t*)wcsstr(__s1, __s2);}
 ^~~~
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/wchar.h:147:38: note:
 passing argument to parameter '__s' here
       wchar_t* wcschr(      wchar_t* __s, wchar_t __c) {return
 __libcpp_wcschr(__s, __c);}
                                      ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/wchar.h:171:90: error:
 use of undeclared identifier 'wmemchr'
 wchar_t* __libcpp_wmemchr(const wchar_t* __s, wchar_t __c, size_t __n)
 {return (wchar_t*)wmemchr(__s, __c, __n);}
 ^
 In file included from test.cc:1:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/iostream:43:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/ios:220:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__ios/fpos.h:14:
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/iosfwd:218:14: error:
 reference to unresolved using declaration
 typedef fpos<mbstate_t>    streampos;
              ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/__mbstate_t.h:40:1:
 note: using declaration annotated with 'using_if_exists' here
 using ::mbstate_t _LIBCPP_USING_IF_EXISTS;
 ^
 In file included from test.cc:1:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/iostream:43:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/ios:220:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__ios/fpos.h:14:
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/iosfwd:218:14: error:
 reference to unresolved using declaration
 typedef fpos<mbstate_t>    streampos;
              ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/__mbstate_t.h:40:1:
 note: using declaration annotated with 'using_if_exists' here
 using ::mbstate_t _LIBCPP_USING_IF_EXISTS;
 ^
 In file included from test.cc:1:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/iostream:43:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/ios:220:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__ios/fpos.h:14:
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/iosfwd:219:14: error:
 reference to unresolved using declaration
 typedef fpos<mbstate_t>    wstreampos;
              ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/__mbstate_t.h:40:1:
 note: using declaration annotated with 'using_if_exists' here
 using ::mbstate_t _LIBCPP_USING_IF_EXISTS;
 ^
 In file included from test.cc:1:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/iostream:43:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/ios:220:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__ios/fpos.h:14:
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/iosfwd:219:14: error:
 reference to unresolved using declaration
 typedef fpos<mbstate_t>    wstreampos;
              ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/__mbstate_t.h:40:1:
 note: using declaration annotated with 'using_if_exists' here
 using ::mbstate_t _LIBCPP_USING_IF_EXISTS;
 ^
 In file included from test.cc:1:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/iostream:43:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/ios:220:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__ios/fpos.h:14:
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/iosfwd:223:14: error:
 reference to unresolved using declaration
 typedef fpos<mbstate_t>    u16streampos;
              ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/__mbstate_t.h:40:1:
 note: using declaration annotated with 'using_if_exists' here
 using ::mbstate_t _LIBCPP_USING_IF_EXISTS;
 ^
 In file included from test.cc:1:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/iostream:43:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/ios:220:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__ios/fpos.h:14:
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/iosfwd:223:14: error:
 reference to unresolved using declaration
 typedef fpos<mbstate_t>    u16streampos;
              ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/__mbstate_t.h:40:1:
 note: using declaration annotated with 'using_if_exists' here
 using ::mbstate_t _LIBCPP_USING_IF_EXISTS;
 ^
 In file included from test.cc:1:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/iostream:43:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/ios:220:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__ios/fpos.h:14:
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/iosfwd:224:14: error:
 reference to unresolved using declaration
 typedef fpos<mbstate_t>    u32streampos;
              ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/__mbstate_t.h:40:1:
 note: using declaration annotated with 'using_if_exists' here
 using ::mbstate_t _LIBCPP_USING_IF_EXISTS;
 ^
 In file included from test.cc:1:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/iostream:43:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/ios:220:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__ios/fpos.h:14:
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/iosfwd:224:14: error:
 reference to unresolved using declaration
 typedef fpos<mbstate_t>    u32streampos;
              ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/__mbstate_t.h:40:1:
 note: using declaration annotated with 'using_if_exists' here
 using ::mbstate_t _LIBCPP_USING_IF_EXISTS;
 ^
 In file included from test.cc:1:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/iostream:43:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/ios:221:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__locale:18:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/mutex:191:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__memory/shared_ptr.h:22:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__memory/allocation_guard.h:14:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__memory/allocator_traits.h:14:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/__memory/construct_at.h:20:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/new:93:
 In file included from /opt/local/libexec/llvm-
 devel/bin/../include/c++/v1/cstdlib:87:
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/stdlib.h:150:34:
 error: unknown type name 'ldiv_t'
 inline _LIBCPP_INLINE_VISIBILITY ldiv_t div(long __x, long __y) _NOEXCEPT
 {
                                  ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/stdlib.h:151:12:
 error: no member named 'ldiv' in the global namespace
   return ::ldiv(__x, __y);
          ~~^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/stdlib.h:154:34:
 error: unknown type name 'lldiv_t'
 inline _LIBCPP_INLINE_VISIBILITY lldiv_t div(long long __x,
                                  ^
 /opt/local/libexec/llvm-devel/bin/../include/c++/v1/stdlib.h:156:12:
 error: no member named 'lldiv' in the global namespace
   return ::lldiv(__x, __y);
          ~~^
 fatal error: too many errors emitted, stopping now [-ferror-limit=]
 20 errors generated.
 }}}

-- 
Ticket URL: <https://trac.macports.org/ticket/66886>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list