File tree Expand file tree Collapse file tree 1 file changed +4
-7
lines changed Expand file tree Collapse file tree 1 file changed +4
-7
lines changed Original file line number Diff line number Diff line change 104
104
&& ( haskellLib . isLibrary componentId )
105
105
&& stdenv . hostPlatform == stdenv . buildPlatform ;
106
106
107
- testExecutable = "dist/build/ ${ componentId . cname } / ${ componentId . cname } "
108
- + lib . optionalString stdenv . hostPlatform . isWindows ".exe ";
107
+ exeExt = lib . optionalString stdenv . hostPlatform . isWindows ".exe" ;
108
+ testExecutable = "dist/build/ ${ componentId . cname } / ${ componentId . cname } ${ exeExt } ";
109
109
110
110
in stdenv . lib . fix ( drv :
111
111
@@ -235,11 +235,8 @@ stdenv.mkDerivation ({
235
235
'' }
236
236
${ lib . optionalString ( haskellLib . isTest componentId || haskellLib . isBenchmark componentId || haskellLib . isAll componentId ) ''
237
237
mkdir -p $out/${ name }
238
- if [ -f "dist/build/${ componentId . cname } /${ componentId . cname } " ]; then
239
- cp dist/build/${ componentId . cname } /${ componentId . cname } $out/${ name } /
240
- fi
241
- if [ -f "dist/build/${ componentId . cname } /${ componentId . cname } .exe" ]; then
242
- cp dist/build/${ componentId . cname } /${ componentId . cname } .exe $out/${ name } /
238
+ if [ -f ${ testExecutable } ]; then
239
+ cp ${ testExecutable } $out/${ name } /
243
240
fi
244
241
'' }
245
242
runHook postInstall
You can’t perform that action at this time.
0 commit comments