We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c1815cd commit 54372c3Copy full SHA for 54372c3
src/server/modules/engine/commander/build.js
@@ -2,6 +2,11 @@ import path from 'path';
2
import { runShellCMD } from '../../../common/utils/process';
3
import { logger } from "../../../common/logging";
4
5
+const DEFAULT_ENV = {
6
+ // necessary for cross compiling and static linking
7
+ CGO_ENABLED: '0'
8
+};
9
+
10
/**
11
* Build the engine.
12
*
@@ -76,11 +81,12 @@ function _translateOptsToCommandArgs(opts) {
76
81
}
77
82
78
83
function _getEnv(opts) {
84
+ const env = {...DEFAULT_ENV};
85
79
86
if (!opts.compile) {
80
- return {};
87
+ return env;
88
89
- const env = {};
90
if (opts.compile.os) {
91
env.GOOS = opts.compile.os;
92
0 commit comments