Following are the instructions to compile the text-icu Haskell package on MacOSX (tested on MacOSX 10.7).
We will use the MacPorts package manager to install the ICU libraries and header files.
If you don't have the MacPorts package manager installed on your system you should download and install it.
We update the port packages database and then we install the icu package. This step will install the required libraries and header files.
sudo port selfupdate
sudo port install icu
Finally, we update the cabal packages databases and we install the text-icu package specifying the locations of the include and lib directories.
sudo cabal update
sudo cabal install text-icu --extra-include-dirs=/opt/local/include --extra-lib-dirs=/opt/local/lib