fix MS_API on windows
This commit is contained in:
parent
a480d07dd2
commit
420093a870
|
@ -23,12 +23,6 @@
|
|||
#include "include/api/data_type.h"
|
||||
#include "include/api/dual_abi_helper.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#define MS_API __declspec(dllexport)
|
||||
#else
|
||||
#define MS_API __attribute__((visibility("default")))
|
||||
#endif
|
||||
|
||||
namespace mindspore {
|
||||
class Model;
|
||||
class ModelImpl;
|
||||
|
|
|
@ -22,12 +22,6 @@
|
|||
#include <memory>
|
||||
#include "include/api/callback/callback.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#define MS_API __declspec(dllexport)
|
||||
#else
|
||||
#define MS_API __attribute__((visibility("default")))
|
||||
#endif
|
||||
|
||||
namespace mindspore {
|
||||
|
||||
class CkptSaver: public TrainCallBack {
|
||||
|
|
|
@ -21,12 +21,6 @@
|
|||
#include <utility>
|
||||
#include "include/api/callback/callback.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#define MS_API __declspec(dllexport)
|
||||
#else
|
||||
#define MS_API __attribute__((visibility("default")))
|
||||
#endif
|
||||
|
||||
using GraphPoint = std::pair<int, float>;
|
||||
|
||||
namespace mindspore {
|
||||
|
|
|
@ -22,12 +22,6 @@
|
|||
#include <memory>
|
||||
#include "include/api/callback/callback.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#define MS_API __declspec(dllexport)
|
||||
#else
|
||||
#define MS_API __attribute__((visibility("default")))
|
||||
#endif
|
||||
|
||||
namespace mindspore {
|
||||
|
||||
constexpr int DONT_UPDATE_LR = 0;
|
||||
|
|
|
@ -22,12 +22,6 @@
|
|||
#include <memory>
|
||||
#include "include/api/callback/callback.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#define MS_API __declspec(dllexport)
|
||||
#else
|
||||
#define MS_API __attribute__((visibility("default")))
|
||||
#endif
|
||||
|
||||
namespace mindspore {
|
||||
|
||||
class TimeMonitor: public TrainCallBack {
|
||||
|
|
|
@ -24,12 +24,6 @@
|
|||
#include "include/api/callback/callback.h"
|
||||
#include "include/api/metrics/accuracy.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#define MS_API __declspec(dllexport)
|
||||
#else
|
||||
#define MS_API __attribute__((visibility("default")))
|
||||
#endif
|
||||
|
||||
using GraphPoint = std::pair<int, float>;
|
||||
|
||||
namespace mindspore {
|
||||
|
|
|
@ -23,12 +23,6 @@
|
|||
#include "include/api/data_type.h"
|
||||
#include "include/api/dual_abi_helper.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#define MS_API __declspec(dllexport)
|
||||
#else
|
||||
#define MS_API __attribute__((visibility("default")))
|
||||
#endif
|
||||
|
||||
namespace mindspore {
|
||||
|
||||
class MixPrecisionCfg {
|
||||
|
|
|
@ -27,12 +27,16 @@
|
|||
|
||||
#ifndef MS_API
|
||||
#ifdef _WIN32
|
||||
#ifdef _MSC_VER
|
||||
#ifdef BUILDING_DLL
|
||||
#define MS_API __declspec(dllexport)
|
||||
#else
|
||||
#define MS_API __declspec(dllimport)
|
||||
#endif
|
||||
#else
|
||||
#define MS_API __declspec(dllexport)
|
||||
#endif
|
||||
#else
|
||||
#define MS_API __attribute__((visibility("default")))
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -34,12 +34,16 @@
|
|||
|
||||
#ifndef MS_API
|
||||
#ifdef _WIN32
|
||||
#ifdef _MSC_VER
|
||||
#ifdef BUILDING_DLL
|
||||
#define MS_API __declspec(dllexport)
|
||||
#else
|
||||
#define MS_API __declspec(dllimport)
|
||||
#endif
|
||||
#else
|
||||
#define MS_API __declspec(dllexport)
|
||||
#endif
|
||||
#else
|
||||
#define MS_API __attribute__((visibility("default")))
|
||||
#endif
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue