Added workaround for build order issues. Now runs fine at least.