def configure_eval(sdk: str):
    """Configure Qualcomm SDK for model evaluation."""
    resource_path = "olive.platform_sdk.qualcomm"
    if sdk == "snpe":
        sdk_env = SNPESDKEnv()
    else:
        sdk_env = QNNSDKEnv()
    target_arch_name = sdk_env.target_arch
    if target_arch_name not in [SDKTargetDevice.aarch64_windows, SDKTargetDevice.arm64x_windows]:
        return

    sdk_root = sdk_env.sdk_root_path

    logger.info("Configuring %s for %s...", sdk, target_arch_name)

    bin_path = Path(f"{sdk_root}/bin/{target_arch_name}")
    lib_path = Path(f"{sdk_root}/lib/{target_arch_name}")
    dsp_lib_path = Path(f"{sdk_root}/lib/dsp")

    # symlink all files under 'olive-arm-win'
    # If all files are not under the same path, there are problems with the dll files being spread under
    # multiple PATH directories
    olive_sdk_path = Path(sdk_root).resolve() / "olive-arm-win"
    if olive_sdk_path.exists():
        shutil.rmtree(olive_sdk_path)
    olive_sdk_path.mkdir()
    for path in [bin_path, lib_path, dsp_lib_path]:
        for member in path.iterdir():
            (olive_sdk_path / member.name).symlink_to(member)

    # copy over libcdsprpc.dll
    with resources.path(resource_path, "copy_libcdsprpc.ps1") as copy_libcdsprpc_path:  # pylint: disable=deprecated-method
        cmd = f"powershell {copy_libcdsprpc_path} {olive_sdk_path}"
        run_subprocess(cmd, check=True)
        if not (olive_sdk_path / "libcdsprpc.dll").exists():
            raise RuntimeError(f"Failed to copy libcdsprpc.dll to {olive_sdk_path}")

    logger.info("Done")
Configure Qualcomm SDK for model evaluation.
olive/platform_sdk/qualcomm/configure/configure.py