Use templates for module population
Also add stddef.h workaround for old GCC.
RHEL-8 still uses GCC 8.5 and templates are not well supported.
Change-Id: Ia4dae23892ec63682ea848c46ba81de85cf6d209
Signed-off-by: Galantsev, Dmitrii <dmitrii.galantsev@amd.com>
[ROCm/rdc commit: f9e80cc37a]
Esse commit está contido em:
@@ -22,6 +22,8 @@ THE SOFTWARE.
|
||||
|
||||
#include "rdc_lib/RdcLibraryLoader.h"
|
||||
|
||||
#include "rdc_lib/RdcException.h"
|
||||
|
||||
namespace amd {
|
||||
namespace rdc {
|
||||
|
||||
@@ -39,7 +41,9 @@ rdc_status_t RdcLibraryLoader::load(const char* filename) {
|
||||
libHandler_ = dlopen(filename, RTLD_LAZY);
|
||||
if (!libHandler_) {
|
||||
char* error = dlerror();
|
||||
RDC_LOG(RDC_ERROR, "Fail to open " << filename << ": " << error);
|
||||
throw RdcException(
|
||||
RDC_ST_FAIL_LOAD_MODULE,
|
||||
std::string("Fail to open ") + std::string(filename) + ": " + std::string(error));
|
||||
return RDC_ST_FAIL_LOAD_MODULE;
|
||||
}
|
||||
|
||||
|
||||
Referência em uma Nova Issue
Bloquear um usuário