c++ - What is the equivalent switch to /MT (VC++) for g++ in linux (CentOS)? -
my users complain have install linux thread building blocks on machines not own, , many hosts don't want intel thread building blocks installed of end users, want create static version of dynamic library / plugin / module / extension (whatever corrct term plugable c++ program / dll / so).
i found out windows have use /mt (multi threaded) instead of default /md switch (multi threaded dll) program have no dependencies (but, windows has concurrent container library don't need use tbb there).
i cannot figure out equivalent linux is?
or there maybe .sln makefile converter can figure out options?
i'm developing on windows, of end users use linux make sure don't have burden on them , want them comfortable using open source releases.
the /mt
flag in microsoft c++ compiler causes linker link against static versions of c , c++ run-time libraries. microsoft ships static , dynamic versions of run-time libraries, option selects set of libs link against. flag not affect linking against third party libraries.
on linux side have -static
option tell linker use static libraries. option not library specific on windows, affects libraries. if use option have provide static versions of libraries need, linker not convert dynamic libraries automatically. includes system , run-time libraries, not available static libs. includes intel tbb, need compile static lib if intel doesn't provide in form.
Comments
Post a Comment