Welcome, Guest. Please login or register.

Author Topic: Compiling shared libraries  (Read 2814 times)

Description:

0 Members and 2 Guests are viewing this topic.

Offline KarlosTopic starter

  • Sockologist
  • Global Moderator
  • Hero Member
  • *****
  • Join Date: Nov 2002
  • Posts: 16879
  • Country: gb
  • Thanked: 5 times
    • Show all replies
Compiling shared libraries
« on: November 30, 2003, 03:02:08 AM »
Hi all,

I'm working on some normal amiga '.library' files from (virtually pure) C. Now, for historical reasons beyond my control I am forced to use storm, at least for some of it...

Unfortunately storm has its gripes and what seems to be an intractable bug in the code generator has waylaid me. I am still seeing exactly what is wrong there but it doesnt look like its the code (having tested that part in another compiler).

Now, can the bulk of the library - as defined as those functions not part of the fd - be compiled in another compiler (I am thinking vbcc uses same object format IIRC) and then linked with stormc ?

Anybody tried this?

On the same note, I need to compile a WarpOS PPC version of the same library but don't have StormC PPC. Assuming that the code could be compiled in vbcc-wos, again, any chance of getting stormlink to make a .library from it?

Cheers,

K
int p; // A
 

Offline KarlosTopic starter

  • Sockologist
  • Global Moderator
  • Hero Member
  • *****
  • Join Date: Nov 2002
  • Posts: 16879
  • Country: gb
  • Thanked: 5 times
    • Show all replies
Re: Compiling shared libraries
« Reply #1 on: December 02, 2003, 03:02:26 PM »
Well, object formats aside, the last time I checked, vbcc couldn't directly create shared libraries and neither could gcc (unless you write the library header stuff yourself by hand).

-edit-

I appreciate this info may be out of date. Feel free to correct me here :-)

-/edit-

OTOH, storm c can create shared libraries fairly easily, just add the fd file and tell it to link as a shared library.

Anyhow, thanks for the replies :-)
int p; // A
 

Offline KarlosTopic starter

  • Sockologist
  • Global Moderator
  • Hero Member
  • *****
  • Join Date: Nov 2002
  • Posts: 16879
  • Country: gb
  • Thanked: 5 times
    • Show all replies
Re: Compiling shared libraries
« Reply #2 on: December 02, 2003, 04:17:09 PM »
@itix

Well, I was hoping for idiot proof simplicity and convenience, but creating the library by hand isn't likely to hurt me too much.

What about warpos ppc native shared libraries? Any good examples out there?
int p; // A
 

Offline KarlosTopic starter

  • Sockologist
  • Global Moderator
  • Hero Member
  • *****
  • Join Date: Nov 2002
  • Posts: 16879
  • Country: gb
  • Thanked: 5 times
    • Show all replies
Re: Compiling shared libraries
« Reply #3 on: December 02, 2003, 06:29:19 PM »
Cheers, I will give that a bash later :-)

I actually got around the stupid bug that was the cause of my main gripe so I can use storm ok now. However, its just one of e depressingly long list of storm c v3 codegenerator problems (admittedly the first non C++ one I encountered)...
int p; // A