diff --git a/BUILD b/BUILD index 4ff18da..ee7950d 100644 --- a/BUILD +++ b/BUILD @@ -52,9 +52,9 @@ cc_library( strip_include_prefix = "src/", visibility = ["//visibility:public"], deps = [ - "//third_party/boost:system", - "//third_party/boost:asio", - "//third_party/boost:date_time" + "@boost//:system", + "@boost//:asio", + "@boost//:date_time", ], ) diff --git a/WORKSPACE b/WORKSPACE index 863fb47..6ac08ea 100644 --- a/WORKSPACE +++ b/WORKSPACE @@ -1 +1,9 @@ workspace(name = "com_github_datasift_served") + +git_repository( + name = "com_github_nelhage_rules_boost", + commit = "72ec09168e5c3a296f667b3d956a853ccd65c8ed", + remote = "https://github.com/nelhage/rules_boost", +) +load("@com_github_nelhage_rules_boost//:boost/boost.bzl", "boost_deps") +boost_deps() diff --git a/third_party/boost/BUILD b/third_party/boost/BUILD deleted file mode 100644 index dab9953..0000000 --- a/third_party/boost/BUILD +++ /dev/null @@ -1,239 +0,0 @@ -licenses(["notice"]) - -boost_path = "upstream" - -load("//third_party/boost:tool.bzl", "boost_library") - -boost_library( - name = "assert", -) - -boost_library( - name = "config", -) - -boost_library( - name = "core", -) - -boost_library( - name = "predef", -) - -boost_library( - name = "system", - srcs = glob([ - boost_path + "/system/src/*.cpp", - ]), - deps = [ - ":assert", - ":config", - ":core", - ":predef", - ], -) - -boost_library( - name = "throw_exception", -) - -boost_library( - name = "detail", -) - -boost_library( - name = "functional", - deps = [ - ":detail", - ], -) - -boost_library( - name = "io", -) - -boost_library( - name = "static_assert", -) - -boost_library( - name = "iterator", - deps = [ - ":detail", - ":static_assert", - ], -) - -boost_library( - name = "concept_check", -) - -boost_library( - name = "optional", -) - -boost_library( - name = "range", - deps = [ - ":concept_check", - ":optional", - ] -) - -boost_library( - name = "align", -) - -boost_library( - name = "utility", -) - -boost_library( - name = "smart_ptr", - deps = [ - ":align", - ":core", - ":predef", - ":throw_exception", - ":utility", - ], -) - -boost_library( - name = "preprocessor", -) - -boost_library( - name = "move", -) - -boost_library( - name = "mpl", - deps = [ - ":preprocessor", - ":move", - ] -) - -boost_library( - name = "type_traits", - deps = [ - ":core", - ":mpl", - ":static_assert", - ] -) - -boost_library( - name = "bind", -) - -boost_library( - name = "function", -) - -boost_library( - name = "algorithm", - deps = [ - ":function", - ":range", - ] -) - -boost_library( - name = "numeric_conversion", -) - -boost_library( - name = "array", -) - -boost_library( - name = "container", -) - -boost_library( - name = "math", -) - -boost_library( - name = "lexical_cast", - deps = [ - ":numeric_conversion", - ":container", - ":array", - ":math", - ] -) - -boost_library( - name = "tokenizer", -) - -boost_library( - name = "date_time", - deps = [ - ":smart_ptr", - ":static_assert", - ":mpl", - ":type_traits", - ":tokenizer", - ":bind", - ":algorithm", - ":iterator", - ":lexical_cast", - ":io", - ], -) - -boost_library( - name = "filesystem", - srcs = glob([ - boost_path + "/filesystem/src/*.cpp", - ]), - deps = [ - ":config", - ":functional", - ":io", - ":iterator", - ":range", - ":smart_ptr", - ":system", - ":type_traits", - ], -) - -boost_library( - name = "integer", -) - -boost_library( - name = "regex", - defines = [ - "BOOST_FALLTHROUGH" - ], - srcs = glob([ - boost_path + "/regex/src/*.cpp", - boost_path + "/regex/src/*.hpp", - ]), - deps = [ - ":assert", - ":config", - ":functional", - ":integer", - ":mpl", - ":smart_ptr", - ":throw_exception", - ":type_traits", - ] -) - -boost_library( - name = "asio", - deps = [ - ":throw_exception", - ":system", - ":regex", - ] -) - diff --git a/third_party/boost/tool.bzl b/third_party/boost/tool.bzl deleted file mode 100644 index a104ead..0000000 --- a/third_party/boost/tool.bzl +++ /dev/null @@ -1,55 +0,0 @@ -def _is_library( is_library = False ): - if is_library: - include_path = "@boost/include" - library_path = "@boost/lib" - includes_pattern = include_path + "/%s/" - include_pattern1 = includes_pattern + "**/*.h" - include_pattern2 = includes_pattern + "**/*pp" # hpp and ipp - else: - includes_pattern = "upstream/%s/include" - include_pattern1 = includes_pattern + "/boost/**/*.h" - include_pattern2 = includes_pattern + "/boost/**/*pp" - - return includes_pattern, include_pattern1, include_pattern2 - -def includes_list( library_name ): - includes_pattern, include_pattern1, include_pattern2 = _is_library() - return [ includes_pattern % library_name ] - -def hdr_list( library_name ): - includes_pattern, include_pattern1, include_pattern2 = _is_library() - return native.glob([ - include_pattern1 % library_name, - include_pattern2 % library_name, - ]) - -def boost_library( name, defines=None, includes=None, hdrs=None, srcs=None, deps=None, copts=None ): - - if defines == None: - defines = [] - - if includes == None: - includes = [] - - if hdrs == None: - hdrs = [] - - if srcs == None: - srcs = [] - - if deps == None: - deps = [] - - if copts == None: - copts = [] - - return native.cc_library( - name = name, - visibility = ["//visibility:public"], - defines = defines, - includes = includes_list(name) + includes, - hdrs = hdr_list(name) + hdrs, - srcs = [] + srcs, - deps = deps, - copts = copts, -) diff --git a/third_party/boost/upstream/algorithm b/third_party/boost/upstream/algorithm deleted file mode 160000 index e5ea93b..0000000 --- a/third_party/boost/upstream/algorithm +++ /dev/null @@ -1 +0,0 @@ -Subproject commit e5ea93bab1bfe66917ee52944619ad8cee9a0a85 diff --git a/third_party/boost/upstream/align b/third_party/boost/upstream/align deleted file mode 160000 index 5c1da00..0000000 --- a/third_party/boost/upstream/align +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 5c1da00200aef15ed70417cda3c82bfce0e27ab8 diff --git a/third_party/boost/upstream/array b/third_party/boost/upstream/array deleted file mode 160000 index 9678f6a..0000000 --- a/third_party/boost/upstream/array +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 9678f6aa3bee620a91d536cdba92bf0d4b7e02fc diff --git a/third_party/boost/upstream/asio b/third_party/boost/upstream/asio deleted file mode 160000 index 7041bc9..0000000 --- a/third_party/boost/upstream/asio +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 7041bc96db2574e2cb9aea614217cbc6dd0ea863 diff --git a/third_party/boost/upstream/assert b/third_party/boost/upstream/assert deleted file mode 160000 index 066d893..0000000 --- a/third_party/boost/upstream/assert +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 066d8933c4061fb865210de71b4df16839bc1c8d diff --git a/third_party/boost/upstream/bind b/third_party/boost/upstream/bind deleted file mode 160000 index 4300db5..0000000 --- a/third_party/boost/upstream/bind +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 4300db5db83be5804785b4bf581f9abbcb193caf diff --git a/third_party/boost/upstream/concept_check b/third_party/boost/upstream/concept_check deleted file mode 160000 index 504ea0b..0000000 --- a/third_party/boost/upstream/concept_check +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 504ea0b18d02e32c223ec8cbaa036806e3ffe6e3 diff --git a/third_party/boost/upstream/config b/third_party/boost/upstream/config deleted file mode 160000 index 84f2fb1..0000000 --- a/third_party/boost/upstream/config +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 84f2fb19d1ffe076e5d3aaca86547569a676b97b diff --git a/third_party/boost/upstream/container b/third_party/boost/upstream/container deleted file mode 160000 index 3e82a27..0000000 --- a/third_party/boost/upstream/container +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 3e82a27917976e4941b8cde484a14a345ac22d58 diff --git a/third_party/boost/upstream/core b/third_party/boost/upstream/core deleted file mode 160000 index f816536..0000000 --- a/third_party/boost/upstream/core +++ /dev/null @@ -1 +0,0 @@ -Subproject commit f81653660ba15d21e0f6fc9db122bb9582b85bad diff --git a/third_party/boost/upstream/date_time b/third_party/boost/upstream/date_time deleted file mode 160000 index 6cad962..0000000 --- a/third_party/boost/upstream/date_time +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 6cad962159fd25b92e8de88c61c6fcab8c1028a1 diff --git a/third_party/boost/upstream/detail b/third_party/boost/upstream/detail deleted file mode 160000 index e9c548e..0000000 --- a/third_party/boost/upstream/detail +++ /dev/null @@ -1 +0,0 @@ -Subproject commit e9c548eeb513a081e8dc34306821c3e1135c7573 diff --git a/third_party/boost/upstream/filesystem b/third_party/boost/upstream/filesystem deleted file mode 160000 index 26540a5..0000000 --- a/third_party/boost/upstream/filesystem +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 26540a5338240ca0fae31dba432ff654c0ca93c4 diff --git a/third_party/boost/upstream/function b/third_party/boost/upstream/function deleted file mode 160000 index 42f2a7c..0000000 --- a/third_party/boost/upstream/function +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 42f2a7c714a2c1254b0eb77c9fea870a47f32e80 diff --git a/third_party/boost/upstream/functional b/third_party/boost/upstream/functional deleted file mode 160000 index df98d4f..0000000 --- a/third_party/boost/upstream/functional +++ /dev/null @@ -1 +0,0 @@ -Subproject commit df98d4fd1ca9d8842da2653fb235ee3dcb2d5e73 diff --git a/third_party/boost/upstream/integer b/third_party/boost/upstream/integer deleted file mode 160000 index 14020f6..0000000 --- a/third_party/boost/upstream/integer +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 14020f6f6c99891aac407618f0c19d383524f02d diff --git a/third_party/boost/upstream/io b/third_party/boost/upstream/io deleted file mode 160000 index 5458fd8..0000000 --- a/third_party/boost/upstream/io +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 5458fd86d5a8e667513d34ea50b18883eae5ea14 diff --git a/third_party/boost/upstream/iterator b/third_party/boost/upstream/iterator deleted file mode 160000 index 22dd100..0000000 --- a/third_party/boost/upstream/iterator +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 22dd100dfded2e8e450b8a079ff2b482f46a9ccc diff --git a/third_party/boost/upstream/lexical_cast b/third_party/boost/upstream/lexical_cast deleted file mode 160000 index 87afdf5..0000000 --- a/third_party/boost/upstream/lexical_cast +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 87afdf53c065c4003fe57caeae6c2d3c6d00f732 diff --git a/third_party/boost/upstream/math b/third_party/boost/upstream/math deleted file mode 160000 index 8a18159..0000000 --- a/third_party/boost/upstream/math +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 8a1815902fde572dab505a371edc7ad7ef53ecb0 diff --git a/third_party/boost/upstream/move b/third_party/boost/upstream/move deleted file mode 160000 index 1a66e24..0000000 --- a/third_party/boost/upstream/move +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 1a66e24fa422f8550e2cecb5193217eb58f7007f diff --git a/third_party/boost/upstream/mpl b/third_party/boost/upstream/mpl deleted file mode 160000 index f023a68..0000000 --- a/third_party/boost/upstream/mpl +++ /dev/null @@ -1 +0,0 @@ -Subproject commit f023a68f786652749a0809584af1f205f0c2c820 diff --git a/third_party/boost/upstream/numeric_conversion b/third_party/boost/upstream/numeric_conversion deleted file mode 160000 index f4c6bd9..0000000 --- a/third_party/boost/upstream/numeric_conversion +++ /dev/null @@ -1 +0,0 @@ -Subproject commit f4c6bd971154449e9c76f3f0573799cea772d70a diff --git a/third_party/boost/upstream/optional b/third_party/boost/upstream/optional deleted file mode 160000 index a421444..0000000 --- a/third_party/boost/upstream/optional +++ /dev/null @@ -1 +0,0 @@ -Subproject commit a4214447884876950a076f805405c0da63424a84 diff --git a/third_party/boost/upstream/predef b/third_party/boost/upstream/predef deleted file mode 160000 index 1e8d1c2..0000000 --- a/third_party/boost/upstream/predef +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 1e8d1c2cfcac343305e2182f665742b9e38f7452 diff --git a/third_party/boost/upstream/preprocessor b/third_party/boost/upstream/preprocessor deleted file mode 160000 index c2beb74..0000000 --- a/third_party/boost/upstream/preprocessor +++ /dev/null @@ -1 +0,0 @@ -Subproject commit c2beb74b90969f369c62d0dea68aa5f0e203268e diff --git a/third_party/boost/upstream/range b/third_party/boost/upstream/range deleted file mode 160000 index 0e931f4..0000000 --- a/third_party/boost/upstream/range +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 0e931f4a80521acb00ff76c03237b0804b2cc572 diff --git a/third_party/boost/upstream/regex b/third_party/boost/upstream/regex deleted file mode 160000 index d84bab7..0000000 --- a/third_party/boost/upstream/regex +++ /dev/null @@ -1 +0,0 @@ -Subproject commit d84bab7c4d36141b860b4b4c43ec43a21c17fd87 diff --git a/third_party/boost/upstream/smart_ptr b/third_party/boost/upstream/smart_ptr deleted file mode 160000 index 83e6e00..0000000 --- a/third_party/boost/upstream/smart_ptr +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 83e6e00456493eb94b7aed44a6bafb354ad5400e diff --git a/third_party/boost/upstream/static_assert b/third_party/boost/upstream/static_assert deleted file mode 160000 index 87f3be4..0000000 --- a/third_party/boost/upstream/static_assert +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 87f3be4a8fe6fa32646aa01782dda29e6eeb0b4c diff --git a/third_party/boost/upstream/system b/third_party/boost/upstream/system deleted file mode 160000 index e5da5ce..0000000 --- a/third_party/boost/upstream/system +++ /dev/null @@ -1 +0,0 @@ -Subproject commit e5da5ce2cfef69630687434b292507af9fda83d9 diff --git a/third_party/boost/upstream/throw_exception b/third_party/boost/upstream/throw_exception deleted file mode 160000 index c89a2db..0000000 --- a/third_party/boost/upstream/throw_exception +++ /dev/null @@ -1 +0,0 @@ -Subproject commit c89a2db1122302e90ebad9cec0b49d77283a6566 diff --git a/third_party/boost/upstream/tokenizer b/third_party/boost/upstream/tokenizer deleted file mode 160000 index 1d204ae..0000000 --- a/third_party/boost/upstream/tokenizer +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 1d204ae9798edf38caf7e6107099c5edff905a3c diff --git a/third_party/boost/upstream/type_traits b/third_party/boost/upstream/type_traits deleted file mode 160000 index 01f41ec..0000000 --- a/third_party/boost/upstream/type_traits +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 01f41ec30e9b4d509e8112b80e3ee463b1186a70 diff --git a/third_party/boost/upstream/utility b/third_party/boost/upstream/utility deleted file mode 160000 index 3982b6d..0000000 --- a/third_party/boost/upstream/utility +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 3982b6d633708849f392434b9b42ba74e2e37170