Use portable way of linking with libdl