summaryrefslogtreecommitdiffstats
path: root/bitbake
diff options
context:
space:
mode:
authorMichael Estner <michaelestner@web.de>2025-02-17 16:29:53 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2025-02-18 23:07:07 +0000
commit8f69906d5ed64f2fa94ebe2f7215e5087bf1e6df (patch)
treea2a7f9749d93734273de1a17fc64499355b91ce4 /bitbake
parentebdbd105efb68bd4c68b5701927e51a3a676859a (diff)
downloadpoky-8f69906d5ed64f2fa94ebe2f7215e5087bf1e6df.tar.gz
bitbake: utils: Clean up imports
* Remove double imports * Re-roder the imports as mentioned by pylint (Bitbake rev: 6de536bbaee8cf7664c5702a96a5ca18ad09fb9d) Signed-off-by: Michael Estner <michaelestner@web.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake')
-rw-r--r--bitbake/lib/bb/utils.py10
1 files changed, 3 insertions, 7 deletions
diff --git a/bitbake/lib/bb/utils.py b/bitbake/lib/bb/utils.py
index 135c71c007..3cb59d8078 100644
--- a/bitbake/lib/bb/utils.py
+++ b/bitbake/lib/bb/utils.py
@@ -11,11 +11,8 @@ import re, fcntl, os, string, stat, shutil, time
11import sys 11import sys
12import errno 12import errno
13import logging 13import logging
14import bb
15import bb.msg
16import locale 14import locale
17import multiprocessing 15import multiprocessing
18import fcntl
19import importlib 16import importlib
20import importlib.machinery 17import importlib.machinery
21import importlib.util 18import importlib.util
@@ -24,7 +21,6 @@ import subprocess
24import glob 21import glob
25import fnmatch 22import fnmatch
26import traceback 23import traceback
27import errno
28import signal 24import signal
29import collections 25import collections
30import copy 26import copy
@@ -36,6 +32,8 @@ import tempfile
36from subprocess import getstatusoutput 32from subprocess import getstatusoutput
37from contextlib import contextmanager 33from contextlib import contextmanager
38from ctypes import cdll 34from ctypes import cdll
35import bb
36import bb.msg
39 37
40logger = logging.getLogger("BitBake.Util") 38logger = logging.getLogger("BitBake.Util")
41python_extensions = importlib.machinery.all_suffixes() 39python_extensions = importlib.machinery.all_suffixes()
@@ -1457,8 +1455,6 @@ def edit_bblayers_conf(bblayers_conf, add, remove, edit_cb=None):
1457 but weren't (because they weren't in the list) 1455 but weren't (because they weren't in the list)
1458 """ 1456 """
1459 1457
1460 import fnmatch
1461
1462 def remove_trailing_sep(pth): 1458 def remove_trailing_sep(pth):
1463 if pth and pth[-1] == os.sep: 1459 if pth and pth[-1] == os.sep:
1464 pth = pth[:-1] 1460 pth = pth[:-1]
@@ -1649,7 +1645,7 @@ def ioprio_set(who, cls, value):
1649 bb.warn("Unable to set IO Prio for arch %s" % _unamearch) 1645 bb.warn("Unable to set IO Prio for arch %s" % _unamearch)
1650 1646
1651def set_process_name(name): 1647def set_process_name(name):
1652 from ctypes import cdll, byref, create_string_buffer 1648 from ctypes import byref, create_string_buffer
1653 # This is nice to have for debugging, not essential 1649 # This is nice to have for debugging, not essential
1654 try: 1650 try:
1655 libc = cdll.LoadLibrary('libc.so.6') 1651 libc = cdll.LoadLibrary('libc.so.6')