-
Notifications
You must be signed in to change notification settings - Fork 164
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
building compare sources #3218
building compare sources #3218
Conversation
Signed-off-by: yash-zededa <yash@zededa.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should separate that "local GOOS" evaluation into its own section of the Makefile, but that definitely is for later.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How are you manually testing this?
I converted it to shell syntax and tried it as
COMPARESOURCE=./build-tools/bin/compare-sbom-sources
COMPARE_SOURCE=./tools/compare-sbom-sources
GOOS=$(uname -s | tr '[A-Z]' '[a-z]') CGO_ENABLED=0 go build -o ${COMPARESOURCES} -C ${COMPARE_SOURCE}
and that fails with the same error as before:
go: cannot find main module, but found .git/config in /home/nordmark/fixes/eve
to create a module there, run:
go mod init
I observe that the existing case we have of using go build in the Makefile (for LINUXKIT) does a cd to the directory and passes in a -mod vendor argument. Do we need the same here?
It does? What version of go? go has supported |
My bad; COMPARESOURCES vs COMPARESOURCE in my manual setup as you can trivially see in my comment above ;-) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
modified the building command used for the compare sources utility.