BILLYSOFTACADEMY

[Solved] How to Easily Fix the 'Unable to Detect ICU Prefix' Error on CentOS, RHEL and Debian Systems.

Introduction

The Unable to Detect ICU Prefix Error is an issue encountered when attempting to compile software such as PHP, install a package such as MediaWiki, or update software packages on CentOS/RHEL/Debian systems. This error can prevent users from being able to access certain software packages and can cause system instability. The issue typically occurs when the system attempts a package installation or update, but cannot locate the appropriate prefix in which it has been installed. The result of this problem is that software packages fail to install, causing many issues for IT professionals and users alike.

The error message

After attempting to compile PHP on a Linux PC, you can get the error:

checking whether to enable internationalization support… yes.
checking for icu-config… no
checking for location of ICU headers and libraries… not found.
configure: error: Unable to detect ICU prefix or no failed. Please verify ICU install prefix and make sure icu-config works.

Solution

To correct the problem on a Centos / RHEL PC, run the command:

To correct the problem on a Debian / Ubuntu based PC, run the command:

Conclusion

If the above solution does not resolve the problem, on a Debian based computer, try to update the system repository and upgrade all packages by running the command
On RHEL / Centos based systems run the command:
We hope that the possible solutions mentioned on this page assist you to fix the ‘Unable to Detect ICU Prefix’ Error.