utils: Fix mkdir with PosixPath
PATCH 1/1 utils: Fix mkdir with PosixPath
Avoid:
Exception: AttributeError: 'PosixPath' object has no attribute 'find'
Signed-off-by Richard Purdie <[email protected]>
--- lib/bb/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
lib/bb/utils.py +1 -1
@@ -759,7 +759,7 @@ def mkdirhier(directory): """Create a directory like 'mkdir -p', but does not complain if directory already exists like os.makedirs """ - if directory.find('${') != -1: + if '${' in directory: bb.fatal("Directory name {} contains unexpanded bitbake variable. This may cause build failures and WORKDIR polution.".format(directory)) try: os.makedirs(directory)
Signature · 1 line
2.39.2