mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-04 11:07:46 +00:00
builder: fix cache paths in -size=full output
This fixes long paths from the TinyGo cached GOROOT, as can be seen
here:
code rodata data bss | flash ram | package
------------------------------- | --------------- | -------
0 5 0 5 | 5 5 | (padding)
148 0 0 5 | 148 5 | (unknown)
76 0 0 0 | 76 0 | /home/ayke/.cache/tinygo/goroot-ce8827882be9dc201bed279a631881177ae124ea064510684a3cf4bb66436e1a/src/device/arm
4 0 0 0 | 4 0 | /home/ayke/.cache/tinygo/goroot-ce8827882be9dc201bed279a631881177ae124ea064510684a3cf4bb66436e1a/src/internal/task
They're now attributed to the correct package instead (device/arm and
internal/task).
This commit is contained in:
committed by
Ron Evans
parent
1b83d43cfa
commit
9172cc15d2
+1
-1
@@ -690,7 +690,7 @@ func Build(pkgName, outpath, tmpdir string, config *compileopts.Config) (BuildRe
|
||||
for _, pkg := range lprogram.Sorted() {
|
||||
pkg := pkg
|
||||
for _, filename := range pkg.CFiles {
|
||||
abspath := filepath.Join(pkg.Dir, filename)
|
||||
abspath := filepath.Join(pkg.OriginalDir(), filename)
|
||||
job := &compileJob{
|
||||
description: "compile CGo file " + abspath,
|
||||
run: func(job *compileJob) error {
|
||||
|
||||
Reference in New Issue
Block a user