Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/ci-getdeps.yml
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,10 @@ jobs:
make setup-folly
make setup-folly-version

- name: Setup cabal.project
run: |
ln -s cabal-github.project cabal.project

- name: Populate hackage index
run: cabal update

Expand Down
7 changes: 5 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -183,10 +183,13 @@ setup-folly::
.PHONY: setup-folly-version setup-folly-0
ver:=$(shell cd folly-clib/folly && date -u "--date=@$$(git log -1 --format=%ct)" +%Y%m%d.%-k%M | sed 's/\.0*/\./')
setup-folly-version::
sed -i "s/^version:\(\s*\).*$$/version:\1$(ver)/" folly-clib/folly-clib.cabal
sed -i "s/^version:\(\s*\).*$$/version:\1$(ver)/" folly-clib/folly-clib.cabal
sed -i "s/^\(\s*\)build-depends:\(\s*\)folly-clib\s*$$/\1build-depends: folly-clib==$(ver)/" common/util/fb-util.cabal

# Make version 0.0 of folly-clib, the empty package
setup-folly-0::
sed "s|__CPP_FILES__||;s|__H_FILES__||" <folly-clib/folly-clib.cabal.in | grep -v '^\s*install-includes' | grep -v '\.h$$' >folly-clib/folly-clib.cabal
sed -i "s/^version:\(\s*\).*$$/version:\10.0/" folly-clib/folly-clib.cabal
sed -i "s/^version:\(\s*\).*$$/version:\10.0/" folly-clib/folly-clib.cabal

setup-meta::
ln -s cabal-meta.project cabal.project
3 changes: 2 additions & 1 deletion build/fbcode_builder/manifests/hsthrift
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ boost
builder = make

[make.build_args]
setup-folly-0
setup-folly
setup-meta
cabal-update
all

Expand Down
File renamed without changes.
23 changes: 23 additions & 0 deletions cabal-meta.project
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
-- Copyright (c) Facebook, Inc. and its affiliates.

packages:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

might be able to avoid the copy/paste by using include

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

leaving that for future work

folly-clib/folly-clib.cabal
common/util/fb-util.cabal
common/github/fb-stubs.cabal
common/mangle/mangle.cabal
lib/thrift-lib.cabal
server/thrift-server.cabal
compiler/thrift-compiler.cabal
tests/thrift-tests.cabal
haxl/thrift-haxl.cabal
cpp-channel/thrift-cpp-channel.cabal
http/thrift-http.cabal

package fb-util
flags: +folly
package folly-clib
flags: -bundled-folly
package thrift-tests
flags: -fbthrift

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why is this needed? I would hope the fbthrift tests should pass, since we have fbthrift.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cabal build fails


tests: true