Both `l-smash` and `gpac` are libraries that deal with MP4.
However, especially in MP4, L-SMASH seems much better libraries.