Just downloaded Xamarin/MonoDevelop in order to create a VB.Net based cross-platform application.
However Xamarin keeps returning a fatal error when attempting to compile a default template.
Steps:
File > New > Solution
VBNet > Gtk# 2.0 Project
Name solution
Click Play (Debug)
Results:
Error Fatal error BC2000 : compiler initialization failed unexpectedly: Project already has a reference to assembly System. A second reference to 'C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.0\System.dll' cannot be added. (Fatal error BC2000 ) (test111)
The above occurs if I click Play, Build, Run/Start Without Debugging, and Run/Start With Debugging.
The above does not occur with a C# Gtk# 2.0 project.
There is only one reference to System within the References folder in the Solution tree.
Any help would be greatly appreciated!
Thanks.
It seems that you can work around this bug if you install Mono and set it as your runtime (Project / Active Runtime menu), then it will build and run successfully.
Related
I have a vb.net WinForms project that was originally developed in VS2010, and I'm now trying to work on in VS2015. However, without changing anything, VS2015 will not compile it. It initially returned 2 errors:
Error BC2023 cannot specify both /win32icon and /win32resource
Error BC37216 Conflicting options specified: Win32 resource file; Win32 manifest
I could (temporarily) get rid of the first one by removing the icon specified in Project properties > Application > Icon. But I can't see how to eliminate the second. Googling the second error seems to return nothing meaningful at all.
The error message clearly comes from the VB compiler itself, but I'm not aware, using the IDE, how to "specify" either a manifest or a resource file. I presume the manifest accessed by clicking on Project properties > Application > View Windows Settings is the manifest it refers to. However even temporarily deleting this file had no effect.
Is there any way to resolve this build error?
I download the WinObjC files for GitHub and following all the steps. When I try to build the project, I have this problem (using Visual Studio Community 2015)
These are the two errors:
Severity Code Description Project File Line
Warning MSB3245 Could not resolve this reference. Could not locate the assembly "XamlCompositorCS". Check to make sure the assembly exists on disk. If this reference is required by your code, you may get compilation errors. WOCCatalog (WOCCatalog\WOCCatalog) C:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.Common.CurrentVersion.targets 1819
Severity Code Description Project File Line
Error LNK1181 cannot open input file 'OpenGLES.lib' WOCCatalog (WOCCatalog\WOCCatalog) D:\WinObjC-master\samples\WOCCatalog\WOCCatalog.vsimporter\WOCCatalog-WinStore10\LINK
1
How do I solve that?
Open included solution in WinObjC/build/build.sln
Select Build / Build Solution
You either need to download the prebuilt SDK (look under "Releases" in github) or, per the above comment:
Open included solution in WinObjC/build/build.sln
Select Build / Build Solution
1.Download the latest release version
2.open ...\WinObjC\build\build.sln
ps:If using virtual machine(Such as PD),make sure all files storing in Windows folder(such as c:\somewhere) instead of Mac folder (such as \\Mac\Home\Desktop)
3.vs 2015 update1 may alert installing wp8/8.1 tools.
4.Building your Solution( Select Build/Build Solution).
So, I've tired everything to get this to work after I've archived the application, but it keeps failing to open with the error message:
Dyld Error Message:
Library not loaded: /Library/Frameworks/RNCryptor.framework/Versions/A/RNCryptor
Referenced from: /Users/USER/Desktop/Project.app/Contents/MacOS/Project
Reason: image not found
I've added the Framework to the Copy Files Build Phase, I've changed the Runpath Search Paths to #loader_path/../Frameworks and the Framework Search Path to #executable_path/../Frameworks and it still doesn't want to open.
It opens fine in Xcode itself, but as soon as it's archived, it complains and doesn't run.
Any help is much appreciated :)
Ok, so I was able to fix it.
So the application was actually looking for the Framework in /Library/Frameworks/ on my Mac, I originally had thought it was looking for a reference in my actual .app file.
To fix it I opened up Terminal, cd' into the folder containing a copy of RNCryptor.framework and used this command
install_name_tool -id #executable_path/../Frameworks/RNCryptor.framework/RNCryptor RNCryptor.framework/RNCryptor
Then removed the old framework from the Xcode Project and re-inserted it using the Framework I just used from the directory I cd' into, and added the new Framework to the Copy Files Build Phase.
And voila, it worked :)
I have a simple Test project where a CodedUITestMethod is created. The test method simply clicks the Windows Start button in the taskbar. The method is generated by the Coded UI Test Builder tool from Visual Studio 2010 Ultimate.
Then, I go to project's Properties page, Code Contracts tab.
Check the Perform Runtime Contract Checking check box.
Change the value of Contract Reference Assembly combo box to "Build".
Now I hit F6 to build the project and receive the 2 errors:
Reading assembly 'Microsoft.VisualStudio.TestTools.UITesting' resulted in errors.
C:\Program Files (x86)\Microsoft\Contracts\MsBuild\v4.0\Microsoft.CodeContracts.targets (240,5): error MSB3073: The command ""C:\Program Files (x86)\Microsoft\Contracts\Bin\ ccrewrite" "#CodedUITest_Contract2ccrewrite.rsp"" exited with code -1.
I have uploaded my project zip file to my codeplex project
Could someone download the project and see if they can reproduce the compile error? Thanks.
The problem is solved. It appears that Microsoft.VisualStudio.TestTools.UITesting.dll references another dll that is not added into the project.
Add Microsoft.VisualStudio.TestTools.UITest.Playback.dll in the folder C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\PrivateAssemblies\ solves the issue.
Thanks to David K Allen who answered the question on the msdn forum.
I'm trying to include the Sparkle framework in my application. I don't really understand the specific steps necessary, and am now getting this error message:
Dyld Error Message:
Library not loaded: #loader_path/../Frameworks/Sparkle.framework/Versions/A/Sparkle
Referenced from: <..>/build/Debug/CoRay.app/Contents/MacOS/CoRay
Reason: image not found
So my question is two part:
1. How do I fix my problem?
2. What is the correct path for including a framework into a Cocoa/Obj-C application?
The error is saying that it cannot find a copy of the sparkle framework inside of your app bundle.
You need to add a new Copy Files build phase to your target. Set it to "Frameworks" to copy frameworks and drag a copy of Sparkle.framework from your Xcode project into the new Copy Files build phase that you have just created.
After adding Sparkle.framework in "Copy Files" phase, you have to remove it from "Link Binary With Libraries".
Cheers.