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
|
#!/usr/bin/make -f
export DH_VERBOSE=1
export PYBUILD_NAME=odoo-bin
export PYBUILD_DISABLE=test
ODOO_VERSION = 18
ODOO_DIR = debian/odoo-$(ODOO_VERSION)
%:
dh ${@} --with=python3 --buildsystem=pybuild
execute_before_dh_auto_build:
cp -r addons/* odoo/addons/
execute_after_dh_auto_install:
# remove extra licenses
find $(ODOO_DIR) -name LICENSE.md -exec rm "{}" \;
find $(ODOO_DIR) -name LICENSE.txt -exec rm "{}" \;
find $(ODOO_DIR) -name LICENSE -exec rm "{}" \;
# remove extra .gitignore
find $(ODOO_DIR) -name .gitignore -exec rm "{}" \;
# fix lintian warning about executable bit
find $(ODOO_DIR) -name "*.csv" -exec chmod 644 "{}" \;
find $(ODOO_DIR) -name "*.pot" -exec chmod 644 "{}" \;
find $(ODOO_DIR) -name "*.txt" -exec chmod 644 "{}" \;
find $(ODOO_DIR) -name "*.svg" -exec chmod 644 "{}" \;
find $(ODOO_DIR) -name "*.xml" -exec chmod 644 "{}" \;
find $(ODOO_DIR) -name "*.sh" -exec chmod 755 "{}" \;
override_dh_installsystemd:
dh_installsystemd --name odoo
override_dh_installinit:
dh_installinit --name odoo
execute_after_dh_auto_clean:
for d in addons/* ; do rm -fr odoo/$$d ; done
|