I haven't had to change my source when switching from 5.73 to 6.00 either. It all works great!
Is PB using zlib?
Re: Is PB using zlib?
Does someone of you also create libraries? In the changelog thread it says that it only supports 32Bit DLL yet. At least, it does not mention it anywhere else until today...
We compile .DLL/.DYLIB and .SO for our backend. It is mandatory for our products.
To be honest, I have not yet tried. I'm very busy this week (also because of the zlib thing, which also affects other parts of our products, not only PureBasic related).
We compile .DLL/.DYLIB and .SO for our backend. It is mandatory for our products.
To be honest, I have not yet tried. I'm very busy this week (also because of the zlib thing, which also affects other parts of our products, not only PureBasic related).
Re: Is PB using zlib?
I had to change small things like ASM Procedures and Macros for DataSection labels.
But my app's worked in v6b3+.
I understand your hesitance for product release with a beta, but Fred said v6 is nearly final.
Selfishly, I want the updates for SQLite(bug fixes) and zlib(security) applied to v6.
v573 patching of zlib does make sense if time allows.
Hopefully, in future v6.x, we can address these random updates with static C lib importing at our own pace.
But my app's worked in v6b3+.
I understand your hesitance for product release with a beta, but Fred said v6 is nearly final.
Selfishly, I want the updates for SQLite(bug fixes) and zlib(security) applied to v6.
v573 patching of zlib does make sense if time allows.
Hopefully, in future v6.x, we can address these random updates with static C lib importing at our own pace.
The nice thing about standards is there are so many to choose from. ~ Andrew Tanenbaum
Re: Is PB using zlib?
Sorry I missed your post, that works fine with mingw32 / Clang 13 build.fryquez wrote: ↑Fri Apr 01, 2022 8:22 am is there a problem with MinGW compiled libs?
https://www.mediafire.com/file/yfpuzmji ... 2.zip/file
@Kukulkan
It's easy to build to build with with cmake and mingw then drop them into
"C:\Program Files\PureBasic\PureLibraries\Windows\Libraries\zlib.lib"
If you don't have mingw32, clang and cmake or the gui cmake It's worth installing as you can also use clang with c backend. (when you up grade to pb 6)
test should say 1.2.12Build tools required for windows builds cmake and mingw64
cmake
https://cmake.org/download/
mingw64
Info https://www.mingw-w64.org/downloads/#llvm-mingw
Available versions info https://github.com/mstorsjo/llvm-mingw/releases
Direct download link https://github.com/mstorsjo/llvm-mingw/ ... x86_64.zip
install to c:\
then add to the PATH environment variable ;type env in windows search
C:\llvm-mingw-20211002-msvcrt-x86_64
C:\llvm-mingw-20211002-msvcrt-x86_64\bin
C:\llvm-mingw-20211002-msvcrt-x86_64\include
Get the zlib source
https://github.com/madler/zlib
extract to where ever E:\
run cmd.exe
make a folder called build and cd into and run cmake
E:\zlib-master> mkdir build
E:\zlib-master> cd build
E:\zlib-master\build> cmake -G="MinGW Makefiles"
E:\zlib-master\build> mingw32-make
Code: Select all
UseZipPacker()
ImportC ""
zlibVersion()
EndImport
Debug PeekS(zlibVersion(),-1,#PB_UTF8) ;1.2.12
Re: Is PB using zlib?
Whoa! I just saw this post.
I was using visual studio to compile sources.
I just need to install mingw and that is compatible with PB ImportC for 32 and 64 bit?
Does the PB v6 folder have these compilers already?
I was using visual studio to compile sources.
I just need to install mingw and that is compatible with PB ImportC for 32 and 64 bit?
Does the PB v6 folder have these compilers already?
The nice thing about standards is there are so many to choose from. ~ Andrew Tanenbaum
Re: Is PB using zlib?
If you follow the links and instructions it should work. I was hoping fryquez would elaborate on his set up and build instructions.
He has compiled both but I know some people will need to build it themselves.
I haven't done 32bit version yet.
Using mingw with clang isn't the magic bullet but it's often much easier to get a build working on windows and Linux. static libs on windows are a nightmare because of the changes Microsoft keep doing to the c runtime and fred uses an old version because he likes its small size and backward compatibility.
He has compiled both but I know some people will need to build it themselves.
I haven't done 32bit version yet.
Using mingw with clang isn't the magic bullet but it's often much easier to get a build working on windows and Linux. static libs on windows are a nightmare because of the changes Microsoft keep doing to the c runtime and fred uses an old version because he likes its small size and backward compatibility.
Re: Is PB using zlib?
Well, it's really super easy with MinGW. I also use the llvm-mingw idle posted. You don't have to install any think to build zlib.
Download and unpack zlib-1.2.12 and llvm-mingw-20220323-msvcrt-i686.
In zlib-1.2.12 folder open a Comment Prompt and set PATH environment:
then build it with
You get the libz.a you can rename and copy into you PB installation as \PureLibraries\Windows\Libraries\zlib.lib
Download and unpack zlib-1.2.12 and llvm-mingw-20220323-msvcrt-i686.
In zlib-1.2.12 folder open a Comment Prompt and set PATH environment:
Code: Select all
set PATH=X:\llvm-mingw-20220323-msvcrt-i686\bin;%PATH%
Code: Select all
mingw32-make -fwin32/Makefile.gcc
Re: Is PB using zlib?
I just wonder, if it is that easy, why Fred is not making a new release in the LTS branch? This is what LTS is for...
Re: Is PB using zlib?
The 6.00 will be the new LTS. The 5.70 was released 2nd January 2019, which is now 3 years old (we support LTS 2 years).
Re: Is PB using zlib?
Ok, this seems easy!fryquez wrote: ↑Tue Apr 05, 2022 8:26 amthen build it withYou get the libz.a you can rename and copy into you PB installation as \PureLibraries\Windows\Libraries\zlib.libCode: Select all
mingw32-make -fwin32/Makefile.gcc
Curious why the output file has `.a` extension?
Does this mean ASCII instead of UNICODE? Or some other meaning?
The nice thing about standards is there are so many to choose from. ~ Andrew Tanenbaum
Re: Is PB using zlib?
The .a extension is for static libs the .lib extension is for import libraries to dll but windows just uses .lib for both.
Re: Is PB using zlib?
As Idle said, the .a extension is for static libs, and it stands for archive, because it's an archive of object files,
On Unix, Linux, BSD and macOS there is the ar command to add or remove object files from an archive.
It probably comes with the C compilers (on macOS when you install Xcode).
So, if a C compiler is installed on Windows it will bring the ar app along, ready to be used...
On Unix, Linux, BSD and macOS there is the ar command to add or remove object files from an archive.
It probably comes with the C compilers (on macOS when you install Xcode).
So, if a C compiler is installed on Windows it will bring the ar app along, ready to be used...
I am to provide the public with beneficial shocks.
Alfred Hitshock
-
- Enthusiast
- Posts: 108
- Joined: Wed May 13, 2009 8:38 am
- Location: Arizona, USA
Re: Is PB using zlib?
zlib before 1.2.12 allows memory corruption when deflating (i.e., when compressing) if the input has many distant matches.
https://nvd.nist.gov/vuln/detail/CVE-20 ... ptionTitle
https://nvd.nist.gov/vuln/detail/CVE-20 ... ptionTitle
Re: Is PB using zlib?
Right. This is the reason for this thread...GoodNPlenty wrote: ↑Sat Apr 09, 2022 1:11 am zlib before 1.2.12 allows memory corruption when deflating (i.e., when compressing) if the input has many distant matches.
https://nvd.nist.gov/vuln/detail/CVE-20 ... ptionTitle