g3/g3proxy/debian/rules
Zhang Jingqiang 145fe58db4
Some checks are pending
Linux-CI / Clippy (push) Waiting to run
Linux-CI / Build vendored (push) Waiting to run
Linux-CI / Build (push) Waiting to run
Linux-CI / Build with OpenSSL Async Job (push) Waiting to run
CodeCoverage / lib unit test (push) Waiting to run
CodeCoverage / g3mkcert test (push) Waiting to run
CodeCoverage / g3keymess test (push) Waiting to run
CodeCoverage / g3proxy test (push) Waiting to run
CodeCoverage / g3bench test (push) Waiting to run
CodeCoverage / g3statsd test (push) Waiting to run
CodeQL Advanced / Analyze (actions) (push) Waiting to run
CodeQL Advanced / Analyze (java-kotlin) (push) Waiting to run
CodeQL Advanced / Analyze (python) (push) Waiting to run
CodeQL Advanced / Analyze (rust) (push) Waiting to run
CrossCompiling / Build (push) Waiting to run
MacOS-CI / Build (push) Waiting to run
MacOS-CI / Build vendored (push) Waiting to run
StaticLinking / musl (push) Waiting to run
StaticLinking / msvc (push) Waiting to run
Windows-CI / Build (push) Waiting to run
Windows-CI / Build vendored (push) Waiting to run
fix deb build for tarball
2025-08-10 23:41:31 +08:00

34 lines
1.2 KiB
Makefile
Executable file

#!/usr/bin/make -f
PACKAGE_NAME := g3proxy
BUILD_PROFILE := release-lto
DEB_VERSION ?= $(shell dpkg-parsechangelog -SVersion)
LUA_FEATURE ?= $(shell scripts/package/detect_lua_feature.sh)
SSL_FEATURE ?= $(shell scripts/package/detect_openssl_feature.sh)
CARES_FEATURE ?= $(shell scripts/package/detect_c-ares_feature.sh)
%:
dh $@
override_dh_clean:
dh_clean -Xvendor
override_dh_auto_clean:
cargo clean --frozen --offline
override_dh_auto_build:
G3_PACKAGE_VERSION=$(DEB_VERSION) \
cargo build --frozen --profile $(BUILD_PROFILE) \
--no-default-features --features $(LUA_FEATURE),$(SSL_FEATURE),rustls-ring,quic,$(CARES_FEATURE) \
--package g3proxy --package g3proxy-ctl --package g3proxy-lua
cargo build --frozen --profile $(BUILD_PROFILE) --package g3proxy-ftp
override_dh_auto_install:
install -m 755 -D target/$(BUILD_PROFILE)/g3proxy debian/tmp/usr/bin/g3proxy
install -m 755 -D target/$(BUILD_PROFILE)/g3proxy-ctl debian/tmp/usr/bin/g3proxy-ctl
install -m 755 -D target/$(BUILD_PROFILE)/g3proxy-ftp debian/tmp/usr/bin/g3proxy-ftp
install -m 755 -D target/$(BUILD_PROFILE)/g3proxy-lua debian/tmp/usr/bin/g3proxy-lua
override_dh_installchangelogs:
dh_installchangelogs $(PACKAGE_NAME)/CHANGELOG