PureBasic Forum
https://www.purebasic.fr/english/

Static lib output
https://www.purebasic.fr/english/viewtopic.php?f=3&t=30342
Page 1 of 2

Author:  Mistrel [ Mon Dec 31, 2007 11:37 pm ]
Post subject:  Static lib output

I know that PureBasic outputs a .dll with a import .lib. It would be a great addition if PureBasic could output a static lib.

Author:  Dare [ Mon Dec 31, 2007 11:37 pm ]
Post subject: 

Yes. Agreed.

Author:  Hroudtwolf [ Wed Jan 02, 2008 1:08 am ]
Post subject: 

Agreed, too.

Author:  inc. [ Wed Jan 02, 2008 9:34 am ]
Post subject: 

The final User of your static lib would be forced to link (in VC++ i.e.) with the needed PB libs where commands have been used from (like Window, 2DDrawing etc). But as the Purebasic Libs are protected thats not possible.
Maybe that could be handled by an internal progress of PB where those needed PB library symbols would be linked/appended directly before outputting the final static lib.

Author:  Dare [ Wed Jan 02, 2008 10:08 am ]
Post subject: 

Technicalities, technicalities! :)

Author:  milan1612 [ Wed Jan 02, 2008 10:34 am ]
Post subject: 

+1

@inc
Maybe an option if you want to compile the lib for PureBasic or
other compilers?

Author:  inc. [ Wed Jan 02, 2008 12:05 pm ]
Post subject: 

milan1612 wrote:
Maybe an option if you want to compile the lib for PureBasic
Could already exactly be done via -> Tailbite :-)
Quote:
or other compilers?
yep, as told, then the PB library symbols have to be embedded in the resulting static lib. Else VC++ compiles would be end up in linking errors.

Author:  Mistrel [ Wed Jan 02, 2008 10:07 pm ]
Post subject: 

inc. wrote:
milan1612 wrote:
Maybe an option if you want to compile the lib for PureBasic
Could already exactly be done via -> Tailbite :-)
Quote:
or other compilers?


Tailbite builds only PureBasic libraries.

Author:  inc. [ Thu Jan 03, 2008 10:12 am ]
Post subject: 

Yes and if you would look closer than you will recognise that my statement belongs to one of Milans Ideas:
Quote:
Maybe an option if you want to compile the lib for PureBasic

Author:  va!n [ Thu Feb 21, 2008 6:05 am ]
Post subject: 

+1 *this would be a really great feature*

Author:  jack [ Thu Feb 21, 2008 4:31 pm ]
Post subject: 

but then you would have the PB command wrapper issue.

Author:  localmotion34 [ Thu Feb 21, 2008 4:45 pm ]
Post subject: 

jack wrote:
but then you would have the PB command wrapper issue.


It wouldnt be all that difficult to decide on a set of limited commands that are allowed to be used in a static lib.

When the "static lib" output option is selected, the compiler will only look for PB libraries in a special folder designed for static lib output. when it encounters a command not allowed in a static lib, it just behaves like the PB demo does "thisprocedure() is not a function array or linked list".

All the win API commands, some math functions, string manipulation could be allowed. it is up to Fred really, but there is a way to do it and be fair to everyone.

Author:  Mistrel [ Tue May 27, 2008 5:21 am ]
Post subject: 

I would still love to see this added as a feature for PureBasic. It would be an obvious solution to the inherit problems that exist with TailBite and future compatibility. PureBasic can already export to a DLL but this is not always an acceptable solution.

Author:  Dummy [ Tue May 27, 2008 5:10 pm ]
Post subject: 

This: http://www.purebasic.fr/english/viewtopic.php?t=31339
looks like a temporary solution...

Author:  Mistrel [ Wed May 28, 2008 1:07 am ]
Post subject: 

Dummy wrote:
This: http://www.purebasic.fr/english/viewtopic.php?t=31339
looks like a temporary solution...


Libraries produced by coffIT cannot be used in other languages if they use any function from the PureBasic libraries. It's still a PureBasic-only solution, like TailBite.

Page 1 of 2 All times are UTC + 1 hour
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/