aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Arvidsson <2972103+AlexanderArvidsson@users.noreply.github.com>2024-12-28 03:56:59 +0100
committerAlexander Arvidsson <2972103+AlexanderArvidsson@users.noreply.github.com>2024-12-28 03:56:59 +0100
commit72cbe13a9bec2abea8f54e2cbec109d0bb03d97a (patch)
tree516b31aa3888e54c712319db72a205e760d6e4d0
parent789d97071d17cbab4e3835a0b0b8b379e98c114f (diff)
gen_odin.py: Use shared linux libraries if USE_DLL
-rw-r--r--bindgen/gen_odin.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/bindgen/gen_odin.py b/bindgen/gen_odin.py
index 497d756c..45bb0364 100644
--- a/bindgen/gen_odin.py
+++ b/bindgen/gen_odin.py
@@ -401,8 +401,13 @@ def gen_c_imports(inp, c_prefix, prefix):
l( ' }')
l( ' }')
l( '} else when ODIN_OS == .Linux {')
- l(f' when DEBUG {{ foreign import {clib_import} {{ "{clib_prefix}_linux_x64_gl_debug.a"{linux_gl_libs} }} }}')
- l(f' else {{ foreign import {clib_import} {{ "{clib_prefix}_linux_x64_gl_release.a"{linux_gl_libs} }} }}')
+ l( ' when USE_DLL {')
+ l(f' when DEBUG {{ foreign import {clib_import} {{ "{clib_prefix}_linux_x64_gl_debug.so"{linux_gl_libs} }} }}')
+ l(f' else {{ foreign import {clib_import} {{ "{clib_prefix}_linux_x64_gl_release.so"{linux_gl_libs} }} }}')
+ l( ' } else {')
+ l(f' when DEBUG {{ foreign import {clib_import} {{ "{clib_prefix}_linux_x64_gl_debug.a"{linux_gl_libs} }} }}')
+ l(f' else {{ foreign import {clib_import} {{ "{clib_prefix}_linux_x64_gl_release.a"{linux_gl_libs} }} }}')
+ l( ' }')
l( '} else {')
l( ' #panic("This OS is currently not supported")')
l( '}')