For whatever reasons I am unable to get a 64-bit wcx framework working with Delphi XE7. TC's 64-bit response is always "Cannot load plugin". If I compile for 32-bit with TC 32-bit then the plugin gets loaded and displays the message box I'd expect.
Can someone help (e.g. having a 64-bit framework for wcx plugin) what needs to be done to get it working with TC-64bit?
Thanks
Struggling with 64-bit wcx plugin
Moderators: Hacker, petermad, Stefan2, white
Did you export all necessary functions? How does the plugin line in your wincmd.ini look like?
Regards
Dalai
Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64
Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64
Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
Well I guess so. These are the exported funtions:
and these are the corresponding declarations:
The functions OpenArchiveW and ReadHeaderExW actually just show a dialog so I am aware that the function is called.
This is the line from wincmd.ini
Code: Select all
OpenArchiveW,
ReadHeaderExW,
ProcessFileW,
CloseArchive,
SetChangeVolProcW,
SetProcessDataProcW,
GetPackerCaps,
PackFilesW,
DeleteFilesW,
CanYouHandleThisFileW
Code: Select all
function OpenArchiveW(var ArchiveDataW: TOpenArchiveDataW): THandle; stdcall;
function ReadHeaderExW(hArcData: THandle; var HeaderDataExW: THeaderDataExW): integer; stdcall;
function ProcessFileW(hArcData: THandle; Operation: integer; DestPath, DestName: PChar):
integer; stdcall;
function CloseArchive(hArcData: THandle): integer; stdcall;
procedure SetChangeVolProcW(hArcData: THandle; pChangeVolProc: TChangeVolProc); stdcall;
procedure SetProcessDataProcW(hArcData: THandle; pProcessDataProc: TProcessDataProc); stdcall;
function GetPackerCaps: integer; stdcall;
function PackFilesW(PackedFile, SubPath, SrcPath, AddList: PChar; Flags: integer):
integer; stdcall;
function DeleteFilesW(PackedFile, DeleteList: PChar): integer; stdcall;
function CanYouHandleThisFileW(FileName: PChar): boolean; stdcall;
This is the line from wincmd.ini
Code: Select all
[PackerPlugins]
CSa=192,C:\VMShare\Delphi XE7\Projekte\TC_Plugins\CSa_gpWCX\Win64\Debug\GpStructuredStoragePacker.wcx64
I currently can't test it in detail, but AFAIK you need the NORMAL non-wide functions too, no matter if they are not going to be used anyway:
OpenArchive
PackFiles
ProcessFile
ReadHeader
ReadHeaderEx
SetChangeVolProc
...
So just make these function "dummies", i.e. return E_BAD_ARCHIVE or so.
TC can't know in advance if the plug-in is Unicode-only, so it still needs the old functions exported, as a certain "signature".
I wonder why it works in 32-bit though.
So maybe it's some different problem.
OpenArchive
PackFiles
ProcessFile
ReadHeader
ReadHeaderEx
SetChangeVolProc
...
So just make these function "dummies", i.e. return E_BAD_ARCHIVE or so.
TC can't know in advance if the plug-in is Unicode-only, so it still needs the old functions exported, as a certain "signature".
I wonder why it works in 32-bit though.
So maybe it's some different problem.
TC plugins: PCREsearch and RegXtract