File debian.rules of Package joplin-desktop
#!/usr/bin/make -f
# -*- makefile -*-
# Sample debian/rules that uses debhelper.
# This file was originally written by Joey Hess and Craig Small.
# As a special exception, when this file is copied by dh-make into a
# dh-make output file, you may use that output file without restriction.
# This special exception was added by Craig Small in version 0.37 of dh-make.
# Uncomment this to turn on verbose mode.
export DH_VERBOSE=1
export DH_COMPAT=12
# export XDG_UTILS_INSTALL_MODE=system
%:
dh $@ --parallel
build:
dh_testdir
# Add here commands to compile the package.
chmod +x joplin-desktop.AppImage
./joplin-desktop.AppImage --appimage-extract
echo 12 > debian/compat
# touch build-stamp
clean:
dh_testdir
dh_testroot
# rm -f build-stamp
# Add here commands to clean up after the build process.
# make clean || true
# --- end custom part for cleaning up
# dh_clean
install:
dh_testdir
dh_testroot
# dh_clean -k
# dh_installdirs
# Add here commands to install the package
# The DESTDIR Has To Be Exactly /usr/src/packages/BUILD/debian/<nameOfPackage>
install -Dm755 joplin-desktop.AppImage /usr/src/packages/BUILD/debian/joplin-desktop/usr/bin/joplin-desktop
# icons
for x in $(ls squashfs-root/usr/share/icons/hicolor/); do install -Dm644 squashfs-root/usr/share/icons/hicolor/${x}/apps/@joplinapp-desktop.png /usr/src/packages/BUILD/debian/joplin-desktop/usr/share/icons/hicolor/${x}/apps/joplin.png; done
# .desktop
install -Dm644 joplin-desktop.desktop /usr/src/packages/BUILD/debian/joplin-desktop/usr/share/applications/joplin-desktop.desktop
# --- end custom part for installing
# Build architecture-independent files here.
binary-indep:
# We have nothing to do by default.
# Build architecture-dependent files here.
binary-arch: build install
dh_testdir
dh_testroot
# dh_installdebconf
# dh_installdocs
# dh_installexamples
# dh_installmenu
# dh_installlogrotate
# dh_installemacsen
# dh_installpam
# dh_installmime
# dh_installinit
# dh_installcron
# dh_installman
# dh_installinfo
# dh_undocumented
# dh_installchangelogs
dh_icons
dh_link
dh_strip
dh_compress
dh_fixperms
dh_makeshlibs
dh_installdeb
# dh_perl
dh_shlibdeps -- --ignore-missing-info
dh_gencontrol
dh_md5sums
dh_builddeb
binary: binary-arch
.PHONY: binary install