$73 GRAYBYTE WORDPRESS FILE MANAGER $71

SERVER : vnpttt-amd7f72-h1.vietnix.vn #1 SMP Fri May 24 12:42:50 UTC 2024
SERVER IP : 103.200.23.149 | ADMIN IP 216.73.216.22
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : NONE

/lib/golang/src/cmd/dist/

HOME
Current File : /lib/golang/src/cmd/dist//buildruntime.go
// Copyright 2012 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package main

import (
	"fmt"
	"os"
	"strings"
)

/*
 * Helpers for building runtime.
 */

// mkzversion writes zversion.go:
//
//	package sys
//
// (Nothing right now!)
func mkzversion(dir, file string) {
	var buf strings.Builder
	writeHeader(&buf)
	fmt.Fprintf(&buf, "package sys\n")
	writefile(buf.String(), file, writeSkipSame)
}

// mkbuildcfg writes internal/buildcfg/zbootstrap.go:
//
//	package buildcfg
//
//	const defaultGOROOT = <goroot>
//	const defaultGO386 = <go386>
//	...
//	const defaultGOOS = runtime.GOOS
//	const defaultGOARCH = runtime.GOARCH
//
// The use of runtime.GOOS and runtime.GOARCH makes sure that
// a cross-compiled compiler expects to compile for its own target
// system. That is, if on a Mac you do:
//
//	GOOS=linux GOARCH=ppc64 go build cmd/compile
//
// the resulting compiler will default to generating linux/ppc64 object files.
// This is more useful than having it default to generating objects for the
// original target (in this example, a Mac).
func mkbuildcfg(file string) {
	var buf strings.Builder
	writeHeader(&buf)
	fmt.Fprintf(&buf, "package buildcfg\n")
	fmt.Fprintln(&buf)
	fmt.Fprintf(&buf, "import \"runtime\"\n")
	fmt.Fprintln(&buf)
	fmt.Fprintf(&buf, "const DefaultGO386 = `%s`\n", go386)
	fmt.Fprintf(&buf, "const DefaultGOAMD64 = `%s`\n", goamd64)
	fmt.Fprintf(&buf, "const DefaultGOARM = `%s`\n", goarm)
	fmt.Fprintf(&buf, "const DefaultGOARM64 = `%s`\n", goarm64)
	fmt.Fprintf(&buf, "const DefaultGOMIPS = `%s`\n", gomips)
	fmt.Fprintf(&buf, "const DefaultGOMIPS64 = `%s`\n", gomips64)
	fmt.Fprintf(&buf, "const DefaultGOPPC64 = `%s`\n", goppc64)
	fmt.Fprintf(&buf, "const DefaultGORISCV64 = `%s`\n", goriscv64)
	fmt.Fprintf(&buf, "const defaultGOEXPERIMENT = `%s`\n", goexperiment)
	fmt.Fprintf(&buf, "const defaultGO_EXTLINK_ENABLED = `%s`\n", goextlinkenabled)
	fmt.Fprintf(&buf, "const defaultGO_LDSO = `%s`\n", defaultldso)
	fmt.Fprintf(&buf, "const version = `%s`\n", findgoversion())
	fmt.Fprintf(&buf, "const defaultGOOS = runtime.GOOS\n")
	fmt.Fprintf(&buf, "const defaultGOARCH = runtime.GOARCH\n")
	fmt.Fprintf(&buf, "const DefaultGOFIPS140 = `%s`\n", gofips140)
	fmt.Fprintf(&buf, "const DefaultCGO_ENABLED = %s\n", quote(os.Getenv("CGO_ENABLED")))

	writefile(buf.String(), file, writeSkipSame)
}

// mkobjabi writes cmd/internal/objabi/zbootstrap.go:
//
//	package objabi
//
// (Nothing right now!)
func mkobjabi(file string) {
	var buf strings.Builder
	writeHeader(&buf)
	fmt.Fprintf(&buf, "package objabi\n")

	writefile(buf.String(), file, writeSkipSame)
}

Current_dir [ NOT WRITEABLE ] Document_root [ WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
16 Dec 2025 9.30 PM
root / root
0755
README
1.014 KB
4 Dec 2025 6.06 PM
root / root
0644
build.go
56.463 KB
4 Dec 2025 6.06 PM
root / root
0644
buildgo.go
3.821 KB
4 Dec 2025 6.06 PM
root / root
0644
buildruntime.go
2.632 KB
4 Dec 2025 6.06 PM
root / root
0644
buildtag.go
3.005 KB
4 Dec 2025 6.06 PM
root / root
0644
buildtool.go
12.018 KB
4 Dec 2025 6.06 PM
root / root
0644
doc.go
0.63 KB
4 Dec 2025 6.06 PM
root / root
0644
exec.go
0.935 KB
4 Dec 2025 6.06 PM
root / root
0644
imports.go
6.326 KB
4 Dec 2025 6.06 PM
root / root
0644
main.go
5.483 KB
4 Dec 2025 6.06 PM
root / root
0644
notgo122.go
0.812 KB
4 Dec 2025 6.06 PM
root / root
0644
quoted.go
1.241 KB
4 Dec 2025 6.06 PM
root / root
0644
sys_default.go
0.209 KB
4 Dec 2025 6.06 PM
root / root
0644
sys_windows.go
1.551 KB
4 Dec 2025 6.06 PM
root / root
0644
test.go
55.557 KB
4 Dec 2025 6.06 PM
root / root
0644
testjson.go
4.588 KB
4 Dec 2025 6.06 PM
root / root
0644
util.go
11.151 KB
4 Dec 2025 6.06 PM
root / root
0644
util_gc.go
0.595 KB
4 Dec 2025 6.06 PM
root / root
0644
util_gccgo.go
0.246 KB
4 Dec 2025 6.06 PM
root / root
0644
vfp_arm.s
0.636 KB
4 Dec 2025 6.06 PM
root / root
0644
vfp_default.s
0.31 KB
4 Dec 2025 6.06 PM
root / root
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2026 CONTACT ME
Static GIF