#!/usr/bin/make -f

export CGO_ENABLED := 1
export COMMIT := c029d48d28322ad0369aabdcf8b656fd3195cd30
export FORCE_HOST_GO := true
export GOPROXY := direct
export KUBE_GIT_TREE_STATE := clean
export TARGET_ARCH := amd64
export TARGET_OS := linux
export VERSION := v1.33.13
export GOMODCACHE := $(PWD)/xxxdalecGomodsInternal


override_dh_auto_clean:
	@# Stop debhelper from doing "make clean"

override_dh_auto_install:
	@# Stop debhelper from doing "make install"
	@# Dalec will generate the right install commands

override_dh_auto_build:
	./debian/dalec/build.sh

.PHONY: fix_generators

fix_generators:
	./debian/dalec/fix_generators.sh

override_dh_auto_configure: fix_generators
	@# Stop debhelper from running auto configure, which should be part of the build steps

# dh_dwz is problematic for (some) go builds and causes the build to error out.
override_dh_dwz:
	@# https://salsa.debian.org/go-team/packages/dh-golang/-/commit/831f3a9dccc14f63f21d3dfac0c0d0e0c25b4084

override_dh_fixperms:
	dh_fixperms
	DESTDIR=debian/$(shell dh_listpackages) debian/dalec/fix_perms.sh









%:
	dh $@ -v
