I Want to Try This .... ... very impressive
I Want to Try This .... ... very impressive
code your Idea
Hey
I put an example up here: http://j-software.dk/crink.zip
The code is based around this example http://in4k.untergrund.net/index.php?title=About_Flow2
You can try and look around in it, and see what I had to hack in order of making it work
Peregrinus, expectavi pedes meos in cymbalis
Nullus norvegicorum sole urinat
Thanks, your example works great! I can experiment from this and see how far I can get with the ZGameEditor source.
Regarding Crinkler compression, I did some testing based on your example JDarling:
The problem is that when using Crinkler you cannot seem to be able to use functions from external libraries using the standard "external dllname" style syntax that Delphi and FPC uses.
Instead you need to link to the name-mangled name in a lib-file like this:
If your source code has many imports (like ZGameEditor does) then it will involve lots of work to IFDEF your code so that it will both compile in Delphi and also in Fpc using Crinkler as a linker. And you need to find the name-mangled name of all the functions you use from OpenGL and WinAPI.Code://Link to import library User32.lib procedure ExitProcess(uExitCode:UINT);stdcall; external name '_ExitProcess@4';
Delphi can compile to obj-files but they are in OMF-format while Crinkler requires COFF. I found a very powerful tool called ObjConv that can convert OMF to COFF format and tried that, but it fails to convert the Delphi files because they have "communal sections".
Another thing I tried to follow was to create import libraries where the names are not mangled so that they will be easier to import from Freepascal. A tool called ImpLib creates LIB-files but I could not make it generate the output I want.
So I'm not sure what to try next. One way would be to load libraries at runtime instead using LoadLibrary, so I might try that if it doesn't seem like to much work or else I'll let this side-project wait for a while and come back to it later with more energy
Bookmarks