aboutsummaryrefslogtreecommitdiff
path: root/compiler_wrapper/libc_exec.go
diff options
context:
space:
mode:
Diffstat (limited to 'compiler_wrapper/libc_exec.go')
-rw-r--r--compiler_wrapper/libc_exec.go7
1 files changed, 6 insertions, 1 deletions
diff --git a/compiler_wrapper/libc_exec.go b/compiler_wrapper/libc_exec.go
index 268221dc..f8db9d86 100644
--- a/compiler_wrapper/libc_exec.go
+++ b/compiler_wrapper/libc_exec.go
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+// +build libc_exec
+
package main
// #include <errno.h>
@@ -26,7 +28,10 @@ import (
// LD_PRELOAD to work properly (e.g. gentoo sandbox).
// Note that this changes the go binary to be a dynamically linked one.
// See crbug.com/1000863 for details.
-func libcExec(env env, cmd *command) error {
+// To use this version of exec, please add '-tags libc_exec' when building Go binary.
+// Without the tags, libc_exec.go will be used.
+
+func execCmd(env env, cmd *command) error {
freeList := []unsafe.Pointer{}
defer func() {
for _, ptr := range freeList {