Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could not load file or assembly in latest User Kit #47

Closed
ghost opened this issue Jan 4, 2015 · 5 comments
Closed

Could not load file or assembly in latest User Kit #47

ghost opened this issue Jan 4, 2015 · 5 comments

Comments

@ghost
Copy link

ghost commented Jan 4, 2015

i have an assembly reference (Orvid.Graphics) which depends on System.Drawing. Unfortunately the Cosmos compiler doesn't like this and refuses to add it as a reference. Is there any way around this?
(It is being used for System.Drawing.Bitmap, System.Drawing.Color, System.Drawing.Imaging.BitmapData, System.Drawing.Imaging.ImageLockMode, System.Drawing.Imaging.PixelFormat, and System.Drawing.Rectangle)

@czhower
Copy link
Member

czhower commented Jan 4, 2015

On 1/4/2015 1:11 PM, Hetal728 wrote:

i have an assembly reference (Orvid.Graphics) which depends on
System.Drawing. Unfortunately the Cosmos compiler doesn't like this and
refuses to add it as a reference. Is there any way around this?

It is much more helpful if you provide us with details as to "what it
doesn't like". I assure you that the compiler is very logical and not
emotional at all and does not have preferences as to what other
assemblies it likes or dislikes.

@ghost
Copy link
Author

ghost commented Jan 4, 2015

Error 2 Could not load file or assembly 'Orvid.Graphics, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.
at System.RuntimeMethodHandle.GetMethodBody(IRuntimeMethodInfo method, RuntimeType declaringType)
at System.Reflection.RuntimeMethodInfo.GetMethodBody()
at Cosmos.IL2CPU.ILReader.ProcessMethod(MethodBase aMethod) in g:\IL2CPU\source2\IL2CPU\Cosmos.IL2CPU\ILReader.cs:line 42
at Cosmos.IL2CPU.ILScanner.ScanMethod(MethodBase aMethod, Boolean aIsPlug, String sourceItem) in g:\IL2CPU\source2\IL2CPU\Cosmos.IL2CPU\ILScanner.cs:line 561
at Cosmos.IL2CPU.ILScanner.ScanQueue() in g:\IL2CPU\source2\IL2CPU\Cosmos.IL2CPU\ILScanner.cs:line 686
at Cosmos.IL2CPU.ILScanner.Execute(MethodBase aStartMethod) in g:\IL2CPU\source2\IL2CPU\Cosmos.IL2CPU\ILScanner.cs:line 277
at Cosmos.Build.MSBuild.IL2CPUTask.Execute() in g:\IL2CPU\source2\Build\Cosmos.Build.MSBuild\IL2CPUTask.cs:line 239 C:\Program Files (x86)\MSBuild\Cosmos\Cosmos.targets 31 6 GalaxyBoot

I suspected the cause of this error to be System.Drawing, but after further investigation, I appear to be incorrect. I apologize for assuming the cause too quickly.

@ghost ghost changed the title System.Drawing Could not load file or assembly in latest User Kit Jan 4, 2015
@mterwoord
Copy link
Contributor

Is Orvid.Graphics set to copylocal?

@ghost
Copy link
Author

ghost commented Jan 6, 2015

Yes

@mterwoord
Copy link
Contributor

Cosmos projects consist of 2 project: the .csproj and the .Cosmos
Do you have both in the same directory, and both set to build to the same directory?

valentinbreiz added a commit that referenced this issue Aug 5, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants