aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2019-05-23 15:31:24 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2019-05-23 15:31:24 +0200
commit9e8fe1472b50b5aae98ab7be7fe0444d251c8d7d (patch)
tree98698c515af37743859743da5019b185b90696fc
parent0ac8a59fd7f3c287dfd1c7dd3f811c19abb30255 (diff)
Switch to libarchive's bsdtar as default on Windows
Note that MSYS GNU tar can still be requested by passing --tar=tar.
-rw-r--r--bpkg/archive.cxx6
1 files changed, 2 insertions, 4 deletions
diff --git a/bpkg/archive.cxx b/bpkg/archive.cxx
index e8fb073..9d19dc5 100644
--- a/bpkg/archive.cxx
+++ b/bpkg/archive.cxx
@@ -4,8 +4,6 @@
#include <bpkg/archive.hxx>
-#include <cstring> // strlen()
-
#include <libbutl/process.mxx>
#include <bpkg/utility.hxx>
@@ -32,7 +30,7 @@ namespace bpkg
static inline bool
bsdtar (const char* p)
{
- const char* l (path::traits::find_leaf (p, strlen (p)));
+ const char* l (path::traits::find_leaf (p));
return l != nullptr && casecmp (l, "bsdtar", 6) == 0;
}
#endif
@@ -48,7 +46,7 @@ namespace bpkg
const char* tar (co.tar_specified ()
? co.tar ().string ().c_str ()
#ifdef _WIN32
- : "tar"
+ : "bsdtar"
#else
: "tar"
#endif