Skip to content

Commit 85ef030

Browse files
mpickeringMikolaj
authored andcommitted
cabal-install: Fix the directory the build folder is created in
Clearly this path needs to be relative to the CWD, and the correct offset is passed as the `srcdir` parameter. Fixes #10772
1 parent c64a32d commit 85ef030

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

cabal-install/src/Distribution/Client/ProjectBuilding/UnpackedPackage.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -459,7 +459,7 @@ buildInplaceUnpackedPackage
459459
-- TODO: [code cleanup] there is duplication between the
460460
-- distdirlayout and the builddir here builddir is not
461461
-- enough, we also need the per-package cachedir
462-
createDirectoryIfMissingVerbose verbosity True $ getSymbolicPath builddir
462+
createDirectoryIfMissingVerbose verbosity True $ interpretSymbolicPath (Just srcdir) builddir
463463
createDirectoryIfMissingVerbose
464464
verbosity
465465
True

changelog.d/pr-10800

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
synopsis: Fix regression where 'build' folder was created in CWD when running a standlone script.
2+
packages: cabal-install
3+
prs: #10800
4+
issues: #10772
5+
significance:
6+
7+
description: {
8+
9+
Fix a regression where the `build` folder was created in the current directory
10+
when running a standalone script.
11+
12+
}

0 commit comments

Comments
 (0)