summaryrefslogtreecommitdiffstats
path: root/debian/rules
diff options
context:
space:
mode:
Diffstat (limited to 'debian/rules')
-rwxr-xr-xdebian/rules67
1 files changed, 67 insertions, 0 deletions
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 0000000..04d66fa
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,67 @@
+#!/usr/bin/make -f
+
+%:
+ dh ${@}
+
+upstream:
+ # main
+ wget --trust-server-names https://flexbox.reconfigure.me/download/electron/linux/x64/current
+
+ # changelog
+ lynx "https://www.flexoptix.net/en/flexoptix-app/?os=linux#flexapp__modal__changelog" -dump | \
+ sed '/^Changelog/,$$!d' | sed '/^Get the latest Version/,$$d' > debian/local/doc/changelog.txt
+
+ # udev
+ wget https://www.flexoptix.net/static/frontend/Flexoptix/default/en_US/files/99-tprogrammer.rules -O debian/local/udev/99-tprogrammer.rules
+
+execute_after_dh_auto_clean:
+ rm -rf squashfs-root
+ chmod 0644 FLEXOPTIX*.AppImage
+
+override_dh_auto_build:
+ chmod 0755 FLEXOPTIX*.AppImage
+ ./FLEXOPTIX*.AppImage --appimage-extract
+
+override_dh_auto_install:
+ mkdir -p debian/flexoptix-app/usr/lib
+ mv squashfs-root debian/flexoptix-app/usr/lib/flexoptix-app
+
+ rm -f debian/flexoptix-app/usr/lib/flexoptix-app/AppRun
+ rm -f debian/flexoptix-app/usr/lib/flexoptix-app/usr/lib/*.so.*
+ rmdir --ignore-fail-on-non-empty --parents debian/flexoptix-app/usr/lib/flexoptix-app/usr/lib
+
+ # bin
+ mkdir -p debian/flexoptix-app/usr
+ cp -a debian/local/bin debian/flexoptix-app/usr/bin
+
+ # udev
+ mkdir -p debian/flexoptix-app/lib/udev
+ cp -a debian/local/udev debian/flexoptix-app/lib/udev/rules.d
+
+ # desktop
+ mkdir -p debian/flexoptix-app/usr/share
+ cp -a debian/local/desktop debian/flexoptix-app/usr/share/applications
+
+ rm -f debian/flexoptix-app/usr/lib/flexoptix-app/flexoptix-app.desktop
+
+ # icon
+ mkdir -p debian/flexoptix-app/usr/share/icons/hicolor/256x256/apps
+ mv debian/flexoptix-app/usr/lib/flexoptix-app/usr/share/icons/hicolor/0x0/apps/flexoptix-app.png debian/flexoptix-app/usr/share/icons/hicolor/256x256/apps
+
+ rmdir --ignore-fail-on-non-empty --parents debian/flexoptix-app/usr/lib/flexoptix-app/usr/share/icons/hicolor/0x0/apps
+ rm -f debian/flexoptix-app/usr/lib/flexoptix-app/flexoptix-app.png
+
+override_dh_installchangelogs:
+ dh_installchangelogs debian/local/doc/changelog.txt
+
+override_dh_dwz:
+ # disabled
+
+override_dh_shlibdeps:
+ # disabled
+
+override_dh_strip:
+ # disabled
+
+override_dh_strip_nondeterminism:
+ # disabled