#!/usr/bin/make -f
export DEB_BUILD_MAINT_OPTIONS = hardening=+all

# upstream does not support ffmpeg7, disable it
export USE_FFMPEG=0
# export FFMPEG_ROOT=/usr

%:
	dh $@ -Spybuild --with python3

override_dh_auto_clean:
	-dh_auto_clean

execute_after_dh_clean:
	-$(RM) -vf src/torchaudio/version.py
	-$(RM) -r build/ torchaudio.egg-info/ .pybuild/

#execute_after_dh_install:
	#find . -name *_torchaudio.so* -exec \
	#	patchelf --replace-needed libtorchaudio.so lib/libtorchaudio.so {} \;

override_dh_python3:
	dh_python3 --no-ext-rename

override_dh_auto_test:
	-dh_auto_test
