Use realpath in rebuilt-epub and free paths