-1

Can anyone please tell whether it is possible to create the shared object(.so) files from the existing .cc files?

Thanks !

Jerry
  • 7,863
  • 2
  • 26
  • 35

1 Answers1

1

Yes, you should look into make.

http://www.cs.colby.edu/maxwell/courses/tutorials/maketutor/

You need to compile your object files and then create an shared object out of those.

duffymo
  • 305,152
  • 44
  • 369
  • 561
  • is this also right? `gcc -c -fPIC hello_world.cc -o hello_world.o` `gcc hello_world.o -shared -o hello_world.so` – Jerry Apr 08 '14 at 10:31
  • Did you try it? You posted the comment 48 minutes ago. You could have answered your own question ten times over if you'd simply tried it. – duffymo Apr 08 '14 at 11:20
  • I the tried comment i have posted,but there is some error in compiling `.cc file`.So i could'nt get the `.so `file.Hence i asked whether is there any other method of generating `.so file` from `.cc files`. – Jerry Apr 08 '14 at 11:25
  • Sounds like you have to fix the compilation error in the .cc file before you can proceed. There's no magic here. What's the .cc error? – duffymo Apr 08 '14 at 11:31
  • ya i am trying to fix the .cc errrors,a part of the errors are here http://stackoverflow.com/questions/22928140/asks-for-complete-directory-path-the-directory-is-present-yet-this-error-no-suc – Jerry Apr 08 '14 at 11:34