compler warnings in ports not supported in gcc 4.2.1 (stable/10)

Kubilay Kocak koobs at
Sun Sep 24 01:02:03 UTC 2017

On 9/24/17 7:42 AM, Julian Elischer wrote:
> Trying to compile the emulators/open-vm-tools-nox11 port
> but I end up dying with:
> libtool: compile:  cc -DPACKAGE_NAME=\"open-vm-tools\"
> -DPACKAGE_TARNAME=\"open-vm-tools\" -DPACKAGE_VERSION=\"10.1.5\"
> "-DPACKAGE_STRING=\"open-vm-tools 10.1.5\""
> -DPACKAGE_BUGREPORT=\"open-vm-tools-devel at\"
> -DPACKAGE_URL=\"\" -DPACKAGE=\"open-vm-tools\" -DVERSION=\"10.1.5\"
> -I/usr/ports/emulators/open-vm-tools-nox11/work/open-vm-tools-stable-10.1.5/open-vm-tools/lib/include
> -I/usr/ports/emulators/open-vm-tools-nox11/work/open-vm-tools-stable-10.1.5/open-vm-tools/lib/include
> -Wno-deprecated-declarations -isystem /usr/local/include
> -DPANZURA_DEV -DPZ_FBSD_10 -isystem /usr/local/include
> -fno-strict-aliasing -Wall -Werror -Wno-unused-function
> -Wno-address-of-packed-member -Wno-unknown-warning-option -Wno-unused
> -MT nicinfo_xdr.lo -MD -MP -MF .deps/nicinfo_xdr.Tpo -c nicinfo_xdr.c 
> -fPIC -DPIC -o .libs/nicinfo_xdr.o
> cc1: error: unrecognized command line option
> "-Wno-address-of-packed-member"
> cc1: error: unrecognized command line option "-Wno-unknown-warning-option"
> *** [nicinfo_xdr.lo] Error code 1
> the system in question is compiled with gcc
> is there a supported way of making the port not set those flags on each
> cc1 command?

The port (all ports) should patch out -Werror. Upstream should not
include it (as a default flag) in distribution sources.

In the mean time, one can always:

CFLAGS=-Wno-error (user or port set, += if the latter)

More information about the freebsd-ports mailing list