x265: refactored to generic, fixed build versioning