summaryrefslogtreecommitdiff
path: root/devel/electron4/files/patch-build_config_BUILDCONFIG.gn
diff options
context:
space:
mode:
Diffstat (limited to 'devel/electron4/files/patch-build_config_BUILDCONFIG.gn')
-rw-r--r--devel/electron4/files/patch-build_config_BUILDCONFIG.gn119
1 files changed, 119 insertions, 0 deletions
diff --git a/devel/electron4/files/patch-build_config_BUILDCONFIG.gn b/devel/electron4/files/patch-build_config_BUILDCONFIG.gn
new file mode 100644
index 000000000000..2dd8598ea826
--- /dev/null
+++ b/devel/electron4/files/patch-build_config_BUILDCONFIG.gn
@@ -0,0 +1,119 @@
+--- build/config/BUILDCONFIG.gn.orig 2019-03-16 09:15:20 UTC
++++ build/config/BUILDCONFIG.gn
+@@ -134,10 +134,10 @@ declare_args() {
+ is_official_build = false
+
+ # Whether we're a traditional desktop unix.
+- is_desktop_linux = current_os == "linux"
++ is_desktop_linux = current_os == "linux" || current_os == "freebsd"
+
+ # Set to true when compiling with the Clang compiler.
+- is_clang = current_os != "linux" ||
++ is_clang = current_os != "linux" || current_os == "freebsd" ||
+ (current_cpu != "s390x" && current_cpu != "s390" &&
+ current_cpu != "ppc64" && current_cpu != "ppc" &&
+ current_cpu != "mips" && current_cpu != "mips64")
+@@ -189,8 +189,8 @@ if (host_toolchain == "") {
+ # TODO(dpranke): Add some sort of assert here that verifies that
+ # no toolchain omitted host_toolchain from its toolchain_args().
+
+- if (host_os == "linux") {
+- if (target_os != "linux") {
++ if (host_os == "linux" || host_os == "freebsd") {
++ if (target_os != "linux" || target_os != "freebsd") {
+ # TODO(dpranke) - is_clang normally applies only to the target
+ # build, and there is no way to indicate that you want to override
+ # it for both the target build *and* the host build. Do we need to
+@@ -230,7 +230,7 @@ if (target_os == "android") {
+ assert(host_os == "linux" || host_os == "mac",
+ "Android builds are only supported on Linux and Mac hosts.")
+ _default_toolchain = "//build/toolchain/android:android_clang_$target_cpu"
+-} else if (target_os == "chromeos" || target_os == "linux") {
++} else if (target_os == "chromeos" || target_os == "linux" || target_os == "freebsd") {
+ # See comments in build/toolchain/cros/BUILD.gn about board compiles.
+ if (is_clang) {
+ _default_toolchain = "//build/toolchain/linux:clang_$target_cpu"
+@@ -304,6 +304,7 @@ if (current_os == "win" || current_os == "winuwp") {
+ is_nacl = false
+ is_posix = false
+ is_win = true
++ is_bsd = false
+ } else if (current_os == "mac") {
+ is_aix = false
+ is_android = false
+@@ -315,6 +316,7 @@ if (current_os == "win" || current_os == "winuwp") {
+ is_nacl = false
+ is_posix = true
+ is_win = false
++ is_bsd = false
+ } else if (current_os == "android") {
+ is_aix = false
+ is_android = true
+@@ -326,6 +328,7 @@ if (current_os == "win" || current_os == "winuwp") {
+ is_nacl = false
+ is_posix = true
+ is_win = false
++ is_bsd = false
+ } else if (current_os == "chromeos") {
+ is_aix = false
+ is_android = false
+@@ -337,6 +340,7 @@ if (current_os == "win" || current_os == "winuwp") {
+ is_nacl = false
+ is_posix = true
+ is_win = false
++ is_bsd = false
+ } else if (current_os == "nacl") {
+ # current_os == "nacl" will be passed by the nacl toolchain definition.
+ # It is not set by default or on the command line. We treat is as a
+@@ -351,6 +355,7 @@ if (current_os == "win" || current_os == "winuwp") {
+ is_nacl = true
+ is_posix = true
+ is_win = false
++ is_bsd = false
+ } else if (current_os == "fuchsia") {
+ is_aix = false
+ is_android = false
+@@ -362,6 +367,7 @@ if (current_os == "win" || current_os == "winuwp") {
+ is_nacl = false
+ is_posix = false
+ is_win = false
++ is_bsd = false
+ } else if (current_os == "ios") {
+ is_aix = false
+ is_android = false
+@@ -373,6 +379,7 @@ if (current_os == "win" || current_os == "winuwp") {
+ is_nacl = false
+ is_posix = true
+ is_win = false
++ is_bsd = false
+ } else if (current_os == "linux") {
+ is_aix = false
+ is_android = false
+@@ -384,6 +391,7 @@ if (current_os == "win" || current_os == "winuwp") {
+ is_nacl = false
+ is_posix = true
+ is_win = false
++ is_bsd = false
+ } else if (current_os == "aix") {
+ is_aix = true
+ is_android = false
+@@ -395,6 +403,19 @@ if (current_os == "win" || current_os == "winuwp") {
+ is_nacl = false
+ is_posix = true
+ is_win = false
++ is_bsd = false
++} else if (current_os == "freebsd") {
++ is_aix = false
++ is_android = false
++ is_chromeos = false
++ is_fuchsia = false
++ is_ios = false
++ is_linux = true
++ is_mac = false
++ is_nacl = false
++ is_posix = true
++ is_win = false
++ is_bsd = true
+ }
+
+ # =============================================================================