diff --git a/modules/codec/vpx.c b/modules/codec/vpx.c
index 296cd9dca78e74ba33745a5dbf989bbc2923650f..0b86489c5a34e33daaf8cc06d1e4e672ced038a6 100644
--- a/modules/codec/vpx.c
+++ b/modules/codec/vpx.c
@@ -299,7 +299,7 @@ static int OpenEncoder(vlc_object_t *p_this)
         vp_version = 8;
         break;
 #endif
-#ifdef ENABLE_VP9_DECODER
+#ifdef ENABLE_VP9_ENCODER
     case VLC_CODEC_VP9:
         iface = &vpx_codec_vp9_cx_algo;
         vp_version = 9;