Skip to content

Commit

Permalink
Proper index for action!
Browse files Browse the repository at this point in the history
  • Loading branch information
JPMoresmau committed Sep 15, 2014
1 parent a95bb3e commit 600ee18
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 4 deletions.
1 change: 1 addition & 0 deletions docs/releasenotes/net.sf.eclipsefp.haskell_2.6.2.txt
Expand Up @@ -12,6 +12,7 @@ Necessary Haskell packages:
Fixes:
- Fix auto indent on cabal file edition
- Do not create .HTF history folder in project folder
- Fix --with-ghc flag not passed properly to some operations (install dependencies, etc). Not that due to a Cabal limitation (https://github.com/haskell/cabal/issues/1511) GHC needs to be in your path for successful sandbox init.

Features:
- Environment tab on Haskell run configurations, passed to process
Expand Down
2 changes: 1 addition & 1 deletion net.sf.eclipsefp.haskell-feature/feature.xml
Expand Up @@ -158,7 +158,7 @@ available at http://www.eclipse.org/legal/epl-v10.html.
id="net.sf.eclipsefp.haskell.buildwrapper"
download-size="0"
install-size="0"
version="2.6.1.qualifier"
version="2.6.2.qualifier"
unpack="false"/>

<plugin
Expand Down
2 changes: 1 addition & 1 deletion net.sf.eclipsefp.haskell.buildwrapper/META-INF/MANIFEST.MF
Expand Up @@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %bundleName
Bundle-SymbolicName: net.sf.eclipsefp.haskell.buildwrapper;singleton:=true
Bundle-Version: 2.6.1.qualifier
Bundle-Version: 2.6.2.qualifier
Bundle-Activator: net.sf.eclipsefp.haskell.buildwrapper.BuildWrapperPlugin
Bundle-Vendor: %bundleVendor
Bundle-Localization: plugin
Expand Down
Expand Up @@ -1498,9 +1498,10 @@ public void runCabal(LinkedList<String> args,String explicitFlags,File workDir){
if (isCanceled()){
return;
}
String action=args.get(0);
args.addFirst(cabalImplDetails.getExecutable());
// we should need flags and extra options ONLY on configure calls...
if (args.get(0).equals("configure")){
if (action.equals("configure")){
if (explicitFlags!=null && explicitFlags.length()>0){
args.add("--flags="+explicitFlags);
}
Expand All @@ -1509,7 +1510,11 @@ public void runCabal(LinkedList<String> args,String explicitFlags,File workDir){
}
}
for (String s:cabalImplDetails.getOptions()){
if (s.startsWith("--with-ghc") && !args.get(0).equals("configure") && !args.get(0).equals("install")){
// https://github.com/haskell/cabal/issues/1511
// sandbox init needs GHC but doesn't accept --with-ghc flag
// && !action.equals("sandbox")

if (s.startsWith("--with-ghc") && !action.equals("configure") && !action.equals("install") ){
continue;
}
args.add(s);
Expand Down

0 comments on commit 600ee18

Please sign in to comment.