Skip to content

Commit eeca277

Browse files
committed
release: fix windows zip files when using zip-archive-0.3
1 parent 3a62513 commit eeca277

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

etc/scripts/release.hs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{-# LANGUAGE CPP #-}
12
{-# LANGUAGE RecordWildCards #-}
23

34
import Control.Applicative
@@ -172,7 +173,11 @@ rules global@Global{..} args = do
172173
entries <- forM stageFiles $ \stageFile -> do
173174
Zip.readEntry
174175
[Zip.OptLocation
176+
#if MIN_VERSION_zip_archive(0,3,0)
177+
(dropFileName (dropDirectoryPrefix (releaseStageDir </> binaryName) stageFile))
178+
#else
175179
(dropDirectoryPrefix (releaseStageDir </> binaryName) stageFile)
180+
#endif
176181
False]
177182
stageFile
178183
let archive = foldr Zip.addEntryToArchive Zip.emptyArchive entries

etc/scripts/windows-releases.bat

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,5 @@ if errorlevel 1 exit /b
1313
cd %BUILD_DIR%
1414
%RELEASE_SCRIPT% --no-test-haddocks --arch=i386 %1 %2 %3 %4 %5 %6 %7 %8 %9 release
1515
if errorlevel 1 exit /b
16-
%RELEASE_SCRIPT% --no-test-haddocks --arch=x86_64 %2 %3 %4 %5 %6 %7 %8 %9 release
16+
%RELEASE_SCRIPT% --no-test-haddocks --arch=x86_64 %1 %2 %3 %4 %5 %6 %7 %8 %9 release
1717
if errorlevel 1 exit /b

0 commit comments

Comments
 (0)