ICUDATA_NAME is in pkg-config files
The three icu pkg-config files icu-i18n.pc, icu-io.pc, icu-uc.pc contain a definition for the nonstandard variable ICUDATA_NAME. For example icu 67.1 installed on x86_64 contains the line:
My understanding is that the "l" suffix means "little-endian" and that on a big-endian system like ppc it would instead say:
Other projects using pkg-config to get info about icu can retrieve this variable using e.g.:
icu-config and the Makefile.inc files also contain definitions of ICUDATA_NAME. (I understand that these are deprecated in favor of the .pc files.)
You can't put definitions into the configuration files that you install that vary based on the processor architecture. This would cause other projects to compile wrong if they are being cross-compiled. There have been many previous reports of this type of problem, such as ICU-10308. See also https://trac.macports.org/ticket/45268.
On macOS it is not uncommon to wish to do a type of cross compilation called a universal binary that contains code compiled for more than one architecture. While it is easy to compile icu several times, once for each architecture, and merge the resulting separate-architecture binaries together into a multiple-architecture binary, there is no equivalent process available for your pkg-config .pc files because at the time that someone is running pkg-config to get information about icu it is not known for which architecture that software will be built.
If icu supports big endian systems, which I believe it does, then it is reasonable to want to build a ppc/i386 universal binary.
is big endian in scope for you ?
I don’t; I’m sorry. My use case is that I want it to be possible to compile a universal binary of icu on macOS that works correctly on any architecture.
Do you have ideas for how to improve this for your use case?
Do you have time to contribute a fix?