Efficient way to encapsulate raw h.264 in mp4

   I checked out adi h264 encoder library and as far as I can tell there is no option for containers, so my application can only produce raw h264 video files, which can be played with vlc, but don't show any timing information such as video length or current video playback time. 
   I have successfully used FFmpeg to encapsulate it in mp4 container but this is only proof of concept as far as I am concerned.
Currently our device can put out h264 videos but users would have a hard time playing them back (especialy with no timing information or VLC required).
I was looking into different solutions for encapsulating encoded video and I am not sure which one to pursue. 
From what I gathered I can either encapsulate fully recorded video file or encapsulate as encoder encodes.
The second option is what I would like to achieve since our BF609 board doesn't store encoded video and sends it off to a different board.
Are there any recommendations whether I should use existing library to do so or should I implement encapsulation according to ISO standards?

Best Regards