-
-
Notifications
You must be signed in to change notification settings - Fork 12.5k
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
julia: build on ARM #96194
julia: build on ARM #96194
Conversation
This will need some |
Going to try a fix -- not that I think these are necessarily mergeable, but I just want to help the build progress a little bit to try to reproduce the error that I saw before. |
faeff36
to
2490d33
Compare
This is the error I mentioned in Slack, @fxcoudert:
The C/C++ code compiles to build a |
Building Julia on ARM macOS from the tip of the master branch (JuliaLang/julia@dbb0e50) outside of Homebrew using mkdir -p usr/lib/julia
for f in $(brew --prefix gcc)/lib/gcc/11/*; do ln -s $f usr/lib/julia; done
make USE_SYSTEM_CSL=1 LDFLAGS=-Wl,-rpath,$(brew --prefix gcc)/lib/gcc/11 works. I suspect that |
No, this was a lie. After a few more adjustments for a HEAD build on ARM, this also fails with the same error. It may not be coming from GCC after all. |
These are also needed to build Julia from diff --git a/Formula/julia.rb b/Formula/julia.rb
index 3a02db432ad..f3d54a6e8b0 100644
--- a/Formula/julia.rb
+++ b/Formula/julia.rb
@@ -104,22 +104,22 @@ class Julia < Formula
def install
# Fix segfaults with Curl 7.81. Remove when this is resolved upstream.
- srccache = buildpath/"stdlib/srccache"
- srccache.install resource("curl-patch")
-
- cd srccache do
- tarball = Pathname.glob("Downloads-*.tar.gz").first
- system "tar", "-xzf", tarball
- extracted_dir = Pathname.glob("JuliaLang-Downloads.jl-*").first
- to_patch = extracted_dir/"src/Curl/Multi.jl"
- system "patch", to_patch, "julia-curl-7.81.patch"
- system "tar", "-czf", tarball, extracted_dir
-
- md5sum = Digest::MD5.file(tarball).hexdigest
- sha512sum = Digest::SHA512.file(tarball).hexdigest
- (buildpath/"deps/checksums"/tarball/"md5").atomic_write md5sum
- (buildpath/"deps/checksums"/tarball/"sha512").atomic_write sha512sum
- end
+ # srccache = buildpath/"stdlib/srccache"
+ # srccache.install resource("curl-patch")
+
+ # cd srccache do
+ # tarball = Pathname.glob("Downloads-*.tar.gz").first
+ # system "tar", "-xzf", tarball
+ # extracted_dir = Pathname.glob("JuliaLang-Downloads.jl-*").first
+ # to_patch = extracted_dir/"src/Curl/Multi.jl"
+ # system "patch", to_patch, "julia-curl-7.81.patch"
+ # system "tar", "-czf", tarball, extracted_dir
+
+ # md5sum = Digest::MD5.file(tarball).hexdigest
+ # sha512sum = Digest::SHA512.file(tarball).hexdigest
+ # (buildpath/"deps/checksums"/tarball/"md5").atomic_write md5sum
+ # (buildpath/"deps/checksums"/tarball/"sha512").atomic_write sha512sum
+ # end
# Build documentation available at
# https://github.com/JuliaLang/julia/blob/v#{version}/doc/build/build.md
@@ -165,7 +165,7 @@ class Julia < Formula
else
Hardware.oldest_cpu
end
- args << "MARCH=#{march}"
+ # args << "MARCH=#{march}"
cpu_targets = ["generic"]
cpu_targets += if Hardware::CPU.arm? |
Upstream does not support building against unpatched LLVM, so we should allow it to build its own modified version. Trying to see if this works on 1.8.0-beta1. |
Two new upstream issues: JuliaLang/julia#44584 and JuliaLang/julia#44585 |
What does Julia's fork do? Can we not use our libuv like we do for other deps? |
Julia needs a bunch of patches that never got accepted upstream: libuv/libuv@libuv:cd7b338...JuliaLang:c2d8a53. Note that a core Julia developer is also a maintainer of libuv, so the situation is very well known upstream.
Julia is rather picky about binary dependencies. For most of them it's actually fine to use system libraries (as long as you match the tested version numbers), but libuv and llvm are somewhat heavily patched (not that heavily, but also not trivial patches). You could use a system libuv, but it's likely users will encounter problems. |
For
So it ends up installing libraries into wrong directory:
Whether this should be using system libs is a separate question. Could be due to building LLVM, e.g.
|
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. |
Julia 1.7.x supports Apple Silicon