-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Harvey port of golang #2
base: harveyport
Are you sure you want to change the base?
Conversation
Signed-off-by: Sevki <[email protected]>
c7dfb7b
to
7fd07e0
Compare
Signed-off-by: Sevki <[email protected]>
add harvey to okgoos var add harvey/amd64 to cgoEnabled as false Signed-off-by: Sevki <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is the approach here? Are you going to go with "harvey implies plan 9 with differences" or a full port? What's your plan for keeping up with ToT?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
my port is in plan9port. Why push to master? Why not a branch? Master is supposed to mirror upstream master.
I'm trying to figure out how would "harvey implies plan9 but with differences" work, and the only way I know how to do that is by trial and error. For instance, our previous assumption that we can handle this by implementing a ast re-writer didn't really pan out, since there are a lot of asm files, and code that's generated from My initial feeling is we'll probably need to fix stuff in runtime by hand and rest can probably be re-written by a tool which I started working on sevki/go2os |
@rminnich done. |
Take a look at how android implies linux. That's what everyone suggested. it's actually what plan9port does in effect and it's why only three files change. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Given that it's into this branch it makes sense to do it.
plan9 files are now tagged with !harvey build tags Signed-off-by: Sevki <[email protected]>
for filename matching go uses android = linux type mechanism. This commit extends that behaviour for harvey to take advantage of that mechanism. Signed-off-by: Sevki <[email protected]>
this commit gets rid of hardcoding the head type as linux Signed-off-by: Sevki <[email protected]>
this commit adds ron's changes to in the plan9 fork applied to harvey specific files and adds build tags that prevent plan9 files to be included in the package file lists. Signed-off-by: Sevki <[email protected]>
Is this going anywhere? It would be great to get Go running well. |
I've been looking into the build error you've been seeing in Travis. I think the problem is caused by the linker thinking that none of the objects are referenced. It seems to think there's no root to the tree. If you use one of the debug modes in the linker, and run with GOOS=plan9, you'll see the first marked object is _rt0_amd64_plan9. Do the same with GOOS=harvey and you'll see nothing. Try copying the file rt0_plan9_amd64.s, and naming it rt0_harvey_amd64.s. You'll also need to rename the function in the file to _rt0_amd64_harvey. This worked on my machine :), with a minimal set of changes on top of the plan9port branch. |
@gmacd it's a Christmas miracle! 🎉 |
Merry Christmas @sevki! It builds the compiler, but if you then compile anything with it, the exe suicides on exit. It's a step in the right direction though :) |
Actually, it's not suiciding on exit, it's half way through printing a line. Maybe I'll get more time to look at it in the evening, unless you get there first :) |
@gmacd best boxing day present ever. I'll have a crack at it 😄 |
Yeah, unfortunately you need to wrap it yourself :) |
ha. it's the thought that counts mate! |
attempting to port go to harvey:
harvey
tosrc/go/build/syslist.go
harvey
tocmd/dist/build.go