Created
May 2, 2017 18:15
-
-
Save anonymous/cc2b69c9e86ff2213e03f59a1ac5494b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
user@ubuntu:~/test$ ocamlopt -c test.c | |
user@ubuntu:~/test$ ocamlopt -c main.ml | |
user@ubuntu:~/test$ ocamlopt -cclib -lz main.cmx test.o -o binary | |
test.o: In function `main': | |
/home/user/test/test.c:5: undefined reference to `deflateInit_' | |
collect2: error: ld returned 1 exit status | |
File "caml_startup", line 1: | |
Error: Error during linking |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let _ = Printf.printf "hello\n" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "zlib.h" | |
void cstub(void){ | |
deflateInit(NULL, 0); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment