• Please review our updated Terms and Rules here

getting the rpc.pcnfs deamon to compile on a newer linux machine

salamontagne

Experienced Member
Joined
Feb 27, 2010
Messages
245
Location
Harwinton,CT
Hi I'm trying to support older nfs clients by running the rpc.pcnfs deamon on a newer machine (actually, currently a virtualbox guest install of Gentoo)

The deamon is apperantly needed to allow ms-dos based nfs clients to connect to a linux server. (Sun's old implementation of nfs is the only one that nfs clients on dos will
recognize)

even with the libgcrypt package (which i thought it was at first, makeing it fails witha
'undefined referance to crypt'

I have a message in the gentoo forums, but i figured i'd also paste it here to see if anyone can help me out.

Here is the detailed posting of my adventures: http://forums.gentoo.org/viewtopic-t-885852.html

gcc info:

gcc -v
Using built-in specs.
Target: i686-pc-linux-gnu
Configured with: /var/tmp/portage/sys-devel/gcc-4.4.5/work/gcc-4.4.5/configure --prefix=/usr --bindir=/usr/i686-pc-linux-gnu/gcc-bin/4.4.5 --includedir=/usr/lib/gcc/i686-pc-linux-gnu/4.4.5/include --datadir=/usr/share/gcc-data/i686-pc-linux-gnu/4.4.5 --mandir=/usr/share/gcc-data/i686-pc-linux-gnu/4.4.5/man --infodir=/usr/share/gcc-data/i686-pc-linux-gnu/4.4.5/info --with-gxx-include-dir=/usr/lib/gcc/i686-pc-linux-gnu/4.4.5/include/g++-v4 --host=i686-pc-linux-gnu --build=i686-pc-linux-gnu --disable-altivec --disable-fixed-point --without-ppl --without-cloog --enable-nls --without-included-gettext --with-system-zlib --disable-werror --enable-secureplt --disable-multilib --enable-libmudflap --disable-libssp --enable-libgomp --with-python-dir=/share/gcc-data/i686-pc-linux-gnu/4.4.5/python --enable-checking=release --disable-libgcj --with-arch=i686 --enable-languages=c,c++,fortran --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu --with-bugurl=http://bugs.gentoo.org/ --with-pkgversion='Gentoo 4.4.5 p1.2, pie-0.4.5'
Thread model: posix
gcc version 4.4.5 (Gentoo 4.4.5 p1.2, pie-0.4.5)

and the last output of make:

linux/pcnfsd_v1.o: In function `pcnfsd_auth_1':
pcnfsd_v1.c:(.text+0xc7): undefined reference to `crypt'
linux/pcnfsd_v2.o: In function `pcnfsd2_auth_2':
pcnfsd_v2.c:(.text+0x12b): undefined reference to `crypt'
collect2: ld returned 1 exit status
make: *** [linux/rpc.pcnfsd] Error 1

Any ideas?
 
Last edited:
Your code compiled but failed in the link stage. You are missing a library that provides the function called 'crypt' - that is what the error messages are telling you.

On my Fedora Core 2 machine (quite old by now) the crypt function is in libcrypt.so.1, which is provided by the C runtime package (glibc):

Code:
[brutman@mugwai brutman]$ rpm -qf /lib/libcrypt.so.1
glibc-2.3.3-27.1
[brutman@mugwai brutman]$ nm /lib/libcrypt.so.1
0773bc80 r b64t
0773ca20 r BITMASK
0773e030 a __bss_start
0773e040 b buffer
0773e048 b buflen.0
0773ca80 r bytemask
07739784 t call_gmon_start
0773e044 b completed.1
07739918 T crypt
0773984c t __crypt_r
0773984c W crypt_r
0773def4 d __CTOR_END__

This is a wild shot, but try adding -lcrypt onto the list of libraries to link against.

If that does not work then you need to find out how to get this function on your Gentoo system. Try doing a "man crypt" to see if the documentation for it is there at least. Crypt is very old and has been supplanted by other encryption routines that are more secure, so it's possible that it has just been dropped.
 
Back
Top