diff options
author | Andrzej Janik <[email protected]> | 2021-01-15 01:17:44 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2021-01-15 01:17:44 +0100 |
commit | 09f679693bec135776380c92409f4693587ff482 (patch) | |
tree | a76c2ea473f92fef4421e8ef3cba82ad24db5930 /zluda_lib | |
parent | 5cd9a5fbc4b92c58a1db6f205559e690af30481b (diff) | |
download | ZLUDA-09f679693bec135776380c92409f4693587ff482.tar.gz ZLUDA-09f679693bec135776380c92409f4693587ff482.zip |
Prevent linker from stripping exports on Linux (#33)
Diffstat (limited to 'zluda_lib')
-rw-r--r-- | zluda_lib/src/lib.rs | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/zluda_lib/src/lib.rs b/zluda_lib/src/lib.rs index 2022614..a489d98 100644 --- a/zluda_lib/src/lib.rs +++ b/zluda_lib/src/lib.rs @@ -1,3 +1,11 @@ pub extern crate zluda;
-pub use zluda::*;
\ No newline at end of file +pub use zluda::cuda::*;
+
+// For some reason, on Linux linker strips out all our re-exports,
+// there's probably a cleaner solution, but for now just exporting
+// the function below stops it from doing so
+#[no_mangle]
+fn _zluda_very_bad_linker_hack() {
+ cuInit(0);
+}
|