Subject: Re: pkgsrc documentation, digest and undefined reference to `RMD160Init'
To: None <tech-pkg@netbsd.org>
From: Jeremy C. Reed <reed@reedmedia.net>
List: tech-pkg
Date: 03/09/2001 22:45:59
Does 1.5.1_ALPHA i386 have rmd160 libs?

> ===> Cleaning for digest-20010302
> ===> Extracting for digest-20010302
> ===> Patching for digest-20010302
> ===> Configuring for digest-20010302
> ~===> Building for digest-20010302
> cc -O2  -Wall -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith
> -Wno-uninitialized -Wreturn-type -Wcast-qual -Wpointer-arith
> -Wwrite-strings -Wswitch -Wshadow -Werror   -DVERSION=20010302
> -DVERSION=20010302 -I/usr/pkg/pkgsrc/pkgtools/digest/work
> -DHAVE_SYS_ENDIAN_H_ -DHAVE_MACHINE_ENDIAN_H_ -c digest.c
> cc  -Wl,-R/usr/pkg/lib -L/usr/pkg/lib -Wl,-R/usr/pkg/lib -L/usr/pkg/lib
> -static -o digest digest.o 
> digest.o: In function `rmd160_digest_file':
> digest.o(.text+0x15b): undefined reference to `RMD160Init'
> digest.o(.text+0x170): undefined reference to `RMD160Update'
> digest.o(.text+0x194): undefined reference to `RMD160End'
> digest.o(.text+0x1b1): undefined reference to `RMD160File'
> collect2: ld returned 1 exit status
> *** Error code 1

Well I worked around this problem.

In digest/work/Makefile I commented out the check for rmd160.

#.if !exists(/usr/include/rmd160.h)
SRCS+= rmd160.c rmd160hl.c
#.endif

My system (1.5.1_ALPHA i386) has the header file, but as far as I can
tell, no library.

It successfully built then. Then I had to update my
pkgsrc/pkgtools/pkg_install. At first "make install" did nothing (except
download the tar file). No errors and no messages when I did "make
install" again.

Then I simply tried "make".  It said there was no checksum. So I did "make
NO_CHECKSUM=yes" and then "make install".

Then after that I could successfully build other packages.

   Jeremy C. Reed
   http://www.reedmedia.net/