diff options
author | Igor Drozdov <idrozdov@gitlab.com> | 2023-01-27 10:40:28 +0100 |
---|---|---|
committer | Igor Drozdov <idrozdov@gitlab.com> | 2023-01-27 17:42:59 +0100 |
commit | 892a770265bb9f4ecd8aed870228d238099a0afc (patch) | |
tree | 7b1400bedd154c23e0ebd96b3d1b19ee2955e95a | |
parent | 7750f56e0c42d619b2a6354d99601d4b4f311867 (diff) | |
download | gitlab-shell-892a770265bb9f4ecd8aed870228d238099a0afc.tar.gz |
Specify CGO_CFLAGS in Makefile to compile gssapi lib
-rw-r--r-- | Makefile | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -1,6 +1,7 @@ .PHONY: validate verify verify_ruby verify_golang test test_ruby test_golang coverage coverage_golang setup _script_install build compile check clean install FIPS_MODE ?= 0 +OS := $(shell uname) GO_SOURCES := $(shell find . -name '*.go') VERSION_STRING := $(shell git describe --match v* 2>/dev/null || awk '$$0="v"$$0' VERSION 2>/dev/null || echo unknown) BUILD_TIME := $(shell date -u +%Y%m%d.%H%M%S) @@ -14,6 +15,11 @@ ifeq (${FIPS_MODE}, 1) export CGO_ENABLED=1 endif +ifeq (${OS}, Darwin) # Mac OS + # To be able to compile gssapi library + export CGO_CFLAGS="-I/opt/homebrew/opt/heimdal/include" +endif + GOBUILD_FLAGS := -ldflags "-X main.Version=$(VERSION_STRING) -X main.BuildTime=$(BUILD_TIME)" -tags "$(BUILD_TAGS)" -mod=mod PREFIX ?= /usr/local |