diff --git a/Build/AtlasCMake/modules/AtlasCompilerSettings.cmake b/Build/AtlasCMake/modules/AtlasCompilerSettings.cmake
index 8bdcc9675f3ad7e99a3f1546113f35fbd0575bfe..85251d68d9db731b3f86c965a877da32c14b5a0c 100644
--- a/Build/AtlasCMake/modules/AtlasCompilerSettings.cmake
+++ b/Build/AtlasCMake/modules/AtlasCompilerSettings.cmake
@@ -1,6 +1,6 @@
 # Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
 
-# $Id: AtlasCompilerSettings.cmake 766879 2016-08-08 09:10:26Z krasznaa $
+# $Id: AtlasCompilerSettings.cmake 776624 2016-10-05 12:49:54Z krasznaa $
 #
 # This file collects settings fine-tuning all the compiler and linker options
 # used in an ATLAS build in one place. It is included by default when using
diff --git a/Build/AtlasCMake/modules/scripts/setup.sh.in b/Build/AtlasCMake/modules/scripts/setup.sh.in
index b3944dc7674f0b7ef85eb24e5854b89a37c467db..7ad0e1eaa9fbe56de081d7018a08ea230be739db 100644
--- a/Build/AtlasCMake/modules/scripts/setup.sh.in
+++ b/Build/AtlasCMake/modules/scripts/setup.sh.in
@@ -1,4 +1,4 @@
-# $Id: setup.sh.in 740257 2016-04-14 12:22:22Z krasznaa $
+# $Id: setup.sh.in 769400 2016-08-23 08:33:18Z krasznaa $
 #
 # Script providing a functional build and runtime environment for project
 # @CMAKE_PROJECT_NAME@ when sourced from either BASH or ZSH.
@@ -47,7 +47,7 @@ remove_duplicates() {
             # Decide whether to add it to the environment or not:
             case ${envval}: in
                 *:"$x":*) ;;
-                *) eval "${envname}=\$$envname:$x";;
+                *) eval "${envname}=${envval}:$x";;
             esac
         fi
         # Or if it begins with "http"...
@@ -57,7 +57,7 @@ remove_duplicates() {
             # Decide whether to add it to the environment or not:
             case ${envval}: in
                 *:"$x":*) ;;
-                *) eval "${envname}=\$$envname:$x";;
+                *) eval "${envname}=${envval}:$x";;
             esac
         fi
         # Remove the element from the list: