Home
Developer Resources
QNX RTOS v4
QNX RTOS v4 Knowledge Base

QNX RTOS v4 Knowledge Base

Foundry27
Foundry27
QNX RTOS v4 project
Resources

QNX RTOS v4 Knowledge Base

Title Finding a function in the Watcom libraries in QNX4
Ref. No. QNX.000005437
Category(ies) Development
Issue We are just starting to learn C. We are having trouble locating some functions, and which headers they are in. Is there some way to quickly find out what library a function is in?



Solution If you want to check for a function in a particular library use the following line
( checking mylib.lib for myfunc() )

wlib mylib.lib | grep myfunc

This will return any occurance of the function name in the library (myfunc in this case).

If the function is not in clib, it should be documented as to which lib its part of.

It is a simple matter to put this into a script that takes the function name as the argument, like so:

#!/bin/sh
cd /usr/lib
for x in $(ls *.lib)
do
  wlib $x | grep $1
done