Skip to content
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

Windows build #779

Merged
merged 67 commits into from
Nov 30, 2021
Merged

Windows build #779

merged 67 commits into from
Nov 30, 2021

Conversation

alexadhy
Copy link
Contributor

@alexadhy alexadhy commented May 27, 2021

Did you run make format && make check? yes

Fixes #778

Changes:

  • Various fixes to make skywire build on windows

TODO:

  • cmdutil function such as cmdutil.SignalContext should probably be fixed on dmsg repo
  • many things are redundant (see stdio package for example) in this draft PR, probably refactor it later once it is tested

How to test this PR:

NEEDS

Copy link
Member

@jdknives jdknives left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good start

@4rchim3d3s
Copy link
Contributor

For additional info on my comment on issue #778

Also tried to build this PR on windows and got this output:

image

@alexadhy
Copy link
Contributor Author

alexadhy commented May 31, 2021

Screen Shot 2021-05-31 at 21 50 54

@4rchim3d3s : the build instruction is here => skycoin/dmsg#83 (comment)

@4rchim3d3s
Copy link
Contributor

Thanks, I followed the instructions and instead of make I tried the go build...

And now got this:

build github.com/skycoin/skywire/cmd/skywire-visor: cannot load embed: malformed module path "embed": missing dot in first path element

@alexadhy
Copy link
Contributor Author

alexadhy commented Jun 5, 2021

@4rchim3d3s : I cannot reproduce.

Please follow the guide:

  • Clone and checkout that PR (https://github.com/skycoin/dmsg/pulls/83) in your local dir (i.e. C:\Users\user\Desktop\dmsg
  • Clone and checkout this PR to the adjacent dir C:\Users\user\Desktop\skywire
  • Run this command inside skywire dir go mod edit -replace github.com/skycoin/dmsg=../dmsg
  • Then sync the vendor directory go mod vendor -v
  • Then do go build -o .\skywire-visor.exe .\cmd\skywire-visor\

@4rchim3d3s
Copy link
Contributor

@alexadhy I retried it on desktop.

go mod vendor -v gave me:

$ go mod vendor -v
go: downloading github.com/songgao/water v0.0.0-20200317203138-2b4b6d7c09d8
go: downloading github.com/syndtr/gocapability v0.0.0-20200815063812-42c35b437635
go: extracting github.com/syndtr/gocapability v0.0.0-20200815063812-42c35b437635
go: extracting github.com/songgao/water v0.0.0-20200317203138-2b4b6d7c09d8
go: downloading github.com/creack/pty v1.1.11
go: extracting github.com/creack/pty v1.1.11
go: downloading github.com/mmcloughlin/avo v0.0.0-20200523190732-4439b6b2c061
go: extracting github.com/mmcloughlin/avo v0.0.0-20200523190732-4439b6b2c061
go: downloading golang.org/x/tools v0.1.0
go: extracting golang.org/x/tools v0.1.0
go: downloading golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1
go: downloading golang.org/x/mod v0.4.2
go: extracting golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1
go: extracting golang.org/x/mod v0.4.2
github.com/skycoin/skywire/cmd/apps/skychat imports
       embed: malformed module path "embed": missing dot in first path element
github.com/skycoin/skywire/cmd/apps/skychat imports
       io/fs: malformed module path "io/fs": missing dot in first path element

And then with go build...

$ go build -o ./skywire-visor.exe ./cmd/skywire-visor/
build github.com/skycoin/skywire/cmd/skywire-visor: cannot load embed: malformed module path "embed": missing dot in first path element

Guess I will just wait until it works as I don't know golang and how to import modules :)

If you wish to I can try again someday but I don't want to make trouble because of my impatience :)

@alexadhy
Copy link
Contributor Author

alexadhy commented Jun 5, 2021

@4rchim3d3s I think you need to upgrade your golang version, you need go version 1.16.x to make it work

@4rchim3d3s
Copy link
Contributor

@alexadhy I am sorry. That was the problem. Now skywire and vpn app build without problem

Comment on lines +9 to 14
func attachTTY(_ *exec.Cmd) {
// not used for Windows
}

return
func (c *Context) ignoreSignals() {
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What are these blank functions?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

placeholder function, to match the unix equivalent

@alexadhy alexadhy marked this pull request as ready for review August 27, 2021 01:15
@jdknives jdknives force-pushed the develop branch 2 times, most recently from 7d70c0b to f222d9d Compare October 23, 2021 12:00
@mrpalide
Copy link
Contributor

mrpalide commented Oct 26, 2021

I test it on test env. One point I see that was wrong for me:

  • Full Terminal of remote visor not available due this error:
[dmsgpty-ui] Error: exec: "C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\powershell.exe": executab
le file not found in $PATH                                                                          
[dmsgpty-ui] Status: Stopped!                                                                       

Full log: log.txt

@ersonp
Copy link
Contributor

ersonp commented Nov 16, 2021

Getting nil pointer dereference in vpn-client when trying to connect to 033d5c3463cf5cba2bcdb0ff84e755c4e5cf63797ec5c93c165f0c02078bafcfa4 with an active dmsg transport to the same visor on prod.
nilpointer.txt

@ersonp
Copy link
Contributor

ersonp commented Nov 16, 2021

Getting nil pointer dereference in vpn-client when trying to connect to 033d5c3463cf5cba2bcdb0ff84e755c4e5cf63797ec5c93c165f0c02078bafcfa4 with an active dmsg transport to the same visor on prod. nilpointer.txt

This was because wintun was not setup. Vpn is working as intended.

Makefile Outdated Show resolved Hide resolved
Makefile Outdated Show resolved Hide resolved
@ersonp
Copy link
Contributor

ersonp commented Nov 23, 2021

image

Everything is working fine now except the ping in the VPN. But I think this should be fixed in the VPN statistics PR. So this is good to go.

@jdknives jdknives merged commit b3ed859 into skycoin:develop Nov 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants