MonoDevelop reports Build Successful but there is no exe file
In MonoDevelop, I create a new solution (C# console application). It gives me a simple hello world program. I press the run button. I see "Build Successful" The terminal comes up and says:
Cannot open assembly '/home/beauxq/MonoProjects/cstest/cstest/bin/Debug/cstest.exe': No such file or directory.
Press any key to continue...
I look in that bin/Debug directory and it is empty.
The build output:
Building: cstest (Debug|x86)
Build started 7/28/2016 9:29:40 AM.
__________________________________________________
Project "/home/beauxq/MonoProjects/cstest/cstest/cstest.csproj" (Build target(s)):
Target PrepareForBuild:
Configuration: Debug Platform: x86
Target GenerateSatelliteAssemblies:
No input files were specified for target GenerateSatelliteAssemblies, skipping.
Target GenerateTargetFrameworkMonikerAttribute:
Skipping target "GenerateTargetFrameworkMonikerAttribute" because its outputs are up-to-date.
Done building project "/home/beauxq/MonoProjects/cstest/cstest/cstest.csproj".-- FAILED
Build FAILED.
0 Warning(s)
---------------------- Done ----------------------
Build successful.
The same happens when I select "Build" from the menu. "Build Successful" but the directory is empty.
Solution 1:
I just stumbled upon this too. Clean, Build, Rebuild all report successful, but nothing really happens.
To fix this, you must install package mono-devel
, which is also in the recommends tag
Recommends: libglade2.0-cil-dev, libgtk2.0-cil-dev, mono-devel
Maybe you installed monodevelop with option --no-install-recommends
, or have APT::Install-Recommends "false";
somewhere in your apt.conf(.d), as I do.
See also How to not install recommended and suggested packages? about recommended packages and no-install-recommends
.
Solution 2:
I have encountered the same issue. In my case, all required packages were installed, so I had to look further.
All I had to do is perform a "Clean All" before building / debugging the project.
It was probably due to the MonoDevelop project which was started on a different machine with quite an older version of MonoDevelop.
Hope this might help someone in the same situation.