diff --git a/deps/build_libcxxffi.jl b/deps/build_libcxxffi.jl index 4230a11c..13cd53c9 100644 --- a/deps/build_libcxxffi.jl +++ b/deps/build_libcxxffi.jl @@ -11,6 +11,8 @@ products = [ download_info = Dict( Linux(:x86_64, libc=:glibc, compiler_abi=CompilerABI(:gcc7)) => ("https://github.com/Gnimuc/CxxBuilder/releases/download/v0.0.0-1/libcxxffi.v0.0.0.x86_64-linux-gnu-gcc7.tar.gz", "8dc796c0577973d09270b79b50a57b547938426951f8830fbec5270d35ffde8e"), MacOS(:x86_64, compiler_abi=CompilerABI(:gcc7)) => ("https://github.com/Gnimuc/CxxBuilder/releases/download/v0.0.0-2/libcxxffi.v0.0.0.x86_64-apple-darwin14-gcc7.tar.gz", "812b78869a318299e33d69fba738514521a139621f5a85633fbcbfd0b58fae6e"), + Windows(:x86_64, compiler_abi=CompilerABI(:gcc7)) => ("https://github.com/Gnimuc/CxxBuilder/releases/download/v0.0.0-3/libcxxffi.v0.0.0.x86_64-w64-mingw32-gcc7.tar.gz", "6376078764d629029039c2e988a2befb9af8eaab56deae49b10272d87130ac81"), + Linux(:i686, libc=:glibc, compiler_abi=CompilerABI(:gcc7)) => ("https://github.com/Gnimuc/CxxBuilder/releases/download/v0.0.0-4/libcxxffi.v0.0.0.i686-linux-gnu-gcc7.tar.gz", "a9896701a7dfd96f94541e45cf58506b9690f405c6d1a354f718089f34668786"), ) # Install unsatisfied or updated dependencies: diff --git a/src/initialization.jl b/src/initialization.jl index 6b810eaa..d446d317 100644 --- a/src/initialization.jl +++ b/src/initialization.jl @@ -12,10 +12,13 @@ depspath = joinpath(BASE_JULIA_SRC, "deps", "srccache") # Load the Cxx.jl bootstrap library (in debug version if we're running the Julia # debug version) - -const libcxxffi = joinpath(dirname(Base.source_path()),"../deps/usr/lib/", - string("libcxxffi", ccall(:jl_is_debugbuild, Cint, ()) != 0 ? "-debug" : "")) - +@static if Sys.iswindows() + const libcxxffi = joinpath(dirname(Base.source_path()),"../deps/usr/bin/", + string("libcxxffi", ccall(:jl_is_debugbuild, Cint, ()) != 0 ? "-debug" : "")) +else + const libcxxffi = joinpath(dirname(Base.source_path()),"../deps/usr/lib/", + string("libcxxffi", ccall(:jl_is_debugbuild, Cint, ()) != 0 ? "-debug" : "")) +end # Set up Clang's global data structures function init_libcxxffi() # Force libcxxffi to be opened with RTLD_GLOBAL @@ -358,11 +361,11 @@ end # function addStdHeaders(C) end # islinux @static if iswindows() function collectStdHeaders!(headers) - base = "C:/mingw-builds/x64-4.8.1-win32-seh-rev5/mingw64/" - push!(headers,(joinpath(base,"x86_64-w64-mingw32/include"), C_System)) - #addHeaderDir(joinpath(base,"lib/gcc/x86_64-w64-mingw32/4.8.1/include/"), kind = C_System) - push!(headers,(joinpath(base,"lib/gcc/x86_64-w64-mingw32/4.8.1/include/c++"), C_System)) - push!(headers,(joinpath(base,"lib/gcc/x86_64-w64-mingw32/4.8.1/include/c++/x86_64-w64-mingw32"), C_System)) + base = joinpath(@__DIR__, "..", "deps", "usr") + push!(headers,(joinpath(base, "mingw", "include"), C_System)) + push!(headers,(joinpath(base, "mingw", "include", "c++", "7.1.0"), C_System)) + push!(headers,(joinpath(base, "mingw", "include", "c++", "7.1.0", "x86_64-w64-mingw32"), C_System)) + push!(headers,(joinpath(base, "mingw", "sys-root", "include"), C_System)) # not sure whether this is necessary end #function addStdHeaders(C) end # iswindows