From 22e5e52598cfdc8e3578de6fe76e33ade4f03207 Mon Sep 17 00:00:00 2001 From: Thomas Pointhuber Date: Sun, 5 Aug 2018 12:28:10 +0200 Subject: [PATCH] Fix warning: 'HAVE_CLOCK_GETTIME' macro redefined --- pcbnew/dialogs/dialog_scripting.cpp | 2 ++ pcbnew/swig/pcbnew_action_plugins.h | 4 ++++ pcbnew/swig/pcbnew_footprint_wizards.h | 4 ++++ pcbnew/swig/pcbnew_scripting_helpers.cpp | 1 + pcbnew/swig/python_scripting.h | 3 +++ 5 files changed, 14 insertions(+) diff --git a/pcbnew/dialogs/dialog_scripting.cpp b/pcbnew/dialogs/dialog_scripting.cpp index 350ca933c0..25beb5d36a 100644 --- a/pcbnew/dialogs/dialog_scripting.cpp +++ b/pcbnew/dialogs/dialog_scripting.cpp @@ -28,6 +28,8 @@ #include +#undef HAVE_CLOCK_GETTIME // macro is defined in Python.h and causes redefine warning + #include #include #include diff --git a/pcbnew/swig/pcbnew_action_plugins.h b/pcbnew/swig/pcbnew_action_plugins.h index a1d6d9ff0e..3a56b5e9e8 100644 --- a/pcbnew/swig/pcbnew_action_plugins.h +++ b/pcbnew/swig/pcbnew_action_plugins.h @@ -28,7 +28,11 @@ #ifndef PCBNEW_ACTION_PLUGINS_H #define PCBNEW_ACTION_PLUGINS_H + +#undef HAVE_CLOCK_GETTIME // macro is defined in Python.h and causes redefine warning #include +#undef HAVE_CLOCK_GETTIME + #include #include diff --git a/pcbnew/swig/pcbnew_footprint_wizards.h b/pcbnew/swig/pcbnew_footprint_wizards.h index 70a41b7286..f102e832b3 100644 --- a/pcbnew/swig/pcbnew_footprint_wizards.h +++ b/pcbnew/swig/pcbnew_footprint_wizards.h @@ -29,7 +29,11 @@ #ifndef PCBNEW_FOOTPRINT_WIZARDS_H #define PCBNEW_FOOTPRINT_WIZARDS_H + +#undef HAVE_CLOCK_GETTIME // macro is defined in Python.h and causes redefine warning #include +#undef HAVE_CLOCK_GETTIME + #include #include diff --git a/pcbnew/swig/pcbnew_scripting_helpers.cpp b/pcbnew/swig/pcbnew_scripting_helpers.cpp index 1b4a2fc6b5..85a95f4dcd 100644 --- a/pcbnew/swig/pcbnew_scripting_helpers.cpp +++ b/pcbnew/swig/pcbnew_scripting_helpers.cpp @@ -28,6 +28,7 @@ */ #include +#undef HAVE_CLOCK_GETTIME // macro is defined in Python.h and causes redefine warning #include #include diff --git a/pcbnew/swig/python_scripting.h b/pcbnew/swig/python_scripting.h index b1517c9479..927edbf4bf 100644 --- a/pcbnew/swig/python_scripting.h +++ b/pcbnew/swig/python_scripting.h @@ -33,7 +33,10 @@ #undef _XOPEN_SOURCE #endif +#undef HAVE_CLOCK_GETTIME // macro is defined in Python.h and causes redefine warning #include +#undef HAVE_CLOCK_GETTIME + #ifndef NO_WXPYTHON_EXTENSION_HEADERS #ifdef KICAD_SCRIPTING_WXPYTHON #include