Problems trying to create a snap package for bioinformatics tools

Gordon Ball gordon at chronitis.net
Mon Oct 24 14:13:51 UTC 2016


Hello

I have been trying to create a snap package for the `cufflinks` [1]
biofinformatics tools. These are packaged for debian/ubuntu, but the
package is not built for xenial due to issues with boost 1.56-1.59. [2]

I tried building a snap package (see snapcraft.yaml below - just a
simple `stage-packages` build) on yakkety in order to bundle the
relevant dependencies and then install it on xenial, but I ran into the
following issues:


 * Trying to run any of the binaries gives the error

    failed to create user data directory. errmsg: Permission denied

   This is presumably related to #1592696, but in this case $HOME is on
an NFS mount under /mnt. Probably an uncommon case, but this probably
isn't the only such configuration.


 * The package contains multiple binaries, and the links in /snap/bin
are named, eg `cufflinks.cuffdiff`, which makes them incompatible with
existing scripts. Additionally, I can't declare `apps:` keys with
underscores in them, so some come out completely misnamed.

   Did I miss an option somewhere to better control command naming?


Snap packages are potentially quite useful for scientific tools with odd
sets of dependencies - where confinement is not an issue, but it
provides a much easier way to handle private library versions, etc.


Gordon




[1]: https://github.com/cole-trapnell-lab/cufflinks
[2]: https://launchpad.net/ubuntu/+source/cufflinks

----8<-snapcraft.yaml-8<----

name: cufflinks
version: 2.2.1
summary: Transcript assembler
description: |
    Cufflinks assembles transcripts, estimates their abundances, and
tests for
    differential expression and regulation in RNA-Seq samples. It
accepts aligned
    RNA-Seq reads and assembles the alignments into a parsimonious set of
    transcripts. Cufflinks then estimates the relative abundances of these
    transcripts based on how many reads support each one, taking into
account biases
    in library preparation protocols.
confinement: devmode

apps:
    compressgtf:
        command: compress_gtf
    cuffcompare:
        command: cuffcompare
    cuffdiff:
        command: cuffdiff
    cufflinks:
        command: cufflinks
    cuffmerge:
        command: cuffmerge
    cuffnorm:
        command: cuffnorm
    cuffquant:
        command: cuffquant
    gffread:
        command: gffread
    gtftosam:
        command: gtf_to_sam

parts:
    cufflinks:
        plugin: nil
        stage-packages:
            - cufflinks
            - libboost-serialization1.61.0
            - libboost-system1.61.0
            - libboost-thread1.61.0
            - libstdc++6
            - zlib1g
            - libc6
            - libgcc1

----8<----




More information about the Snapcraft mailing list