2009-02-06 01:06:31     Building libpam

Document created by Aaronwu Employee on Aug 11, 2013
Version 1Show Document
  • View in full screen mode

2009-02-06 01:06:31     Building libpam

Parimala Baggiri (INDIA)

Message: 68945   

 

Hello,

 

           I am trying to build libpam in uclinux-dist module with PAM_STATIC enabled, getting some compilation errors saying that

 

../../libpam/pam_handlers.c: In function '_pam_add_handler':

../../libpam/pam_handlers.c:605: error: 'servicefn' undeclared (first use in this function)

../../libpam/pam_handlers.c:605: error: (Each undeclared identifier is reported only once

../../libpam/pam_handlers.c:605: error: for each function it appears in.)

../../libpam/pam_handlers.c:605: error: expected ';' before 'func'

../../libpam/pam_handlers.c:756: error: 'func' undeclared (first use in this function)

../../libpam/pam_handlers.c:756: error: 'func2' undeclared (first use in this function)

../../libpam/pam_handlers.c:816: error: expected ')' before '_pam_get_static_sym'

../../libpam/pam_handlers.c:829: error: expected ')' before '_pam_get_static_sym'

make[3]: *** [pam_handlers.lo] Error 1

 

 

then I included pam_dynamic.h in pam_handler.c as "servicefn" is declared in that file. After that in modules dirctory of libpam, I had run the script "./register_static pam_access pam_access/pam_access.o", now it giving the error as

 

In file included from ../../libpam/pam_static.c:23:

../../libpam/../modules/_static_module_list:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before '/' token

In file included from ../../libpam/pam_static.c:32:

../../libpam/../modules/_static_module_entry:1: error: '_pam_access' undeclared here (not in a function)

../../libpam/../modules/_static_module_entry:1: error: '_modstruct' undeclared here (not in a function)

../../libpam/pam_static.c: In function '_pam_open_static_handler':

../../libpam/pam_static.c:71: error: 'pamh' undeclared (first use in this function)

../../libpam/pam_static.c:71: error: (Each undeclared identifier is reported only once

../../libpam/pam_static.c:71: error: for each function it appears in.)

../../libpam/pam_static.c:71: warning: passing argument 1 of 'pam_syslog' from incompatible pointer type

make[3]: *** [pam_static.lo] Error 1

make[3]: Leaving directory `/home/parimala/uClinux-dist-2008R1-RC8/lib/libpam/build/libpam'

make[2]: *** [all-recursive] Error 1

make[2]: Leaving directory `/home/parimala/uClinux-dist-2008R1-RC8/lib/libpam/build'

 

My uclinux-dist is uClinux-dist-2008R1-RC8

 

Is it the way building libpam as static library? I can compile successfully with PAM_DYNAMIC option.

 

Regards

 

Parimala

 

 

 

 

QuoteReplyEditDelete

 

 

2009-02-06 01:12:43     Re: Building libpam

Mike Frysinger (UNITED STATES)

Message: 68946   

 

why do you want PAM ?  it doesnt really make sense on embedded systems

QuoteReplyEditDelete

 

 

2009-02-06 01:38:57     Re: Building libpam

Parimala Baggiri (INDIA)

Message: 68950   

 

Hello Mike,

 

                    I need it for PPP. For PPP authentication I am using PAM.

 

Thank You.

 

Regards

 

Parimala

QuoteReplyEditDelete

 

 

2009-02-06 01:44:46     Re: Building libpam

Mike Frysinger (UNITED STATES)

Message: 68951   

 

why ?  ppp supports storing of auth information in /etc/ppp/*-secrets files just fine, and rather than having PAM lookup the user/pass info in the passwd/group/etc... db files, pppd can do it itself just fine.

 

do you actually have some exotic authentication method that requires PAM ?

Attachments

    Outcomes