当前位置: 首页>>代码示例>>Python>>正文


Python CMake.definitions["vcl_ext_glew"]方法代码示例

本文整理汇总了Python中conans.CMake.definitions["vcl_ext_glew"]方法的典型用法代码示例。如果您正苦于以下问题:Python CMake.definitions["vcl_ext_glew"]方法的具体用法?Python CMake.definitions["vcl_ext_glew"]怎么用?Python CMake.definitions["vcl_ext_glew"]使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在conans.CMake的用法示例。


在下文中一共展示了CMake.definitions["vcl_ext_glew"]方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: build

# 需要导入模块: from conans import CMake [as 别名]
# 或者: from conans.CMake import definitions["vcl_ext_glew"] [as 别名]
    def build(self):
        cmake = CMake(self)
        # Configure which parts to build
        cmake.definitions["VCL_BUILD_BENCHMARKS"] = False
        cmake.definitions["VCL_BUILD_TESTS"] = False
        cmake.definitions["VCL_BUILD_TOOLS"] = False
        cmake.definitions["VCL_BUILD_EXAMPLES"] = False
        # Support multi-package configuration
        #cmake.definitions["CMAKE_DEBUG_POSTFIX"] = "_d"
        # Configure features
        cmake.definitions["VCL_VECTORIZE"] = str(self.options.vectorization)
        cmake.definitions["VCL_OPENGL_SUPPORT"] = True
        if self.settings.os != "Windows":
            cmake.definitions["CMAKE_POSITION_INDEPENDENT_CODE"] = self.options.fPIC
        # Configure external targets
        cmake.definitions["vcl_ext_absl"] = "CONAN_PKG::abseil"
        cmake.definitions["vcl_ext_eigen"] = "CONAN_PKG::eigen"
        cmake.definitions["vcl_ext_fmt"] = "CONAN_PKG::fmt"
        cmake.definitions["vcl_ext_glew"] = "CONAN_PKG::glew"
        cmake.configure(source_dir=self.source_folder + "/src/")

        if cmake.is_multi_configuration:
            cmake.build(target="vcl_core",     args=["--config","Debug"])
            cmake.build(target="vcl_geometry", args=["--config","Debug"])
            cmake.build(target="vcl_graphics", args=["--config","Debug"])
            cmake.build(target="vcl_math",     args=["--config","Debug"])
            cmake.build(target="vcl_core",     args=["--config","Release"])
            cmake.build(target="vcl_geometry", args=["--config","Release"])
            cmake.build(target="vcl_graphics", args=["--config","Release"])
            cmake.build(target="vcl_math",     args=["--config","Release"])
        else:
            cmake.build(target="vcl_core")
            cmake.build(target="vcl_geometry")
            cmake.build(target="vcl_graphics")
            cmake.build(target="vcl_math")
开发者ID:bfierz,项目名称:vcl,代码行数:37,代码来源:conanfile.py


注:本文中的conans.CMake.definitions["vcl_ext_glew"]方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。