Hello,

Does linux automatically link lsocket if you are using it in a program?

I ask because I can compile my program and it works fine using:

#g++ wisdom.cc

but im supposed to use a make file which contains:
Code:
CCC=	g++ -Dsocklen_t=int
LLIB=	-lsocket -lnsl

wisdom:	wisdom.o
	$(CCC) -o wisdom wisdom.o $(LLIB)
but when i run this I get the following:
Code:
g++ -Dsocklen_t=int -o wisdom wisdom.o -lsocket -lnsl
/usr/lib/gcc-lib/i586-suse-linux/3.3.1/../../../../i586-suse-linux/bin/ld: canno
t find -lsocket
collect2: ld returned 1 exit status
make: *** [wisdom] Error 1
I guess im just wondering what is exactly going on.

Thanks.

-matt