From fc743155b9f45951122a0724cd41ca3053fa5001 Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Sun, 15 Mar 2015 18:50:46 -0700 Subject: [PATCH] tools: make sandbox-links, more build nuttiness --- Makefile | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 375a2b101..cf6f9e39a 100644 --- a/Makefile +++ b/Makefile @@ -176,12 +176,17 @@ defaulttarget: bin/hledgerdev # at least start cabal build in hledger packages, to make cabal include files (dist/build/{Paths_PKG.hs,cabal_macros.h}) (not working with a sandbox) # When done we should be able to make install, repl-{lib,cli,web}, ghci[-web], check etc. -sandbox: .cabal-sandbox +sandbox: .cabal-sandbox sandbox-links .cabal-sandbox: cabal sandbox init cabal sandbox add-source ./hledger-lib ./hledger ./hledger-web +# when using a cabal sandbox, create dist/build symlinks (assumes you +# did cabal build) so that make ghci[-web] works +sandbox-links: + -for p in hledger{-lib,,-web}; do (cd $$p/dist; ln -s dist-*/build); done + # cabal install the main hledger packages and all their dependencies # in the sandbox if any, otherwise in the user's package db install: