Live data from Hacker News

Gopher-OS: A Proof of Concept OS Written in Go

github.com

81–84 of 84 posts

Re: Gopher-OS: A Proof of Concept OS Written in Go

#81
post #79

Earlier quoted context omitted.

I take a slightly different approach for my implementation that allows me to use the standard go toolchain. I use nasm for the early ASM code and patch the go build tool's output (see: https://github.com/achilleasa/gopher-os/blob/master/Makefile... ) to bypass the link step and replace it with a manual call to ld that links the go object files with the output from nasm. I will be talking about this approach in more d…

Do you know if your talk going to be online afterwards?

Yes, the talk will be recorded and posted online with the slides and some getting started code.

Re: Gopher-OS: A Proof of Concept OS Written in Go

#82
post #46

Earlier quoted context omitted.

Even worse is when Justin Timberlake did that song "Cry Me A River", when there was already an excellent song by the same name. It just obscures the existing song, and does the world a disservice.

Pretty rude way to disagree with someone. I'd appreciate any criticism, but not sure what I'm supposed to do with this comment, other than feeling bad.

perhaps, have a laugh?

Re: Gopher-OS: A Proof of Concept OS Written in Go

#83

Hi, I am the author of gopher-os. It started as a fun research project to learn more about the Go runtime internals and I didn't really expect it making it to HN. If you take a look at the Go runtime sources you will notice that all the low-level arch/os-related bits have been split into separate files which usually invoke some syscalls (e.g. the memory allocator eventually calls mmap) The idea I am currently investi…

Have you seen https://github.com/atmanos/atmanos ? It may be of interest to you.

Re: Gopher-OS: A Proof of Concept OS Written in Go

#84
Interesting project.

What's all this voodoo inside Makefile, I would love more comments in there. I think that would be the first step for anyone wanting to contribute, to understand the Makefile.

    @echo "[go] compiling go sources into a standalone .o file"
    @GOARCH=$(GOARCH) GOOS=$(GOOS) go build -n 2>&1 | sed \
	   -e "1s|^|set -e\n|" \
	   -e "1s|^|export GOOS=$(GOOS)\n|" \
	   -e "1s|^|export GOARCH=$(GOARCH)\n|" \
	   -e "1s|^|WORK='$(BUILD_ABS_DIR)'\n|" \
	   -e "1s|^|alias pack='go tool pack'\n|" \
	   -e "/^mv/d" \
	   -e "s|-extld|-tmpdir='$(BUILD_ABS_DIR)' -linkmode=external -extldflags='-nostartfiles -nodefaultlibs -nostdlib -r' -extld|g" \
	    | sh 2>&1 | sed -e "s/^/  | /g"
edit I think I understand what's happening here, funny how writing it down helps one understand. It's just building up a build script with sed and executing it. The thing was I didn't know sed could do that. TIL
Post reply on HN