diff --git a/pyext/py2/Makefile.am b/pyext/py2/Makefile.am index 11e0d2d37785..3bffbdbc648f 100644 --- a/pyext/py2/Makefile.am +++ b/pyext/py2/Makefile.am @@ -6,6 +6,8 @@ pkgpyexec_LTLIBRARIES = _pysairedis.la INCLUDE=-I../../SAI/inc -I../../SAI/meta -I../../SAI/experimental -I../../lib/inc -I.. +BUILT_SOURCES = pysairedis_wrap.cpp + _pysairedis_la_SOURCES = pysairedis_wrap.cpp $(SOURCES) _pysairedis_la_CXXFLAGS = $(INCLUDE) -I/usr/include/python$(PYTHON_VERSION) $(AM_CXXFLAGS) $(CXXFLAGS_COMMON) \ -Wno-cast-qual -Wno-shadow -Wno-redundant-decls -Wno-conversion $(NO_CAST_FUNCTION_TYPE) diff --git a/pyext/py3/Makefile.am b/pyext/py3/Makefile.am index ecaf58f3497c..afbe36bb5942 100644 --- a/pyext/py3/Makefile.am +++ b/pyext/py3/Makefile.am @@ -6,6 +6,8 @@ pkgpy3exec_LTLIBRARIES = _pysairedis.la INCLUDE=-I../../SAI/inc -I../../SAI/meta -I../../SAI/experimental -I../../lib/inc -I.. +BUILT_SOURCES = pysairedis_wrap.cpp + _pysairedis_la_SOURCES = pysairedis_wrap.cpp $(SOURCES) _pysairedis_la_CXXFLAGS = $(INCLUDE) -I/usr/include/python$(PYTHON3_VERSION) $(AM_CXXFLAGS) $(CXXFLAGS_COMMON) \ -Wno-cast-qual -Wno-shadow -Wno-redundant-decls -Wno-conversion $(NO_CAST_FUNCTION_TYPE)