-
Notifications
You must be signed in to change notification settings - Fork 703
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Nix-style builds need to install data files for inplace builds #4120
Comments
To be more specific, when we new-build an inplace package, we configure some bogus install paths for data files which get baked into Paths_pkg.hs. However, a new-build of an inplace package never actually installs into those directories, so if you actually try to run an inplace executable it won't find anything. One way to fix this is to configure install paths into the dist-newstyle directory (at the cost of accumulating technical debt for when we eventually want relocatable build directories) and then installing the files into that location. Another possibility is to teach Paths to be able to pick up local data files prior to installation (so we don't have to go copy things), although this may be difficult if the install layout is different than the source layout. @dcoutts is likely to have Opinions(TM). |
Known workarounds:
|
Is it reasonable to assume this? What could change it? Old-run also does this. Is it fine if i replicate this behaviour in new-run (i.e. not copying the data files anywhere and simply setting the env var)? |
I can't think of anything except maybe custom setup shenaningans (it should be ok to ignore those). You should remember to take |
This enables the executale to find the datafiles in inplace builds. Fixes haskell#4120
Datafiles should work when running an inplace exe
NB: This is not fixed in the general case (running the inplace-built exe from |
Currently,
new-build
does not installdata-files
(possibly alsoextra-files
). A sufficient condition for this bug is an "inplace" build. It may happen in other cases as well.The text was updated successfully, but these errors were encountered: