1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
|
#!/usr/bin/make -f
export DEB_BUILD_MAINT_OPTIONS = hardening=+all optimize=+lto
export PYBUILD_NAME=xgboost
#export CC=cuda-gcc
#export CXX=cuda-g++
%:
dh $@ -Scmake+ninja --with python3
#execute_before_dh_auto_configure:
# cp -rv debian/gputreeshap $(CURDIR)
# # patch the cmake file
# sed -e '20,$$d' -i gputreeshap/CMakeLists.txt
#override_dh_auto_configure:
# dh_auto_configure -- \
# -DUSE_CUDA=ON -DBUILD_WITH_CUDA_CUB=ON -DUSE_NCCL=ON
override_dh_auto_test:
# upstream ctest is not enabled because many tests require network
true
execute_after_dh_auto_configure:
dh_auto_configure -Spybuild -- -d python-package/ --system=pyproject
execute_after_dh_auto_build:
dh_auto_build -Spybuild -- -d python-package/ --system=pyproject
execute_after_dh_auto_install:
dh_auto_install -Spybuild -- -d python-package/ --system=pyproject
mkdir -p debian/tmp/usr/lib/python3/dist-packages/xgboost/lib/
ln -s ../../../../$(DEB_HOST_MULTIARCH)/libxgboost.so.0 \
debian/tmp/usr/lib/python3/dist-packages/xgboost/lib/libxgboost.so
execute_after_dh_auto_clean:
dh_auto_clean -Spybuild -- -d python-package/ --system=pyproject
-$(RM) xgboost
-$(RM) -rf lib
override_dh_python3:
dh_python3
-$(RM) debian/tmp/usr/lib/python3/dist-packages/xgboost/lib/libxgboost.cpy*
-$(RM) debian/python3-xgboost/usr/lib/python3/dist-packages/xgboost/lib/libxgboost.cpy*
|