#!/usr/bin/make -f
# You must remove unused comment lines for the released package.
#export DH_VERBOSE = 1
#export DEB_BUILD_MAINT_OPTIONS = hardening=+all
#export DEB_CFLAGS_MAINT_APPEND  = -Wall -pedantic
#export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed

override_dh_auto_configure:
	# 从 nexus 下载并解压预编译包
	$(eval VERSION := $(shell debian/get-version.sh))
	curl -L "https://github.com/spacemit-com/llama.cpp/releases/download/spacemit-llama.cpp.riscv64.$(VERSION)/spacemit-llama.cpp.riscv64.$(VERSION).tar.gz" | tar -xz --strip-components=1
	dh_auto_configure

override_dh_shlibdeps:
	true

%:
	dh $@
