Skip to content

Commit

Permalink
Replace Hazel by stack_snapshot (digital-asset#2743)
Browse files Browse the repository at this point in the history
* Unmangled libz.so and libbz2.so

* Use stack_snapshot instead of Hazel

* Remove Hazel

* Define stack_snapshot

* Update rules_haskell

* Document stack_snapshot

* Clean stack's lock file from aborted builds
  • Loading branch information
aherrmann-da authored and mergify[bot] committed Nov 22, 2019
1 parent 0ff716d commit f4d0eb6
Show file tree
Hide file tree
Showing 41 changed files with 851 additions and 15,807 deletions.
5 changes: 0 additions & 5 deletions 3rdparty/README.md

This file was deleted.

26 changes: 19 additions & 7 deletions 3rdparty/c/bzip2.BUILD
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
package(default_visibility = ["//visibility:public"])

cc_library(
name = "libbz2",
# Import `:bz2` as `srcs` to enforce the library name `libbz2.so`.
# Othwerwise, Bazel would mangle the library name and e.g. Cabal
# wouldn't recognize it.
srcs = [":bz2"],
hdrs = [":headers"],
includes = ["."],
linkstatic = 1,
visibility = ["//visibility:public"],
)

cc_library(
name = "bz2",
srcs = [
Expand All @@ -11,14 +23,14 @@ cc_library(
"huffman.c",
"randtable.c",
],
hdrs = [
hdrs = [":headers"],
includes = ["."],
)

filegroup(
name = "headers",
srcs = [
"bzlib.h",
"bzlib_private.h",
],
includes = [
".",
],
visibility = [
"//visibility:public",
],
)
42 changes: 14 additions & 28 deletions 3rdparty/c/zlib.BUILD
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
package(default_visibility = ["//visibility:public"])

cc_library(
name = "libz",
# Import `:z` as `srcs` to enforce the library name `libz.so`.
# Othwerwise, Bazel would mangle the library name and e.g. Cabal
# wouldn't recognize it.
srcs = [":z"],
hdrs = [":headers"],
includes = ["."],
linkstatic = 1,
visibility = ["//visibility:public"],
)

cc_library(
name = "z",
srcs = [
Expand All @@ -15,34 +27,8 @@ cc_library(
"uncompr.c",
"zutil.c",
],
hdrs = [
"crc32.h",
"deflate.h",
"gzguts.h",
"inffast.h",
"inffixed.h",
"inflate.h",
"inftrees.h",
"trees.h",
"zconf.h",
"zlib.h",
"zutil.h",
],
includes = [
".",
],
visibility = [
"//visibility:public",
],
)

# filegroups for library and headers, to
# be passed to hazel_repositories.

filegroup(
name = "lib",
srcs = [":z"],
output_group = "dynamic_library",
hdrs = [":headers"],
includes = ["."],
)

filegroup(
Expand Down
7 changes: 0 additions & 7 deletions 3rdparty/haskell/BUILD

This file was deleted.

18 changes: 0 additions & 18 deletions 3rdparty/haskell/BUILD.bindings-DSL

This file was deleted.

56 changes: 0 additions & 56 deletions 3rdparty/haskell/BUILD.clock

This file was deleted.

96 changes: 0 additions & 96 deletions 3rdparty/haskell/BUILD.ghc-lib-parser

This file was deleted.

Loading

0 comments on commit f4d0eb6

Please sign in to comment.