diff --git a/src/makefile/basic.mk b/src/makefile/basic.mk
index 8ddc6550bf775a1b4c6167d8ac8a27b22d58bc78..003792db4b173c219dfa5fbbe74943aeae120bbe 100644
--- a/src/makefile/basic.mk
+++ b/src/makefile/basic.mk
@@ -44,7 +44,7 @@ CONDA := source $(SERVER_CONDA_PATH)/etc/profile.d/conda.sh && conda
 default: help # customize, if you know what you're doing
 
 help: # list targets and usage
-	@awk '/^[a-zA-Z0-9_-]+:/{print $1}' makefile
+	@awk '/^[a-zA-Z0-9_-]+:/{print $1}' $(lastword $(MAKEFILE_LIST))
 
 install: # install conda environment
 	$(SSH) '\