Lines Matching +full:stdout +full:- +full:path

1 # Recipe creation tool - append plugin
5 # SPDX-License-Identifier: GPL-2.0-only
38 …"""Find the recipe installing the specified target path, optionally limited to a select list of pa…
52 …e': '${sysconfdir}/hostname contents should be set by setting hostname:pn-base-files = "value" in …
61 for root, dirs, files in os.walk(os.path.join(pkgdata_dir, 'runtime')):
67 pkgdatafile = os.path.join(root, fn)
68 if pkglist and not os.path.exists(pkgdatafile):
83 … scriptval = line.split(': ', 1)[1].strip().encode('utf-8').decode('unicode_escape')
84 if 'update-alternatives --install %s ' % targetpath in scriptval:
111 logger.debug('source path: %s' % srcpath)
113 # Handle non-absolute path
114 … srcpath = os.path.abspath(os.path.join(rd.getVarFlag('do_install', 'dirs').split()[-1], srcpath))
117 workdirfile = os.path.relpath(srcpath, workdir)
121 # Source path specified in do_install might be a glob
122 if fnmatch.fnmatch(os.path.basename(localpath), workdirfile):
148 """Find the source path specified within a command"""
151 … helptext = subprocess.check_output('LC_ALL=C %s --help' % command, shell=True).decode('utf-8')
153 argopt_line_re = re.compile('^-([a-zA-Z0-9]), --[a-z-]+=')
169 for elem in cmdelements[1:-1]:
170 if elem.startswith('-'):
192 """Look at do_install for a command that installs/copies the specified target path"""
193 instpath = os.path.abspath(os.path.join(rd.getVar('D'), targetpath.lstrip('/')))
204 if (line.startswith('install ') and ' -m' in line) or line.startswith('cp '):
206 destpath = os.path.abspath(elements[-1])
209 elif destpath.rstrip('/') == os.path.dirname(instpath):
212 if fnmatch.fnmatchcase(os.path.basename(instpath), os.path.basename(srcpath)):
220 stdout = ''
222 (stdout, _) = bb.process.run('LANG=C file -b %s' % args.newfile, shell=True)
223 if 'cannot open' in stdout:
224 raise bb.process.ExecutionError(stdout)
227 stdout = ''
228 if stdout:
229 logger.debug('file command output: %s' % stdout.rstrip())
230 if ('executable' in stdout and not 'shell script' in stdout) or 'shared object' in stdout:
242 …logger.error('Unable to find any package producing path %s - this may be because the recipe packag…
263 …sibly provided by recipe %s but seemingly no other, selecting it by default - you should double ch…
279 …logger.warning('File %s is added by the patch %s - you may need to remove or replace this patch in…
289 # Auto-determine permissions
293 if os.path.abspath(os.path.dirname(args.targetpath)) in rd.expand(binpaths).split(':'):
306 …sibly provided by the following recipes:\n %s\nPlease select recipe with -r/--recipe' % (targetpa…
308 …install script of the following recipes:\n %s\nPlease select recipe with -r/--recipe' % (targetpa…
323 uri = uri[:-1]
331 src_destdir = os.path.dirname(srcfile)
334 srcdir = os.path.join(workdir, 'git')
335 if not bb.data.inherits_class('kernel-yocto', rd):
336 …logger.warning('S == STAGING_KERNEL_DIR and non-kernel-yocto, unable to determine path to srcdir, …
337 src_destdir = os.path.join(os.path.relpath(srcdir, workdir), src_destdir)
338 src_destdir = os.path.normpath(src_destdir)
340 source_uri = 'file://{0}'.format(os.path.basename(srcfile))
365 files = dict((f, os.path.join(args.destdir, os.path.basename(f)))
376 args.destfile = os.path.basename(args.file)
378 args.destfile = os.path.join(args.destfile, os.path.basename(args.file))
384 if not os.path.exists(os.path.join(layerpath, 'conf', 'layer.conf')):
385 raise argparse.ArgumentTypeError('{0!r} must be a path to a valid layer'.format(layerpath))
390 if not os.path.exists(filepath):
391 raise argparse.ArgumentTypeError('{0!r} must be an existing path'.format(filepath))
397 if os.path.isdir(filepath):
403 if os.path.isabs(destpath):
404 … raise argparse.ArgumentTypeError('{0!r} must be a relative path, not absolute'.format(destpath))
409 if not os.path.isabs(targetpath):
410 …raise argparse.ArgumentTypeError('{0!r} must be an absolute path, not relative'.format(targetpath))
416 …common.add_argument('-m', '--machine', help='Make bbappend changes specific to a machine only', me…
417 …common.add_argument('-w', '--wildcard-version', help='Use wildcard to make the bbappend apply to a…
423 …et system, determining the recipe that packages the file and the required path and name for the bb…
424 …parser_appendfile.add_argument('targetpath', help='Path to the file to be replaced (as it would ap…
426 …parser_appendfile.add_argument('-r', '--recipe', help='Override recipe to apply to (default is to …
430 …common_src.add_argument('-W', '--workdir', help='Unpack file into WORKDIR rather than S', dest='us…
437 …parser.add_argument('-D', '--destdir', help='Destination directory (relative to S or WORKDIR, defa…
446 …parser.add_argument('destfile', metavar='DESTFILE', nargs='?', help='Destination path (relative to…