Skip to content

Comments

staging-next 2023-06-11#237233

Merged
vcunat merged 222 commits intomasterfrom
staging-next
Jun 17, 2023
Merged

staging-next 2023-06-11#237233
vcunat merged 222 commits intomasterfrom
staging-next

Conversation

@vcunat
Copy link
Member

@vcunat vcunat commented Jun 11, 2023

yajo and others added 30 commits April 24, 2023 13:26
As you can see in PyCQA/autoflake#138, TOML support is added using python 3.11's builtin `tomllib`. However, for older Python versions, they use `tomli`. Thus, it must be included for those versions.

@moduon MT-2798
Fixes the issue introduced in 3.9 and makes cmp and diff work past Y2K39
fetchurl can't be used on generated patches this way.
The hash doesn't match anymore.  fetchpatch would be an alternative.
Clang 15 does not like the fake xpc headers. Use the real ones instead.
Doing this no longer causes an infinite recursion because xnu now
depends on python3Minimal, which does not include configd support.
Closes #230870. Thanks to @eliasnaur for the test case and for rasining
awareness and to @veprbl for the work done on #111385.

This takes a slightly different approach from those two PRs. The hook is
set unconditionally. The stdenv bootstrap doesn’t really need CF at all,
so setting the hook is harmless. This simplifies things.
Without the change `zeromq` build on `gcc-13` fails as:

    [ 92%] Building CXX object tests/CMakeFiles/test_security_curve.dir/test_security_curve.cpp.o
    In file included from /<<NIX>>/gcc-13.0.0/include/c++/13.0.0/ext/alloc_traits.h:34,
                     from /<<NIX>>/gcc-13.0.0/include/c++/13.0.0/bits/stl_uninitialized.h:64,
                     from /<<NIX>>/gcc-13.0.0/include/c++/13.0.0/memory:69,
                     from tests/../src/secure_allocator.hpp:42,
                     from tests/../src/curve_client_tools.hpp:49,
                     from tests/test_security_curve.cpp:53:
    /<<NIX>>/gcc-13.0.0/include/c++/13.0.0/bits/alloc_traits.h: In instantiation of 'struct std::__allocator_traits_base::__rebind<zmq::secure_allocator_t<unsigned char>, unsigned char, void>':
    /<<NIX>>/gcc-13.0.0/include/c++/13.0.0/bits/alloc_traits.h:94:11:   required by substitution of 'template<class _Alloc, class _Up> using std::__alloc_rebind = typename std::__allocator_traits_base::__rebind<_Alloc, _Up>::type [with _Alloc = zmq::secure_allocator_t<unsigned char>; _Up = unsigned char]'
    /<<NIX>>/gcc-13.0.0/include/c++/13.0.0/bits/alloc_traits.h:228:8:   required by substitution of 'template<class _Alloc> template<class _Tp> using std::allocator_traits< <template-parameter-1-1> >::rebind_alloc = std::__alloc_rebind<_Alloc, _Tp> [with _Tp = unsigned char; _Alloc = zmq::secure_allocator_t<unsigned char>]'
    /<<NIX>>/gcc-13.0.0/include/c++/13.0.0/ext/alloc_traits.h:126:65:   required from 'struct __gnu_cxx::__alloc_traits<zmq::secure_allocator_t<unsigned char>, unsigned char>::rebind<unsigned char>'
    /<<NIX>>/gcc-13.0.0/include/c++/13.0.0/bits/stl_vector.h:88:21:   required from 'struct std::_Vector_base<unsigned char, zmq::secure_allocator_t<unsigned char> >'
    /<<NIX>>/gcc-13.0.0/include/c++/13.0.0/bits/stl_vector.h:423:11:   required from 'class std::vector<unsigned char, zmq::secure_allocator_t<unsigned char> >'
    tests/../src/curve_client_tools.hpp:64:76:   required from here
    /<<NIX>>/gcc-13.0.0/include/c++/13.0.0/bits/alloc_traits.h:70:31: error: static assertion failed: allocator_traits<A>::rebind_alloc<A::value_type> must be A
       70 |                         _Tp>::value,
          |                               ^~~~~
Without the change `nlohmann_json` build on `gcc-13 `fails as:

    In file included from <<NIX>>-gcc-13.0.0/include/c++/13.0.0/ext/alloc_traits.h:34,
                     from <<NIX>>-gcc-13.0.0/include/c++/13.0.0/bits/basic_string.h:39,
                     from <<NIX>>-gcc-13.0.0/include/c++/13.0.0/string:54,
                     from <<NIX>>-gcc-13.0.0/include/c++/13.0.0/bits/locale_classes.h:40,
                     from <<NIX>>-gcc-13.0.0/include/c++/13.0.0/locale:41,
                     from tests/src/unit-regression2.cpp:19:
    <<NIX>>-gcc-13.0.0/include/c++/13.0.0/bits/alloc_traits.h: In instantiation of 'struct std::__allocator_traits_base::__rebind<my_allocator<unsigned char>, unsigned char, void>':
    <<NIX>>-gcc-13.0.0/include/c++/13.0.0/bits/alloc_traits.h:94:11:   required by substitution of 'template<class _Alloc, class _Up> using std::__alloc_rebind = typename std::__allocator_traits_base::__rebind<_Alloc, _Up>::type [with _Alloc = my_allocator<unsigned char>; _Up = unsigned char]'
    <<NIX>>-gcc-13.0.0/include/c++/13.0.0/bits/alloc_traits.h:228:8:   required by substitution of 'template<class _Alloc> template<class _Tp> using std::allocator_traits< <template-parameter-1-1> >::rebind_alloc = std::__alloc_rebind<_Alloc, _Tp> [with _Tp = unsigned char; _Alloc = my_allocator<unsigned char>]'
    <<NIX>>-gcc-13.0.0/include/c++/13.0.0/ext/alloc_traits.h:126:65:   required from 'struct __gnu_cxx::__alloc_traits<my_allocator<unsigned char>, unsigned char>::rebind<unsigned char>'
    <<NIX>>-gcc-13.0.0/include/c++/13.0.0/bits/stl_vector.h:88:21:   required from 'struct std::_Vector_base<unsigned char, my_allocator<unsigned char> >'
    <<NIX>>-gcc-13.0.0/include/c++/13.0.0/bits/stl_vector.h:423:11:   required from 'class std::vector<unsigned char, my_allocator<unsigned char> >'
    tests/src/unit-regression2.cpp:807:63:   required from here
    <<NIX>>-gcc-13.0.0/include/c++/13.0.0/bits/alloc_traits.h:70:31: error: static assertion failed: allocator_traits<A>::rebind_alloc<A::value_type> must be A
       70 |                         _Tp>::value,
          |                               ^~~~~
