* Re: Compileing
[not found] <199802251806.NAA24999@rrdjazz.nist.gov>
@ 1998-02-25 20:18 ` mike
0 siblings, 0 replies; 7+ messages in thread
From: mike @ 1998-02-25 20:18 UTC (permalink / raw)
Thanks for all the help guys. I got it working now. It was the -lcrypt
thing.
On Wed, 25 Feb 1998, Przemek Klosowski wrote:
>
> Yup... This:
>
> nwdbm.o: In function `crypt_pw_ok':
> nwdbm.c(.text+0x56d8): undefined reference to `crypt'
> nwdbm.c(.text+0x56dc): undefined reference to `crypt'
> make[2]: *** [nwbind] Error 1
>
> This is dureing the linking stage.
>
> Argh---that is a completely different problem from the one you mentioned the first time
> around. It just shows that it is important to assume nothing when debugging :^)
>
> You need to link with the crypt library; just add -lcrypt to the linking line.
>
> --
> To unsubscribe: send e-mail to axp-list-request@redhat.com with
> 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
>
--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Compileing
@ 1998-02-25 19:34 Uncle George
0 siblings, 0 replies; 7+ messages in thread
From: Uncle George @ 1998-02-25 19:34 UTC (permalink / raw)
i'm not into crypt, but i suppose u need something like -lcrypt ( cc switch )
which will look for libcrypt.so ( or .a ).
mike@alpha.lab.realminfo.com wrote:
> Yup... This:
>
> nwdbm.o: In function `crypt_pw_ok':
> nwdbm.c(.text+0x56d8): undefined reference to `crypt'
> nwdbm.c(.text+0x56dc): undefined reference to `crypt'
> make[2]: *** [nwbind] Error 1
>
> This is dureing the linking stage.
>
> I get the same error in a small test prog that I wrote when I try to
> compile it also.
>
> On Wed, 25 Feb 1998, Uncle George ( Garlic Pizza Specialist ) wrote:
>
> > warnings have never ( for me ) stopped a compile from creating an object.
> > something more to the messages?
> >
> >
> > mike@alpha.lab.realminfo.com wrote:
> >
> > > I am trying to compile a piece of software and I get this error:
> > >
> > > gcc -c -pipe -Wall -I/usr/include -DLINUX -DUSE_GDBM -D_VERS_H_=0
> > > -D_VERS_L_=99
> > > -D_VERS_P_=2 ../nwdbm.c
> > > ../nwdbm.c: In function `crypt_pw_ok':
> > > ../nwdbm.c:1326: warning: implicit declaration of function `crypt'
> > > ../nwdbm.c:1326: warning: initialization makes pointer from integer
> > > without a cast
> > >
> > > I looked to make sure that the header that crypt is in is being #inc'd and
> > > it is in one of the headers that nwdbm.c is including. I also included it
> > > directly into the file. I still get the same error and cant get it to
> > > compile. Its like the compiler cant find unistd.h. What would cause this?
> > > Any help appreciated. I am not sure if this is an alpha specific problem
> > > or maby its just C related.
> > >
> > > Mike Panetta
> > > REALM Information Technologies
> > >
> > > --
> > > To unsubscribe: send e-mail to axp-list-request@redhat.com with
> > > 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
> >
> >
> >
> > --
> > To unsubscribe: send e-mail to axp-list-request@redhat.com with
> > 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
> >
>
> --
> To unsubscribe: send e-mail to axp-list-request@redhat.com with
> 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
^ permalink raw reply [flat|nested] 7+ messages in thread
[parent not found: <Pine.LNX.3.96.980225130110.7331A-100000@alpha.lab.realminfo.com>]
* Re: Compileing
[not found] <Pine.LNX.3.96.980225130110.7331A-100000@alpha.lab.realminfo.com>
@ 1998-02-25 18:09 ` Christopher C Chimelis
0 siblings, 0 replies; 7+ messages in thread
From: Christopher C Chimelis @ 1998-02-25 18:09 UTC (permalink / raw)
On Wed, 25 Feb 1998 mike@alpha.lab.realminfo.com wrote:
> Yup... This:
>
> nwdbm.o: In function `crypt_pw_ok':
> nwdbm.c(.text+0x56d8): undefined reference to `crypt'
> nwdbm.c(.text+0x56dc): undefined reference to `crypt'
> make[2]: *** [nwbind] Error 1
> This is dureing the linking stage.
> I get the same error in a small test prog that I wrote when I try to
> compile it also.
You need to add -lcrypt to your gcc command. This will link in libcrypt,
which contains the crypt() function. Without linking to libcrypt, it
won't know what code to include for the crypt() function since it only
links to glibc unless other libraries are included as well with the -l
switch. For more info on this, check the linker options section in the
info files that came with gcc :)
Hope this helps!
Chris
--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Compileing
@ 1998-02-25 18:06 Przemek Klosowski
0 siblings, 0 replies; 7+ messages in thread
From: Przemek Klosowski @ 1998-02-25 18:06 UTC (permalink / raw)
Yup... This:
nwdbm.o: In function `crypt_pw_ok':
nwdbm.c(.text+0x56d8): undefined reference to `crypt'
nwdbm.c(.text+0x56dc): undefined reference to `crypt'
make[2]: *** [nwbind] Error 1
This is dureing the linking stage.
Argh---that is a completely different problem from the one you mentioned the first time
around. It just shows that it is important to assume nothing when debugging :^)
You need to link with the crypt library; just add -lcrypt to the linking line.
--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
^ permalink raw reply [flat|nested] 7+ messages in thread
[parent not found: <34F455CC.8E667B3E@voicenet.com>]
* Re: Compileing
[not found] <34F455CC.8E667B3E@voicenet.com>
@ 1998-02-25 18:02 ` mike
0 siblings, 0 replies; 7+ messages in thread
From: mike @ 1998-02-25 18:02 UTC (permalink / raw)
Yup... This:
nwdbm.o: In function `crypt_pw_ok':
nwdbm.c(.text+0x56d8): undefined reference to `crypt'
nwdbm.c(.text+0x56dc): undefined reference to `crypt'
make[2]: *** [nwbind] Error 1
This is dureing the linking stage.
I get the same error in a small test prog that I wrote when I try to
compile it also.
On Wed, 25 Feb 1998, Uncle George ( Garlic Pizza Specialist ) wrote:
> warnings have never ( for me ) stopped a compile from creating an object.
> something more to the messages?
>
>
> mike@alpha.lab.realminfo.com wrote:
>
> > I am trying to compile a piece of software and I get this error:
> >
> > gcc -c -pipe -Wall -I/usr/include -DLINUX -DUSE_GDBM -D_VERS_H_=0
> > -D_VERS_L_=99
> > -D_VERS_P_=2 ../nwdbm.c
> > ../nwdbm.c: In function `crypt_pw_ok':
> > ../nwdbm.c:1326: warning: implicit declaration of function `crypt'
> > ../nwdbm.c:1326: warning: initialization makes pointer from integer
> > without a cast
> >
> > I looked to make sure that the header that crypt is in is being #inc'd and
> > it is in one of the headers that nwdbm.c is including. I also included it
> > directly into the file. I still get the same error and cant get it to
> > compile. Its like the compiler cant find unistd.h. What would cause this?
> > Any help appreciated. I am not sure if this is an alpha specific problem
> > or maby its just C related.
> >
> > Mike Panetta
> > REALM Information Technologies
> >
> > --
> > To unsubscribe: send e-mail to axp-list-request@redhat.com with
> > 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
>
>
>
> --
> To unsubscribe: send e-mail to axp-list-request@redhat.com with
> 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
>
--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Compileing
@ 1998-02-25 17:33 Uncle George
0 siblings, 0 replies; 7+ messages in thread
From: Uncle George @ 1998-02-25 17:33 UTC (permalink / raw)
warnings have never ( for me ) stopped a compile from creating an object.
something more to the messages?
mike@alpha.lab.realminfo.com wrote:
> I am trying to compile a piece of software and I get this error:
>
> gcc -c -pipe -Wall -I/usr/include -DLINUX -DUSE_GDBM -D_VERS_H_=0
> -D_VERS_L_=99
> -D_VERS_P_=2 ../nwdbm.c
> ../nwdbm.c: In function `crypt_pw_ok':
> ../nwdbm.c:1326: warning: implicit declaration of function `crypt'
> ../nwdbm.c:1326: warning: initialization makes pointer from integer
> without a cast
>
> I looked to make sure that the header that crypt is in is being #inc'd and
> it is in one of the headers that nwdbm.c is including. I also included it
> directly into the file. I still get the same error and cant get it to
> compile. Its like the compiler cant find unistd.h. What would cause this?
> Any help appreciated. I am not sure if this is an alpha specific problem
> or maby its just C related.
>
> Mike Panetta
> REALM Information Technologies
>
> --
> To unsubscribe: send e-mail to axp-list-request@redhat.com with
> 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
^ permalink raw reply [flat|nested] 7+ messages in thread
* Compileing
@ 1998-02-25 17:17 mike
0 siblings, 0 replies; 7+ messages in thread
From: mike @ 1998-02-25 17:17 UTC (permalink / raw)
I am trying to compile a piece of software and I get this error:
gcc -c -pipe -Wall -I/usr/include -DLINUX -DUSE_GDBM -D_VERS_H_=0
-D_VERS_L_=99
-D_VERS_P_=2 ../nwdbm.c
../nwdbm.c: In function `crypt_pw_ok':
../nwdbm.c:1326: warning: implicit declaration of function `crypt'
../nwdbm.c:1326: warning: initialization makes pointer from integer
without a cast
I looked to make sure that the header that crypt is in is being #inc'd and
it is in one of the headers that nwdbm.c is including. I also included it
directly into the file. I still get the same error and cant get it to
compile. Its like the compiler cant find unistd.h. What would cause this?
Any help appreciated. I am not sure if this is an alpha specific problem
or maby its just C related.
Mike Panetta
REALM Information Technologies
--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~1998-02-25 20:18 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <199802251806.NAA24999@rrdjazz.nist.gov>
1998-02-25 20:18 ` Compileing mike
1998-02-25 19:34 Compileing Uncle George
[not found] <Pine.LNX.3.96.980225130110.7331A-100000@alpha.lab.realminfo.com>
1998-02-25 18:09 ` Compileing Christopher C Chimelis
-- strict thread matches above, loose matches on Subject: below --
1998-02-25 18:06 Compileing Przemek Klosowski
[not found] <34F455CC.8E667B3E@voicenet.com>
1998-02-25 18:02 ` Compileing mike
1998-02-25 17:33 Compileing Uncle George
1998-02-25 17:17 Compileing mike
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox