Thanks a lot.
However, I still have an error.
gcc -fPIC -shared -o niftest.so niftest.c -I $ERL_ROOT/usr/include/ -bundle -bundle_loader $ERL_ROOT/erts-12.3/bin/beam.smp
clang: error: invalid argument '-bundle' not allowed with '-dynamiclib'
I think this comes from using clang instead of gcc although I don’t know how -bundle works. I will check the option.




















