On 2018-06-12 20:29 +0800, Xi Ruoyao wrote: > On 2018-06-12 17:46 +0530, Ajay Garg wrote: > > Oh, sorry for that (and thanks for the quick reply ..). > > > > Just a quick-question, is there a gcc option that can disable > > compilation of *any* shared-libraries at gcc's level? > > You can write a shell script wrapping GCC to do that. But I don't think it > would be useful as the building process won't continue because of missing > libraries. > > leptonica's CMake building system seems to use "cmake -DSTATIC=yes". And its > Makefile (src/makefile.static) doesn't produce shared libraries by default > (DON'T -DSHARED=no! just `make -f makefile.static`. It actually just tests > if SHARED is defined and doesn't check the value). For autoconf building > system (configure script) --disable-shared should work. I tested leptonica-1.76.0 and '--disable-shared' works. Maybe the warning you seen is just a false warning from libtool. `find -name \*.so` after `make` finishes to see if there is a liblept.so. -- Xi Ruoyao <ryxi@xxxxxxxxxxxxxxxxx> School of Aerospace Science and Technology, Xidian University