Closed lizthegrey closed 5 years ago
This is a side effect of https://github.com/golang/go/issues/26366, which apparently has workarounds?
Whoa! That was quick! :100:
We'll make this work with go mods, somehow, thanks for link
https://github.com/golang/go/issues/26366#issuecomment-424199216 is the further detail -- you have to put it in the same directory.
When the Go tool sees that one or more Go files use the special import "C", it will look for other non-Go files in the directory and compile them as part of the Go package.
...
Note that changes to files in other directories do not cause the package to be recompiled, so all non-Go source code for the package should be stored in the package directory, not in subdirectories.
I think I found another workaround by making kafka/librdkafka a sub-package that kafka/ imports, seems to make go mod vendor
include it.
I pushed the fix to confluent-kafka-go-dev master, please update/reset your vendor version and give it a go.
Trying :)
Awesome! Thank you 🥇
Description
I can get this to work in my local dev environment (stretch,
go version go1.12.7 linux/amd64
) but not inside a CircleCI golang docker container (stretch,circleci/golang:1.12.5
andcircleci/golang:1.12.7
andcircleci/golang:1.12.7-buster
).go mod vendor
doesn't actually pull the correct subdirs with the packaged.a
library files :(go.mod
contains:github.com/confluentinc/confluent-kafka-go-dev v0.0.0-20190703144503-78a815343f20
How to reproduce
Checklist
Please provide the following information:
LibraryVersion()
):ConfigMap{...}
"debug": ".."
as necessary)