CLang flags query:: I'm wanting to port software to FreeBSD

Brooks Davis brooks at freebsd.org
Thu Feb 27 02:26:16 UTC 2014


On Wed, Feb 26, 2014 at 06:43:38PM -0500, Joe Nosay wrote:
> I've noticed different flags such as -Wno-parentheses and such along with
> the -Wno-unused-variable. I would like to know where would be a good source
> online to find the flags; and, I would like to know what flags are used by
> porters to optimize builds. These will be placed on the Makefile of the
> source such that it can be built  natively on FreeBSD. I would be able to
> test software.

There is unfortunately no central reference for Clang warning flags.
The closest I've found is

http://clang.llvm.org/docs/UsersManual.html#options-to-control-error-and-warning-messages

but it omits most of them.

Flags of the form -Wno-* disable warnings, usually because the code in
question is vendor code we don't want to touch, a mess no one want's to
clean up, or both.  You should generally avoid them.  I'm confused why
you talk about optimization in the context of these flags.  They have no
impact on code generation.

-- Brooks
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 326 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/freebsd-ports/attachments/20140226/a773c2ed/attachment.sig>


More information about the freebsd-ports mailing list