aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Archive.cpp8
-rw-r--r--src/GlobalLib.cpp2
2 files changed, 4 insertions, 6 deletions
diff --git a/src/Archive.cpp b/src/Archive.cpp
index 08106c3..6455df2 100644
--- a/src/Archive.cpp
+++ b/src/Archive.cpp
@@ -75,8 +75,6 @@ namespace sibs
flags |= ARCHIVE_EXTRACT_ACL;
flags |= ARCHIVE_EXTRACT_FFLAGS;
- FileString rootName;
-
a = archive_read_new();
archive_read_support_format_all(a);
archive_read_support_compression_all(a);
@@ -115,11 +113,11 @@ namespace sibs
}
const _tinydir_char_t* currentFile = archive_entry_pathname_native(entry);
- if(rootName.empty())
- rootName = currentFile;
FileString fullOutputPath = destination;
- fullOutputPath += (currentFile + (rootName.empty() ? 0 : rootName.size() - 1));
+ if(!fullOutputPath.empty() && fullOutputPath.back() != '/')
+ fullOutputPath += '/';
+ fullOutputPath += currentFile;
// TODO: Verify if this really works. Why doesn't libarchive have wide string version of archive_entry_set_pathname?
string fullOutputPathUtf8 = toUtf8(fullOutputPath);
archive_entry_set_pathname(entry, fullOutputPathUtf8.c_str());
diff --git a/src/GlobalLib.cpp b/src/GlobalLib.cpp
index 8346a83..9ad3d77 100644
--- a/src/GlobalLib.cpp
+++ b/src/GlobalLib.cpp
@@ -92,7 +92,7 @@ namespace sibs
{
if(globalLibLinkerFlagsResult.getErrorCode() == GlobalLib::DependencyError::DEPENDENCY_NOT_FOUND || globalLibLinkerFlagsResult.getErrorCode() == GlobalLib::DependencyError::DEPENDENCY_VERSION_NO_MATCH)
{
- printf("Dependency not found in global lib, trying to download from github\n");
+ printf("Dependency not found in global lib, trying to download from package repository\n");
// TODO: Download several dependencies at the same time by adding them to a list
// and then iterate them and download them all using several threads.
// All dependecies should be downloaded at the same time, this includes dependencies of dependencies.