File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -1447,7 +1447,11 @@ function copy_embedded_compiler_rt_builtins_from_darwin_host_toolchain() {
1447
1447
DEST_LIB_PATH=" ${DEST_BUILTINS_DIR} /${LIB_NAME} "
1448
1448
if [[ ! -f " ${DEST_LIB_PATH} " ]]; then
1449
1449
if [[ -f " ${HOST_LIB_PATH} " ]]; then
1450
- call cp " ${HOST_LIB_PATH} " " ${DEST_LIB_PATH} "
1450
+ if [[ " $OS " == " tvos" ]]; then
1451
+ call lipo -remove i386 " ${HOST_LIB_PATH} " -output " ${DEST_LIB_PATH} " || call cp " ${HOST_LIB_PATH} " " ${DEST_LIB_PATH} "
1452
+ else
1453
+ call cp " ${HOST_LIB_PATH} " " ${DEST_LIB_PATH} "
1454
+ fi
1451
1455
elif [[ " ${VERBOSE_BUILD} " ]]; then
1452
1456
echo " no file exists at ${HOST_LIB_PATH} "
1453
1457
fi
@@ -1459,7 +1463,11 @@ function copy_embedded_compiler_rt_builtins_from_darwin_host_toolchain() {
1459
1463
DEST_SIM_LIB_PATH=" ${DEST_BUILTINS_DIR} /${SIM_LIB_NAME} "
1460
1464
if [[ ! -f " ${DEST_SIM_LIB_PATH} " ]]; then
1461
1465
if [[ -f " ${HOST_SIM_LIB_PATH} " ]]; then
1462
- call cp " ${HOST_SIM_LIB_PATH} " " ${DEST_SIM_LIB_PATH} "
1466
+ if [[ " $OS " == " tvos" ]]; then
1467
+ call lipo -remove i386 " ${HOST_SIM_LIB_PATH} " -output " ${DEST_SIM_LIB_PATH} " || call cp " ${HOST_SIM_LIB_PATH} " " ${DEST_SIM_LIB_PATH} "
1468
+ else
1469
+ call cp " ${HOST_SIM_LIB_PATH} " " ${DEST_SIM_LIB_PATH} "
1470
+ fi
1463
1471
elif [[ -f " ${HOST_LIB_PATH} " ]]; then
1464
1472
# The simulator .a might not exist if the host
1465
1473
# Xcode is old. In that case, copy over the
You can’t perform that action at this time.
0 commit comments