|
|
@@ -1,79 +0,0 @@
|
|
|
-From fd4f8c65ecbbdd15d71a04d213314de056107a31 Mon Sep 17 00:00:00 2001
|
|
|
-From: CN_SZTL <[email protected]>
|
|
|
-Date: Tue, 18 Aug 2020 20:47:40 +0000
|
|
|
-Subject: [PATCH 2/3] build: add mips & x86 OpenWrt toolchain definitions
|
|
|
-
|
|
|
----
|
|
|
- src/build/toolchain/linux/BUILD.gn | 42 ++++++++++++++++++++++++++++++
|
|
|
- 1 file changed, 42 insertions(+)
|
|
|
-
|
|
|
-diff --git a/src/build/toolchain/linux/BUILD.gn b/src/build/toolchain/linux/BUILD.gn
|
|
|
-index 2e7913a4f..cc8084eac 100644
|
|
|
---- a/src/build/toolchain/linux/BUILD.gn
|
|
|
-+++ b/src/build/toolchain/linux/BUILD.gn
|
|
|
-@@ -95,6 +95,18 @@ clang_toolchain("clang_x86") {
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
-+clang_toolchain("clang_x86_openwrt") {
|
|
|
-+ # Output linker map files for binary size analysis.
|
|
|
-+ enable_linker_map = true
|
|
|
-+ extra_cppflags = "--target=i386-openwrt-linux-musl -D_LIBCPP_HAS_MUSL_LIBC -D__UCLIBC__"
|
|
|
-+ extra_ldflags = "--target=i386-openwrt-linux-musl"
|
|
|
-+
|
|
|
-+ toolchain_args = {
|
|
|
-+ current_cpu = "x86"
|
|
|
-+ current_os = "linux"
|
|
|
-+ }
|
|
|
-+}
|
|
|
-+
|
|
|
- clang_toolchain("clang_x86_v8_arm") {
|
|
|
- toolchain_args = {
|
|
|
- current_cpu = "x86"
|
|
|
-@@ -203,6 +215,26 @@ gcc_toolchain("x64") {
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
-+clang_toolchain("clang_mips_openwrt") {
|
|
|
-+ extra_cppflags = "--target=mips-openwrt-linux-musl -D_LIBCPP_HAS_MUSL_LIBC -D__UCLIBC__"
|
|
|
-+ extra_ldflags = "--target=mips-openwrt-linux-musl"
|
|
|
-+
|
|
|
-+ toolchain_args = {
|
|
|
-+ current_cpu = "mips"
|
|
|
-+ current_os = "linux"
|
|
|
-+ }
|
|
|
-+}
|
|
|
-+
|
|
|
-+clang_toolchain("clang_mips64_openwrt") {
|
|
|
-+ extra_cppflags = "--target=mips64-openwrt-linux-musl -D_LIBCPP_HAS_MUSL_LIBC -D__UCLIBC__"
|
|
|
-+ extra_ldflags = "--target=mips64-openwrt-linux-musl"
|
|
|
-+
|
|
|
-+ toolchain_args = {
|
|
|
-+ current_cpu = "mips64"
|
|
|
-+ current_os = "linux"
|
|
|
-+ }
|
|
|
-+}
|
|
|
-+
|
|
|
- clang_toolchain("clang_mipsel") {
|
|
|
- toolchain_args = {
|
|
|
- current_cpu = "mipsel"
|
|
|
-@@ -227,6 +259,16 @@ clang_toolchain("clang_mips64el") {
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
-+clang_toolchain("clang_mips64el_openwrt") {
|
|
|
-+ extra_cppflags = "--target=mips64el-openwrt-linux-musl -D_LIBCPP_HAS_MUSL_LIBC -D__UCLIBC__"
|
|
|
-+ extra_ldflags = "--target=mips64el-openwrt-linux-musl"
|
|
|
-+
|
|
|
-+ toolchain_args = {
|
|
|
-+ current_cpu = "mips64el"
|
|
|
-+ current_os = "linux"
|
|
|
-+ }
|
|
|
-+}
|
|
|
-+
|
|
|
- gcc_toolchain("mipsel") {
|
|
|
- toolprefix = "mipsel-linux-gnu-"
|
|
|
-
|
|
|
---
|
|
|
-2.17.1
|
|
|
-
|