cyoung / stratux

Aviation weather and traffic receiver based on RTL-SDR.
BSD 3-Clause "New" or "Revised" License
1.05k stars 360 forks source link

Can't build #7

Closed felixk closed 9 years ago

felixk commented 9 years ago

I'm having trouble building the go code...I get the following on raspian:

GOARCH=6 go-linux-arm build gen_gdl90.go traffic.go ry835ai.go /bin/sh: 1: go-linux-arm: not found Makefile:2: recipe for target 'all' failed make: *\ [all] Error 127

If i just run go build gen_gdl90.go traffic.go and ry835ai.go i get:

github.com/tarm/serial

/usr/lib/go/src/pkg/github.com/tarm/serial/serial_linux.go:114: undefined: syscall.TCIOFLUSH

github.com/kidoman/embd

/usr/lib/go/src/pkg/github.com/kidoman/embd/detect.go:58: undefined: strings.TrimSuffix

Any ideas?

Thanks! Felix

jpoirier commented 9 years ago

You either need to use the full path to the compiler (go-linux-arm) or add the compiler's bin folder to PATH.

GOARCH would need to be one of the following: 386|amd64|arm, but you don't need to set any build variables if you're building for the host system, i.e. targeting the system the compiler is running on.

Check where the other go compiler is $ which go

Check the compiler versions $ go version $ go-linux-arm version

You want to use whichever is the latest, which is probably go-linux-arm .

As far as the build errors for the "go" version of the compiler, I'm guessing it's a very old version (maybe 1.0.2) and not compatible with newer code in the serial or embd packages.

felixk commented 9 years ago

Thanks! I built GO from source and installed version 1.4.2 and it built fine. Thanks for this great project. I can't wait to try it in the air.

cyoung commented 9 years ago

felixk, are you testing AHRS and/or GPS?

felixk commented 9 years ago

Not yet, i don't have the mpu6050 or the ry835ai. I was thinking about buying them. Why do you need some help testing?

cyoung commented 9 years ago

The MPU6050 is part of the RY835AI, along with the BMP180.

Just asking since you were compiling from source. You won't gain any extra features by compiling the current code over the v0.1r2 image, the only things in there since then are GPS/AHRS.

felixk commented 9 years ago

Got it. Thanks. I definitely want the AHRS and GPS capability. I'm going to pick up the RY835AI and give it a try.