Folks- I'm not able to understand this:
My code layout:
src/rtagent/rtagent.go (has package main)
src/simplerouter/simplerouter.go (has package simplerouter)
src/p4/p4runtime.pb.go (has package p4)
rtagent.go:
package main
import (
"fmt"
"golang.org/x/net/context"
"google.golang.org/grpc"
"google.golang.org/grpc/reflection"
"io"
"log"
"net"
"p4"
"simplerouter"
p4_config "p4/config"
)
simplerouter.go
package simplerouter
import (
"encoding/binary"
"errors"
"fmt"
"p4"
"p4InfoUtils"
"strings"
"unsafe"
)
p4runtime.pb.go
package p4
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import google_protobuf "github.com/golang/protobuf/ptypes/any"
import google_rpc "google.golang.org/genproto/googleapis/rpc/status"
import p4_config "p4/config"
import p41 "p4"
import (
context "golang.org/x/net/context"
grpc "google.golang.org/grpc"
)
I get this error:
go install rtagent
import cycle not allowed
package rtagent
imports p4
imports p4
Could someone please help?