# Cpan::GD, libgd  problem



## a129878 (Mar 25, 2010)

Trying to install libgd, because 'install Cpan::GD' complains.
Download the libgd_latest and try to make after several ./config's.

I get :-

```
gcc -DHAVE_CONFIG_H -I. -I. -I. -g -O2 -MT gdhelpers.lo -MD -MP -MF 
     .deps/gdhelpers.Tpo -c gdhelpers.c -o gdhelpers.o >/dev/null 2>&1
if /bin/sh ./libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H  -I. -I. -I.
      -g -O2 -MT gdkanji.lo -MD -MP -MF ".deps/gdkanji.Tpo" -c -o gdkanji.lo gdkanji.c;  then mv -f ".deps/gdkanji.Tpo" ".deps/gdkanji.Plo";
else rm -f ".deps/gdkanji.Tpo"; exit 1; 
fi
 gcc -DHAVE_CONFIG_H -I. -I. -I. -g -O2 -MT gdkanji.lo -MD -MP -MF .deps/gdkanji.Tpo -c gdkanji.c  -fPIC -DPIC -o .libs/gdkanji.o
gdkanji.c:20:19: error: iconv.h: No such file or directory
gdkanji.c: In function 'do_convert':
gdkanji.c:378: error: 'iconv_t' undeclared (first use in this function)
```

I have twiddled the configure to the likes of:-


```
./configure --includedir=/usr/local/include
```


```
# ls -l /usr/local/include/icon*
-r--r--r--  1 root  wheel  9244 Oct 20 20:46 /usr/local/include/iconv.h
```

This must be me not running configure properly.

Any help please?


----------



## DutchDaemon (Mar 25, 2010)

libgd should be supplied by graphics/gd. 


```
# pkg_info -W /usr/local/lib/libgd.so.4
/usr/local/lib/libgd.so.4 was installed by package gd-2.0.35_3,1
```

Are you sure the CPAN::GD module isn't available as a port as well (graphics/p5-GD, dunno, graphics/gd is a run/build dependency for it anyway)?


----------



## SirDice (Mar 25, 2010)

graphics/p5-GD is indeed the perl module GD. Why install it with CPAN?


----------



## a129878 (Mar 26, 2010)

Ummm - I use sysinstall and its not in the package options.
This probably comes down to me not knowing how to install something from  freebsdports where I have NO internet connection.

Although helpful - its not the answer guys !


----------



## SirDice (Mar 26, 2010)

a129878 said:
			
		

> Ummm - I use sysinstall and its not in the package options.


Don't use sysinstall for this.


----------



## a129878 (Mar 26, 2010)

SirDice - NOT using sysinstall - I agree, but raises the skill level !!

Using DutchDeamon's offering:-
 ian# pkg_info -W /usr/local/lib/libgd.so.4
 pkg_info: /usr/local/lib/libgd.so.4: file cannot be found
Already know that.
The Ports reference is the GD I am trying to install (GD-Latest) from http://www.libgd.org.
This needs some decisions as the README wants a `configure` run, which is where I am stuck.

Its odd, in that I have installed GD OK on a FreeBSD where I installed the world, but this 4G build need's more FreeBSD skill than I have.

I copied the libgd.* from my full F8 (same VBox PC) into /usr/local/lib, but no dice.

So - any more advice out there guys ?


----------



## SirDice (Mar 26, 2010)

```
root@molly:/usr/ports#cd graphics/p5-GD
root@molly:/usr/ports/graphics/p5-GD#make fetch
===>  Vulnerability check disabled, database not found
=> GD-2.44.tar.gz doesn't seem to exist in /storage/FreeBSD/distfiles//.
=> Attempting to fetch from ftp://ftp.funet.fi/pub/languages/perl/CPAN/modules/by-module/GD/.
^Cfetch: transfer interrupted
```

Download that file by hand and place it in /usr/ports/distfiles. Then do the normal `# make install clean`.


----------

