File: squashfs.py

package info (click to toggle)
python3-dmm 0.1.3-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 540 kB
  • sloc: python: 441; makefile: 2
file content (21 lines) | stat: -rw-r--r-- 541 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
"""
mksquashfs functions for for dmm.
"""

import os

def recipe_run(config, globalconf):
    """
    Perform actions for mksquashfs module
    """
    if config['action'] == 'make-squashfs':
        blocksize = config['blocksize']
        compress = config['compression-method']
        source = config['source']
        dest = config['destination']
        opts = config['options']
        os.system("mksquashfs %s %s -b %s -comp %s %s" % (source, dest, blocksize, compress, opts))

    #if config['action'] == unsquashfs:
        # todo