Compiling issues with mono and multi-threaded application

别说谁变了你拦得住时间么 提交于 2019-12-11 16:48:10

问题


I am trying to compile a C# app that uses the TPL for linux, using mono. The app was built on windows using VS. i am trying to compile the cs classes via gmcs. However i am getting this error:

gmcs Main.cs FileUtil.cs BH.cs 

BH.cs(6,24): error CS0234: The type or namespace name `Tasks' does not exist in the
namespace `System.Threading'. Are you missing an assembly reference?
Main.cs(17,24): error CS0234: The type or namespace name `Tasks' does not exist in the
namespace `System.Threading'. Are you missing an assembly reference?
BH.cs(6,24): error CS0234: The type or namespace name `Tasks' does not exist in the
namespace `System.Threading'. Are you missing an assembly reference?
Compilation failed: 3 error(s), 0 warnings

any suggestions?


回答1:


gmcs targets 2.0 corlib. Try to use mcs instead.



来源:https://stackoverflow.com/questions/20287254/compiling-issues-with-mono-and-multi-threaded-application

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!