lshw
lshw copied to clipboard
sysfs: Fix basename() build with musl
musl provides only standard basename() which accepts non-const string. This fixes build error with musl C library:
| sysfs.cc: In function 'std::__cxx11::string sysfs_getbustype(const string&)':
| sysfs.cc:102:21: error: 'basename' was not declared in this scope
| "/devices/" + basename(path.c_str());
| ^~~~~~~~
Signed-off-by: Krzysztof Kozlowski [email protected]
@lyonel Can you take a look, please?
Fixed in d3c66a6b2a0799d6982f4dc77b291934fcba80c9?