8

I'm trying to use the "data-files" mechanism, and stuff works fine except that the relevant files are not copied into the share/ directory. e.g. my .cabal file looks like:

name:                nano-js
version:             0.1.0.0
data-files:          include/prelude.js

but after building and installing the directory

.hsenv/cabal/share/nano-js-0.1.0.0

does not exist. So queries of the form

getDataFileName "include/prelude.js" 

yield a FilePath that does not exist

nanojs: /home/rjhala/research/liquid/.hsenv/cabal/share/nano-js-0.1.0.0/include/prelude.js: openFile: does not exist (No such file or directory)

Are some extra keywords required to populate share/?

Or could this be an issue with hsenv?

Thanks!

Ranjit Jhala
  • 1,242
  • 8
  • 18

1 Answers1

3

I was being silly -- the data-files clause needs to be at the top while I had it buried in the executable section...!

Ranjit Jhala
  • 1,242
  • 8
  • 18