问题描述
我正在使用libsodium 0.10.0.0包来实现密码哈希。
在安装nuget软件包之后,将在package.config和项目文件中创建条目,如下所示:
<Reference Include="sodium,Version=0.10.0.0,Culture=neutral,processorArchitecture=MSIL">
<HintPath>..\packages\libsodium-net.0.10.0\lib\Net40\sodium.dll</HintPath>
</Reference>
构建后发生以下错误:
Severity Code Description Project File Line Suppression State
Error Could not copy the file "C:\Projects\GIT\EP2\ep2-api.git\Applications\AMS\packages\runtimes\win-x86\native\libsodium.dll" because it was not found. Ace.Ams.Web
为了解决上述错误,我在csproj文件中手动添加了以下配置设置,但仍然无法正常工作,然后我尝试将libsodium软件包路径中的“运行时”文件夹手动复制到上述路径中,在我的本地版本中工作,但我的竹子自动构建失败。
<ItemGroup>
<None Include="runtimes\win7-x86\native\**\*">
<PackagePath>runtimes/win7-x86/native/</PackagePath>
<Pack>true</Pack>
</None>
<None Include="runtimes\win7-x64\native\**\*">
<PackagePath>runtimes/win7-x64/native/</PackagePath>
<Pack>true</Pack>
</None>
</ItemGroup>
<ItemGroup Condition="'$(TargetFramework)' != 'net461'">
<None Include="runtimes\osx-x64\native\**\*">
<PackagePath>runtimes/osx-x64/native/</PackagePath>
<Pack>true</Pack>
</None>
<None Include="runtimes\linux-x64\native\**\*">
<PackagePath>runtimes/linux-x64/native/</PackagePath>
<Pack>true</Pack>
</None>
</ItemGroup>
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)