These two pull requests here and here allow me to build the most recent version of Rust on DragonFly again. The first patch fixes
rust-lang/libc, the pure-Rust
libc equivalent. The second patch is a follow up of an old patch I submitted a few month ago and fixes the way Rust determines the filename of the currently executing binary.