Skip to content

Commit

Permalink
Merge pull request #7690 from fhs/plan9-pr
Browse files Browse the repository at this point in the history
fix build on Plan 9
  • Loading branch information
aschmahmann authored Sep 30, 2020
2 parents 1168639 + cac753b commit 8e6358a
Show file tree
Hide file tree
Showing 19 changed files with 44 additions and 16 deletions.
2 changes: 1 addition & 1 deletion cmd/ipfs/util/ulimit_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// +build !windows
// +build !windows,!plan9

package util

Expand Down
2 changes: 2 additions & 0 deletions cmd/ipfswatch/ipfswatch_test.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// +build !plan9

package main

import (
Expand Down
2 changes: 2 additions & 0 deletions cmd/ipfswatch/main.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// +build !plan9

package main

import (
Expand Down
3 changes: 1 addition & 2 deletions cmd/seccat/seccat.go
Original file line number Diff line number Diff line change
Expand Up @@ -243,8 +243,7 @@ func netcat(c io.ReadWriteCloser) {

// wait until we exit.
sigc := make(chan os.Signal, 1)
signal.Notify(sigc, syscall.SIGHUP, syscall.SIGINT,
syscall.SIGTERM, syscall.SIGQUIT)
signal.Notify(sigc, notifySignals...)

select {
case <-done:
Expand Down
8 changes: 8 additions & 0 deletions cmd/seccat/seccat_plan9.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
package main

import (
"os"
"syscall"
)

var notifySignals = []os.Signal{syscall.SIGHUP, syscall.SIGINT, syscall.SIGTERM}
10 changes: 10 additions & 0 deletions cmd/seccat/seccat_posix.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// +build !plan9

package main

import (
"os"
"syscall"
)

var notifySignals = []os.Signal{syscall.SIGHUP, syscall.SIGINT, syscall.SIGTERM, syscall.SIGQUIT}
2 changes: 1 addition & 1 deletion core/commands/add.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@ import (

"github.com/ipfs/go-ipfs/core/commands/cmdenv"

"github.com/cheggaaa/pb"
cmds "github.com/ipfs/go-ipfs-cmds"
files "github.com/ipfs/go-ipfs-files"
coreiface "github.com/ipfs/interface-go-ipfs-core"
"github.com/ipfs/interface-go-ipfs-core/options"
mh "github.com/multiformats/go-multihash"
pb "gopkg.in/cheggaaa/pb.v1"
)

// ErrDepthLimitExceeded indicates that the max depth has been exceeded.
Expand Down
2 changes: 1 addition & 1 deletion core/commands/dag/dag.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ import (
//gipselector "github.com/ipld/go-ipld-prime/traversal/selector"
//gipselectorbuilder "github.com/ipld/go-ipld-prime/traversal/selector/builder"

"gopkg.in/cheggaaa/pb.v1"
"github.com/cheggaaa/pb"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion core/commands/get.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ import (
"github.com/ipfs/go-ipfs/core/commands/cmdenv"
"github.com/ipfs/go-ipfs/core/commands/e"

"github.com/cheggaaa/pb"
cmds "github.com/ipfs/go-ipfs-cmds"
files "github.com/ipfs/go-ipfs-files"
"github.com/ipfs/interface-go-ipfs-core/path"
"github.com/whyrusleeping/tar-utils"
"gopkg.in/cheggaaa/pb.v1"
)

var ErrInvalidCompressionLevel = errors.New("compression level must be between 1 and 9")
Expand Down
2 changes: 1 addition & 1 deletion fuse/ipns/ipns_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// +build !nofuse,!openbsd,!netbsd
// +build !nofuse,!openbsd,!netbsd,!plan9

package ipns

Expand Down
2 changes: 1 addition & 1 deletion fuse/ipns/ipns_unix.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// +build !nofuse,!openbsd,!netbsd
// +build !nofuse,!openbsd,!netbsd,!plan9

// package fuse/ipns implements a fuse filesystem that interfaces
// with ipns, the naming system for ipfs.
Expand Down
2 changes: 1 addition & 1 deletion fuse/ipns/link_unix.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// +build !nofuse,!openbsd,!netbsd
// +build !nofuse,!openbsd,!netbsd,!plan9

package ipns

Expand Down
2 changes: 1 addition & 1 deletion fuse/mount/fuse.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// +build !nofuse,!windows,!openbsd,!netbsd
// +build !nofuse,!windows,!openbsd,!netbsd,!plan9

package mount

Expand Down
2 changes: 1 addition & 1 deletion fuse/node/mount_notsupp.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// +build !nofuse,openbsd !nofuse,netbsd
// +build !nofuse,openbsd !nofuse,netbsd !nofuse,plan9

package node

Expand Down
2 changes: 1 addition & 1 deletion fuse/node/mount_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// +build !openbsd,!nofuse,!netbsd
// +build !openbsd,!nofuse,!netbsd,!plan9

package node

Expand Down
2 changes: 1 addition & 1 deletion fuse/node/mount_unix.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// +build !windows,!openbsd,!netbsd,!nofuse
// +build !windows,!openbsd,!netbsd,!plan9,!nofuse

package node

Expand Down
2 changes: 1 addition & 1 deletion fuse/readonly/ipfs_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// +build !nofuse,!openbsd,!netbsd
// +build !nofuse,!openbsd,!netbsd,!plan9

package readonly

Expand Down
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ require (
github.com/AndreasBriese/bbloom v0.0.0-20190825152654-46b345b51c96 // indirect
github.com/blang/semver v3.5.1+incompatible
github.com/bren2010/proquint v0.0.0-20160323162903-38337c27106d
github.com/cheggaaa/pb v1.0.29
github.com/coreos/go-systemd/v22 v22.1.0
github.com/dustin/go-humanize v1.0.0
github.com/elgris/jsondiff v0.0.0-20160530203242-765b5c24c302
Expand All @@ -22,7 +23,7 @@ require (
github.com/ipfs/go-cidutil v0.0.2
github.com/ipfs/go-datastore v0.4.5
github.com/ipfs/go-detect-race v0.0.1
github.com/ipfs/go-ds-badger v0.2.4
github.com/ipfs/go-ds-badger v0.2.5
github.com/ipfs/go-ds-flatfs v0.4.5
github.com/ipfs/go-ds-leveldb v0.4.2
github.com/ipfs/go-ds-measure v0.1.0
Expand Down Expand Up @@ -107,7 +108,6 @@ require (
golang.org/x/lint v0.0.0-20200302205851-738671d3881b // indirect
golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1
golang.org/x/tools v0.0.0-20200522201501-cb1345f3a375 // indirect
gopkg.in/cheggaaa/pb.v1 v1.0.28
)

go 1.13
7 changes: 7 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,8 @@ github.com/cespare/xxhash/v2 v2.1.1 h1:6MnRN8NT7+YBpUIWxHtefFZOKTAPgGjpQSxqLNn0+
github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
github.com/cheekybits/genny v1.0.0 h1:uGGa4nei+j20rOSeDeP5Of12XVm7TGUd4dJA9RDitfE=
github.com/cheekybits/genny v1.0.0/go.mod h1:+tQajlRqAUrPI7DOSpB0XAqZYtQakVtB7wXkRAgjxjQ=
github.com/cheggaaa/pb v1.0.29 h1:FckUN5ngEk2LpvuG0fw1GEFx6LtyY2pWI/Z2QgCnEYo=
github.com/cheggaaa/pb v1.0.29/go.mod h1:W40334L7FMC5JKWldsTWbdGjLo0RxUKK73K+TuPxX30=
github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI=
github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI=
github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU=
Expand Down Expand Up @@ -119,6 +121,8 @@ github.com/dgraph-io/badger v1.6.0 h1:DshxFxZWXUcO0xX476VJC07Xsr6ZCBVRHKZ93Oh7Ev
github.com/dgraph-io/badger v1.6.0/go.mod h1:zwt7syl517jmP8s94KqSxTlM6IMsdhYy6psNgSztDR4=
github.com/dgraph-io/badger v1.6.1 h1:w9pSFNSdq/JPM1N12Fz/F/bzo993Is1W+Q7HjPzi7yg=
github.com/dgraph-io/badger v1.6.1/go.mod h1:FRmFw3uxvcpa8zG3Rxs0th+hCLIuaQg8HlNV5bjgnuU=
github.com/dgraph-io/badger v1.6.2 h1:mNw0qs90GVgGGWylh0umH5iag1j6n/PeJtNvL6KY/x8=
github.com/dgraph-io/badger v1.6.2/go.mod h1:JW2yswe3V058sS0kZ2h/AXeDSqFjxnZcRrVH//y2UQE=
github.com/dgraph-io/ristretto v0.0.2 h1:a5WaUrDa0qm0YrAAS1tUykT5El3kt62KNZZeMxQn3po=
github.com/dgraph-io/ristretto v0.0.2/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E=
github.com/dgryski/go-farm v0.0.0-20190104051053-3adb47b1fb0f/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw=
Expand Down Expand Up @@ -324,6 +328,8 @@ github.com/ipfs/go-ds-badger v0.2.3 h1:J27YvAcpuA5IvZUbeBxOcQgqnYHUPxoygc6Qxxkod
github.com/ipfs/go-ds-badger v0.2.3/go.mod h1:pEYw0rgg3FIrywKKnL+Snr+w/LjJZVMTBRn4FS6UHUk=
github.com/ipfs/go-ds-badger v0.2.4 h1:UPGB0y7luFHk+mY/tUZrif/272M8o+hFsW+avLUeWrM=
github.com/ipfs/go-ds-badger v0.2.4/go.mod h1:pEYw0rgg3FIrywKKnL+Snr+w/LjJZVMTBRn4FS6UHUk=
github.com/ipfs/go-ds-badger v0.2.5 h1:oKRP6xVdgunjioOvaW4Ue2N7rBI7h/sWNERHTguUmpE=
github.com/ipfs/go-ds-badger v0.2.5/go.mod h1:02rnztVKA4aZwDuaRPTf8mpqcKmXP7mLl6JPxd14JHA=
github.com/ipfs/go-ds-flatfs v0.4.5 h1:4QceuKEbH+HVZ2ZommstJMi3o3II+dWS3IhLaD7IGHs=
github.com/ipfs/go-ds-flatfs v0.4.5/go.mod h1:e4TesLyZoA8k1gV/yCuBTnt2PJtypn4XUlB5n8KQMZY=
github.com/ipfs/go-ds-leveldb v0.0.1/go.mod h1:feO8V3kubwsEF22n0YRQCffeb79OOYIykR4L04tMOYc=
Expand Down Expand Up @@ -910,6 +916,7 @@ github.com/mattn/go-isatty v0.0.8 h1:HLtExJ+uU2HOZ+wI0Tt5DtUDrx8yhUqDcp7fYERX4CE
github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s=
github.com/mattn/go-isatty v0.0.11 h1:FxPOTFNqGkuDUGi3H/qkUbQO4ZiBa2brKq5r0l8TGeM=
github.com/mattn/go-isatty v0.0.11/go.mod h1:PhnuNfih5lzO57/f3n+odYbM4JtupLOxQOAqxQCu2WE=
github.com/mattn/go-runewidth v0.0.4/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU=
github.com/mattn/go-runewidth v0.0.9 h1:Lm995f3rfxdpd6TSmuVCHVb/QhupuXlYr8sCI/QdE+0=
github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI=
github.com/matttproud/golang_protobuf_extensions v1.0.1 h1:4hp9jkHxhMHkqkrB3Ix0jegS5sx/RkqARlsWZ6pIwiU=
Expand Down

0 comments on commit 8e6358a

Please sign in to comment.