pkg / term

Package term manages POSIX terminals.
BSD 2-Clause "Simplified" License
393 stars 64 forks source link

fix on FreeBSD #15

Closed swills closed 3 years ago

swills commented 8 years ago

Fixes build and test on FreeBSD 11 with Go 1.5 for me.

davecheney commented 8 years ago

Thanks for this. I have some comments and questions, please let me know when you're ready for the next round of review.

swills commented 8 years ago

Thanks for the quick reply!

davecheney commented 8 years ago

Is your freebsd system 32bit or 64 bit?

On Tue, 8 Dec 2015, 16:57 Steve Wills notifications@github.com wrote:

Thanks for the quick reply!

— Reply to this email directly or view it on GitHub https://github.com/pkg/term/pull/15#issuecomment-162777529.

swills commented 8 years ago

My system is 64 bit.

davecheney commented 8 years ago

Hmm. Those values are known to be correct for Darwin, so I think you'll have to copy the file and make a freebsd specific version.

On Tue, 8 Dec 2015, 17:09 Steve Wills notifications@github.com wrote:

My system is 64 bit.

— Reply to this email directly or view it on GitHub https://github.com/pkg/term/pull/15#issuecomment-162781117.

swills commented 8 years ago

Sorry, found two test failures locally that I will look into:

--- FAIL: TestTcflush (0.00s) termios_bsd_test.go:16: inappropriate ioctl for device --- FAIL: TestTcsendbreak (0.00s) termios_test.go:43: inappropriate ioctl for device

davecheney commented 8 years ago

Sure thing, no hurry.

On Tue, Dec 8, 2015 at 6:03 PM, Steve Wills notifications@github.com wrote:

Sorry, found two test failures locally that I will look into:

--- FAIL: TestTcflush (0.00s) termios_bsd_test.go:16: inappropriate ioctl for device --- FAIL: TestTcsendbreak (0.00s) termios_test.go:43: inappropriate ioctl for device

— Reply to this email directly or view it on GitHub https://github.com/pkg/term/pull/15#issuecomment-162796224.

swills commented 8 years ago

I'm thinking it may not be possible to make this work properly without access to the posix_openpt(4) syscall. :(

swills commented 8 years ago

ie, without patching the syscall package (https://golang.org/pkg/syscall/)

davecheney commented 8 years ago

Hmm, i'd like to fix this. There is also the golang.org/x/term repo that we're trying to get off the ground. I'm sure it's possible to make this work on freebsd. I'll rattle the cage on the x/term repository to see who is in charge there.

On Wed, Dec 9, 2015 at 12:42 AM, Steve Wills notifications@github.com wrote:

ie, without patching the syscall package (https://golang.org/pkg/syscall/)

— Reply to this email directly or view it on GitHub https://github.com/pkg/term/pull/15#issuecomment-162882720.

davecheney commented 3 years ago

I think this has been done