Subject: Re: [nycbug-talk] pkgsrc on FreeBSD
To: None <talk@lists.nycbug.org>
From: George Georgalis <george@galis.org>
List: tech-pkg
Date: 06/24/2005 17:17:31
On Fri, Jun 24, 2005 at 01:52:15PM -0400, Marc Spitzer wrote:
>> >On 6/24/05, George Georgalis <george@galis.org> wrote:
>> >> I'm setting up the FreeBSD with pkgsrc... but the bootstrap failed, can
>> >> you make sense of this?
>> >>
>
>try ./bootstrap --pkgdbdir=/var/db/pkgsrc 

right! I miss read the instructions I was using...
but still....

cd /usr/
cvs -d anoncvs@anoncvs.us.netbsd.org:/cvsroot co pkgsrc
set PATH=/usr/pkgsrc/bin:$PATH
export PATH
cd /usr/pkgsrc/bootstrap
./bootstrap --pkgdbdir=/var/db/pkgsrc --prefix=/usr/pkgsrc
cp work/mk.conf.example /etc/mk.conf


# cd /usr/pkgsrc/bootstrap/work/tnftp && make distclean && ./configure 
...
# make
( cd libedit; make )
gcc -g -O2 -I. -I./.. -I. -I.. -I./../libedit  -I./../libnetbsd -c chared.c
In file included from chared.c:36:
./../tnftp.h:316: error: conflicting types for 'dirname'
/usr/include/libgen.h:39: error: previous declaration of 'dirname' was here
./../tnftp.h:316: error: conflicting types for 'dirname'
/usr/include/libgen.h:39: error: previous declaration of 'dirname' was here
*** Error code 1

Stop in /usr/pkgsrc/bootstrap/work/tnftp/libedit.
*** Error code 1

Stop in /usr/pkgsrc/bootstrap/work/tnftp.


I don't know why this doesn't work.....

if ! HAVE_DIRNAME
char    *dirname(char *);
#endif


But this "patch" fixed it for me...

> diff -du /usr/pkgsrc/net/tnftp/files/tnftp.h.orig  /usr/pkgsrc/net/tnftp/files/tnftp.h
--- /usr/pkgsrc/net/tnftp/files/tnftp.h.orig    Fri Jun 10 01:06:25 2005
+++ /usr/pkgsrc/net/tnftp/files/tnftp.h Fri Jun 24 17:04:46 2005
@@ -313,7 +313,7 @@
 #endif
 
 #if ! HAVE_DIRNAME
-char   *dirname(char *);
+/* char        *dirname(char *); */
 #endif
 
 #if ! HAVE_ERR


context: this is a FreeBSD 5.4-RELEASE base install.

>ps why not just use ports?

I like the OS portable nature of pkgsrc.

// George


-- 
George Georgalis, systems architect, administrator Linux BSD IXOYE
http://galis.org/george/ cell:646-331-2027 mailto:george@galis.org