[OpenAFS] Undefined symbol problem

David Botsch dwb7@ccmr.cornell.edu
Thu, 13 Nov 2003 17:19:34 -0500


Hi, all.

Working on some code under linux (Rh 7.3 - oafs 1.2.10).

It wasn't compiling, so I wrote a quick piece of test code. The test code
doesn't compile using:

> gcc -L/usr/lib/afs -lauth test.c
test.c: In function `main':
test.c:4: warning: return type of `main' is not `int'
/tmp/ccObLywC.o: In function `main':
/tmp/ccObLywC.o(.text+0x2b): undefined reference to `ktc_ListTokens'
collect2: ld returned 1 exit status


Here's the snippet:

#include <rx/xdr.h>
#include <afs/auth.h>

void main(void) {
        struct ktc_principal serviceName;
        int cellNum;

        cellNum=0;

        ktc_ListTokens(cellNum, &cellNum, &serviceName);
}

What am I missing, here?

Thanks!

-- 

********************************
David William Botsch
Consultant/Advisor II
CCMR Computing Facility
dwb7@ccmr.cornell.edu
********************************