Page 1 of 1

Cobra.Compiler.dll

PostPosted: Sat Jul 28, 2012 1:33 am
by Charles
I just tweaked the install program so that Cobra.Core.Compiler.dll is now Cobra.Compiler.dll which is what I originally intended. FYI.

Re: Cobra.Compiler.dll

PostPosted: Thu Aug 09, 2012 11:46 am
by nerdzero
I just ran the latest installer in Ubuntu and the permissions on all the files under /usr/local/cobra/Cobra-svn-2771/ are 750 instead of 755 so a regular user doesn't have read or execute permissions. Did it always work this way? Maybe I just updated the permissions manually back when I first installed Cobra and I don't remember.

Re: Cobra.Compiler.dll

PostPosted: Thu Aug 09, 2012 6:07 pm
by Charles
I haven't recently changed anything with regards to permissions. So you're saying non-root users cannot access it?

I suppose we'll slip in a /bin/chmod call then.

Re: Cobra.Compiler.dll

PostPosted: Thu Aug 09, 2012 7:59 pm
by nerdzero
Yes, but someone else should confirm in case I have some weird rules in my fstab or something else I forgot about.

Re: Cobra.Compiler.dll

PostPosted: Tue Sep 04, 2012 8:01 pm
by nerdzero
My install must be hosed or I have some funky values in my path or something. Look what I get when I try to compile hello.cobra

Code: Select all
ramon@ragnarok:~$ cobra -ert:yes my_workspace/cobra/trunk/Source/hello.cobra
error: COBRA INTERNAL ERROR / UnauthorizedAccessException / Access to the path "/usr/local/cobra/Cobra-svn-2790/bin/Cobra.Core/CobraCore.cobra.cs" is denied.
Compilation failed - 1 error, 0 warnings
Not running due to errors above.

Am I interpreting that correctly? It's trying to write the C# files to the installation folder? Man, time for me to take a break and grab some beer.

Re: Cobra.Compiler.dll

PostPosted: Wed Sep 05, 2012 12:38 am
by Charles
That's a known bug.

On a somewhat related note, I was thinking of adding a -copy-core option like:

cobra -c -copy-core Program.cobra

Which could copy the Cobra.Core.dll (and debugging symbol file) next to cobra.exe to be next to Program.exe. This would provide some insulation from new installations of Cobra so that they don't complain that the installed Cobra.Core.dll is the wrong version number. You could recompile/rebuild, of course, but sometimes you don't want to.

And you could copy the file manually. This would just be a convenience.

Re: Cobra.Compiler.dll

PostPosted: Wed Sep 05, 2012 7:31 am
by nerdzero
-copy-core would actually be really useful for the MD addin. It would make it easier to squash this bug: https://github.com/ramon-rocha/MonoDeve ... g/issues/3

Re: Cobra.Compiler.dll

PostPosted: Wed Sep 05, 2012 1:50 pm
by Charles
I got this started with changeset:2791.

I haven't yet automated tests for it and I forgot to respect the -verbosity/-v flag. I used it in one of my projects and the files get copied, but I haven't really tested that this insulates the .exe from future Cobra.Core.dll versions.

Give it a whirl and let me know if you have any problems.

Re: Cobra.Compiler.dll

PostPosted: Wed Sep 05, 2012 1:55 pm
by nerdzero
Cool. I'll try it out soon.