How to compress a directory to tar.xz with compression level and multithreading via CMake?

259 Views Asked by At

I am trying to compress a directory as .tar.xz under Windows with CMake tools.

I want the following three things with priority in that order of importance:

  1. The root directory of the tar should be different from my working directory.
  2. Use maximum number of threads to speed up the compression.
  3. Set the compression level.

I have found three ways to realize this:

The first point I can apparently implement with any of these approaches. Multithreading seems to be possible only with the CPack approach.

Unfortunately I did not manage to implement the approach via cpack.

Is there any way to fulfill all three points or at least the first two ones?

0

There are 0 best solutions below