Re: [Haskell-beginners] Just started working with Haskell. Need some help
Hello again. Thank you all for your very helpful replies (below) Here is the error I got when I tried to run my script : Could not find module `Graphics.GD' Locations searched: Graphics/GD.hs Graphics/GD.lhs As with the previous errors, I went on Google, to find out which module and/or package I needed to install. Apparently, I need something called "GD" When I tried : cabal install gd I got the following : Resolving dependencies... Configuring gd-3000.7.3... cabal-1.16.0.2: Missing dependencies on foreign libraries: * Missing (or bad) header file: gd.h * Missing C libraries: gd, expat Failed to install gd-3000.7.3 cabal-1.16.0.2: Error: some packages failed to install: gd-3000.7.3 failed during the configure step. The exception was: ExitFailure 1 Upon further inquiries via google, I found somewhere the following : This problem can usually be solved by installing the system packages that provide these libraries (you may need the "-dev" versions). If the libraries are already installed but in a non-standard location then you can use the flags --extra-include-dirs= and --extra-lib-dirs= to specify where they are. I thought I did this already. But, apparently, I did something wrong?? -----Original Message----- From: beginners-request <beginners-request@haskell.org> To: beginners <beginners@haskell.org> Sent: Sat, Jan 18, 2014 11:35 pm Subject: Beginners Digest, Vol 67, Issue 19 Message: 1 Date: Sat, 18 Jan 2014 12:25:01 -0500 (EST) From: Pyro Crane <pyrocrane1@aol.com> To: beginners@haskell.org Subject: [Haskell-beginners] Just started working with Haskell. Need some help Message-ID: <8D0E2895A21535B-1058-8B60@webmail-d276.sysops.aol.com> Content-Type: text/plain; charset="us-ascii" Hi, I just started working with Haskell Running it on a RHEL linux operating system I was able to download and install it, along with libraries and packages (or, at least, what I thought were the libraries and packages) But, when I try to run a simple script, I keep getting the error : "Could not find module XXXXXX".............. I understand what this error means ---- there is a package/library missing. I tried using the "Cabal Update" command, but this did not solve the problem. So, I am now fixing this problem the primitive way, as follows : (a) I use Google to first find out what the missing module is (b) then, based on what google says, I am able to determine the name of the actual package that needs to be installed (c) I use "Cabal Install" to install the package (d) I try to run the script again (e) I get the same error, but this time, it cannot find a different module (f) I go back to Google to locate the missing module etc, etc, etc, etc Obviously, this is as slow as it is ridiculous............... especially when one considers that there are probably hundreds of these modules/packages And, now, I've come up against a module/package, which I am unable to locate in Google. It's missing from my installation, and Google does not know what it is, or where I can find it Is there any way to simply install ALL required packages??? I thought I already did this, but obviously I missed something Thanks
Hi, W dniu 20.01.2014 08:06, Pyro Crane pisze:
Hello again.
Thank you all for your very helpful replies (below)
Here is the error I got when I tried to run my script :
*Could not find module `Graphics.GD'* *Locations searched:* *Graphics/GD.hs* *Graphics/GD.lhs*
As with the previous errors, I went on Google, to find out which module and/or package I needed to install.
Apparently, I need something called "GD"
When I tried : *cabal install gd*
I got the following :
*Resolving dependencies...* *Configuring gd-3000.7.3...* *cabal-1.16.0.2: Missing dependencies on foreign libraries:* ** Missing (or bad) header file: gd.h* ** Missing C libraries: gd, expat*
*Failed to install gd-3000.7.3* *cabal-1.16.0.2: Error: some packages failed to install:* *gd-3000.7.3 failed during the configure step. The exception was: ExitFailure 1*
Upon further inquiries via google, I found somewhere the following :
*This problem can usually be solved by installing the system packages that* *provide these libraries (you may need the "-dev" versions). If the libraries* *are already installed but in a non-standard location then you can use the* *flags --extra-include-dirs= and --extra-lib-dirs= to specify where they are.*
I thought I did this already.
But, apparently, I did something wrong??
This haskell package provides only library bindings. You need to install original library using system package manager. Regards, Emanuel
If you are using a Debian based system you could try: sudo apt-get install libgd2-xpm-dev In general look at the package description: http://hackage.haskell.org/package/gd-3000.7.3/gd.cabal
Extra-libraries: gd, png, z, jpeg, m, fontconfig, freetype, expat These extra libraries are required by the package and have to be installed using the system package manager, as Emanuel pointed out.
Hi, Thanks for the replies. I was able to solve the problem Simply by deleting everything completely...........and re-installing the ghc from scratch, along with all haskell packages (This is what I did earlier; but apparently, I missed something) Anyway, it's working fine now -----Original Message----- From: Pyro Crane <pyrocrane1@aol.com> To: beginners <beginners@haskell.org> Sent: Mon, Jan 20, 2014 9:06 am Subject: Re: Just started working with Haskell. Need some help Hello again. Thank you all for your very helpful replies (below) Here is the error I got when I tried to run my script : Could not find module `Graphics.GD' Locations searched: Graphics/GD.hs Graphics/GD.lhs As with the previous errors, I went on Google, to find out which module and/or package I needed to install. Apparently, I need something called "GD" When I tried : cabal install gd I got the following : Resolving dependencies... Configuring gd-3000.7.3... cabal-1.16.0.2: Missing dependencies on foreign libraries: * Missing (or bad) header file: gd.h * Missing C libraries: gd, expat Failed to install gd-3000.7.3 cabal-1.16.0.2: Error: some packages failed to install: gd-3000.7.3 failed during the configure step. The exception was: ExitFailure 1 Upon further inquiries via google, I found somewhere the following : This problem can usually be solved by installing the system packages that provide these libraries (you may need the "-dev" versions). If the libraries are already installed but in a non-standard location then you can use the flags --extra-include-dirs= and --extra-lib-dirs= to specify where they are. I thought I did this already. But, apparently, I did something wrong?? -----Original Message----- From: beginners-request <beginners-request@haskell.org> To: beginners <beginners@haskell.org> Sent: Sat, Jan 18, 2014 11:35 pm Subject: Beginners Digest, Vol 67, Issue 19 Message: 1 Date: Sat, 18 Jan 2014 12:25:01 -0500 (EST) From: Pyro Crane <pyrocrane1@aol.com> To: beginners@haskell.org Subject: [Haskell-beginners] Just started working with Haskell. Need some help Message-ID: <8D0E2895A21535B-1058-8B60@webmail-d276.sysops.aol.com> Content-Type: text/plain; charset="us-ascii" Hi, I just started working with Haskell Running it on a RHEL linux operating system I was able to download and install it, along with libraries and packages (or, at least, what I thought were the libraries and packages) But, when I try to run a simple script, I keep getting the error : "Could not find module XXXXXX".............. I understand what this error means ---- there is a package/library missing. I tried using the "Cabal Update" command, but this did not solve the problem. So, I am now fixing this problem the primitive way, as follows : (a) I use Google to first find out what the missing module is (b) then, based on what google says, I am able to determine the name of the actual package that needs to be installed (c) I use "Cabal Install" to install the package (d) I try to run the script again (e) I get the same error, but this time, it cannot find a different module (f) I go back to Google to locate the missing module etc, etc, etc, etc Obviously, this is as slow as it is ridiculous............... especially when one considers that there are probably hundreds of these modules/packages And, now, I've come up against a module/package, which I am unable to locate in Google. It's missing from my installation, and Google does not know what it is, or where I can find it Is there any way to simply install ALL required packages??? I thought I already did this, but obviously I missed something Thanks
participants (3)
-
Emanuel Koczwara -
Pyro Crane -
Roel van Dijk