You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hey there. Intero crashes when I start Intero inside a specific project. Changing the file to another hs file in some other project still crashes Intero, whereas starting intero in another project works perfectly fine (and thus loading a file from the problematic project works, although it doesn't compile due to the wrong project settings being used by intero).
Here's the error I get. Intero crashes when this appears, and any attempt to restart it gives this error. I can't call any intero commands until it has started up, and this is preventing it from doing so:
FirstGameHS-0.1.0.0: initial-build-steps (exe)
Configuring GHCi with the following packages: FirstGameHS
/home/ashe/Documents/FirstGameHS/.stack-work/install/x86_64-linux-tinfo6-nopie/lts-10.7/8.2.2/bin/intero: error while loading shared libraries: libHSnetwork-2.6.3.3-LsInmfJLY3IBO2L8iqXwV9-ghc8.2.2.so: cannot open shared object fi
le: No such file or directory
[Process exited 127]
Here's a copy paste of the cabal of the project that doesn't work:
Here's the one and only file of the problematic project:
{-# LANGUAGE OverloadedStrings #-}
moduleMainwhereimportControl.MonadimportForeign.C.TypesimportSDL.VectimportSDL (($=))
importqualifiedSDLimportPaths_FirstGameHS(getDataFileName)
screenWidth, screenHeight::CInt
(screenWidth, screenHeight) = (640, 480)
loadBMP::FilePath->IOSDL.Surface
loadBMP path = getDataFileName path >>=SDL.loadBMP
main::IO()
main =do-- Initialise SDLSDL.initialize [SDL.InitVideo]
-- Create a window with the correct screensize and make it appear
window <-SDL.createWindow "SDL Tutorial"SDL.defaultWindow { SDL.windowInitialSize =V2 screenWidth screenHeight }
SDL.showWindow window
-- Create a renderer for the window for rendering textures
renderer <-SDL.createRenderer
window
(-1)
SDL.RendererConfig
{ SDL.rendererType =SDL.AcceleratedRenderer
, SDL.rendererTargetTexture =False
}
SDL.rendererDrawColor renderer $=V4maxBoundmaxBoundmaxBoundmaxBound-- Make a surface from file
xOutSurface <- getDataFileName "foo.bmp">>=SDL.loadBMP
texture <-SDL.createTextureFromSurface renderer xOutSurface
-- Free the surface as we have a texture nowSDL.freeSurface xOutSurface
let loop =do
events <-SDL.pollEvents
let quit =elemSDL.QuitEvent$mapSDL.eventPayload events
SDL.clear renderer
SDL.copy renderer texture Nothing (Just$SDL.Rectangle (P$V200) (V2200200))
SDL.present renderer
unless quit loop
loop
SDL.destroyWindow window
SDL.quit
Finally, I'd like to add that this project does compile both in stack ghci and stack build, and stack exec works perfectly fine too. One thing to take note of is that I have extra data-files being packaged when the game is built, and so Paths_FirstGameHS is a module generated by cabal which allows these files to be moved and included automatically, providing their new path etc.
Hey there. Intero crashes when I start Intero inside a specific project. Changing the file to another hs file in some other project still crashes Intero, whereas starting intero in another project works perfectly fine (and thus loading a file from the problematic project works, although it doesn't compile due to the wrong project settings being used by intero).
Here's the error I get. Intero crashes when this appears, and any attempt to restart it gives this error. I can't call any intero commands until it has started up, and this is preventing it from doing so:
Here's a copy paste of the cabal of the project that doesn't work:
Here's the one and only file of the problematic project:
Finally, I'd like to add that this project does compile both in
stack ghci
andstack build
, andstack exec
works perfectly fine too. One thing to take note of is that I have extradata-files
being packaged when the game is built, and soPaths_FirstGameHS
is a module generated by cabal which allows these files to be moved and included automatically, providing their new path etc.I followed this guide to achieve this
The text was updated successfully, but these errors were encountered: