# Error "build constraints exclude all Go files" while building beats from source for Solaris 11.3 x86

**URL:** <https://discuss.elastic.co/t/error-build-constraints-exclude-all-go-files-while-building-beats-from-source-for-solaris-11-3-x86/198482>\
**Category:** Beats\
**Created:** [September 6, 2019, 8:23pm UTC](https://discuss.elastic.co/t/error-build-constraints-exclude-all-go-files-while-building-beats-from-source-for-solaris-11-3-x86/198482 "2019-09-06T20:23:05Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ConnorRies](https://avatars.discourse-cdn.com/v4/letter/c/4da419/32.png) [@ConnorRies](https://discuss.elastic.co/u/ConnorRies)\
**Post date:** [September 6, 2019, 8:23pm UTC](https://discuss.elastic.co/t/error-build-constraints-exclude-all-go-files-while-building-beats-from-source-for-solaris-11-3-x86/198482/1 "2019-09-06T20:23:05Z")

</div>

My goal is to run Filebeat on a Solaris 11.3 system. Running uname -a shows me:

`SunOS solaris 5.11 11.3 i86pc i386 i86pc`

To build Filebeat, I also need to build go because the version found in package manager is too low of a version and won't work. I used a binary I obtained here ([http://www.bolthole.com/solaris/go-lang.html](http://www.bolthole.com/solaris/go-lang.html)) because it was said to work.

It successfully built go 1.12.9 (which is version needed to build filebeat) and it passed all it's tests. You can see my validation below.

```
test@solaris:~$ go version
go version go1.12.9 solaris/amd64
test@solaris:~$ go env
GOARCH="amd64"
GOBIN=""
GOCACHE="/export/home/test/.cache/go-build"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="solaris"
GOOS="solaris"
GOPATH="/export/home/test/go"
GOPROXY=""
GORACE=""
GOROOT="/export/home/test/goroot"
GOTMPDIR=""
GOTOOLDIR="/export/home/test/goroot/pkg/tool/solaris_amd64"
GCCGO="gccgo"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build919129086=/tmp/go-build -gno-record-gcc-switches"

```

When I run either "go build" or "gmake" on filebeat, I get the following error

`test@solaris:~/go/src/github.com/elastic/beats/filebeat$ gmake go build -i -ldflags "-X github.com/elastic/beats/libbeat/version.buildTime=2019-09-06T19:51:12Z -X github.com/elastic/beats/libbeat/version.commit=dfd8ed0d1fb7a0e5a86246a7dde574d1e9e1c11b" ../vendor/github.com/sirupsen/logrus/terminal_check_notappengine.go:9:2: build constraints exclude all Go files in /export/home/test/go/src/github.com/elastic/beats/vendor/github.com/sirupsen/logrus/terminal gmake: *** [filebeat] Error 1`

I have the following questions:

Is this an issue with the Makefile for beats, or could it have to do with the go compiler I created?

Is there an unofficial set of binaries for either beats or go that are available to help me?

---

<div class="post-metadata">

**Author:** ![ConnorRies](https://avatars.discourse-cdn.com/v4/letter/c/4da419/32.png) [@ConnorRies](https://discuss.elastic.co/u/ConnorRies)\
**Post date:** [September 10, 2019, 2:40pm UTC](https://discuss.elastic.co/t/error-build-constraints-exclude-all-go-files-while-building-beats-from-source-for-solaris-11-3-x86/198482/2 "2019-09-10T14:40:26Z")

</div>

If anybody sees this, just follow Andrews steps in the link below (Change the version information). Don't go down the path I was.

> [@Install Filebeat on Solaris 10](https://discuss.elastic.co/t/install-filebeat-on-solaris-10/106085):
>
> Hello, Has anyone been able to install filebeat on solaris10 and 11? Kindly share how this has been done please Thanks, Wako

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [October 8, 2019, 4:40pm UTC](https://discuss.elastic.co/t/error-build-constraints-exclude-all-go-files-while-building-beats-from-source-for-solaris-11-3-x86/198482/3 "2019-10-08T16:40:49Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
