Github Action Static Linking #127
-
I'm opening this as a discussion question since I don't think it's an issue with the library but rather my application of it. I'm attempting to statically link in the onnx runtime from https://github.com/supertone-inc/onnxruntime-build/releases/. I've set up a build script to download the appropriate lib at compile time and then set ORT_STRATEGY and ORT_LIB_LOCATION environment variables. This strategy is working when I test locally on MacOS (Monterey, Intel chip) and Windows 11 but when trying to use this on a Github Action with ubuntu-latest, I'm getting a whole host of I ran into similar errors when testing locally on a machine running Ubuntu 20.04 and was able to get it to compile by installing Has anyone run into similar issues? I'm not very familiar with c++ linking and so I might be missing something obvious but thought I would put this out in case anyone had a quick idea. Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Supertone's static libraries are compiled on Ubuntu 22.04 so it's indeed very strange that your action isn't working with What I think may be happening is, for whatever reason, I see you're using ort v1.15, would it be possible to update to ort |
Beta Was this translation helpful? Give feedback.
Supertone's static libraries are compiled on Ubuntu 22.04 so it's indeed very strange that your action isn't working with
ubuntu-latest
.What I think may be happening is, for whatever reason,
ort
is not properly linking tolibstdc++
, but there is another dependency compiled beforeort
that does so only on macOS, hence why it works on your local macOS machine.I see you're using ort v1.15, would it be possible to update to ort
2.0.0-alpha.2
? We have a migration guide here: https://ort.pyke.io/migrating/v2v2 now provides static libraries by default, and with it there were also a few fixes to linking, specifically with
libstdc++
. Our CI runs are working with stockubuntu-latest
+ static lin…