-
-
Notifications
You must be signed in to change notification settings - Fork 223
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
resolves #20 use stack to build a statically linked binary of erd
- Loading branch information
1 parent
ac9d499
commit 9b4c510
Showing
5 changed files
with
14 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,17 @@ | ||
# build static executable binary | ||
FROM haskell:8 | ||
FROM ubuntu:18.04 | ||
|
||
RUN apt-get update && apt-get install -y graphviz curl git | ||
|
||
RUN curl -sSL https://get.haskellstack.org/ | sh | ||
|
||
RUN git clone https://github.com/BurntSushi/erd.git | ||
|
||
WORKDIR erd | ||
|
||
# version 0.1.3.0 | ||
RUN git checkout c443372d431a5020afa91989829352a2aa6b07cb | ||
|
||
# use "old" commands on purpose to workaround an issue with static link | ||
RUN cabal update | ||
RUN cabal install --only-dependencies --force-reinstalls | ||
RUN cabal configure --disable-executable-dynamic --disable-shared --ghc-option=-optl=-static \ | ||
&& cabal build | ||
RUN git checkout v0.2.0.0 | ||
|
||
RUN /usr/local/bin/stack install --ghc-options="-fPIC" \ | ||
--ghc-options="-static" \ | ||
--ghc-options="-optl=-static" \ | ||
--ghc-options="-optc=-static" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters