diff --git a/src/plugins/e-acsl/Makefile.in b/src/plugins/e-acsl/Makefile.in
index 25672c530b45fa6983742a093f233076eb1393e4..2b0b6a3b57ca2d5a76d4726972c12ed59a041fb2 100644
--- a/src/plugins/e-acsl/Makefile.in
+++ b/src/plugins/e-acsl/Makefile.in
@@ -215,11 +215,13 @@ TEST_DEPENDENCIES += \
 	$(EACSL_PLUGIN_DIR)/tests/E_ACSL_test.cmxs
 endif
 
+ifneq ("$(PLUGIN_ENABLE)","no")
 # Add the test dependencies to the test targets, but also to
 # `plugins_ptests_config` so that they are built along with the main target.
 plugins_ptests_config: $(TEST_DEPENDENCIES)
 E_ACSL_TESTS E_ACSL_DEFAULT_TESTS: $(TEST_DEPENDENCIES)
 tests:: $(TEST_DEPENDENCIES)
+endif
 
 $(EACSL_PLUGIN_DIR)/tests/test_config: \
 		$(EACSL_PLUGIN_DIR)/tests/test_config.in \
@@ -281,10 +283,12 @@ $(EACSL_DLMALLOC_LIB): $(EACSL_DLMALLOC_SRC)
 	echo 'RANLIB       $@'
 	ranlib $@
 
+ifneq ("$(PLUGIN_ENABLE)","no")
 all:: $(EACSL_DLMALLOC_LIB)
 
 clean::
 	$(RM) $(EACSL_DLMALLOC_LIB)
+endif
 
 ############
 # Cleaning #