Support building for Magic Leap.

This commit is contained in:
Alan Jeffrey 2018-09-12 17:21:51 -05:00
parent e580250d5d
commit dab8f4a97f
34 changed files with 1601 additions and 7 deletions

21
support/magicleap/fake-ld.sh Executable file
View file

@ -0,0 +1,21 @@
#!/usr/bin/env bash
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
set -o errexit
set -o nounset
set -o pipefail
MAGICLEAP_TOOLCHAIN=${MAGICLEAP_TOOLCHAIN:-"${MAGICLEAP_SDK}/tools/toolchains"}
TARGET=${TARGET:-"aarch64-linux-android"}
LD=${LD:-"${MAGICLEAP_TOOLCHAIN}/bin/${TARGET}-ld"}
LDFLAGS=${LDFLAGS:-"-L${MAGICLEAP_SDK}/lumin/stl/libc++/lib -L${MAGICLEAP_SDK}/lumin/usr/lib -L${MAGICLEAP_TOOLCHAIN}/lib/gcc/${TARGET}/4.9.x ${MAGICLEAP_SDK}/lumin/usr/lib/crtbegin_so.o"}
# Remove the -landroid flag, grr
ARGS=("$@")
ARGS=${ARGS[@]/-landroid}
echo ${LD} ${LDFLAGS} ${ARGS}
${LD} ${LDFLAGS} ${ARGS}