Author Topic: question about bundling exe file  (Read 6096 times)

0 Members and 1 Guest are viewing this topic.

Frankolinox

  • Guest
Re: question about bundling exe file
« Reply #15 on: May 17, 2012, 03:29:57 AM »
thanks charles, the embed a file idea I like very mucho :)

a) I have tested your new example: the embedfile for "scriptbasic" (project folder) doesn't work here correct. I can compile the scriptbasic example with oxygen but there's no running.

b) "#file": that was only an idea to cut some parts of oxygen (assembler code) from the "#file" part and wanted to include and convert to powerbasic (that was a very hard work to collect all files!) but was a good exercise too. mword/tword part I haven't translated all the functions are linked to another oxygen include files (haha *smile*) and so I can imagine it's better to convert all files or bind oxygen.dll for my "funbasic" project. but "PE" has to implement too, that's a very big job I can see but how does it work for powerbasic I haven't idea at this moment..

c) my thoughts about that topic today is that it's nearly impossible to create a "compile" file (I wanted to create from powerbasic side an exe file that's do the work for me to start the compiling job for my funbasic *.bas file. the idea I liked very much, but that's not working here ;)

thanks for feedback, I have still to learn much more about oxygenbasic and the source is very, very interesting stuff.

perhaps I will send you an example next days, what's possible here or if that's working for embedding my "funbasic.dll" and an example file (*.bas) to compile (exe bundle) . nice weekend, frank

Charles Pegge

  • Guest
Re: question about bundling exe file
« Reply #16 on: May 17, 2012, 07:34:05 AM »

Hi Frank,

PE file generation is quite a challenge. Most of the code for this can be found in o2hdrs.bas

I found the most difficult part was debugging, since there are no helpful error messages! If the system finds fault with the PE file, it spits it out with contempt!

Microsoft's official specification for the PE format can be obtained here:

http://msdn.microsoft.com/en-us/windows/hardware/gg463119.aspx

The parser is a good starting point. I will continue work on script language code examples. I am all for experimenting with new languages.

Charles


Aurel

  • Guest
Re: question about bundling exe file
« Reply #17 on: May 17, 2012, 10:44:32 AM »
Quote
The parser is a good starting point. I will continue work on script language code examples. I am all for experimenting with new languages.

Good to know that.. :)

Frankolinox

  • Guest
Re: question about bundling exe file
« Reply #18 on: May 28, 2012, 11:39:20 PM »
hello charles, short question: do you are using "ELF" technique for making your executable / dll file creation ? If you agree to it with yes: Why do you are using "ELF"? ;) the whole examples I've found of pe file creation at official sites from msdn or vb is a hell to understand here at the moment. but I will continue to search a good solution for my purposes :)

best regards, frank

Charles Pegge

  • Guest
Re: question about bundling exe file
« Reply #19 on: May 29, 2012, 12:50:49 AM »
Hi Frank,

ELF is used in Linux and other Unix-based operating systems. MS Windows uses PE. Both of these system evolved from another format called COFF. They are both organised as a bunch of fixed length records and variable length records. They carry quite a lot of information, for mapping a program into memory, ready for execution.

So I will need to use ELF for Linux, and other forms of coding for systems like Android. Producing C-source code or LLVM for native compilers is also a feasible way of extending Oxygen's reach.

Charles