diff --git a/Makefile b/Makefile index ceba9b9..b2ebd10 100644 --- a/Makefile +++ b/Makefile @@ -94,8 +94,8 @@ clean-docs: # ====================================== makefile-build: $(MAKE) -C src/pEp/_pEp - $(MAKE) -C src/pEp/_pybind + $(MAKE) -C src/pEp/_gen makefile-clean: $(MAKE) -C src/pEp/_pEp clean - $(MAKE) -C src/pEp/_pybind clean + $(MAKE) -C src/pEp/_gen clean diff --git a/setup.py b/setup.py index b4530a0..73fb16e 100755 --- a/setup.py +++ b/setup.py @@ -174,11 +174,11 @@ class BuildExtCommand(build_ext): module_pEp.libraries = libs module_pEp.extra_compile_args = compile_flags - global module_pybind11 - module_pybind11.include_dirs = includes - module_pybind11.library_dirs = libdirs - # module_pybind11.libraries = libs - module_pybind11.extra_compile_args = compile_flags + global module_gen + module_gen.include_dirs = includes + module_gen.library_dirs = libdirs + # module_gen.libraries = libs + module_gen.extra_compile_args = compile_flags pEpLog("Include Dirs:", module_pEp.include_dirs) pEpLog("Libs Dirs:", module_pEp.library_dirs) @@ -212,10 +212,10 @@ module_pEp = Extension( ], ) -module_pybind11 = Extension( - 'pEp._pybind', +module_gen = Extension( + 'pEp._gen', sources=[ - 'src/pEp/_pybind/pEpmodule.cc', + 'src/pEp/_gen/pEpmodule.cc', ], ) @@ -224,7 +224,7 @@ module_pybind11 = Extension( setup( package_dir={'': 'src'}, packages=['pEp'], - ext_modules=[module_pEp, module_pybind11], + ext_modules=[module_pEp, module_gen], cmdclass={ 'build_ext': BuildExtCommand, }, diff --git a/src/pEp/Makefile.conf b/src/pEp/Makefile.conf index 9461ade..11d94f4 100644 --- a/src/pEp/Makefile.conf +++ b/src/pEp/Makefile.conf @@ -2,7 +2,7 @@ HERE:=$(dir $(lastword $(MAKEFILE_LIST))) -include $(HERE)../../local.conf TARGET_PEP=_pEp.so -TARGET_PYBIND=_pybind.so +TARGET_GEN=_gen.so # General Build settings CXX=g++ diff --git a/src/pEp/__init__.py b/src/pEp/__init__.py index a49f529..eca5412 100755 --- a/src/pEp/__init__.py +++ b/src/pEp/__init__.py @@ -25,12 +25,12 @@ except ImportError: # Imports all symbols EXCEPT the ones beginning with underscore from ._pEp import * -from ._pybind import * +from ._gen import * # import the native module into the current namespace because we also need to access the names beginning # with an underscore (of _pEp), but we dont want to import them into this module import pEp._pEp -import pEp._pybind +import pEp._gen # Executed on module import def init(): diff --git a/src/pEp/_pybind/Makefile b/src/pEp/_gen/Makefile similarity index 94% rename from src/pEp/_pybind/Makefile rename to src/pEp/_gen/Makefile index e28eded..9c18dc3 100644 --- a/src/pEp/_pybind/Makefile +++ b/src/pEp/_gen/Makefile @@ -1,5 +1,5 @@ include ../Makefile.conf -TARGET=$(TARGET_PYBIND) +TARGET=$(TARGET_GEN) # Specific Build settings CXXFLAGS+= diff --git a/src/pEp/_pybind/pEpModule.cc b/src/pEp/_gen/pEpModule.cc similarity index 89% rename from src/pEp/_pybind/pEpModule.cc rename to src/pEp/_gen/pEpModule.cc index de0b79d..1286a29 100644 --- a/src/pEp/_pybind/pEpModule.cc +++ b/src/pEp/_gen/pEpModule.cc @@ -7,7 +7,7 @@ string testfunc() { return "fsdfg"; } -PYBIND11_MODULE(_pybind, m) { +PYBIND11_MODULE(_gen, m) { m.doc() = "pybind11 example plugin"; // optional module docstring m.def("add", &testfunc, "A function which adds two numbers"); }