faylang / fay

A proper subset of Haskell that compiles to JavaScript
https://github.com/faylang/fay/wiki
BSD 3-Clause "New" or "Revised" License
1.29k stars 86 forks source link

problems with cabal-sandbox in windows #420

Closed CarstenKoenig closed 9 years ago

CarstenKoenig commented 9 years ago

I tried installing fay and fay-base into a local sandbox under windows. When I try to compile a simple file using fay I always get this (when giving the absolute path to the x...-packages.conf.d):

fay.exe: ghc: <command line>: cannot satisfy -package fay-base-0.19.4.1:
    fay-base-0.19.4.1-985fcb829f3541d3d885d378bc2c898f is unusable due to missing or recursive dependencies:
      fay-0.21.2.1-5f3f88230341a60e39daf9c3eb15daac
    (use -v for more information)

When I look into the packages both libs with the correct version are there.

The same situation under Linux: everything works, so I guess it's some strange windows/path issue?

bergmark commented 9 years ago

How are you specifying the package sandbox location? Also note that the fay executable and fay-base needs to be installed in the same sandbox. You should also make sure that you don't have two versions of fay-base installed since I recall seeing errors like this for that case as well.

It may very well be a windows issue though, I have never used fay on windows myself.

CarstenKoenig commented 9 years ago

I tried this under windows, linux and osx (every time with the same sandbox-setup) and only on windows I get this issue.

I choose the location with the parameter argument to fay (I couldn't get the env.variable thing going at all) and basically I just did

cabal update    
cabal sandbox init --sandbox=.
cabal install fay
cabal install fay-base

so it should all be there (and is on linux/osx)

So yeah I think it's some strange windows / pathing thing

bergmark commented 9 years ago

One way to debug this is to add some tracing for flags in Fay.Compiler.Typecheck to see what is passed to ghc.

CarstenKoenig commented 9 years ago

ok - I have not much time right now but I'll to get something done tomorrow - thanks for your help

bergmark commented 9 years ago

Spring cleaning. Lack of activity.