Include heimdal into GDK
What does this merge request do and why?
This library is necessary to compile krb5
related changes in Gitlab Shell.
Related issue: gitlab-shell!682 (merged)
Related comment: gitlab-shell!682 (comment 1184275500)
How to set up and validate locally
- Install
brew
dependencies - Go to Gitlab Shell folder
cd gitlab-shell
- Checkout the
main
branchgit checkout main
- Run
make
For some users, installing heimdal
is enough, some users receive a compilation error as a result:
GOBIN="/Users/igordrozdov/Documents/Projects/gitlab-development-kit/gitlab-shell/bin" go install -ldflags "-X main.Version=v14.13.0-21-g27e5268 -X main.BuildTime=20221124.113306" -tags "tracer_static tracer_static_jaeger continuous_profiler_stackdriver" -mod=mod ./cmd/...
# github.com/openshift/gssapi
../../../../.asdf/installs/golang/1.18.7/packages/pkg/mod/github.com/openshift/gssapi@v0.0.0-20161010215902-5fb4217df13b/name.go:213:9: could not determine kind of name for C.wrap_gss_canonicalize_name
cgo:
clang errors for preamble:
../../../../.asdf/installs/golang/1.18.7/packages/pkg/mod/github.com/openshift/gssapi@v0.0.0-20161010215902-5fb4217df13b/name.go:90:2: error: unknown type name 'gss_const_name_t'
gss_const_name_t input_name,
^
1 error generated.
The error is fixed when CGO_CFLAGS
are specified:
CGO_CFLAGS="-I/opt/homebrew/opt/heimdal/include" make
CGO_CFLAGS
are related to OS here, so I wonder if they could be specified by GDK
Impacted categories
The following categories relate to this merge request:
-
gdk-reliability - e.g. When a GDK action fails to complete. -
gdk-usability - e.g. Improvements or suggestions around how the GDK functions. -
gdk-performance - e.g. When a GDK action is slow or times out.
Merge request checklist
-
This change is backward compatible. If not, please include steps to communicate to our users. -
Tests added for new functionality. If not, please raise an issue to follow-up. -
Documentation added/updated, if needed. -
Announcement added, if change is notable. -
gdk doctor
test added, if needed. -
Add the ~highlight
label if this MR should be included in theCHANGELOG.md
.