04-24-2013 06:26 PM
Hello BlackBerry devs,
We are developping a relatively large application consisting of around 1500 compilation units spread over 2 static libraries and the main application. We are using WNX Momentics and managed build. Overall recompilation times are 40 minutes with a 5 minute link time on the final application. Is there any settings people may know of that could help on this front?
We are using preincludes in all projects. It seems a PCH would be beneficial in this case, however, there doesn't seem to be a way of enabling this in Momentics managed builds.
Also, our codebase is dependent on short wchar_t (-fshort-wchar). This causes the linker to emit a warning (uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail) for every linked object which, with over 1500 linked object results in A LOT of output and is probably slowing down the link accumulating these messages. There doesn't seem to be a way of silencing this warning since -fshort-wchar actually enables this warning from its default error status.
Solved! Go to Solution.
04-26-2013 02:20 PM
I don't have build settings explicitly for pre-compiled headers but have confirmed they are supported. Since they are standard GCC options, you can add them to the general QCC options settings page. I am trying to see if anyone internally has the settings that I can share.
About the linker warning: -fshort-wchart changes the ABI, and makes the code incompatible with the system libraries. This is why the linker warns about the ABI mismatch. It's not a warning that should be silenced, but if you want to, you can do it using -Wl,--no-warn-mismatch.