[New custom build] Implement platform-specific dependencies

cc #610