Skip to content

lib/ folder missing on Windows, create_library-exported depot cannot create new pkgimages #1067

@topolarity

Description

@topolarity

After starting julia with JULIA_DEPOT_PATH="..." julia -J ./path/to/library/sysimage.dll --project=NewPackage:

julia> using NewPackage
Precompiling NewPackage...
lld: error: unable to find library -lssp             ]  0/1
lld: error: unable to find library -lgcc_s
lld: error: unable to find library -lgcc
lld: error: unable to find library -lmsvcrt
  ◑ NewPackage
[ Info: Precompiling NewPackage [43226e4c-cb2d-415f-b5fa-2c1e0cbb9fa0] (cache misses: mismatched flags (6))
lld: error: unable to find library -lssp
lld: error: unable to find library -lgcc_s
lld: error: unable to find library -lgcc
lld: error: unable to find library -lmsvcrt
ERROR: failed process: Process(setenv(`'.\dyad_library\libexec\julia\lld.exe' -flavor gnu -m i386pep -Bdynamic --enable-auto-image-base --allow-multiple-definition --disable-auto-import --disable-runtime-pseudo-reloc '' -shared -o './dyad_library/share/julia\compiled\v1.11\NewPackage\jl_53B5.tmp' --whole-archive './dyad_library/share/julia\compiled\v1.11\NewPackage\jl_53B4.tmp' --no-whole-archive '-LD:\...\dyad_library\lib\julia' '-LD:\...\dyad_library\bin' -ljulia -ljulia-internal -lopenlibm -lssp -lgcc_s -lgcc -lmsvcrt`,["PATH=D:\\...\\dyad_library\\lib\\julia;D:\\...\\dyad_library\\bin;...", ...]), ProcessExited(1)) [1]

Stacktrace:
  [1] pipeline_error
    @ .\process.jl:598 [inlined]
  [2] run(::Cmd, ::Base.DevNull, ::Vararg{Any}; wait::Bool)
    @ Base .\process.jl:513
  [3] run
    @ .\process.jl:510 [inlined]
  [4] link_image (repeats 2 times)
    @ .\linking.jl:166 [inlined]
  [5] compilecache(pkg::Base.PkgId, path::String, internal_stderr::IO, internal_stdout::IO, keep_loaded_modules::Bool; flags::Cmd, cacheflags::Base.CacheFlags, reasons::Dict{…}, loadable_exts::Nothing)
    @ Base .\loading.jl:3085
  [6] (::Base.var"#1110#1111"{Base.PkgId})()
    @ Base .\loading.jl:2579
  [7] mkpidlock(f::Base.var"#1110#1111"{Base.PkgId}, at::String, pid::Int32; kwopts::@Kwargs{stale_age::Int64, wait::Bool})
    @ FileWatching.Pidfile D:\...\dyad_library\share\julia\stdlib\v1.11\FileWatching\src\pidfile.jl:95
...
 [24] require(into::Module, mod::Symbol)
    @ Base .\loading.jl:2260
Some type information was truncated. Use `show(err)` to see complete types. 

The issue seems to be that libgcc.a, libgcc_s.a, libssp.dll.a are expected in "D:...\dyad_library\lib\julia" but PackageCompiler only copied bin\ and not lib\ when setting up the library depot on Windows.

This makes it impossible to link newly-created pkgimages with the exported Julia installation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions