Merge pull request #11208 from electron/mips64el
Add support for mips64el
This commit is contained in:
commit
f8adaed763
17 changed files with 207 additions and 46 deletions
|
@ -5,6 +5,11 @@ import os
|
|||
import platform
|
||||
import sys
|
||||
|
||||
# URL to the mips64el sysroot image.
|
||||
MIPS64EL_SYSROOT_URL = 'https://github.com/electron/debian-sysroot-image-creator/releases/download/v0.5.0/debian_jessie_mips64-sysroot.tar.bz2'
|
||||
# URL to the mips64el toolchain.
|
||||
MIPS64EL_GCC = 'gcc-4.8.3-d197-n64-loongson'
|
||||
MIPS64EL_GCC_URL = 'http://ftp.loongnix.org/toolchain/gcc/release/' + MIPS64EL_GCC + '.tar.gz'
|
||||
|
||||
BASE_URL = os.getenv('LIBCHROMIUMCONTENT_MIRROR') or \
|
||||
'https://s3.amazonaws.com/github-janky-artifacts/libchromiumcontent'
|
||||
|
@ -79,3 +84,21 @@ def get_zip_name(name, version, suffix=''):
|
|||
if suffix:
|
||||
zip_name += '-' + suffix
|
||||
return zip_name + '.zip'
|
||||
|
||||
|
||||
def build_env():
|
||||
env = os.environ.copy()
|
||||
if get_target_arch() == "mips64el":
|
||||
SOURCE_ROOT = os.path.abspath(os.path.dirname(os.path.dirname(os.path.dirname(__file__))))
|
||||
VENDOR_DIR = os.path.join(SOURCE_ROOT, 'vendor')
|
||||
gcc_dir = os.path.join(VENDOR_DIR, MIPS64EL_GCC)
|
||||
ldlib_dirs = [
|
||||
gcc_dir + '/usr/x86_64-unknown-linux-gnu/mips64el-redhat-linux/lib',
|
||||
gcc_dir + '/usr/lib64',
|
||||
gcc_dir + '/usr/mips64el-redhat-linux/lib64',
|
||||
gcc_dir + '/usr/mips64el-redhat-linux/sysroot/lib64',
|
||||
gcc_dir + '/usr/mips64el-redhat-linux/sysroot/usr/lib64',
|
||||
]
|
||||
env['LD_LIBRARY_PATH'] = os.pathsep.join(ldlib_dirs)
|
||||
env['PATH'] = os.pathsep.join([gcc_dir + '/usr/bin', env['PATH']])
|
||||
return env
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue