Beispiel #1
0
 def __init__(self):
     args = [
         ArgparseArgument('--build-tools-only', action='store_true',
             default=False, help=_('only fetch the build tools')),
         ArgparseArgument('--jobs', '-j', action='store', nargs='?', type=int,
                 const=NUMBER_OF_JOBS_IF_USED, default=NUMBER_OF_JOBS_IF_UNUSED, help=_('number of async jobs'))]
     Command.__init__(self, args)
Beispiel #2
0
 def __init__(self):
     args = [
         ArgparseArgument('--build-tools-only',
                          action='store_true',
                          default=False,
                          help=_('only bootstrap the build tools')),
         ArgparseArgument(
             '--use-binaries',
             action='store_true',
             default=False,
             help=_('use binaries from the repo before building')),
         ArgparseArgument(
             '--upload-binaries',
             action='store_true',
             default=False,
             help=
             _('after a recipe is built upload the corresponding binary package'
               )),
         ArgparseArgument(
             '--build-missing',
             action='store_true',
             default=False,
             help=_('in case a binary package is missing try to build it')),
     ]
     Command.__init__(self, args)
Beispiel #3
0
    def __init__(self, force=None, no_deps=None):
        args = [
            ArgparseArgument('recipe',
                             nargs='*',
                             help=_('name of the recipe to build')),
            ArgparseArgument('--missing-files',
                             action='store_true',
                             default=False,
                             help=_(
                                 'prints a list of files installed that are '
                                 'listed in the recipe'))
        ]
        if force is None:
            args.append(
                ArgparseArgument('--force',
                                 action='store_true',
                                 default=False,
                                 help=_(
                                     'force the build of the recipe ingoring '
                                     'its cached state')))
        if no_deps is None:
            args.append(
                ArgparseArgument('--no-deps',
                                 action='store_true',
                                 default=False,
                                 help=_('do not build dependencies')))

        self.force = force
        self.no_deps = no_deps
        Command.__init__(self, args)
Beispiel #4
0
 def __init__(self):
     Command.__init__(self,
         [ArgparseArgument('recipe', nargs=1,
                          help=_('name of the recipe to run checks on')),
         ArgparseArgument('--recursive', action='store_true', default=False,
                          help=_('Recursively run checks on dependencies')),
         ])
Beispiel #5
0
    def __init__(self):
        self.recipe_status = RecipeStatus('filepath')
        self.recipe_attributes = list(
            set(dir(self.recipe_status)) - set(dir(RecipeStatus)))
        arguments = [
            ArgparseArgument('recipe',
                             nargs='*',
                             help=_('Recipe to work with')),
            ArgparseArgument('--bootstrap',
                             action='store_true',
                             default=False,
                             help=_('Use bootstrap\'s cache file')),
            ArgparseArgument('--touch',
                             action='store_true',
                             default=False,
                             help=_('Touch recipe modifying its mtime')),
            ArgparseArgument('--reset',
                             action='store_true',
                             default=False,
                             help=_('Clean entirely the cache for the recipe'))
        ]

        for attr in self.recipe_attributes:
            attr_nargs = '*' if isinstance(getattr(self.recipe_status, attr),
                                           list) else None
            attr_type = type(getattr(self.recipe_status, attr))
            arg_type = str if attr_type == bool or attr_type == list else attr_type
            arguments.append(
                ArgparseArgument('--' + attr,
                                 nargs=attr_nargs,
                                 type=arg_type,
                                 help=_('Modify ' + attr)))
        Command.__init__(self, arguments)
Beispiel #6
0
 def __init__(self):
     args = [
         ArgparseArgument('--build-tools-only',
                          action='store_true',
                          default=False,
                          help=_('only bootstrap the build tools')),
         ArgparseArgument('--system-only',
                          action='store_true',
                          default=False,
                          help=('only boostrap the system')),
         ArgparseArgument('--offline',
                          action='store_true',
                          default=False,
                          help=_('Use only the source cache, no network')),
         ArgparseArgument(
             '-y',
             '--assume-yes',
             action='store_true',
             default=False,
             help=(
                 'Automatically say yes to prompts and run non-interactively'
             )),
         ArgparseArgument('--jobs',
                          '-j',
                          action='store',
                          type=int,
                          default=0,
                          help=_('How many recipes to build concurrently. '
                                 '0 = number of CPUs.'))
     ]
     Command.__init__(self, args)
Beispiel #7
0
 def __init__(self, args=[]):
     args.append(
         ArgparseArgument('--commit',
                          action='store',
                          type=str,
                          default='HEAD',
                          help=_('the commit to pick artifact from')))
     args.append(
         ArgparseArgument('--namespace',
                          action='store',
                          type=str,
                          default='gstreamer',
                          help=_('GitLab namespace to search from')))
     args.append(
         ArgparseArgument('--branch',
                          action='store',
                          type=str,
                          default='master',
                          help=_('Git branch to search from')))
     args.append(
         ArgparseArgument('--job-id',
                          action='store',
                          type=str,
                          default='master',
                          help=_('Artifact job id, this will skip'
                                 ' commit matching')))
     args.append(
         ArgparseArgument(
             '--skip-fetch',
             action='store_true',
             default=False,
             help=_(
                 'Skip fetching cached build, the '
                 'commit/url log will be updated if --job-id is present')))
     Command.__init__(self, args)
Beispiel #8
0
 def __init__(self):
     args = [
         ArgparseArgument('--build-tools-only', action='store_true',
             default=False, help=_('only bootstrap the build tools')),
         ArgparseArgument('--offline', action='store_true',
             default=False, help=_('Use only the source cache, no network'))]
     Command.__init__(self, args)
Beispiel #9
0
 def __init__(self):
     args = [
         ArgparseArgument('--build-tools-only',
                          action='store_true',
                          default=False,
                          help=argparse.SUPPRESS),
         ArgparseArgument(
             '--toolchains',
             action=StoreBool,
             default=True,
             nargs='?',
             choices=('yes', 'no'),
             help='Setup any toolchains needed by the target platform'),
         ArgparseArgument(
             '--build-tools',
             action=StoreBool,
             default=True,
             nargs='?',
             choices=('yes', 'no'),
             help='Compile the build tools needed while building'),
         ArgparseArgument('--jobs',
                          '-j',
                          action='store',
                          nargs='?',
                          type=int,
                          const=NUMBER_OF_JOBS_IF_USED,
                          default=NUMBER_OF_JOBS_IF_UNUSED,
                          help=_('number of async jobs'))
     ]
     Command.__init__(self, args)
Beispiel #10
0
 def __init__(self, args=[]):
     args.append(
         ArgparseArgument('--reset-rdeps',
                          action='store_true',
                          default=False,
                          help=_('reset the status of reverse '
                                 'dependencies too')))
     args.append(
         ArgparseArgument('--print-only',
                          action='store_true',
                          default=False,
                          help=_('print all source URLs to stdout')))
     args.append(
         ArgparseArgument(
             '--full-reset',
             action='store_true',
             default=False,
             help=_('reset to extract step if rebuild is needed')))
     args.append(
         ArgparseArgument('--jobs',
                          '-j',
                          action='store',
                          nargs='?',
                          type=int,
                          const=NUMBER_OF_JOBS_IF_USED,
                          default=NUMBER_OF_JOBS_IF_UNUSED,
                          help=_('number of async jobs')))
     Command.__init__(self, args)
Beispiel #11
0
 def __init__(self):
     Command.__init__(self, [
         ArgparseArgument(
             'package', nargs=1, help=_('name of the package to create')),
         ArgparseArgument('-o',
                          '--output-dir',
                          default='.',
                          help=_('Output directory for the tarball file')),
         ArgparseArgument(
             '-t',
             '--tarball',
             action='store_true',
             default=False,
             help=_('Creates a tarball instead of a native package')),
         ArgparseArgument(
             '-n',
             '--no-split',
             action='store_true',
             default=False,
             help=_(
                 '(only meaningfull when --tarball is set) Create one single '
                 'tarball with devel and runtime files')),
         ArgparseArgument('-f',
                          '--force',
                          action='store_true',
                          default=False,
                          help=_('Delete any existing package file')),
         ArgparseArgument('-d',
                          '--no-devel',
                          action='store_false',
                          default=True,
                          help=_('Do not create the development version '
                                 'of this package')),
         ArgparseArgument(
             '-s',
             '--skip-deps-build',
             action='store_true',
             default=False,
             help=_(
                 'Do not build the recipes needed to '
                 'create this package (conflicts with --only-build-deps)')),
         ArgparseArgument(
             '-b',
             '--only-build-deps',
             action='store_true',
             default=False,
             help=_(
                 'Only build the recipes needed to '
                 'create this package (conflicts with --skip-deps-build)')),
         ArgparseArgument('-k',
                          '--keep-temp',
                          action='store_true',
                          default=False,
                          help=_('Keep temporary files for debug')),
         ArgparseArgument('--offline',
                          action='store_true',
                          default=False,
                          help=_('Use only the source cache, no network')),
     ])
Beispiel #12
0
 def __init__(self):
     Command.__init__(self,
         [ArgparseArgument('-o', '--output_dir', default='.',
             help=_('output directory where .vsprops files will be saved')),
          ArgparseArgument('-p', '--prefix', default=DEFAULT_PREFIX_MACRO,
              help=_('name of the prefix environment variable '
                     '(eg:CERBERO_SDK_ROOT_X86)')),
         ])
Beispiel #13
0
 def __init__(self):
     Command.__init__(self,
         [ArgparseArgument('cmd', nargs='+',
                          help=_('command to run')),
          ArgparseArgument('-v', '--verbose',
                          action='store_true',
                          default=False,
                          help=_('verbose mode'))
         ])
Beispiel #14
0
 def __init__(self):
     Command.__init__(self,
         [ArgparseArgument('-o', '--output_dir', default='.',
             help=_('output directory where .xcconfig files will be saved')),
         ArgparseArgument('-f', '--filename', default=None,
             help=_('filename of the .xcconfig file')),
         ArgparseArgument('libraries', nargs='*',
             help=_('List of libraries to include')),
         ])
Beispiel #15
0
 def __init__(self):
     Command.__init__(self, [
         ArgparseArgument('recipe', nargs=1, help=_('name of the recipe')),
         ArgparseArgument('--all',
                          action='store_true',
                          default=False,
                          help=_('list all dependencies, including the '
                                 'build ones')),
     ])
Beispiel #16
0
 def __init__(self):
     args = [
             ArgparseArgument('recipes', nargs='*',
                 help=_('list of the recipes to fetch (fetch all if none '
                        'is passed)')),
             ArgparseArgument('--no-deps', action='store_true',
                 default=False, help=_('do not fetch dependencies')),
             ]
     Fetch.__init__(self, args)
Beispiel #17
0
 def __init__(self):
     args = [
         ArgparseArgument('package', nargs=1, help=_('package to fetch')),
         ArgparseArgument('--deps',
                          action='store_false',
                          default=True,
                          help=_('also fetch dependencies')),
     ]
     Fetch.__init__(self, args)
Beispiel #18
0
    def __init__(self, force=None, no_deps=None):
        args = [
            ArgparseArgument('name', nargs='*', help=_('name of the package')),
            ArgparseArgument('--output-dir',
                             type=str,
                             default='.',
                             help=_('directory of package stored'))
        ]

        Command.__init__(self, args)
Beispiel #19
0
 def __init__(self):
     Command.__init__(self, [
         ArgparseArgument('package', nargs=1,
                          help=_('name of the package')),
         ArgparseArgument(
             '-l',
             '--list-files',
             action='store_true',
             default=False,
             help=_('List all files installed by this package')),
     ])
Beispiel #20
0
 def __init__(self):
     args = [
         ArgparseArgument('--build-tools-only', action='store_true',
             default=False, help=_('only bootstrap the build tools')),
         ArgparseArgument('--system-only', action='store_true',
             default=False, help=('only boostrap the system')),
         ArgparseArgument('--offline', action='store_true',
             default=False, help=_('Use only the source cache, no network')),
         ArgparseArgument('-y', '--assume-yes', action='store_true',
             default=False, help=('Automatically say yes to prompts and run non-interactively'))]
     Command.__init__(self, args)
Beispiel #21
0
 def __init__(self):
     Command.__init__(self,
         [ArgparseArgument('name', nargs=1, default='sdk-shell',
                          help=_('name of the scrips')),
         ArgparseArgument('-o', '--output-dir', default='.',
                          help=_('output directory')),
         ArgparseArgument('-p', '--prefix',
                          help=_('prefix of the SDK')),
         ArgparseArgument('--cmd', default=self.DEFAULT_CMD,
                          help=_('command to run in the script')),
         ])
Beispiel #22
0
 def __init__(self):
     args = [
         ArgparseArgument('recipe',
             help=_('name of the recipe to tag or "all" to '
                     'tag all recipes')),
         ArgparseArgument('tagname',
             help=_('name of the tag to use')),
         ArgparseArgument('tagdescription',
             help=_('description of the tag')),
         ArgparseArgument('-f', '--force', action='store_true',
             default=False, help=_('Replace tag if existing'))]
     Command.__init__(self, args)
Beispiel #23
0
 def __init__(self):
     Command.__init__(self, [
         ArgparseArgument(
             '--force',
             action='store_true',
             default=False,
             help=_('force the deletion of everything without user '
                    'input')),
         ArgparseArgument('--build-tools',
                          action='store_true',
                          default=False,
                          help=_('wipe the build tools too'))
     ])
Beispiel #24
0
    def __init__(self, force=None, no_deps=None, deps_only=False):
            args = [
                ArgparseArgument('recipe', nargs='*',
                    help=_('name of the recipe to build')),
                ArgparseArgument('--missing-files', action='store_true',
                    default=False,
                    help=_('prints a list of files installed that are '
                           'listed in the recipe')),
                ArgparseArgument('--dry-run', action='store_true',
                    default=False,
                    help=_('only print commands instead of running them ')),
                ArgparseArgument('--offline', action='store_true',
                    default=False, help=_('Use only the source cache, no network')),
                ArgparseArgument('--jobs', '-j', action='store', type=int,
                    default=0, help=_('How many recipes to build concurrently. '
                        '0 = number of CPUs.')),
                ArgparseArgument('--build-tools', '-b', action='store_true',
                    default=False, help=_('Runs the build command for the build tools of this config.')),
                ]
            if force is None:
                args.append(
                    ArgparseArgument('--force', action='store_true',
                        default=False,
                        help=_('force the build of the recipe ingoring '
                                    'its cached state')))
            if no_deps is None:
                args.append(
                    ArgparseArgument('--no-deps', action='store_true',
                        default=False,
                        help=_('do not build dependencies')))

            self.force = force
            self.no_deps = no_deps
            self.deps_only = deps_only
            Command.__init__(self, args)
Beispiel #25
0
    def __init__(self, force=None, no_deps=None):
            args = [
                ArgparseArgument('recipe', nargs='*',
                    help=_('name of the recipe to build')),
                ArgparseArgument('--missing-files', action='store_true',
                    default=False,
                    help=_('prints a list of files installed that are '
                           'listed in the recipe')),
                ArgparseArgument('--dry-run', action='store_true',
                    default=False,
                    help=_('only print commands instead of running them ')),
                ArgparseArgument('--use-binaries', action='store_true',
                    default=False,
                    help=_('use binaries from the repo before building')),
                ArgparseArgument('--upload-binaries', action='store_true',
                    default=False,
                    help=_('after a recipe is built upload the corresponding binary package')),
                ArgparseArgument('--build-missing', action='store_true',
                    default=False,
                    help=_('in case a binary package is missing try to build it'))]
            if force is None:
                args.append(
                    ArgparseArgument('--force', action='store_true',
                        default=False,
                        help=_('force the build of the recipe ingoring '
                                    'its cached state')))
            if no_deps is None:
                args.append(
                    ArgparseArgument('--no-deps', action='store_true',
                        default=False,
                        help=_('do not build dependencies')))

            self.force = force
            self.no_deps = no_deps
            Command.__init__(self, args)
Beispiel #26
0
 def __init__(self, args=[]):
     args.append(
         ArgparseArgument('--commit',
                          action='store',
                          type=str,
                          default='HEAD',
                          help=_('the commit to pick artifact from')))
     args.append(
         ArgparseArgument('--branch',
                          action='store',
                          type=str,
                          default='master',
                          help=_('Git branch to search from')))
     Command.__init__(self, args)
    def __init__(self, force=None, no_deps=None):
        args = [
            ArgparseArgument('name', nargs='*', help=_('name of the package')),
            ArgparseArgument('--gen-file',
                             action='store_true',
                             default=False,
                             help=_('generate profile report (yaml)')),
            ArgparseArgument('--pkg-location',
                             type=str,
                             default='.',
                             help=_('directory of package stored'))
        ]

        Command.__init__(self, args)
Beispiel #28
0
 def __init__(self, args=[]):
     args.append(
         ArgparseArgument('--reset-rdeps',
                          action='store_true',
                          default=False,
                          help=_('reset the status of reverse '
                                 'dependencies too')))
     args.append(
         ArgparseArgument(
             '--full-reset',
             action='store_true',
             default=False,
             help=_('reset to extract step if rebuild is needed')))
     Command.__init__(self, args)
Beispiel #29
0
 def __init__(self):
     args = [
         ArgparseArgument(
             '--dry-run',
             action='store_true',
             default=False,
             help=_('only print commands instead of running them ')),
         ArgparseArgument(
             '-f',
             '--force',
             action='store_true',
             default=False,
             help=_('Force the creation of the binary package')),
     ]
     Command.__init__(self, args)
Beispiel #30
0
 def __init__(self, args=[]):
     args = [
         ArgparseArgument('bundlepackages',
                          nargs='+',
                          help=_('packages to bundle')),
         ArgparseArgument('--add-recipe',
                          action='append',
                          default=[],
                          help=_('additional recipes to bundle')),
         ArgparseArgument('--no-bootstrap',
                          action='store_true',
                          default=False,
                          help=_('Don\'t include bootstrep sources')),
     ]
     Command.__init__(self, args)