Remove build directory once build of `jemalloc-sys` finishes
And link to the libraries installed with make install instead. This saves disk space in the target directory. When you build jemalloc multiple times, with different Cargo profiles, RUSTFLAGS etc., the files on disk will begin accumulating for no reason (if there is a change, Cargo will just rebuild the library in a different directory).
Target directory disk space usage is a big concern to Rust users (https://blog.rust-lang.org/2025/02/13/2024-State-Of-Rust-Survey-results.html#challenges), and jemalloc is quite popular, so I think that it would be nice to improve this.
Fixes: https://github.com/tikv/jemallocator/issues/89
Welcome @Kobzol! It looks like this is your first PR to tikv/jemallocator 🎉
The contributing guide link is 404. Do you have any suggestion on how to do the DCO sign-off?
Added the signoff.
@BusyJay What do you think about this? :)
@BusyJay ping :)
You need to rebase master
Done. I also ignored any potential errors, so that they don't impact the result of the build.
Thanks!