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 44 45 46 47 48 49 50 51 52 53 54
|
#!/usr/bin/make -f
# -*- makefile -*-
# Uncomment this to turn on verbose mode.
export DH_VERBOSE=1
include /usr/share/debhelper/dh-fortran/fortran-support.mk
export F77 FC
DO_FLANG:=false
ifeq ($(FC_DEFAULT),gfortran)
export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed
endif
PY3VERS=$(shell py3versions -vr)
%:
dh $@ --with fortran_mod
override_dh_auto_configure:
dh_auto_configure -Bbuild-main -- --disable-python --with-perl-dir=vendor --without-pcre
cp src/*.h build-main/src/
for v in $(PY3VERS); do \
dh_auto_configure -Bbuild-py$$v -- --disable-bindings --enable-python --with-python=/usr/bin/python$$v; \
cp src/*.h build-py$$v/src/; \
done
#trick from python-ldns
# magic is: PYTHON_VERSION=$$v dh_auto_configure -Bbuild-py$$v
# and later dh_auto_build -Bbuild-py$$v
override_dh_auto_build:
dh_auto_build -Bbuild-main
for v in $(PY3VERS); do \
dh_auto_build -Bbuild-py$$v; \
done
override_dh_auto_install:
dh_auto_install -Bbuild-main
for v in $(PY3VERS); do \
dh_auto_install -Bbuild-py$$v; \
done
dh_numpy3
for v in $(PY3VERS); do \
dh_install -ppython3-pygetdata usr/local/lib/python$$v/dist-packages/* /usr/lib/python3/dist-packages ; \
done
override_dh_auto_clean:
dh_auto_clean -Bbuild-main
for v in $(PY3VERS); do \
dh_auto_clean -Bbuild-py$$v; \
done
|