INNER CODE UNIT · Python

build_cmake

andrewssobral/bgslibrary · setup.py:155

    def build_cmake(self, extension):
        """
        The steps required to build the extension
        """
        self.announce("Preparing the build environment", level=3)
        build_dir = os.path.join(self.build_temp)
        extension_path = os.path.abspath(os.path.dirname(self.get_ext_fullpath(extension.name)))
        os.makedirs(build_dir)
        os.makedirs(extension_path)
        python_version = str(sys.version_info[0]) + "." + str(sys.version_info[1])

        # Now that the necessary directories are created, build
        self.announce("Configuring cmake project", level=3)
        cmake_args = ['-DPYTHON_EXECUTABLE=' + sys.executable,
                      '-DBGS_CORE_STATIC=ON',
                      '-DBGS_PYTHON_SUPPORT=ON',
                      '-DBGS_PYTHON_ONLY=ON',
                      '-DBGS_PYTHON_VERSION=' + python_version]

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…