Without the change `abseil-cpp` build fails on `gcc-13` as:

    /build/abseil-cpp/absl/strings/internal/str_format/extension.h:34:33:
      error: found ':' in nested-name-specifier, expected '::'
       34 | enum class FormatConversionChar : uint8_t;
          |                                 ^
          |                                 ::
Without the change the test fails on gcc-13 as:

    $ ./tests/nametabletest/nametabletest
    tests/nametabletest/nametabletest.cpp:142:79: runtime error: index 5 out of bounds for type 'NameRecord [5]'
    ...
    tests/nametabletest/nametabletest.cpp:142:79: runtime error: index 7 out of bounds for type 'NameRecord [7]'
    ...

In silnrsi/graphite#74 upstream agrees it's a
problem in the test (and possibly the library). Let's disable the test
itself until upstream fixes it completely.
-licuuc is required when linking against libv8 output of nodejs.
Rely on swift-corefoundation to set this in its hook. That way, it will
be dropped from the `extraBuildInputs` during a cross build.
Clang 16 makes implicit int and function declarations an error by
default in any mode except for C89. The configure script has two of
these that cause it to misdetect features when using Clang 16.

* Implicit `int main` in the errno check. This is fixed by adding the
  missing `int`.
* Implicit definitions of `opendir` and `closedir`. These are fixed by
  including the required headers.
Normally, when getopt builds on a non-glibc platform, it uses C library
headers without including them. That’s fine unless your compiler is
clang 16, which is strict about using functions without prototypes.
Fortunately, Darwin’s headers are compatible enough as are Musl’s, so
defining `__GNU_LIBRARY__` can be done unconditionally.
Clang 16 does not allow `main` with an implicit `int`, which causes the
configure script to misdetect clang as a non-working compiler. Patching
`configure.in` and regenerating `configure` allows libelf to build.

Due to the comment regarding bootstrap tools, this patching is only done
on Darwin with clang.
Signed-off-by: Henri Rosten <henri.rosten@unikie.com>
@dotlambda dotlambda mentioned this pull request Jun 15, 2023
12 tasks
@apfelkuchen6 apfelkuchen6 mentioned this pull request Jun 15, 2023
12 tasks
vcunat and others added 2 commits June 15, 2023 22:41
Applies a modified version of upstreams patch to fix the tests, only
upstream only recognized the issue from 3.12, while it hit us on 3.11.4.
@vcunat
Copy link
Member Author

vcunat commented Jun 17, 2023

@lilyinstarlight: gst_all_1.gst-plugins-rs regressed on aarch64-* (linux link). Maybe rustc or llvm update; I don't know.

@vcunat vcunat merged commit 6d80b59 into master Jun 17, 2023
@lilyinstarlight
Copy link
Member

@lilyinstarlight: gst_all_1.gst-plugins-rs regressed on aarch64-* (linux link). Maybe rustc or llvm update; I don't know.

Ugh, more test failures. Probably easiest to just add raptorq to the list to disable on aarch64 for now on it. I'm computer-less until Tuesday so it would be ideal if someone else can do that to at least unblock it for now

I'll investigate further and open an upstream issue when I'm back at my computer

Thanks for the ping!

@vcunat
Copy link
Member Author

vcunat commented Jun 18, 2023

@vcunat
Copy link
Member Author

vcunat commented Jun 18, 2023

Probably easiest to just add raptorq to the list to disable on aarch64 for now on it.

OK, done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

1.severity: security Issues which raise a security issue, or PRs that fix one 6.topic: golang Go is a high-level general purpose programming language that is statically typed and compiled. 6.topic: kernel The Linux kernel 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 6.topic: python Python is a high-level, general-purpose programming language. 6.topic: rust General-purpose programming language emphasizing performance, type safety, and concurrency. 6.topic: stdenv Standard environment 6.topic: systemd Software suite that provides an array of system components for Linux operating systems. 8.has: changelog This PR adds or changes release notes 8.has: documentation This PR adds or changes documentation 8.has: module (update) This PR changes an existing module in `nixos/` 10.rebuild-darwin: 501+ This PR causes many rebuilds on Darwin and should normally target the staging branches. 10.rebuild-darwin: 5001+ This PR causes many rebuilds on Darwin and must target the staging branches. 10.rebuild-darwin-stdenv This PR causes stdenv to rebuild on Darwin and must target a staging branch. 10.rebuild-linux: 501+ This PR causes many rebuilds on Linux and should normally target the staging branches. 10.rebuild-linux: 5001+ This PR causes many rebuilds on Linux and must target the staging branches. 10.rebuild-linux-stdenv This PR causes stdenv to rebuild on Linux and must target a staging branch.

Projects

None yet

Development

Successfully merging this pull request may close these issues.