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

x/sys/unix: Mkfifo is missing on Solaris #8609

Closed
tgulacsi opened this issue Aug 28, 2014 · 6 comments
Closed

x/sys/unix: Mkfifo is missing on Solaris #8609

tgulacsi opened this issue Aug 28, 2014 · 6 comments

Comments

@tgulacsi
Copy link
Contributor

What does 'go version' print?
go version go1.3.1 solaris/amd64

What steps reproduce the problem?

1. call syscall.Mkfifo("/tmp/a", 0640)

What happened?
undefined: syscall.Mkfifo

What should have happened instead?
syscall should provide the same Mkfifo implementation, as on Linux:
syscall.Mknod(path, mode|syscall.S_IFIFO, 0)

Please provide any additional information below.
On Solaris, mkfifo just calls mknod: http://www.unix.com/man-page/opensolaris/3c/mkfifo/
@bradfitz
Copy link
Contributor

Comment 1:

The syscall package is frozen. See
https://docs.google.com/a/golang.org/document/d/1QXzI9I1pOfZPujQzxhyRy6EeHYTQitKKjHfpq0zpxZs/edit

Status changed to WontFix.

@tgulacsi
Copy link
Contributor Author

Comment 2:

Ooops. I've read that document, but failed to sink in.
So, shall I report it against
https://code.google.com/p/go/source/browse/unix/syscall_solaris.go?repo=sys ?

@4ad
Copy link
Member

4ad commented Aug 28, 2014

Comment 3:

No, I edited it to refer to go.sys.

Labels changed: added release-none, repo-sys, os-solaris.

Owner changed to @4ad.

Status changed to Accepted.

@mikioh mikioh changed the title go.sys/unix: Mkfifo is missing on Solaris unix: Mkfifo is missing on Solaris Jan 7, 2015
@rsc rsc removed the os-solaris label Apr 10, 2015
@rsc rsc added this to the Unplanned milestone Apr 10, 2015
@rsc rsc changed the title unix: Mkfifo is missing on Solaris x/sys/unix: Mkfifo is missing on Solaris Apr 14, 2015
@rsc rsc modified the milestones: Unreleased, Unplanned Apr 14, 2015
@rsc rsc added OS-Solaris and removed repo-sys labels Apr 14, 2015
@binarycrusader
Copy link
Contributor

Actually, Solaris is missing a number of functions offered on Linux and others:

  • Mount
  • Getwd
  • Futimes
  • Acct
  • Creat
  • Dup2
  • Mkfifo
  • Pause
  • Times
  • Ustat
  • Utime

I'll submit a CL to add the missing functions where appropriate.

@gopherbot
Copy link

CL https://golang.org/cl/14420 mentions this issue.

4ad pushed a commit that referenced this issue Sep 9, 2015
In support of the changes required for #8609, it was suggested that
syscall.getwd() be updated to work on Solaris first since the runtime
uses it and today it's unimplemented.

Fixes #12507

Change-Id: Ifb58ac9db8540936d5685c2c58bdc465dbc836cb
Reviewed-on: https://go-review.googlesource.com/14420
Reviewed-by: Aram Hăvărneanu <aram@mgk.ro>
@binarycrusader
Copy link
Contributor

Fixed in this CL:

https://golang.org/cl/14643

@4ad 4ad closed this as completed Sep 17, 2015
@golang golang locked and limited conversation to collaborators Sep 22, 2016
stanhu pushed a commit to stanhu/go that referenced this issue Sep 14, 2020
Various syscalls offered by x/sys/unix on Linux are not available on
Solaris and should be, such as Mkfifo, Getwd(), Futimes() and others.
In particular, all of the *at() variants of existing functions were
added where appropriate.

Getgroups() was fixed to use the correct value for its sanity check on
the maximum number of groups.

Utimesnano() was updated to use the native Solaris utimensat function
for setting nanosecond-precision time.

Utimes() was updated to have the same error semantics and checking as
other platforms.

Getgroups(), anysocktoaddr(), and Recvmsg() were fixed to check the
return value before assuming syscall failure instead of relying solely
on errno being set.

mksyscall_solaris.pl needed some updates to better match the output of
the one found in syscall.

mkerrors.sh needed some updates to work out of the box on Solaris,
matching those recently done to the one in syscall.

The signatures (names) of some function parameters were changed to be
consistent with other platforms for the sake of documentation.

Fixes golang#8609

Change-Id: I9e4e2fee6d3ecfad9f4d845a5702ffde5166e804
Reviewed-on: https://go-review.googlesource.com/14643
Reviewed-by: Aram Hăvărneanu <aram@mgk.ro>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

6 participants