new make dev target

rename old to make prof
This commit is contained in:
Joey Hess 2023-09-15 08:10:32 -04:00
parent 6472da265b
commit 9d2e8e2caa
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38

View file

@ -43,12 +43,16 @@ tmp/configure-stamp: Build/TestConfig.hs Build/Configure.hs
mkdir -p tmp
touch tmp/configure-stamp
# Build with stack if it was used to build before, otherwise cabal.
dev:
@if [ -d .stack-work ]; then BUILDER=stack make; else make; fi
# Non-optimised build for development, with profiling enabled (for memory
# profiling).
#
# This leaves cabal.project.local configured for a dev build,
# so just running make will continue to do dev builds.
dev:
# This leaves cabal.project.local configured for a prof build,
# so just running make will continue to do prof builds.
prof:
$(BUILDER) configure -f"-Production" \
--enable-executable-dynamic --enable-profiling
rm cabal.project.local~* 2>/dev/null || true