Friday, March 2, 2018

compilation - c++ compiling problem

I'm trying to compile a c++ program, which is something I didn't do for a long time...



What I'm trying is:



g++ -c A.cpp  -o A.o

g++ -c dir/B.h -o B.o



which seem to work, and then I try:



g++ A.o B.o -o A -lX11 -lpthread


and get:





B.o: file not recognized: File format
not recognized



collect2: ld returned 1 exit status




What is the problem?



Thanks a lot :)

No comments:

Post a Comment

plot explanation - Why did Peaches' mom hang on the tree? - Movies & TV

In the middle of the movie Ice Age: Continental Drift Peaches' mom asked Peaches to go to sleep. Then, she hung on the tree. This parti...