From 0f3409951329e6edba6d61429ec703c35cf10e58 Mon Sep 17 00:00:00 2001 From: wmayer Date: Sat, 10 May 2014 14:12:25 +0200 Subject: [PATCH] + add '_' as prefix for PartDesign module to fix name clash --- src/Mod/PartDesign/App/AppPartDesign.cpp | 4 ++-- src/Mod/PartDesign/App/CMakeLists.txt | 2 +- src/Mod/PartDesign/__init__.py | 5 +++-- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/Mod/PartDesign/App/AppPartDesign.cpp b/src/Mod/PartDesign/App/AppPartDesign.cpp index ace223d465..7a8efe1c98 100644 --- a/src/Mod/PartDesign/App/AppPartDesign.cpp +++ b/src/Mod/PartDesign/App/AppPartDesign.cpp @@ -58,7 +58,7 @@ PyDoc_STRVAR(module_PartDesign_doc, /* Python entry */ extern "C" { -void PartDesignExport initPartDesign() +void PartDesignExport init_PartDesign() { // load dependent module try { @@ -69,7 +69,7 @@ void PartDesignExport initPartDesign() PyErr_SetString(PyExc_ImportError, e.what()); return; } - Py_InitModule3("PartDesign", PartDesign_methods, module_PartDesign_doc); /* mod name, table ptr */ + Py_InitModule3("_PartDesign", PartDesign_methods, module_PartDesign_doc); /* mod name, table ptr */ Base::Console().Log("Loading PartDesign module... done\n"); diff --git a/src/Mod/PartDesign/App/CMakeLists.txt b/src/Mod/PartDesign/App/CMakeLists.txt index 544e971844..783fa3036a 100644 --- a/src/Mod/PartDesign/App/CMakeLists.txt +++ b/src/Mod/PartDesign/App/CMakeLists.txt @@ -128,7 +128,7 @@ fc_target_copy_resource(PartDesign ${CMAKE_BINARY_DIR}/Mod/PartDesign ${PartDesign_Scripts}) -SET_BIN_DIR(PartDesign PartDesign /Mod/PartDesign) +SET_BIN_DIR(PartDesign _PartDesign /Mod/PartDesign) SET_PYTHON_PREFIX_SUFFIX(PartDesign) INSTALL(TARGETS PartDesign DESTINATION ${CMAKE_INSTALL_LIBDIR}) diff --git a/src/Mod/PartDesign/__init__.py b/src/Mod/PartDesign/__init__.py index 6c19fb5af6..29a70ae509 100644 --- a/src/Mod/PartDesign/__init__.py +++ b/src/Mod/PartDesign/__init__.py @@ -1,2 +1,3 @@ -import Scripts.FilletArc -makeFilletArc = Scripts.FilletArc.makeFilletArc +import _PartDesign +makeFilletArc = _PartDesign.makeFilletArc +