Skip to content

Wrong env-var name for ICU root dir on Windows #7

@user-canada

Description

@user-canada

Problem

Considering the following:

# For windows or non standard installation, define ICU_ROOT_DIR variable to point to the root installation of ICU. Two ways:
#   - run cmake with -DICU_ROOT_DIR=<PATH>

The specified env-var name is ICU_ROOT_DIR, but looking inside FindICU.cmake, this identifier cannot be found. Instead, you will find "ICU_ROOT".

The issue here was that I was not able to load my CMake project. It was yielding this error:

CMake Error at C:/Program Files/JetBrains/CLion 2022.2.1/bin/cmake/win/share/cmake-3.23/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  Failed to find all ICU components (missing: ICU_INCLUDE_DIR ICU_LIBRARY)
  (Required is at least version "73.1")

Solution

Having changed env-var name ICU_ROOT_DIR to ICU_ROOT fixes the issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions