Page 1 of 1

PureCAB library : compress / extract CAB archives

Posted: Thu Mar 20, 2008 10:29 am
by gnozal
PureCAB library

Overview

Code: Select all

The purpose of PureCAB is to handle CAB files [MS-Cabinet].

Note : This library does not support InstallShield archives [also CAB extension].
Functions
PB4.xx : http://gnozal.ucoz.com/PureCAB_.htm

Example

Code: Select all

; Compression callback
Procedure.l MyCustom_Compression_StatusCallBack(Filename.s, PerCent.f)
  ; Filename : current processed filename
  ; PerCent  : current compression progression [0-100%]
  Debug "Packing " + Filename + " - " + StrF(PerCent, 2) + "%"
EndProcedure
; Set compression callback
PureCAB_SetCompressionCallback(@MyCustom_Compression_StatusCallBack())
; Create Archive
Handle = PureCAB_Create("c:\PureBasic410\Program\test.cab")
If Handle
  PureCAB_Compress(Handle, "c:\WINDOWS\Coffee Bean.bmp", "Another Name.bmp")
  PureCAB_Compress(Handle, "c:\PureBasic410\Help\Win32.hlp")
  PureCAB_Compress(Handle, "c:\WINDOWS\FeatherTexture.bmp")
  PureCAB_Compress(Handle, "c:\WINDOWS\Gone Fishing.bmp")
  PureCAB_Compress(Handle, "c:\PureBasic410\Help\SOCK2.HLP")
  PureCAB_Close(Handle)
  Debug "Done"
Else
  Debug "Failed creating cab"
EndIf
Download
Only available for Purebasic Windows x86
PB4.0x-4.2x : http://gnozal.ucoz.com/PureCAB_.zip
PB4.3x : http://gnozal.ucoz.com/PureCAB_430.zip
PB4.4x : http://gnozal.ucoz.com/PureCAB_440.zip
PB4.5x : http://gnozal.ucoz.com/PureCAB_450.zip
PB4.6x : http://gnozal.ucoz.com/PureCAB_460.zip
PB5.0x : http://gnozal.ucoz.com/PureCAB_500.zip

Posted: Wed Aug 27, 2008 2:13 pm
by SFSxOI
Nice little Library, thank you :)

By any chance are you planning on expanding it to support InstallShield archives (.cab) maybe in the near future?

Posted: Wed Aug 27, 2008 3:06 pm
by gnozal
SFSxOI wrote:By any chance are you planning on expanding it to support InstallShield archives (.cab) maybe in the near future?
No chance, sorry !
IS archives are completely different from m$ cabinet files, the only thing in common is the extension.

Re: PureCAB library : compress / extract CAB archives

Posted: Thu Jun 16, 2011 9:15 am
by X0r
Please would you also offer an unicode version?
Thanks!

Re: PureCAB library : compress / extract CAB archives

Posted: Thu Jun 16, 2011 12:18 pm
by gnozal
Forge wrote:Please would you also offer an unicode version?
The PB4.6x version should be unicode compatible.

Re: PureCAB library : compress / extract CAB archives

Posted: Tue Aug 23, 2011 9:58 pm
by X
It is great that you have all of these libraries and tools. What prevents them from being released in a a x64 flavor?

Re: PureCAB library : compress / extract CAB archives

Posted: Wed Aug 24, 2011 9:47 am
by gnozal
X wrote:It is great that you have all of these libraries and tools. What prevents them from being released in a a x64 flavor?
Let's see...
I don't use a x64 OS. But the OS is the easy part, and a user already sent me a Se7en x64 CD !
The big part is the library conversion, and some of them (very few actually) may use some older public domain C code not ported to x64.

The other issues on my side are :
- (free) time
- a PC recent enough to run Se7en
- a x64 version of jaPBe ;-)

However, only x86 software will run on all OS's, and there are still a lot of x86 machines out there.

I will migrate to x64 eventually, but don't expect any schedule.

Re: PureCAB library : compress / extract CAB archives

Posted: Wed Aug 24, 2011 4:59 pm
by X
Oh no problemo. I was curious. Wonderful libraries and tools!

Re: PureCAB library : compress / extract CAB archives

Posted: Thu Dec 12, 2013 1:31 pm
by Fangbeast
Gnozal, I realise you are busy these days but I am desperate..Is there any chance to update PureCAB to PB 5.21?

Unfortunately, I had to update and that broke PureCAB and I can run my tool..

Regards and Merry Christmas, Fang.