Lib2PBImport 2013 - new Version

Applications, Games, Tools, User libs and useful stuff coded in PureBasic
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Lib2PBImport 2013 - new Version

Post by ts-soft »

After a long time, i have created a new version of Lib2PBImport.
Required OS: Windows XP and higher.

This tool reads static libs and Importlibs for DLLs and displays the included functions.

You can and should make various settings in the tool:
- Number of parameters (partially recognized in StdCall libs with decoration)
- Change AliasName
- Select which functions should imported
- Calling Convention of functions (StdCall, CDECL or FASTCALL)

Then you can save an ImportTemplate as an include file, copy to the Clipboard, or
the tool was started directly from the IDE you can directly insert.

Screenshot:
Image

Download

Greetings - Thomas
Last edited by ts-soft on Thu May 11, 2017 9:36 pm, edited 2 times in total.
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
jassing
Addict
Addict
Posts: 1768
Joined: Wed Feb 17, 2010 12:00 am

Re: Lib2PBImport 2013 - new Version

Post by jassing »

Glad to see it being maintained, but...

win2003 - when I ran it and opened a lib:
Image

in contrast, the old one:
Image
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: Lib2PBImport 2013 - new Version

Post by ts-soft »

Thanks for bugreport!

I have updated the version, to refresh on systems without enabled XP-Style, please test it.

To see all buttons, you have to configure as IDE-Tool, like this:
Image
Attention: "Insert Import" will only work, if you not changed the Tab in the IDE!

You can open your libs from Explorer- or Projectpanel with doubleclick.
Drop a lib on the GUI is also supported.

Added New-Button "Save Import"

Have Fun

Thomas
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
jassing
Addict
Addict
Posts: 1768
Joined: Wed Feb 17, 2010 12:00 am

Re: Lib2PBImport 2013 - new Version

Post by jassing »

ts-soft wrote:...without enabled XP-Style, please test it...
YUP! Working now.

Thanks
-j
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: Lib2PBImport 2013 - new Version

Post by ts-soft »

Update:

- More menuentries and shortcuts added
- Comments colored in red
- Imports can be created for DLLs, therefore is the polib.exe in the directory of the tool required (supplied).
DLLs can be opened via the menu or drop.

The create of imports may be still some bugs, please test it.

Greetings - Thomas
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: Lib2PBImport 2013 - new Version

Post by ts-soft »

Update:

Fixed a problem with generated Importsource.
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
sec
Enthusiast
Enthusiast
Posts: 789
Joined: Sat Aug 09, 2003 3:13 am
Location: 90-61-92 // EU or ASIA
Contact:

Re: Lib2PBImport 2013 - new Version

Post by sec »

ts-soft wrote:Thanks for bugreport!

I have updated the version, to refresh on systems without enabled XP-Style,

Thomas
How you fix that? My app has same problem (menuitem, or toolbar do not show image)
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: Lib2PBImport 2013 - new Version

Post by ts-soft »

sec wrote: How you fix that? My app has same problem (menuitem, or toolbar do not show image)
This is very individuell :wink:
For Menu you can add: DrawMenuBar_(hWnd)
(make sure, you have used: CreateImageMenu)
For Gadgets: InvalidateRect_(hWnd, 0, #True)

You should make a search in the forum, you will found many tipps to solve such problems.
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: Lib2PBImport 2013 - new Version

Post by ts-soft »

Update:

- Creation of importlibs supports 64-Bit DLLs (autodetect)
- The Alias (As "...") is now optional for created Importsource
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: Lib2PBImport 2013 - new Version

Post by ts-soft »

Update:

+ added Flag /NOUND to Polib
Polib-Help wrote:The /NOUND option prevents the library manager from adding an underscore ('_') to the beginning of symbols exported from an executable.
Only affect symbols that looks like functions, and lacks other form of decoration.
+ updated Polib to Version 7.00
+ Drop a Lib or DLL on a not empty grid opens a new instance.
+ Preview with ScintillaGadget
Screenshot:
Image

If there comes no bugreports or wishes, i think this one is the final.
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: Lib2PBImport 2013 - new Version

Post by ts-soft »

small bugfix:
Insert Import use the codepage (ASCII or UTF-8) from the actuell scintilla.
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
IdeasVacuum
Always Here
Always Here
Posts: 6425
Joined: Fri Oct 23, 2009 2:33 am
Location: Wales, UK
Contact:

Re: Lib2PBImport 2013 - new Version

Post by IdeasVacuum »

Really usefull tool, thank you so much for taking the time to publish it. 8)

Enhancement request: Save Import - remember path last saved to.
IdeasVacuum
If it sounds simple, you have not grasped the complexity.
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: Lib2PBImport 2013 - new Version

Post by ts-soft »

Thx,
IdeasVacuum wrote:Enhancement request: Save Import - remember path last saved to.
Done :wink:
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
User avatar
luis
Addict
Addict
Posts: 3876
Joined: Wed Aug 31, 2005 11:09 pm
Location: Italy

Re: Lib2PBImport 2013 - new Version

Post by luis »

It's nice thanks and yes I have a wish :)

Would be nice to be able to run it from the command line, something like:

Lib2PBImport libname.lb [/alias] > libname_import.pbi

to automate includes creation when updating a dll, especially if you have multiple versions of it ... or many dll.
"Have you tried turning it off and on again ?"
A little PureBasic review
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: Lib2PBImport 2013 - new Version

Post by ts-soft »

In the moment following commandline parameter used:
1. Filename with path of lib or dll
2. LastPath (Path from last opened Lib)
3. SavePath (Path from last saved Import)

I think save without change the settings (all functions are selected, all parameters set to 0)
is not usefull?
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
Post Reply