1
0
mirror of https://github.com/taigrr/gopher-os synced 2025-01-18 04:43:13 -08:00

makefile: tweak build script to compile kernel using go 1.10

This commit is contained in:
Achilleas Anagnostopoulos 2018-03-23 07:17:12 +00:00
parent ce9a397008
commit c0f92f4454

View File

@ -61,11 +61,13 @@ go.o:
-e "1s|^|export GOOS=$(GOOS)\n|" \ -e "1s|^|export GOOS=$(GOOS)\n|" \
-e "1s|^|export GOARCH=$(GOARCH)\n|" \ -e "1s|^|export GOARCH=$(GOARCH)\n|" \
-e "1s|^|export GOROOT=$(GOROOT)\n|" \ -e "1s|^|export GOROOT=$(GOROOT)\n|" \
-e "1s|^|WORK='$(BUILD_ABS_DIR)'\n|" \ -e "1s|^|export CGO_ENABLED=0\n|" \
-e "1s|^|alias pack='$(GO) tool pack'\n|" \ -e "1s|^|alias pack='$(GO) tool pack'\n|" \
-e "/^mv/d" \ -e "/^mv/d" \
-e "/\/buildid/d" \
-e "s|-extld|-tmpdir='$(BUILD_ABS_DIR)' -linkmode=external -extldflags='-nostartfiles -nodefaultlibs -nostdlib -r' -extld|g" \ -e "s|-extld|-tmpdir='$(BUILD_ABS_DIR)' -linkmode=external -extldflags='-nostartfiles -nodefaultlibs -nostdlib -r' -extld|g" \
| sh 2>&1 | sed -e "s/^/ | /g" -e 's|$$WORK|$(BUILD_ABS_DIR)|g' \
| sh 2>&1 | sed -e "s/^/ | /g"
@# build/go.o is a elf32 object file but all go symbols are unexported. Our @# build/go.o is a elf32 object file but all go symbols are unexported. Our
@# asm entrypoint code needs to know the address to 'main.main' so we use @# asm entrypoint code needs to know the address to 'main.main' so we use