#!/usr/bin/make -f
# See debhelper(7) (uncomment to enable)
# output every command that modifies files on the build system.
#DH_VERBOSE = 1

TARGET_DIR=/opt/pycharm-community-sloppy
TARGET_PKG_DIR=debian/pycharm-community-sloppy$(TARGET_DIR)

# main packaging script based on dh7 syntax
%:
	dh $@

override_dh_auto_install:
	cp -Lrp $$(/bin/ls | grep -v debian) $(TARGET_PKG_DIR)
	chmod a+rX -R $(TARGET_PKG_DIR)
	# Clean up a bit
	find $(TARGET_PKG_DIR)  -iname '*.dll' -o -iname '*.exe' -delete
	ln -s $(TARGET_DIR)/bin/pycharm.sh debian/pycharm-community-sloppy/usr/bin/pycharm
