include/pops/runtime/export.hpp Source FileΒΆ

adc_cpp: include/pops/runtime/export.hpp Source File
adc_cpp 0.3.0
Model-free C++23 core for coupled hyperbolic-elliptic systems on adaptive (AMR) meshes, with MPI and GPU (Kokkos) backends
export.hpp
Go to the documentation of this file.
1#pragma once
2
14
15// Windows: the _pops module (which DEFINES these symbols) must define POPS_EXPORT_BUILDING_MODULE at its
16// compilation -> dllexport; the generated .dll loader that IMPORTS them falls back on dllimport. Unix:
17// default visibility (the module is compiled with -fvisibility=hidden). See ADC-99 (portable layer).
18#if defined(_WIN32)
19#if defined(POPS_EXPORT_BUILDING_MODULE)
20#define POPS_EXPORT __declspec(dllexport)
21#else
22#define POPS_EXPORT __declspec(dllimport)
23#endif
24#else
25#define POPS_EXPORT __attribute__((visibility("default")))
26#endif