Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
Paddle
提交
0e439210
P
Paddle
项目概览
PaddlePaddle
/
Paddle
大约 1 年 前同步成功
通知
2299
Star
20931
Fork
5422
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1423
列表
看板
标记
里程碑
合并请求
543
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
Paddle
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1,423
Issue
1,423
列表
看板
标记
里程碑
合并请求
543
合并请求
543
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
0e439210
编写于
2月 13, 2023
作者:
H
HongyuJia
提交者:
GitHub
2月 13, 2023
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[Fix Compile Error] Fix copysign compile error on Windows (#50387)
* fix copysign compile error on Windows * fix more files' macro
上级
d5b55112
变更
14
显示空白变更内容
内联
并排
Showing
14 changed file
with
56 addition
and
0 deletion
+56
-0
paddle/fluid/framework/io/shell.h
paddle/fluid/framework/io/shell.h
+4
-0
paddle/fluid/pybind/const_value.h
paddle/fluid/pybind/const_value.h
+4
-0
paddle/fluid/pybind/eager.cc
paddle/fluid/pybind/eager.cc
+4
-0
paddle/fluid/pybind/eager.h
paddle/fluid/pybind/eager.h
+4
-0
paddle/fluid/pybind/eager_functions.cc
paddle/fluid/pybind/eager_functions.cc
+4
-0
paddle/fluid/pybind/eager_math_op_patch.cc
paddle/fluid/pybind/eager_math_op_patch.cc
+4
-0
paddle/fluid/pybind/eager_method.cc
paddle/fluid/pybind/eager_method.cc
+4
-0
paddle/fluid/pybind/eager_properties.cc
paddle/fluid/pybind/eager_properties.cc
+4
-0
paddle/fluid/pybind/eager_py_layer.cc
paddle/fluid/pybind/eager_py_layer.cc
+4
-0
paddle/fluid/pybind/eager_utils.cc
paddle/fluid/pybind/eager_utils.cc
+4
-0
paddle/fluid/pybind/eager_utils.h
paddle/fluid/pybind/eager_utils.h
+4
-0
paddle/fluid/pybind/io.h
paddle/fluid/pybind/io.h
+4
-0
paddle/fluid/pybind/protobuf.h
paddle/fluid/pybind/protobuf.h
+4
-0
paddle/fluid/pybind/pybind_variant_caster.h
paddle/fluid/pybind/pybind_variant_caster.h
+4
-0
未找到文件。
paddle/fluid/framework/io/shell.h
浏览文件 @
0e439210
...
@@ -21,6 +21,10 @@
...
@@ -21,6 +21,10 @@
#ifndef NOMINMAX
#ifndef NOMINMAX
#define NOMINMAX // msvc max/min macro conflict with std::min/max
#define NOMINMAX // msvc max/min macro conflict with std::min/max
#endif
#endif
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include <windows.h>
#include <windows.h>
#else
#else
#include <sys/syscall.h>
#include <sys/syscall.h>
...
...
paddle/fluid/pybind/const_value.h
浏览文件 @
0e439210
...
@@ -14,6 +14,10 @@ limitations under the License. */
...
@@ -14,6 +14,10 @@ limitations under the License. */
#pragma once
#pragma once
#include <Python.h>
#include <Python.h>
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include "paddle/fluid/platform/enforce.h"
#include "paddle/fluid/platform/enforce.h"
#include "pybind11/pybind11.h"
#include "pybind11/pybind11.h"
...
...
paddle/fluid/pybind/eager.cc
浏览文件 @
0e439210
...
@@ -12,6 +12,10 @@ limitations under the License. */
...
@@ -12,6 +12,10 @@ limitations under the License. */
#include "paddle/fluid/pybind/eager.h"
#include "paddle/fluid/pybind/eager.h"
#include <Python.h>
#include <Python.h>
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include <string>
#include <string>
#include <vector>
#include <vector>
...
...
paddle/fluid/pybind/eager.h
浏览文件 @
0e439210
...
@@ -11,6 +11,10 @@ limitations under the License. */
...
@@ -11,6 +11,10 @@ limitations under the License. */
#pragma once
#pragma once
#include <Python.h>
#include <Python.h>
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include "paddle/fluid/eager/hooks.h"
#include "paddle/fluid/eager/hooks.h"
#include "paddle/fluid/eager/pylayer/py_layer_node.h"
#include "paddle/fluid/eager/pylayer/py_layer_node.h"
...
...
paddle/fluid/pybind/eager_functions.cc
浏览文件 @
0e439210
...
@@ -16,6 +16,10 @@ typedef SSIZE_T ssize_t;
...
@@ -16,6 +16,10 @@ typedef SSIZE_T ssize_t;
#endif
#endif
#include <Python.h>
#include <Python.h>
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include <string>
#include <string>
#include <vector>
#include <vector>
...
...
paddle/fluid/pybind/eager_math_op_patch.cc
浏览文件 @
0e439210
...
@@ -16,6 +16,10 @@ typedef SSIZE_T ssize_t;
...
@@ -16,6 +16,10 @@ typedef SSIZE_T ssize_t;
#endif
#endif
#include <Python.h>
#include <Python.h>
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include <string>
#include <string>
#include <unordered_map>
#include <unordered_map>
...
...
paddle/fluid/pybind/eager_method.cc
浏览文件 @
0e439210
...
@@ -16,6 +16,10 @@ typedef SSIZE_T ssize_t;
...
@@ -16,6 +16,10 @@ typedef SSIZE_T ssize_t;
#endif
#endif
#include <Python.h>
#include <Python.h>
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include <string>
#include <string>
#include <unordered_map>
#include <unordered_map>
...
...
paddle/fluid/pybind/eager_properties.cc
浏览文件 @
0e439210
...
@@ -10,6 +10,10 @@ See the License for the specific language governing permissions and
...
@@ -10,6 +10,10 @@ See the License for the specific language governing permissions and
limitations under the License. */
limitations under the License. */
// disable numpy compile error
// disable numpy compile error
#include <Python.h>
#include <Python.h>
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include <string>
#include <string>
#include <vector>
#include <vector>
...
...
paddle/fluid/pybind/eager_py_layer.cc
浏览文件 @
0e439210
...
@@ -10,6 +10,10 @@ See the License for the specific language governing permissions and
...
@@ -10,6 +10,10 @@ See the License for the specific language governing permissions and
limitations under the License. */
limitations under the License. */
// disable numpy compile error
// disable numpy compile error
#include <Python.h>
#include <Python.h>
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include <set>
#include <set>
#include <string>
#include <string>
...
...
paddle/fluid/pybind/eager_utils.cc
浏览文件 @
0e439210
...
@@ -12,6 +12,10 @@ limitations under the License. */
...
@@ -12,6 +12,10 @@ limitations under the License. */
#include "paddle/fluid/pybind/eager_utils.h"
#include "paddle/fluid/pybind/eager_utils.h"
#include <Python.h>
#include <Python.h>
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include <string>
#include <string>
#include <vector>
#include <vector>
...
...
paddle/fluid/pybind/eager_utils.h
浏览文件 @
0e439210
...
@@ -16,6 +16,10 @@ typedef SSIZE_T ssize_t;
...
@@ -16,6 +16,10 @@ typedef SSIZE_T ssize_t;
#endif
#endif
#include <Python.h>
#include <Python.h>
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include "paddle/fluid/eager/hooks.h"
#include "paddle/fluid/eager/hooks.h"
#include "paddle/fluid/framework/lod_tensor.h"
#include "paddle/fluid/framework/lod_tensor.h"
...
...
paddle/fluid/pybind/io.h
浏览文件 @
0e439210
...
@@ -20,6 +20,10 @@ typedef SSIZE_T ssize_t;
...
@@ -20,6 +20,10 @@ typedef SSIZE_T ssize_t;
#endif
#endif
#include <Python.h>
#include <Python.h>
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include "paddle/fluid/pybind/pybind_variant_caster.h"
#include "paddle/fluid/pybind/pybind_variant_caster.h"
...
...
paddle/fluid/pybind/protobuf.h
浏览文件 @
0e439210
...
@@ -19,6 +19,10 @@ limitations under the License. */
...
@@ -19,6 +19,10 @@ limitations under the License. */
typedef
SSIZE_T
ssize_t
;
typedef
SSIZE_T
ssize_t
;
#endif
#endif
#include <Python.h>
#include <Python.h>
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include <fstream>
#include <fstream>
#include <vector>
#include <vector>
...
...
paddle/fluid/pybind/pybind_variant_caster.h
浏览文件 @
0e439210
...
@@ -14,6 +14,10 @@ limitations under the License. */
...
@@ -14,6 +14,10 @@ limitations under the License. */
#pragma once
#pragma once
#include <Python.h>
#include <Python.h>
// Avoid a problem with copysign defined in pyconfig.h on Windows.
#ifdef copysign
#undef copysign
#endif
#include <vector>
#include <vector>
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录