kassane / druntime-zigbuild

D runtime build using zig-build
Other
1 stars 0 forks source link

Dynamic libraries: Linking issues #3

Open kassane opened 5 months ago

kassane commented 5 months ago

CI: https://github.com/kassane/druntime-zigbuild/actions/runs/9750504082

lld-link: error: undefined symbol: __declspec(dllimport) vtable for core.sync.mutex.Mutex

referenced by D:\a\druntime-zigbuild\druntime-zigbuild\druntime\src\ldc\eh_msvc.d:622 D:\a\druntime-zigbuild\druntime-zigbuild.zig-cache\o\4bcbbb8f1a3942f3354094b3fadc2bf0\druntime-ldc-shared-debug.obj:(_D3ldc7eh_msvc12msvc_eh_initFZv)

lld-link: error: undefined symbol: __declspec(dllimport) initializer for core.sync.mutex.Mutex

referenced by D:\a\druntime-zigbuild\druntime-zigbuild\druntime\src\ldc\eh_msvc.d:622 D:\a\druntime-zigbuild\druntime-zigbuild.zig-cache\o\4bcbbb8f1a3942f3354094b3fadc2bf0\druntime-ldc-shared-debug.obj:(_D3ldc7eh_msvc12msvc_eh_initFZv) referenced by D:\a\druntime-zigbuild\druntime-zigbuild\druntime\src\core\lifetime.d:106 D:\a\druntime-zigbuild\druntime-zigbuild.zig-cache\o\4bcbbb8f1a3942f3354094b3fadc2bf0\druntime-ldc-shared-debug.obj:(_D4core8lifetime__T7emplaceTCQBb4sync5mutex5MutexZQBfFNbNiNfQBgZQBk)

lld-link: error: undefined symbol: _D4core4sync5mutex5Mutex6__ctorMFNbNiNeZCQBnQBlQBjQBg

referenced by D:\a\druntime-zigbuild\druntime-zigbuild\druntime\src\ldc\eh_msvc.d:622 D:\a\druntime-zigbuild\druntime-zigbuild.zig-cache\o\4bcbbb8f1a3942f3354094b3fadc2bf0\druntime-ldc-shared-debug.obj:(_D3ldc7eh_msvc12msvc_eh_initFZv) referenced by D:\a\druntime-zigbuild\druntime-zigbuild\druntime\src\core\lifetime.d:126 D:\a\druntime-zigbuild\druntime-zigbuild.zig-cache\o\4bcbbb8f1a3942f3354094b3fadc2bf0\druntime-ldc-shared-debug.obj:(_D4core8lifetime__T7emplaceTCQBb4sync5mutex5MutexZQBfFNbNiNfQBgZQBk)

lld-link: error: undefined symbol: init_msvc

referenced by D:\a\druntime-zigbuild\druntime-zigbuild\druntime\src\rt\dmain2.d:119 D:\a\druntime-zigbuild\druntime-zigbuild.zig-cache\o\4bcbbb8f1a3942f3354094b3fadc2bf0\druntime-ldc-shared-debug.obj:(rt_init)

kassane commented 2 months ago

Target Windows does not detect libdruntime with .lib suffix (generating only dll) https://github.com/kassane/druntime-zigbuild/actions/runs/10905266374/job/30263688710


MacOS

https://github.com/kassane/druntime-zigbuild/actions/runs/10905266374/job/30263688347#step:5:12

error: undefined symbol: section$end$__DATA$.minfo
    note: referenced by /Users/runner/.cache/zig/o/dd6ab5043092597b04e52dd988141101/libdruntime-ldc-debug-shared.o:__D2rt3dso12register_dsoFZv
    note: referenced by /Users/runner/.cache/zig/o/dd6ab5043092597b04e52dd988141101/libdruntime-ldc-debug-shared.o:__D2rt3dso12register_dsoFZv