-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Building Julia-1.7.1 in Debian-64 SID, errors are given #43624
Comments
That's an error in mbedtls, not Julia itself. Here is a patch to fix the error: Mbed-TLS/mbedtls#3848 |
Presumably, when doing source builds (i.e. |
Many thanks to giordano for the link: And it led to the link ARMmbed/mbedtls#7303 And it led to the idea that if you need to install a different version of the component from "./deps/Versions.make", then it is better to copy the "julia" folder from git to the working folder. Next, change the version of the component to "./deps/Versions.make", delete folders and files with the previous version of the component from "./deps" and run "make -j$(nproc)" in the root of the working folder (if a single-core processor, then just "make"), but the Internet must be for this. Running "make clean" or "make cleanall" does not help, because reassembling with a component of a different version mostly fails. The reasons for this are not yet clear. The Julia build with mbedtls 2.28.0 or 2.16.12 goes fine, and with 2.24.0 it completes with errors. Usage in "./deps/mbedtls.mk":
patch "./deps/patches/mbedtls-cmake-findpy.patch" for mbedtls 2.28.0 or 2.16.12 leads to build errors. The last 3 lines should be commented out, then the building will pass without errors. The developers of the Julia build system can be respected, since you can change the version of the component and this needs to be done only in one place and remove the old version from
|
You may have just needed |
Also note that in Yggdrasil we just staged Mbed TLS 2.28: and that the PR to update Julia for Mbed TLS 2.28 is here: |
Julia 1.6.4 used to be going fine. Now all versions give the same error when building: JULIA usr/lib/julia/sys-o.a WARNING: Error during initialization of module LinearAlgebra: Generating REPL precompile statements... 36/36 Precompilation complete. Summary: Building with mbedtls 2.24.0 leads to errors. Using OpenBLAS 0.3.13 or 0.3.19 does not solve anything. $ julia -tauto julia> Threads.nthreads() |
Are you still using the same command to build? It sounds like something has gone wrong with your build environment as opposed to the Julia sources. Just to make sure, clone a fresh repository. |
From time to time I rename the folder with git to "julia.old" and run Added in first lines «./deps/checksums/mbedtls»: Replace some lines in «./media/u1/s1/0/julia-1.7.1/deps/Versions.make»: Comments some lines in «./deps/mbedtls.mk»: A week ago Julia was going to be fine. And the previous versions, and 1.7.0, and 1.7.1. But now the installation of Julia 1.8-Dev is being completed: I have already reinstalled Debian-64 Sid 2 times, but nothing helps. The problem is "libopenblas64_.so ". Except for her, everything works. |
You may want to take a look at the BinaryBuilder script to see if that produces a better build: |
That sounds like the patchelf-related issue we used to see on FreeBSD. @staticfloat any idea if glibc is adding new checks that are now stricter like FreeBSD was? |
@domr2695 what version of glibc are you running? You can tell by looking at the target of the
So on my machine, I'm running glibc version 2.31. |
Debian Sid should have glibc 2.33: https://packages.debian.org/source/sid/glibc, same as Arch Linux: % /usr/lib/libc.so.6
GNU C Library (GNU libc) release release version 2.33.
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
Compiled by GNU CC version 11.1.0.
libc ABIs: UNIQUE IFUNC ABSOLUTE
For bug reporting instructions, please see:
<https://bugs.archlinux.org/>. |
I have glibc 2.33-2. If in "./Make.user": USE_BINARYBUILDER=1 Then everything is going fine. But, at the same time, all libraries are downloaded from the Internet, but from another (unknown to me) place and nothing is builded on the computer. But Julia starts and works fine. And libopenblas64_.0.3.13.so 30.2 Mb. And there are 33 segments in the library. libopenblas64_.0.3.13.so: file format elf64-x86-64 If this library is replaced in the Julia assembly with a broken library, then Julia starts and works normally. At the same time, if in "./Make.user": USE_BINARYBUILDER=0 Then all libraries are assembled from source texts on the computer. And libopenblas64_.so 29.5 Mb, and it doesn't work. LINK usr/lib/julia/says.so And there are 26 segments in the library. |
If you look at Line 210 in 32abe71
bb-install . That's defined here:
which says to download a tar ball from: julia/deps/tools/bb-install.mk Line 32 in da28c17
In the case of openblas that leads to one of the Assets here: https://github.com/JuliaBinaryWrappers/OpenBLAS_jll.jl/releases which leads to one of the build recipes here: https://github.com/JuliaPackaging/Yggdrasil/tree/master/O/OpenBLAS My suggestion is to try one of the build recipes above. In particular you might want to build 0.3.17 which is what is currently on the master branch: That uses julia functions defined here: https://github.com/JuliaPackaging/Yggdrasil/blob/master/O/OpenBLAS/common.jl |
Yeah, by default the binaries are downloaded from here, we host a community build tree where binary dependencies for Julia packages and Julia itself are built for all the platforms Julia supports (Windows, macOS, Linux, FreeBSD, etc...) and hosted as tarballs on GitHub. If you're interested, you can actually find the precise build steps used to create the OpenBLAS binaries. So if the Yggdrasil-provided binaries are working, that makes me think that there might be something fishy going on with your particular build toolchain. This is part of the reason why we prefer to use precompiled binaries; there is an enormous amount of surface area across all of these different platforms, and if users use a toolchian that behaves ever so slightly differently than most other toolchains, there can be compilation issues. And, in this case, it's in a dependency, rather than our own code! I don't immediately see any reason why this would be happening..... especially since the steps taken on the local machine should be more or less the same as what happens in Yggdrasil. @domr2695 can you build OpenBLAS manually? Do something like the following:
Once that's done, it'll have a It would also be good to find out the version of |
./julia-1.7.1/deps/Versions.make:
Now (on 2022-01-13 22:17 GMT+3) when installing Julia 1.7.1 during: I had to add the "-i" parameter to line 60 in "./Makefile"`: Also in "./Make.user" leads to premature termination of the make build or to the issue of make at the end of the build. I had to specify, because my processor architecture is SANDYBRIDGE: OPENBLAS_USE_THREAD = 32 At the end of the assembly , it began to be issued: JULIA usr/lib/julia/sys-o.a Solved the problem:
I draw your attention to the fact that in "./deps/Versions.make" for Julia 1.7.0-1.8.0-DEV is:
using mbedTLS 2.24.0 results in the output of the messages that I gave in the first message, and the completion of make with an error message: In versions 2.16.12 and 2.28.0, this problem has been fixed, so they should be used. And now it is enough to copy for each version of Julia: 1.7.0, 1.7.1, 1.8.0-DEV the corresponding files in the corresponding folder with the Julia source texts and run julia-deps: |
|
That upgrade work was ongoing in #42311. It looks like mbedTLS violated semver, so it is being a bit more challenging to push through that particular update and needs some additional help to upgrade the additional dependencies. |
Began to emerge: Before that, there was often a message about exceeding TIMEOUT = 15 seconds. and the termination of the "make" execution. /deps/p7zip.mk:6: The $(JLDOWNLOAD) variable is defined in "./Make.inc": ././deps/tools/jl download: Everything started downloading normally. |
The "ELF load command offset/address not properly aligned" error has now been traced to a bug in binutils 2.38, see OpenMathLib/OpenBLAS#3708 and subsequent https://sourceware.org/bugzilla/show_bug.cgi?id=29435 with a source patch for the binutils ld |
Given that the error has been traced to a 3rd party, can this issue now be closed? |
This seems stale indeed. |
The text was updated successfully, but these errors were encountered: