-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathBUILD.bazel
56 lines (52 loc) · 1.62 KB
/
BUILD.bazel
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
load("@rules_haskell//haskell:defs.bzl", "haskell_library")
load("//third_party/haskell/hspec-discover:build_defs.bzl", "hspec_test")
load("//tools/project:build_defs.bzl", "project")
project(license = "gpl3-https")
#[genrule(
# name = "api_" + src[:-2].replace("/", "_"),
# srcs = ["//c-toxcore:" + src],
# outs = ["src/FFI/%s.hs" % "/".join([mod.capitalize() for mod in src[:-2].split("/")])],
# cmd = "$(location //hs-apigen/tools:apigen) -hs $< > $@",
# tools = ["//hs-apigen/tools:apigen"],
# tags = ["no-cross"],
# ) for src in [
# "tox/tox.h",
# ]]
haskell_library(
name = "hs-toxcore-c",
srcs = glob(
["src/**/*.*hs"],
#exclude = ["src/FFI/**"],
) + [
#":api_tox_tox",
],
src_strip_prefix = "src",
tags = ["no-cross"],
version = "0.2.19",
visibility = ["//visibility:public"],
deps = [
"//c-toxcore",
"//hs-msgpack-binary",
"//third_party/haskell:QuickCheck",
"//third_party/haskell:base",
"//third_party/haskell:bytestring",
"//third_party/haskell:generic-arbitrary",
"//third_party/haskell:quickcheck-instances",
],
)
hspec_test(
name = "testsuite",
timeout = "short",
deps = [
":hs-toxcore-c",
"//hs-msgpack-binary",
"//third_party/haskell:QuickCheck",
"//third_party/haskell:base",
"//third_party/haskell:base16-bytestring",
"//third_party/haskell:bytestring",
"//third_party/haskell:cryptohash",
"//third_party/haskell:hspec",
"//third_party/haskell:saltine",
"//third_party/haskell:vector",
],
)