Home | History | Annotate | Download | only in toolchain
      1 # Copyright 2018 the V8 project authors. All rights reserved.
      2 # Use of this source code is governed by a BSD-style license that can be
      3 # found in the LICENSE file.
      4 
      5 import("//build/toolchain/gcc_toolchain.gni")
      6 
      7 gcc_toolchain("mips-bundled") {
      8   toolprefix = rebase_path("//tools/mips_toolchain/bin/mips-mti-linux-gnu-",
      9                            root_build_dir)
     10   cc = "${toolprefix}gcc"
     11   cxx = "${toolprefix}g++"
     12 
     13   readelf = "${toolprefix}readelf"
     14   nm = "${toolprefix}nm"
     15   ar = "${toolprefix}ar"
     16   ld = cxx
     17 
     18   # Flag that sets endianness
     19   extra_ldflags = "-EB"
     20   extra_cppflags = "-EB"
     21 
     22   toolchain_args = {
     23     current_cpu = "mips"
     24     current_os = "linux"
     25     is_clang = false
     26   }
     27 }
     28 
     29 gcc_toolchain("mips64-bundled") {
     30   toolprefix = rebase_path("//tools/mips_toolchain/bin/mips-mti-linux-gnu-",
     31                            root_build_dir)
     32   cc = "${toolprefix}gcc"
     33   cxx = "${toolprefix}g++"
     34 
     35   readelf = "${toolprefix}readelf"
     36   nm = "${toolprefix}nm"
     37   ar = "${toolprefix}ar"
     38   ld = cxx
     39 
     40   # Flag that sets endianness and ABI
     41   extra_ldflags = "-EB -mabi=64"
     42   extra_cppflags = "-EB -mabi=64"
     43 
     44   toolchain_args = {
     45     current_cpu = "mips64"
     46     current_os = "linux"
     47     is_clang = false
     48   }
     49 }
     50 
     51 gcc_toolchain("mipsel-bundled") {
     52   toolprefix = rebase_path("//tools/mips_toolchain/bin/mips-mti-linux-gnu-",
     53                            root_build_dir)
     54   cc = "${toolprefix}gcc"
     55   cxx = "${toolprefix}g++"
     56 
     57   readelf = "${toolprefix}readelf"
     58   nm = "${toolprefix}nm"
     59   ar = "${toolprefix}ar"
     60   ld = cxx
     61 
     62   # Flag that sets endianness
     63   extra_ldflags = "-EL"
     64   extra_cppflags = "-EL"
     65 
     66   toolchain_args = {
     67     current_cpu = "mipsel"
     68     current_os = "linux"
     69     is_clang = false
     70   }
     71 }
     72 
     73 gcc_toolchain("mips64el-bundled") {
     74   toolprefix = rebase_path("//tools/mips_toolchain/bin/mips-mti-linux-gnu-",
     75                            root_build_dir)
     76   cc = "${toolprefix}gcc"
     77   cxx = "${toolprefix}g++"
     78 
     79   readelf = "${toolprefix}readelf"
     80   nm = "${toolprefix}nm"
     81   ar = "${toolprefix}ar"
     82   ld = cxx
     83 
     84   # Flag that sets endianness and ABI
     85   extra_ldflags = "-EL -mabi=64"
     86   extra_cppflags = "-EL -mabi=64"
     87 
     88   toolchain_args = {
     89     current_cpu = "mips64el"
     90     current_os = "linux"
     91     is_clang = false
     92   }
     93 }
     94