@@ -77,12 +77,18 @@ cd $BUILDDIR/$ARCH
7777
7878# =========== libicuXX.so ===========
7979
80- [ -e libicuuc.so ] || {
80+ [ -e libicuuc$LIBSUFFIX .so ] || {
8181
8282 [ -e ../icu4c-55_1-src.tgz ] || exit 1
8383
8484 tar xvf ../icu4c-55_1-src.tgz
8585
86+ # The ENVVAR LIBSUFFIX should add the suffix only to the libname and not to the symbols.
87+ # ToDo: Find the right way in Swift to refer to an alternative library with symbol prefixing or any other method to remove this.
88+ if $[ -n " $LIBSUFFIX " ]; then
89+ patch -p0 < ../patches/icu_suffix_only_on_libname.patch
90+ fi
91+
8692 cd icu/source
8793
8894 # cp -f $BUILDDIR/config.sub .
@@ -104,6 +110,7 @@ cd $BUILDDIR/$ARCH
104110 ./configure \
105111 --host=arm-linux-androideabi \
106112 --prefix=` pwd` /../../ \
113+ --with-library-suffix=$LIBSUFFIX \
107114 --with-cross-build=` pwd` /cross \
108115 --enable-static --enable-shared \
109116 || exit 1
@@ -119,7 +126,7 @@ cd $BUILDDIR/$ARCH
119126 $BUILDDIR /setCrossEnvironment-$ARCH .sh \
120127 make V=1 install || exit 1
121128
122- for f in libicudata libicutest libicui18n libicuio libicule libiculx libicutu libicuuc; do
129+ for f in libicudata$LIBSUFFIX libicutest$LIBSUFFIX libicui18n$LIBSUFFIX libicuio$LIBSUFFIX libicule$LIBSUFFIX libiculx$LIBSUFFIX libicutu$LIBSUFFIX libicuuc$LIBSUFFIX ; do
123130 cp -f -H ../../lib/$f .so ../../
124131 cp -f ../../lib/$f .a ../../
125132 $BUILDDIR /setCrossEnvironment-$ARCH .sh \
0 commit comments