Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
name: xnviewmp
version: 0.91
summary: Photo Viewer, Image Resizer & Batch Converter
description: |
XnView MP is the enhanced version to XnView. It is a powerful
cross-platform media browser, viewer and converter.
And it's compatible with more than 500 formats.
grade: stable
#confinement: classic
confinement: devmode
apps:
xnviewmp:
command: xnviewmp
plugs:
- alsa
- cups-control
- desktop
- desktop-legacy
- home
- opengl
- pulseaudio
- removable-media
- unity7
- unity8
- wayland
- x11
parts:
xnviewmp:
plugin: dump
source: XnViewMP-091-linux-x64.tgz
#source: https://download.xnview.com/old_versions/XnViewMP-091-linux-x64.tgz
#source: https://download.xnview.com/XnViewMP-linux-x64.tgz
build-packages:
- chrpath
stage-packages:
- libasound2
- libatk1.0-0
- libbz2-1.0
- libcairo-gobject2
- libcairo2
- libcups2
- libdbus-1-3
- libdrm2
- libegl1-mesa
- libfontconfig1
- libfreetype6
- libgdk-pixbuf2.0-0
- libglib2.0-0
- libgstreamer-plugins-base1.0-0
- libgstreamer1.0-0
- libgtk-3-0
- libpango-1.0-0
- libpangocairo-1.0-0
- libpulse-mainloop-glib0
- libpulse0
- libsqlite3-0
- libx11-6
- libx11-xcb1
- libxcb1
- libxcomposite1
- libxext6
- libxfixes3
- libxi6
- libxrender1
- libxv1
- zlib1g
override-build: |
chrpath -d XnView lib/libQtAV.so.1 lib/libQtAVWidgets.so.1 lib/libqgsttools_p.so.1.0.0
sed -i 's,lib:\$dirname/Plugins"$,lib:$dirname/Plugins:$LD_LIBRARY_PATH:$dirname/../lib/x86_64-linux-gnu/pulseaudio",' xnview.sh
sed -i 's,\$dirname/lib"$,$dirname/lib:$QT_PLUGIN_PATH",' xnview.sh
install -d $SNAPCRAFT_PART_INSTALL/usr/bin
install -d $SNAPCRAFT_PART_INSTALL/usr/xnviewmp
cp -r * $SNAPCRAFT_PART_INSTALL/usr/xnviewmp
ln -s ../xnviewmp/xnview.sh $SNAPCRAFT_PART_INSTALL/usr/bin/xnviewmp
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.