containerd / continuity

A transport-agnostic, filesystem metadata manifest system
https://containerd.io
Apache License 2.0
139 stars 67 forks source link

sysx/xattr: unify implementation #121

Closed kolyshkin closed 5 years ago

kolyshkin commented 6 years ago
  1. Remove sysx/xattr_darwin* as it's now available from x/sys/unix.

  2. Merge xattr_{freebsd,openbsd,solaris}.go into xattr_unsupported.go.

  3. Merge xattr_linux.go into xattr.go.

  4. Add proper build tags (linux and darwin are supported, others are not).

  5. Remove some unused files.

Let's save some bytes, shall we?

 sysx/asm.s                 |  10 ----------
 sysx/sys.go                |  37 -------------------------------------
 sysx/xattr.go              |  48 +++++++++++++++++++++++++++++++++++++++++++++---
 sysx/xattr_darwin.go       |  70 ----------------------------------------------------------------------
 sysx/xattr_darwin_386.go   | 111 ---------------------------------------------------------------------------------------------------------------
 sysx/xattr_darwin_amd64.go | 111 ---------------------------------------------------------------------------------------------------------------
 sysx/xattr_freebsd.go      |  12 ------------
 sysx/xattr_linux.go        |  44 --------------------------------------------
 sysx/xattr_openbsd.go      |   7 -------
 sysx/xattr_solaris.go      |  12 ------------
 sysx/xattr_unsupported.go  |   9 ++++++++-
 11 files changed, 53 insertions(+), 418 deletions(-)
kolyshkin commented 6 years ago

Unfortunately I can't test in on darwin (other than by looking at it).

kolyshkin commented 5 years ago

@dmcgowan @crosbymichael PTAL; despite the lengthy commits this stuff is trivial.

crosbymichael commented 5 years ago

LGTM