alandefreitas / clang-unformat

A simple tool to infer a .clang-format file from existing code
Boost Software License 1.0
58 stars 13 forks source link

Problem with archive_read_next_header(): Pathname cannot be converted from UTF-8 to current locale. #21

Open abraxa opened 1 month ago

abraxa commented 1 month ago

During cmake execution, I run into this error:

-- Downloading... done -- extracting... src='/home/abraxa/repositories/sigrok/clang-unformat/build/_deps/boost-subbuild/boost-populate-prefix/src/boost-1.81.0.zip' dst='/home/abraxa/repositories/sigrok/clang-unformat/build/_deps/boost-src' -- extracting... [tar xfz] CMake Error: Problem with archive_read_next_header(): Pathname cannot be converted from UTF-8 to current locale. CMake Error: Problem extracting tar: /home/abraxa/repositories/sigrok/clang-unformat/build/_deps/boost-subbuild/boost-populate-prefix/src/boost-1.81.0.zip

As you can see, the extractor assumes the file to be a .tar.gz file, not .zip. Sure enough, changing https://github.com/alandefreitas/clang-unformat/blob/master/CMakeLists.txt#L25 to

URL https://github.com/boostorg/boost/releases/download/boost-${BOOST_VERSION}/boost-${BOOST_VERSION}.tar.gz

fixed it.