Hi,
Some users reported problems installing the correct libmyql.dll version durning hMailServer/MySQL Setup process.
To mitigate this Problem i have written a little DLL (libhmsutils.dll, native - not .NET) which will:
[*]Download the MySQL Connector ZIP-Archive from Oracles MySQL-Website to local Windows Temp Folder
[*]Unzip the downloaded file to a GUID-Uniquefolder (to avoid access and search problems)
[*]Search and locate libmysql.dll inside the extracted folder
[*]Copy libmysql to c:\Program Files (x86)\Bin\hMailServer\Bin\libmysql.dll
The following params can modified as needed in install_dlg.cpp Line: 7
std::wstring locate_libmysql = L"Unknown"; // if libmysql.dll could not be found
std::wstring download_server = L"dev.mysql.com";
std::string webspace_url = "/get/Downloads/Connector-C/";
std::string ZipArchiveName = "mysql-connector-c-6.1.11-win32.zip";
Here you can see how it looks like:
The Download and Install-Wizzard
Installer for testing this feature:
https://github.com/Dravion/hmailserver/ ... g/5.6.7-B1
Sourcecode Repo (VS2017)
https://github.com/Dravion/libhmsutils.dll
Notes: The DLL and DLLCall.exe are completely written in C/C++ Win32, without MFC/ATL or Ressource
Editor Dependencies, so this will work within the normal Buildprocess of hMailServer. You only need to
open the libhmsutils.sln solution and click build, it simply will run and build.
Modified Installer - Download+Install Libmysql.dll
- jimimaseye
- Moderator
- Posts: 10053
- Joined: 2011-09-08 17:48
Re: Modified Installer - Download+Install Libmysql.dll
What if the user doesnt use this path and installs hmailsverer in to, say, d:\hmailserver?Copy libmysql to c:\Program Files (x86)\Bin\hMailServer\Bin\libmysql.dll
5.7 on test.
SpamassassinForWindows 3.4.0 spamd service
AV: Clamwin + Clamd service + sanesecurity defs : https://www.hmailserver.com/forum/viewtopic.php?f=21&t=26829
SpamassassinForWindows 3.4.0 spamd service
AV: Clamwin + Clamd service + sanesecurity defs : https://www.hmailserver.com/forum/viewtopic.php?f=21&t=26829
Re: Modified Installer - Download+Install Libmysql.dll
I use a WQL Query like this:
Select PathName from win32_service Where name ='hMailServer'. This will return the complete Servicepath with all its params. From this String i simply extract the real Installationpath of hMailServers bin folder.
Select PathName from win32_service Where name ='hMailServer'. This will return the complete Servicepath with all its params. From this String i simply extract the real Installationpath of hMailServers bin folder.
Re: Modified Installer - Download+Install Libmysql.dll
I believe the actual problem isn't resolved by your update. The problem I encountered is that I also needed to install the Visual C++ Redistributable for the libmysql.dll.
I downloaded and installed this: https://www.microsoft.com/en-us/downloa ... x?id=52685 then everything worked.
I downloaded and installed this: https://www.microsoft.com/en-us/downloa ... x?id=52685 then everything worked.
Re: Modified Installer - Download+Install Libmysql.dll
Redist DLLs must be installed with or without this Libmysql.dll Installer. But it should installed by hMailServer Mainsetup bc it depends on it.
Re: Modified Installer - Download+Install Libmysql.dll
Yep, the only time I've ever had to manually install that was on a 'core server' or a 'hyperV Core' server
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation
https://www.hmailserver.com/documentation