diff --git a/include/Makefile.am b/include/Makefile.am
index 38ba14c..ffed583 100644
--- a/include/Makefile.am
+++ b/include/Makefile.am
$(AM_V_GEN)sed -e's/XX/$*/g' $< > $@
osmocom/gsm/gsm0503.h: $(top_srcdir)/utils/conv_gen.py $(top_srcdir)/utils/conv_codes_gsm.py
- $(AM_V_GEN)python $(top_srcdir)/utils/conv_gen.py gen_header gsm \
+ $(AM_V_GEN)@PYTHON_EXECUTABLE@ $(top_srcdir)/utils/conv_gen.py gen_header gsm \
--target-path $(builddir)/osmocom/gsm
CLEANFILES = osmocom/gsm/gsm0503.h
diff --git a/src/gsm/Makefile.am b/src/gsm/Makefile.am
index 5387e3a..e19fde4 100644
--- a/src/gsm/Makefile.am
+++ b/src/gsm/Makefile.am
# Convolutional codes generation
gsm0503_conv.c: $(top_srcdir)/utils/conv_gen.py $(top_srcdir)/utils/conv_codes_gsm.py
- $(AM_V_GEN)python $(top_srcdir)/utils/conv_gen.py gen_codes gsm
+ $(AM_V_GEN)@PYTHON_EXECUTABLE@ $(top_srcdir)/utils/conv_gen.py gen_codes gsm
CLEANFILES = gsm0503_conv.c
diff --git a/tests/Makefile.am b/tests/Makefile.am
index db4e520..36ca8b7 100644
conv/gsm0503_test_vectors.c: $(top_srcdir)/utils/conv_gen.py $(top_srcdir)/utils/conv_codes_gsm.py
- $(AM_V_GEN)python $(top_srcdir)/utils/conv_gen.py gen_vectors gsm \
+ $(AM_V_GEN)@PYTHON_EXECUTABLE@ $(top_srcdir)/utils/conv_gen.py gen_vectors gsm \
--target-path $(builddir)/conv
diff --git a/utils/conv_codes_gsm.py b/utils/conv_codes_gsm.py
index ec77660..48b161a 100644
--- a/utils/conv_codes_gsm.py
+++ b/utils/conv_codes_gsm.py
from conv_gen import ConvolutionalCode
diff --git a/utils/conv_gen.py b/utils/conv_gen.py
index 06283d8..88968d3 100644