diff --git a/src/Makefile.global.in b/src/Makefile.global.in
index 2af9413f216115caab15a0b154ef05575a5a22ca..e76b22fb2d2ec652acb85035827948bc365ffac0 100644
--- a/src/Makefile.global.in
+++ b/src/Makefile.global.in
@@ -302,7 +302,7 @@ PROVE_FLAGS = --verbose
 
 # prepend to path if already set, else just set it
 define add_to_path
-$(1)='$(if $($(1)),$(2):$$$(1),$(2))'
+$(1)="$(if $($(1)),$(2):$$$(1),$(2))"
 endef
 
 # platform-specific environment variable to set shared library path