diff options
Diffstat (limited to 'src/libutil/tarfile.cc')
-rw-r--r-- | src/libutil/tarfile.cc | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/libutil/tarfile.cc b/src/libutil/tarfile.cc new file mode 100644 index 000000000..ae6d512bd --- /dev/null +++ b/src/libutil/tarfile.cc @@ -0,0 +1,14 @@ +#include "rust-ffi.hh" + +extern "C" { + rust::CBox2<rust::Result<std::tuple<>>> unpack_tarfile(rust::Source source, rust::StringSlice dest_dir); +} + +namespace nix { + +void unpackTarfile(Source & source, Path destDir) +{ + unpack_tarfile(source, destDir).use()->unwrap(); +} + +} |