Initial setup for CLion
This commit is contained in:
31
engines/TensorRTAPI/include/engine_api.h
Normal file
31
engines/TensorRTAPI/include/engine_api.h
Normal file
@@ -0,0 +1,31 @@
|
||||
#pragma once
|
||||
|
||||
// ============================================================================
|
||||
// ENGINE_API — DLL export/import control macro
|
||||
//
|
||||
// HOW TO USE
|
||||
// ----------
|
||||
// Library project (CodeAid):
|
||||
// Add ENGINE_EXPORTS to Project Properties →
|
||||
// C/C++ → Preprocessor → Preprocessor Definitions.
|
||||
// This causes all ENGINE_API-decorated symbols to be __declspec(dllexport).
|
||||
//
|
||||
// Consuming projects:
|
||||
// Do NOT define ENGINE_EXPORTS. ENGINE_API becomes __declspec(dllimport),
|
||||
// which tells the linker to resolve decorated symbols from the DLL's .lib
|
||||
// import library. No engine.cpp needs to be added to the consuming project.
|
||||
//
|
||||
// WHAT IS DECORATED
|
||||
// -----------------
|
||||
// Logger — class ENGINE_API Logger
|
||||
// GpuDeviceInfo — struct ENGINE_API GpuDeviceInfo
|
||||
// Int8EntropyCalibrator2 — class ENGINE_API Int8EntropyCalibrator2
|
||||
// Engine<float> — explicit instantiation at bottom of engine.h
|
||||
// (and any other Engine<T> types listed there)
|
||||
// ============================================================================
|
||||
|
||||
#ifdef ENGINE_EXPORTS
|
||||
# define ENGINE_API __declspec(dllexport)
|
||||
#else
|
||||
# define ENGINE_API __declspec(dllimport)
|
||||
#endif
|
||||
Reference in New Issue
Block a user