[torquedev] [PATCH] Problems with PAM

Adrian Knoth adi at drcomp.erfurt.thur.de
Thu Nov 1 06:48:31 MDT 2007


Hi!

Though I have been able to compile torque with PAM support in the past,
there are now some problems.

I haven't checked whether it is my PAM version (0.99.7.1) or something
else, but here's the snippet from config.log:


| extern int
| pam_get_user(
|         pam_handle_t *pamh,             /* PAM handle */
|         char **user,                    /* User Name */
|         const char *prompt              /* Prompt */
| );
| 
| 
| int
| main ()
| {
| 
|                   char* username;
|                   pam_get_user(0,&username,0);
| 
|   ;
|   return 0;
| }
configure:23228: gcc -c -g -O2 -W -Wall -Wno-unused-parameter -Wno-long-long -pedantic -Werror -D_LARGEFILE64_SOURCE  conftest.c >&5
cc1: warnings being treated as errors
conftest.c: In function 'main':
conftest.c:98: warning: null argument where non-null required (argument 1)
configure:23234: $? = 1

Afterwards, pam_get_user_2nd_arg_t is defined as "none", thus breaking
pam_pbssimpleauth.c:64.

The attached patch corrects the problem, but I guess there is some
configure.ac or a bunch of m4 files to be patched instead.

(the patch is what I'm doing for the Torque Debian package to get a
working configure and by this a valid value for pam_get_user_2nd_arg_t)


-- 
mail: adi at thur.de  	http://adi.thur.de	PGP/GPG: key via keyserver

Man soll den Tag nicht vor dem Abendprogramm loben
-------------- next part --------------
--- configure	2007-11-01 12:11:56.000000000 +0100
+++ configure.new	2007-11-01 12:18:35.000000000 +0100
@@ -23218,7 +23218,7 @@
 {
 
                   $t* username;
-                  pam_get_user(0,&username,0);
+                  pam_get_user((pam_handle_t*) 1,&username,0);
 
   ;
   return 0;


More information about the torquedev mailing list