-
-
Notifications
You must be signed in to change notification settings - Fork 147
Open
Description
Maybe more documentation needed?
- Haskell test results in module is not loaded: 'Graphics.Implicit' (./Graphics/Implicit.hs)
This is most likely a problem with your Linux distro and cabal not playing nice. GHC is not configured to see the ImplicitCAD libraries. You can confirm this by trying the test in
~/.cabal/lib/. If that works, you should be able to use ghc anywhere with the -Ldir or -llib options. Alternatively, some people have permanently fixed this by doing the cabal install as root.
A slightly edited log:
$ apt install ghc haskell-stack cabal-install
$ cabal update && cabal install implicit
$ echo "circle(30);" > test.escad
$ extopenscad test.escad
Loading File.
Processing File.
Rendering 2D object from test.escad to test.stl with resolution 2.0 in
box (V2 (-30.0) (-30.0),V2 30.0 30.0) circle 30.0
<<ghc:
2264880 bytes, 2 GCs, 238032/238032 avg/max bytes residency (1
samples), 18M in use, 0.005 INIT (0.002 elapsed), 0.004 MUT (0.002
elapsed), 0.000 GC (0.000 elapsed)
:ghc>>
$ ls
test.escad test.stl
$ ghci
GHCi, version 8.8.4: https://www.haskell.org/ghc/ :? for help
Prelude> import Graphics.Implicit
<no location info>: error:
Could not find module ‘Graphics.Implicit’
It is not a module in the current program, or in any known package.
Prelude> ^D
$ locate cabal | grep lib | grep -i implicit | wc -l
117
$ locate cabal | grep lib | grep -i implicit | rev | cut -d "/" -f 2- | rev | sort | uniq | head -n 1
~/.cabal/store/ghc-8.8.4/implicit-0.4.1.0-a990a66c188ce67ca424777aeecf8a34c19946f74d8d9563353b724167c06df9
And within that directory we have /lib/Graphics/ which contains:
- Implicit
- Implicit/Export
- Implicit/Export/Render
- Implicit/Export/Symbolic
- Implicit/ExtOpenScad
- Implicit/ExtOpenScad/Eval
- Implicit/ExtOpenScad/Parser
- Implicit/ExtOpenScad/Util
- Implicit/ObjectUtil
I attempted the import while cd'd to ~/.cabal/ and then to each of the subdirectories, all with the same result.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels