Cobra has an option to embed its run-time library in the resulting program so that there is no external Cobra.Lang.dll needed. However, there has been a bug for some time, described in ticket:3, in which the "Cobra.Lang" namespaces would collide from the embedded and non-embedded (or 2 DLLs with embedded). Now fixed.
To try this feature, say:
cobra -ert:yes MyProg.cobra
You'll notice that the .exe gets bigger:
>cobra hello
Hello, world.
>dir hello.exe
12/24/2008 03:09 AM 4,096 hello.exe
>cobra -ert:yes hello
Hello, world.
>dir hello.exe
12/24/2008 03:10 AM 135,168 hello.exe
>cobra -ert:yes -turbo hello
Hello, world.
>dir hello.exe
12/24/2008 03:12 AM 90,112 hello.exe
Try it out and let me know if you have any problems.
Forums
Embed run-time fully works now
4 posts
• Page 1 of 1
Re: Embed run-time fully works now
it seems the install-from-workspace script performs
which give
manual instructions work as expected
- Code: Select all
run: cobra.exe -ert:no hello
which give
- Code: Select all
c:\home\dev\src\dotnet\projects\cobralanguage\Source\hello.cobra(3): error: The name "CobraCore" does not exist in the current context
c:\home\dev\src\dotnet\projects\cobralanguage\Source\hello.cobra(4): error: The name "CobraImp" does not exist in the current context
c:\home\dev\src\dotnet\projects\cobralanguage\Source\hello.cobra(4): error: The name "CobraCore" does not exist in the current context
c:\home\dev\src\dotnet\projects\cobralanguage\Source\hello.cobra(1): error: The name "CobraImp" does not exist in the current context
Compilation failed - 4 errors, 0 warnings
Not running due to errors above.
** ERROR: Exit code from running Source Cobra: 1
manual instructions work as expected
- gauthier
- Posts: 116
Re: Embed run-time fully works now
"cobra -bsl" for building the standard library is somehow the culprit. After this command:
copy Cobra.Lang-previous.dll Cobra.Lang.dll
I was able to run "cobra -ert:no hello" again.
Will fix.
copy Cobra.Lang-previous.dll Cobra.Lang.dll
I was able to run "cobra -ert:no hello" again.
Will fix.
- Charles
- Posts: 2515
- Location: Los Angeles, CA
Re: Embed run-time fully works now
Fixed.
"cobra -bsl" was mangling the Cobra.Lang namespace name which caused all manner of havoc. Easy fix.
"cobra -bsl" was mangling the Cobra.Lang namespace name which caused all manner of havoc. Easy fix.
- Charles
- Posts: 2515
- Location: Los Angeles, CA
4 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 40 guests