Import a bvh file and export it to be the same
I looked a little closer and found a solution. On importing, there's an option to set which axes point up and forward. Set those to Z up and Y forward.
  

Here's the original file with the axes set like that:
  

And here's after exporting it and re-importing it with the axes set like that:
  

As you can see the entire scene gets rotated when you do this, but the files are essentially identical. A possible workaround would be to import with the axes set to their defaults, and when you're done working with it, select everything and rotating it by -90° around the X axis before exporting. Snap the 3D cursor to the world centre (ShiftS > R) and set the pivot point to 3D cursor before rotating.