On Fri, May 3, 2019 at 6:14 PM Lawrence D'Oliveiro <l...@geek-central.gen.nz> wrote:
> On Fri, 3 May 2019 03:00:25 +0000, suzuki toshiya wrote: > > > BTW, does cmake have any hardwired database for > > the available flags for each compilers? I can check > > for gcc and clang, but I'm not sure about other > > proprietary compilers... > > I thought most C compilers supported at least some small core of > GCC-compatible flags, including ā-gā for generating debugging symbols > and ā-Dā for defining preprocessor symbols that can be queried in the > code. Plus of course the usual ones for specifying library and include > paths. You can do a lot with just these. > Re CMake Yes, and generally cmake provides those with the default flags by compiler/generator/toolchain file. [Dd][Ee][Bb][Uu][Gg] includes -g , no optimization, and default flags if the compiler uses them (_DEBUG) [Rr][Ee][Ll][Ee][Aa][Ss][Ee] includes optimization, does not comiple with symbols, and would be (NDEBUG) RelWithDebInfo - includes optimization, but also debug information MinSize - Extra optimzation, no symbols/debugging. Unfortunatly, RelWithDebInfo on MSVC does also include multi-threaded-debug runtime, so it's not very 'Release'. This can be overridden... But generally the default flags for compiler/generator selected in cmake switch with CMAKE_BUILD_TYPE There are Visutal Studio/Xcode/... multi-configuration generators, but they don't really support multiple install outputs, so it's almost always easiest to just make a new build per configuration like makefiles and only build the appropriate configuration for that target. (I wonder if there's somehow a way to disable generation of parallel targets) I find that with VS now, even Release gets PDB debugging information associated with it so you can debug/step through things you've compiled. > > _______________________________________________ > Freetype mailing list > Freetype@nongnu.org > https://lists.nongnu.org/mailman/listinfo/freetype > _______________________________________________ Freetype mailing list Freetype@nongnu.org https://lists.nongnu.org/mailman/listinfo/freetype