Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ include $(addprefix ./vendor/github.com/openshift/build-machinery-go/make/, \
KUBE_GIT_MINOR_VERSION := "34"
KUBE_GIT_VERSION := "v1.34.1"

STRIP_DEBUGGING_SYMBOLS ?= true
ifeq ($(STRIP_DEBUGGING_SYMBOLS), true)
STRIP_DEBUGGING_SYMBOLS_FLAGS := -s -w
endif

GO_LD_EXTRAFLAGS :=-X k8s.io/component-base/version.gitMajor="1" \
-X k8s.io/component-base/version.gitMinor=$(KUBE_GIT_MINOR_VERSION) \
-X k8s.io/component-base/version.gitVersion=$(KUBE_GIT_VERSION) \
Expand All @@ -25,7 +30,8 @@ GO_LD_EXTRAFLAGS :=-X k8s.io/component-base/version.gitMajor="1" \
-X k8s.io/client-go/pkg/version.gitVersion="$(SOURCE_GIT_TAG)" \
-X k8s.io/client-go/pkg/version.gitCommit="$(SOURCE_GIT_COMMIT)" \
-X k8s.io/client-go/pkg/version.buildDate="$(shell date -u +'%Y-%m-%dT%H:%M:%SZ')" \
-X k8s.io/client-go/pkg/version.gitTreeState="$(SOURCE_GIT_TREE_STATE)"
-X k8s.io/client-go/pkg/version.gitTreeState="$(SOURCE_GIT_TREE_STATE)" \
$(STRIP_DEBUGGING_SYMBOLS_FLAGS)

GO_BUILD_PACKAGES :=$(strip \
./cmd/... \
Expand Down
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ and the [Kubernetes project](https://github.com/kubernetes/kubernetes).
To build oc invoke `make oc`. At any time you can invoke `make help` and you'll
get a list of all supported make sub-commands.

By default `make oc` builds the executable without debugging symbols. To include
debugging symbols, run `make STRIP_DEBUGGING_SYMBOLS=false oc`.

In order to build `oc`, you will need the GSSAPI sources. On a Fedora/CentOS/RHEL
workstation, install them with:

Expand Down