I'm publishing my net 5 app with:dotnet publish -r win-x64 -p:PublishSingleFile=true --self-contained truebut, as a result I have:Mode LastWriteTime Length Name---- ------------- ------ -----a---- 2/16/2021 10:20 PM 747896 clrcompression.dll-a---- 2/16/2021 10:20 PM 1322360 clrjit.dll-a---- 2/16/2021 10:20 PM 5153144 coreclr.dll-a---- 3/15/2021 11:48 AM 53841260 fff.exe-a---- 3/15/2021 11:48 AM 11300 fff.pdb-a---- 3/15/2021 11:48 AM 537 fff.xml-a---- 2/16/2021 10:20 PM 1056640 mscordaccore.dlldeploying just fff.exe does not work. Have to deploy dll's too. Why?Source code for reference can be found here: Fast Find in Files 解决方案 Use this command insteaddotnet publish -r win-x64 /p:PublishSingleFile=true /p:IncludeNativeLibrariesInSingleFile=true /p:IncludeNativeLibrariesForSelfExtract=true -c releaseDocumentation 这篇关于NET5.0 PublishSingleFile 发布多个文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!
09-09 04:11