charlock_holmes
charlock_holmes copied to clipboard
Fix ICU detection to use actual installed version on macOS
The previous implementation used brew --prefix icu4c which returns the path where the latest icu4c package would be installed, not necessarily where an installed version actually exists.
If a user has an older versioned package installed (e.g., icu4c@77), the path /opt/homebrew/opt/icu4c would not exist, causing the build to fail.
This change:
- Detects all installed icu4c packages (including versioned ones)
- Selects the latest installed version
- Uses that version's actual installation path
This ensures the build works correctly when users have versioned ICU packages installed via Homebrew.
@tenderlove Could I trouble you for a review and release for this? It seems that many of my team members are getting bit by this problem now that Homebrew released icu4c 78. Thank you!