Skip to content

Commit 449e1aa

Browse files
committed
[[ Prebuilts ]] Compile the set of prebuilt libs needed on each platform
1 parent 75bb07b commit 449e1aa

2 files changed

Lines changed: 26 additions & 10 deletions

File tree

prebuilt/build-libraries.sh

Lines changed: 26 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,29 @@ fi
2727
export CUSTOM_CC="${CC}"
2828
export CUSTOM_CXX="${CXX}"
2929

30-
# Build all of the libraries that we depend on (OpenSSL, CURL and ICU) if not specified
31-
$BASEDIR/scripts/build-openssl.sh
32-
$BASEDIR/scripts/build-curl.sh
33-
$BASEDIR/scripts/build-icu.sh
30+
# Set which libs to build for the target platform
31+
case "${PLATFORM}" in
32+
android)
33+
PREBUILT_LIBS="openssl icu"
34+
;;
35+
mac)
36+
PREBUILT_LIBS="openssl icu"
37+
;;
38+
ios)
39+
PREBUILT_LIBS="openssl icu"
40+
;;
41+
win32)
42+
PREBUILT_LIBS="openssl curl icu"
43+
;;
44+
linux)
45+
PREBUILT_LIBS="openssl curl icu"
46+
;;
47+
emscripten)
48+
PREBUILT_LIBS="icu"
49+
;;
50+
esac
51+
52+
# Build all of the libraries that the target platform depends on
53+
for t_lib in ${PREBUILT_LIBS} ; do
54+
${BASEDIR}/scripts/build-${t_lib}.sh
55+
done

prebuilt/scripts/build-curl.sh

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,6 @@ source "${BASEDIR}/scripts/platform.inc"
44
source "${BASEDIR}/scripts/lib_versions.inc"
55
source "${BASEDIR}/scripts/util.inc"
66

7-
# Only for desktop platforms
8-
if [ "${PLATFORM}" == "ios" -o "${PLATFORM}" == "android" ] ; then
9-
echo "Curl not required for platform ${PLATFORM}"
10-
exit 0
11-
fi
12-
137
# Configuration flags
148
CURL_CONFIG="--disable-debug \
159
--enable-http --enable-ftp --disable-file --disable-ldap --disable-ldaps --disable-rtsp --disable-dict --disable-telnet \

0 commit comments

Comments
 (0)