-
-
Notifications
You must be signed in to change notification settings - Fork 5.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
Fix wine bootstrap #40425
Fix wine bootstrap #40425
Conversation
heh, I just had worked on this recently in 483379f. Looks like I'm missing a few of your changes and you're missing a few of mine |
wanna just squash your changes into this branch? |
Does this mean we could fully build julia (including precompilation) with BinaryBuilder? I tried to run Julia in Wine some weeks ago, the REPL looked kind of broken, but running it non-interactively worked fine at least for simple tasks (I did some matrix multiplications) |
I thought julia in BB needs full cross-compilation capabilities in the Julia compiler, which we do not have. |
We can already build the |
It's been a while since I tried to cross-compile. The build process goes through fine, but I'm getting
Following the instructions at https://github.com/JuliaLang/julia/blob/master/doc/build/windows.md#cross-compiling-from-unix |
My bad, I had a configuration/env. variable set in my bashrc file that interacted badly with wine, that lead to the printing of messages like:
In any case removing that, I still have some warnings during the compilation process (posted below). The main issue I'm experiencing is that the compilation process seems to hang during the precompilation statement generation step (it hands and never complete?).
...stuck Update, after an awfully long time, it managed to finish the precompilation process. However, running the executable leads to following errors:
Compilation Log
$ make -j16
CC cli/loader_exe.o
CC cli/loader_lib.o
CC cli/loader_trampolines.o
PERL base/pcre_h.jl
PERL base/errno_h.jl
PERL base/file_constants.jl
LINK usr/bin/libjulia.dll
PERL base/uv_constants.jl
PERL base/features_h.jl
PERL base/features_h.jl
PERL base/features_h.jl
PERL base/build_h.jl.phony
ANALYZE usr/bin/libjulia.dll
LINK usr/bin/julia.exe
PERL base/version_git.jl.phony
CC usr/bin/libllvmcalltest.dll
CC usr/bin/libccalltest.dll
FLISP src/julia_flisp.boot
chmod a+x /home/mus/julia/julia.bat
FLISP src/julia_flisp.boot.inc
CC src/jloptions.o
CC src/runtime_ccall.o
CC src/rtutils.o
CC src/codegen.o
CC src/llvm-ptls.o
CC src/jltypes.o
CC src/gf.o
CC src/typemap.o
CC src/smallintset.o
CC src/ast.o
CC src/builtins.o
CC src/module.o
CC src/interpreter.o
CC src/symbol.o
CC src/dlload.o
In file included from /home/mus/julia/src/codegen.cpp:57:
/home/mus/julia/usr/include/llvm/ADT/Statistic.h:38: warning: "LLVM_ENABLE_STATS" redefined
38 | #define LLVM_ENABLE_STATS 1
|
In file included from /home/mus/julia/src/codegen.cpp:3:
/home/mus/julia/src/llvm-version.h:24: note: this is the location of the previous definition
24 | #define LLVM_ENABLE_STATS 0
|
CC src/init.o
CC src/sys.o
CC src/task.o
CC src/array.o
CC src/dump.o
CC src/staticdata.o
CC src/toplevel.o
CC src/jl_uv.o
/home/mus/julia/src/sys.c: In function ‘jl_dllist’:
/home/mus/julia/src/sys.c:609:14: warning: passing argument 1 of ‘free’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
609 | free(path);
| ^~~~
In file included from /home/mus/julia/src/sys.c:8:
/usr/share/mingw-w64/include/stdlib.h:530:27: note: expected ‘void *’ but argument is of type ‘const char *’
530 | void __cdecl free(void *_Memory);
| ~~~~~~^~~~~~~
CC src/datatype.o
CC src/simplevector.o
CC src/runtime_intrinsics.o
CC src/precompile.o
CC src/threading.o
CC src/partr.o
CC src/stackwalk.o
CC src/gc.o
CC src/gc-debug.o
CC src/gc-pages.o
CC src/gc-stacks.o
CC src/method.o
CC src/jlapi.o
CC src/signal-handling.o
CC src/safepoint.o
CC src/timing.o
CC src/subtype.o
CC src/crc32c.o
CC src/APInt-C.o
CC src/processor.o
/home/mus/julia/src/jlapi.c: In function ‘repl_entrypoint’:
/home/mus/julia/src/jlapi.c:692:9: warning: implicit declaration of function ‘execv’ [-Wimplicit-function-declaration]
692 | execv("/proc/self/exe", orig_argv);
| ^~~~~
CC src/ircode.o
CC src/opaque_closure.o
CC src/jitlayers.o
CC src/aotcompile.o
CC src/debuginfo.o
CC src/disasm.o
CC src/llvm-simdloop.o
CC src/llvm-muladd.o
CC src/llvm-final-gc-lowering.o
CC src/llvm-pass-helpers.o
CC src/llvm-late-gc-lowering.o
CC src/llvm-lower-handlers.o
CC src/llvm-gc-invariant-verifier.o
CC src/llvm-propagate-addrspaces.o
CC src/llvm-multiversioning.o
CC src/llvm-alloc-opt.o
CC src/cgmemmgr.o
CC src/llvm-api.o
CC src/llvm-remove-addrspaces.o
CC src/llvm-remove-ni.o
/home/mus/julia/src/jitlayers.cpp: In function ‘jl_value_t* (* _jl_compile_codeinst(jl_code_instance_t*, jl_code_info_t*, size_t))(jl_value_t*, jl_value_t**, uint32_t, _jl_code_instance_t*)’:
/home/mus/julia/src/jitlayers.cpp:220:45: warning: unknown conversion type character ‘l’ in format [-Wformat=]
220 | jl_printf(dump_compiles_stream, "%" PRIu64 "\t\"", end_time - start_time);
| ^~~~~~~~~~~~~~~~~
/home/mus/julia/src/jitlayers.cpp:220:45: warning: too many arguments for format [-Wformat-extra-args]
/home/mus/julia/src/jitlayers.cpp: In member function ‘virtual CompilerResultT JuliaOJIT::CompilerT::operator()(llvm::Module&)’:
/home/mus/julia/src/jitlayers.cpp:580:69: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘long long int’ [-Wformat=]
580 | jl_printf(dump_llvm_opt_stream, " basicblocks: %lu\n", countBasicBlocks(F));
| ~~^ ~~~~~~~~~~~~~~~~~~~
| | |
| long unsigned int long long int
| %I64u
/home/mus/julia/src/jitlayers.cpp:635:41: warning: unknown conversion type character ‘l’ in format [-Wformat=]
635 | jl_printf(dump_llvm_opt_stream, " time_ns: %" PRIu64 "\n", end_time - start_time);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
/home/mus/julia/src/jitlayers.cpp:635:41: warning: too many arguments for format [-Wformat-extra-args]
/home/mus/julia/src/jitlayers.cpp:646:69: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘long long int’ [-Wformat=]
646 | jl_printf(dump_llvm_opt_stream, " basicblocks: %lu\n", countBasicBlocks(F));
| ~~^ ~~~~~~~~~~~~~~~~~~~
| | |
| long unsigned int long long int
| %I64u
CC src/llvm-julia-licm.o
CC src/llvm-demote-float16.o
LINK usr/bin/libjulia-internal.dll
JULIA usr/lib/julia/corecompiler.ji
JULIA usr/lib/julia/sys.ji |
You can set the WINEPATH to the bin directory and it'll find it, but I thought the new stdlib jll work took care of this. @staticfloat ? |
My guess is this is something wrong with wine, since the same build works fine without the PATH modifications on Windows |
I agree with this patch (many, many thanks for the effort!), although I think we should keep the original issue open since cross-compilation is still not 100% functioning. |
* Fix wine bootstrap Fixes JuliaLang#39124 Closes JuliaLang#39022 * fix cross-build, and other build issues * this should probably be part of spawn, if it is needed * Revert "this should probably be part of spawn, if it is needed" This reverts commit eb88a9c. Seems to be needed * fixup! fix cross-build, and other build issues Co-authored-by: Jameson Nash <[email protected]>
* Fix wine bootstrap Fixes JuliaLang#39124 Closes JuliaLang#39022 * fix cross-build, and other build issues * this should probably be part of spawn, if it is needed * Revert "this should probably be part of spawn, if it is needed" This reverts commit eb88a9c. Seems to be needed * fixup! fix cross-build, and other build issues Co-authored-by: Jameson Nash <[email protected]>
* Fix wine bootstrap Fixes JuliaLang#39124 Closes JuliaLang#39022 * fix cross-build, and other build issues * this should probably be part of spawn, if it is needed * Revert "this should probably be part of spawn, if it is needed" This reverts commit eb88a9c. Seems to be needed * fixup! fix cross-build, and other build issues Co-authored-by: Jameson Nash <[email protected]>
Fixes #39124
Closes #39022