bugst / go-serial

A cross-platform serial library for go-lang.
BSD 3-Clause "New" or "Revised" License
657 stars 199 forks source link

TCGETS2 is not available on all arches #112

Closed QuLogic closed 3 years ago

QuLogic commented 3 years ago

You can check the zerrors_linux_*.go files in https://github.com/golang/sys/tree/master/unix for TCGETS2, which is missing from a few of the files.

I also found this message from glibc about how it's architecture specific, though I did not find any specific docs about it.

Specifically, it is ppc64le that is failing when I build on Fedora.

cmaglie commented 3 years ago

That's a bummer, I guess we should split func (port *unixPort) setSpecialBaudrate(speed uint32) error by architecture and put an "unimplemented" placeholder for ppc64le (unless you have a different solution for that architecture).

QuLogic commented 3 years ago

Unfortunately, I do not have any other solution. It's a primary build target in Fedora, but I'm not even sure if anyone uses it with go-serial. If they do, hopefully they can come around with a better fix if one exists.