conanfile.py 2.3 KB
Newer Older
E
Enwei Jiao 已提交
1 2 3 4 5 6 7 8
from conans import ConanFile, CMake


class MilvusConan(ConanFile):

    settings = "os", "compiler", "build_type", "arch"
    requires = (
        "rocksdb/6.29.5",
E
Enwei Jiao 已提交
9
        "boost/1.81.0",
E
Enwei Jiao 已提交
10 11
        "onetbb/2021.7.0",
        "zstd/1.5.2",
E
Enwei Jiao 已提交
12 13 14
        "lz4/1.9.4",
        "snappy/1.1.9",
        "lzo/2.10",
E
Enwei Jiao 已提交
15 16 17 18 19
        "arrow/8.0.1",
        "openssl/1.1.1q",
        "aws-sdk-cpp/1.9.234",
        "benchmark/1.7.0",
        "gtest/1.8.1",
E
Enwei Jiao 已提交
20
        "protobuf/3.21.9",
E
Enwei Jiao 已提交
21 22 23 24
        "rapidxml/1.13",
        "yaml-cpp/0.7.0",
        "marisa/0.2.6",
        "zlib/1.2.13",
25
        "libcurl/7.86.0",
E
Enwei Jiao 已提交
26 27 28 29 30 31 32 33 34 35 36 37 38
        "glog/0.6.0",
        "fmt/8.0.1",
        "gflags/2.2.2",
        "double-conversion/3.2.1",
        "libevent/2.1.12",
        "libdwarf/20191104",
        "libiberty/9.1.0",
        "libsodium/cci.20220430",
        "bison/3.5.3",
        "flex/2.6.4",
        "xsimd/9.0.1",
        "folly/2022.10.31.01@milvus/dev",
        "velox/2023.02.07.01@milvus/dev",
E
Enwei Jiao 已提交
39
    )
40
    generators = ("cmake", "cmake_find_package")
E
Enwei Jiao 已提交
41 42 43 44 45
    default_options = {
        "rocksdb:shared": True,
        "arrow:parquet": True,
        "arrow:compute": True,
        "arrow:with_zstd": True,
J
jaime 已提交
46 47
        "arrow:shared": False,
        "arrow:with_jemalloc": True,
E
Enwei Jiao 已提交
48 49 50
        "aws-sdk-cpp:text-to-speech": False,
        "aws-sdk-cpp:transfer": False,
        "gtest:build_gmock": False,
E
Enwei Jiao 已提交
51
        "folly:use_sse4_2": True,
E
Enwei Jiao 已提交
52 53
    }

E
Enwei Jiao 已提交
54 55
    def configure(self):
        # Macos M1 cannot use jemalloc
E
Enwei Jiao 已提交
56 57
        if self.settings.os == "Macos":
            if self.settings.arch not in ("x86_64", "x86"):
E
Enwei Jiao 已提交
58 59 60
                del self.options["folly"].use_sse4_2

            self.options["arrow"].with_jemalloc = False
E
Enwei Jiao 已提交
61 62 63 64 65 66 67 68 69
            self.options["boost"].without_fiber = True
            self.options["boost"].without_json = True
            self.options["boost"].without_wave = True
            self.options["boost"].without_math = True
            self.options["boost"].without_graph = True
            self.options["boost"].without_graph_parallel = True
            self.options["boost"].without_nowide = True
            self.options["boost"].without_locale = True
            self.options["boost"].without_url = True
E
Enwei Jiao 已提交
70

E
Enwei Jiao 已提交
71 72 73 74 75
    def imports(self):
        self.copy("*.dylib", "../lib", "lib")
        self.copy("*.dll", "../lib", "lib")
        self.copy("*.so*", "../lib", "lib")
        self.copy("*", "../bin", "bin")