Re: Compiling Circle3.0bpl11 on HPUX 9000

From: Barid Bel Medar (
Date: 04/24/96

I won't quote your message, but as I recall you had a slew of 
warnings for select(), a warning for an uninitialized vnum in the OLC 
code, and several undefined symbols by a different name.

Check the prototype for select.  Go to your include directory and type:

grep select *.h

Then find the most likely-looking file and see what it has for argument 
values.  Compare them to what's being used.  I'm fairly confident that 
Circle uses select() correctly, so you may need to have someone change 
the include file itself (or you may be able to).  The use of 'grep' is to 
make sure that several include files aren't defining multiple prototypes 
which, for some reason, don't show up (this has been a problem for me in 
the past) as warnings.  Or, select() may just be un-prototyped.  I didn't 
see if it was also an undefined symbol.  If there's no prototype, well, I 
don't know what it is.  Man pages.

"Variable 'variable' is used uninitialized" just means that a variable is 
declared, but used before a value is assigned.  For example,

int x;

if(x == 3) {

In this case, the result of the if statement is undefined, as is the 
value of x.  Generally, you can fix this by setting the value of x to 
zero or inserting code to give x a meaningful value.  This is something 
especially easy to screw up on when dealing with pointers.  For example,

void function(int arg1, char *arg2)
  char *p;

  if(arg1 > 0)
    p = arg2;

  /* p is only initialized properly if arg1 is positive.  This if statement
   * should always produce a warning with optimizations turned on. */
  if(strtok(p, 'c') == NULL) {

So, anyway, check to see what variable is used on the line mentioned and 
make sure it has a value.

With regards to the undefined symbols, well, you may have some problems 
there.  Your best bet is to check through all the man pages and libraries 
to see if you need anything special included for linking.  After that, 
you may have to go to a more common system (like Linux, for example) and 
see what the various functions do; then write them from scratch.  Hardly 
a solution at all, but it's all I can think of (having no HP/UX or 
whatever experience at all).

Barid Bel Medar                     
Knights of the Cosmos            Shayol Ghul Resort and Health Spa
"I  am  returning  this otherwise good typing paper to you because
someone has printed gibberish all over it and  put  your  name  at
the top." - English Professor, Ohio University

This archive was generated by hypermail 2b30 : 12/18/00 PST