← Back to team overview

kicad-developers team mailing list archive

Re: Broken Linux build

 

Hi,

On 07.02.20 19:19, Simon Richter wrote:

> This. The COMPILE_DEFINITIONS property is applied to CC and CXX
> invocations, not to the SWIG command line.

Spoke too soon. Those are actually applied. What is happening is that
swig is invoked as

/usr/bin/swig3.0 -python -c++ -outdir /home/geier/OSS/kicad/Build/pcbnew
-I/home/geier/OSS/kicad/pcbnew -I/home/geier/OSS/kicad/include
-I/home/geier/OSS/kicad/scripting -I/home/geier/OSS/kicad/common/swig
-I/home/geier/OSS/kicad/libs/kimath/include -I -DDEBUG
-DKICAD_CONFIG_DIR=kicad -DHAVE_STDINT_H -DKICAD_SCRIPTING
-DKICAD_SCRIPTING_MODULES -DKICAD_SCRIPTING_PYTHON3
-DKICAD_SCRIPTING_WXPYTHON -DKICAD_SCRIPTING_WXPYTHON_PHOENIX
-DKICAD_SCRIPTING_ACTION_MENU -DKICAD_SPICE -DKICAD_USE_OCE
-DGLM_FORCE_CTOR_INIT -DWX_COMPATIBILITY -D_FILE_OFFSET_BITS=64
-DWXUSINGDLL -D__WXGTK__ -DPCBNEW -o
/home/geier/OSS/kicad/Build/pcbnew/pcbnew_wrap.cxx swig/pcbnew.i

Notice the -I before the -DDEBUG? The fix for -DDEBUG reordered the
preprocessor definitions, so now -DDEBUG instead of the
-DKICAD_CONFIG_DIR is interpreted as an include directory.

The -I is expanded from -I${WXPYTHON_SWIG_DIR} which is an empty
variable that is never mentioned anywhere else in the source tree.

Unless there is a configuration that sets this variable, removing that
-I line from the swig invocation is the way to go.

   Simon

Attachment: signature.asc
Description: OpenPGP digital signature


Follow ups

References