It's more than a PITA, it's almost impossible to implement ACID correctly. It's very very hard to do. There almost no point in implementing that in house when we have sqlite3.
For custom binary file you could and should use sqlite, it has many benefits instead of writing your own custom file format. You just have acid without any cost. It's a single file database you can access throuhg lib statically linked in your application and that's done.
It's not that really interesting but it's something I use daily. I've written a sqlite3 based time tracking tool. I highly inspired by timewarrior, but I wasn't satisfied with it.