You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// Purpose: returns a pointer to a function, given a module
// Input : pModuleName - module name
// *pName - proc name
//static hlds_run wants to use this function
void *Sys_GetProcAddress(const char *pModuleName, const char *pName)
{
return (void*)GetProcAddress(GetModuleHandle(pModuleName), pName);
}
// Purpose: returns a pointer to a function, given a module
// Input : pModuleName - module name
// *pName - proc name
// hlds_run wants to use this function
void *Sys_GetProcAddress(void *pModuleHandle, const char *pName)
{
return (void*)GetProcAddress((HMODULE)pModuleHandle, pName);
}
In file included from ReAPI.cpp:4:
include/cssdk/public/interface.cpp: In function 'void* Sys_GetProcAddress(const char*, const char*)':
include/cssdk/public/interface.cpp:112:30: error: invalid conversion from 'FARPROC' {aka 'int (__attribute__((stdcall)) *)()'} to 'void*' [-fpermissive]
112 | return GetProcAddress(GetModuleHandle(pModuleName), pName);
| ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| |
| FARPROC {aka int (__attribute__((stdcall)) *)()}
include/cssdk/public/interface.cpp: In function 'void* Sys_GetProcAddress(void*, const char*)':
include/cssdk/public/interface.cpp:121:30: error: invalid conversion from 'FARPROC' {aka 'int (__attribute__((stdcall)) *)()'} to 'void*' [-fpermissive]
121 | return GetProcAddress((HMODULE)pModuleHandle, pName);
| ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| |
| FARPROC {aka int (__attribute__((stdcall)) *)()}
mingw32-make[1]: *** [Makefile:62: Release/ReAPI.o] Error 1
It will solve the problem to use CSSDK on MinGW32
The text was updated successfully, but these errors were encountered:
Sys_GetProcAddress - Build failed on MinGW32
ReGameDLL_CS/regamedll/public/interface.cpp
Line 110 in dc16b12
Maybe change to:
It will solve the problem to use CSSDK on MinGW32
The text was updated successfully, but these errors were encountered: