Skip to content
This repository has been archived by the owner on Nov 8, 2022. It is now read-only.

"no buildable Go source files" when running "go build" #37

Open
ghost opened this issue Nov 29, 2016 · 1 comment
Open

"no buildable Go source files" when running "go build" #37

ghost opened this issue Nov 29, 2016 · 1 comment

Comments

@ghost
Copy link

ghost commented Nov 29, 2016

With the newest version of Snap (i.e. commit 668a381e3f603991e35639a02b0492a97cec152f) snap-plugin-utilities do not compile. Command "make" doesn't work, as the "go build" command returns error: can't load package: package github.com/intelsdi-x/snap-plugin-utilities: no buildable Go source files in /home/mkuculyma/snap/src/github.com/intelsdi-x/snap-plugin-utilities

How to reproduce:

@mkleina
Copy link

mkleina commented Feb 20, 2017

@mkuculyma Do you know if it worked in the past? I never tried running make on library itself, but I think that build scripts are independent from the snap repo and Makefile is just useless here at the moment, because there is no "main.go" available in the root folder. You need to include library inside your code first.

Right now, to build library, you need to change dir to certain subpackage and then run go build, for example:

$ cd ns
$ go build

or for running unit tests:

$ cd ns
$ go test -tags unit

I think it is good idea to modify build script to go through library subpackages and run go build (or go test for unit tests if available) in every subpackage directory.

cc @intelsdi-x/plugin-maintainers what do you think?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants