Warn if old-style cocotb usage is detected
Before cocotb had a Python package, cocotb was referenced in Makefiles
using the COCOTB environment variable. Instead, the cocotb-config tool
should be used from now on. Inform users about that change by displaying
a warning during the build process.
@@ -40,6 +40,10 @@ ifeq ($(COCOTB_SHARE_DIR),)
export COCOTB_SHARE_DIR:=$(abspath $(dir $(lastword $(MAKEFILE_LIST)))/..)
endif
+ifeq ($(COCOTB_PY_DIR),$(COCOTB_SHARE_DIR))
+$(warning 'Deprecated cocotb file structure detected. Please use "include $$(shell cocotb-config --makefile)/Makefile.inc" in Makefiles')
+endif
+
ifeq ($(USER_DIR),)
export USER_DIR:=$(abspath $(dir $(firstword $(MAKEFILE_LIST))))
endif
