native libraries check fix
This commit is contained in:
parent
459b3f09f9
commit
ab1aefd619
@ -41,15 +41,21 @@ public class LibrariesDownloadTaskFactory : INetworkTaskFactory
|
|||||||
bool nativeDirExists = Directory.Exists(_nativesDir);
|
bool nativeDirExists = Directory.Exists(_nativesDir);
|
||||||
|
|
||||||
foreach (var l in _libraries.Libs)
|
foreach (var l in _libraries.Libs)
|
||||||
|
{
|
||||||
|
if (l is Libraries.NativeLib native)
|
||||||
|
{
|
||||||
|
//TODO: replace with actual native libraries check
|
||||||
|
if(!nativeDirExists || checkHashes)
|
||||||
|
{
|
||||||
|
_libsToDownload.Add(l);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
{
|
{
|
||||||
if (!HashHelper.CheckFileSHA1(l.jarFilePath, l.artifact?.sha1, checkHashes))
|
if (!HashHelper.CheckFileSHA1(l.jarFilePath, l.artifact?.sha1, checkHashes))
|
||||||
{
|
{
|
||||||
_libsToDownload.Add(l);
|
_libsToDownload.Add(l);
|
||||||
}
|
}
|
||||||
//TODO: replace with actual native libraries check
|
|
||||||
else if (!nativeDirExists && l is Libraries.NativeLib)
|
|
||||||
{
|
|
||||||
_libsToDownload.Add(l);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user