diff --git a/config/hdl_buildset_casperunb1.cfg b/config/hdl_buildset_casperunb1.cfg
index 54870b026532fd915f63c4a18995dc9780116420..68d27b45fb280d7242b3b647cf29b401aa998141 100644
--- a/config/hdl_buildset_casperunb1.cfg
+++ b/config/hdl_buildset_casperunb1.cfg
@@ -9,7 +9,7 @@ synth_tool_version        = 11.1
 sim_tool_name             = modelsim
 sim_tool_version          = 6.6c
 
-lib_root_dirs             = ${RADIOHDL_WORK}
+lib_root_dirs             = ${HDL_WORK}
 
 [quartus]
 quartus_dir               = ${ALTERA_DIR}/<synth_tool_version>
diff --git a/config/hdl_buildset_casperxpm.cfg b/config/hdl_buildset_casperxpm.cfg
index cf7ae532eae25e7e9c4bbb37f036e13737eb61a4..ca58df5248613a14dd91762af96de517e9fc2307 100644
--- a/config/hdl_buildset_casperxpm.cfg
+++ b/config/hdl_buildset_casperxpm.cfg
@@ -9,7 +9,7 @@ synth_tool_version        = 11.1 # ???
 sim_tool_name             = modelsim
 sim_tool_version          = 6.6c
 
-lib_root_dirs             = ${RADIOHDL_WORK}
+lib_root_dirs             = ${HDL_WORK}
 
 [quartus]
 
diff --git a/config/hdl_buildset_unb1.cfg b/config/hdl_buildset_unb1.cfg
index dc9c660ba412e05bbf328756416e9354518998da..3ad266b1f02cf953965b17d40e794c8dc037871b 100644
--- a/config/hdl_buildset_unb1.cfg
+++ b/config/hdl_buildset_unb1.cfg
@@ -9,7 +9,7 @@ synth_tool_version        = 11.1
 sim_tool_name             = modelsim
 sim_tool_version          = 6.6c
 
-lib_root_dirs             = ${RADIOHDL_WORK}/libraries ${RADIOHDL_WORK}/applications ${RADIOHDL_WORK}/boards
+lib_root_dirs             = ${HDL_WORK}/libraries ${HDL_WORK}/applications ${HDL_WORK}/boards
 
 [quartus]
 quartus_dir               = ${ALTERA_DIR}/<synth_tool_version>
diff --git a/config/hdl_buildset_unb2.cfg b/config/hdl_buildset_unb2.cfg
index e01a70612796c8780f2b23b76eb0b9c986712d1e..1d6a0a45beb882d48743cac31d868f2dac2bae6f 100644
--- a/config/hdl_buildset_unb2.cfg
+++ b/config/hdl_buildset_unb2.cfg
@@ -9,7 +9,7 @@ synth_tool_version        = 15.0
 sim_tool_name             = modelsim
 sim_tool_version          = 10.4
 
-lib_root_dirs             = ${RADIOHDL_WORK}/libraries ${RADIOHDL_WORK}/applications ${RADIOHDL_WORK}/boards
+lib_root_dirs             = ${HDL_WORK}/libraries ${HDL_WORK}/applications ${HDL_WORK}/boards
 
 [quartus]
 quartus_dir               = ${ALTERA_DIR}/<synth_tool_version>
diff --git a/config/hdl_buildset_unb2a.cfg b/config/hdl_buildset_unb2a.cfg
index 518b015a08ef024f7c22ec17a80904cf8ff8eebb..9d1513c8e1732c5a1c39c2084c18939b4413959c 100644
--- a/config/hdl_buildset_unb2a.cfg
+++ b/config/hdl_buildset_unb2a.cfg
@@ -9,7 +9,7 @@ synth_tool_version        = 16.0
 sim_tool_name             = modelsim
 sim_tool_version          = 10.4
 
-lib_root_dirs             = ${RADIOHDL_WORK}/libraries ${RADIOHDL_WORK}/applications ${RADIOHDL_WORK}/boards
+lib_root_dirs             = ${HDL_WORK}/libraries ${HDL_WORK}/applications ${HDL_WORK}/boards
 
 [quartus]
 quartus_dir               = ${ALTERA_DIR}/<synth_tool_version>
diff --git a/config/hdl_buildset_unb2b.cfg b/config/hdl_buildset_unb2b.cfg
index aae7f3253f4d7a03f5d2f6c4c8645bce7eb5ecc3..df2a666bd95b17a669c44fb1c8b7bdd24408da47 100644
--- a/config/hdl_buildset_unb2b.cfg
+++ b/config/hdl_buildset_unb2b.cfg
@@ -9,14 +9,14 @@ synth_tool_version        = 18.0
 sim_tool_name             = modelsim
 sim_tool_version          = 10.4
 
-#lib_root_dirs             = ${RADIOHDL_WORK}/libraries ${RADIOHDL_WORK}/applications ${RADIOHDL_WORK}/boards
-lib_root_dirs             = ${RADIOHDL_WORK}/libraries
-                            ${RADIOHDL_WORK}/boards/uniboard2b/
-                            ${RADIOHDL_WORK}/applications/disturb2
-                            ${RADIOHDL_WORK}/applications/lofar1
-                            ${RADIOHDL_WORK}/applications/lofar2/libraries
-                            ${RADIOHDL_WORK}/applications/lofar2/designs/lofar2_unb2b_sdp_station/
-                            ${RADIOHDL_WORK}/applications/lofar2/designs/lofar2_unb2b_ring/
+#lib_root_dirs             = ${HDL_WORK}/libraries ${HDL_WORK}/applications ${HDL_WORK}/boards
+lib_root_dirs             = ${HDL_WORK}/libraries
+                            ${HDL_WORK}/boards/uniboard2b/
+                            ${HDL_WORK}/applications/disturb2
+                            ${HDL_WORK}/applications/lofar1
+                            ${HDL_WORK}/applications/lofar2/libraries
+                            ${HDL_WORK}/applications/lofar2/designs/lofar2_unb2b_sdp_station/
+                            ${HDL_WORK}/applications/lofar2/designs/lofar2_unb2b_ring/
 
 [quartus]
 quartus_dir               = ${ALTERA_DIR}/<synth_tool_version>
diff --git a/config/hdl_buildset_unb2c.cfg b/config/hdl_buildset_unb2c.cfg
index fac5af517d0f494cc3d8304ab0574f7ccef6fdd5..4846d3615711383382a9435cfb191d5544a8f167 100644
--- a/config/hdl_buildset_unb2c.cfg
+++ b/config/hdl_buildset_unb2c.cfg
@@ -9,15 +9,15 @@ synth_tool_version        = 19.4
 sim_tool_name             = modelsim
 sim_tool_version          = 10.4
 
-#lib_root_dirs             = ${RADIOHDL_WORK}/libraries ${RADIOHDL_WORK}/applications ${RADIOHDL_WORK}/boards
-lib_root_dirs             = ${RADIOHDL_WORK}/libraries
-                            ${RADIOHDL_WORK}/boards/uniboard2c/
-                            ${RADIOHDL_WORK}/applications/disturb2
-                            ${RADIOHDL_WORK}/applications/lofar1
-                            ${RADIOHDL_WORK}/applications/lofar2/libraries
-                            ${RADIOHDL_WORK}/applications/lofar2/designs/lofar2_unb2c_sdp_station/
-                            ${RADIOHDL_WORK}/applications/lofar2/designs/lofar2_unb2c_ring/
-                            ${RADIOHDL_WORK}/applications/lofar2/designs/lofar2_unb2c_ddrctrl/
+#lib_root_dirs             = ${HDL_WORK}/libraries ${HDL_WORK}/applications ${HDL_WORK}/boards
+lib_root_dirs             = ${HDL_WORK}/libraries
+                            ${HDL_WORK}/boards/uniboard2c/
+                            ${HDL_WORK}/applications/disturb2
+                            ${HDL_WORK}/applications/lofar1
+                            ${HDL_WORK}/applications/lofar2/libraries
+                            ${HDL_WORK}/applications/lofar2/designs/lofar2_unb2c_sdp_station/
+                            ${HDL_WORK}/applications/lofar2/designs/lofar2_unb2c_ring/
+                            ${HDL_WORK}/applications/lofar2/designs/lofar2_unb2c_ddrctrl/
 
 [quartus]
 quartus_dir               = ${ALTERA_DIR}/<synth_tool_version>
diff --git a/core/generate_ip_libs b/core/generate_ip_libs
index e81fa0cc61db0bfc12a21648a1e260dc2ec8672d..0d0851f65d08c59bd87067ce4a29595f6d376187 100755
--- a/core/generate_ip_libs
+++ b/core/generate_ip_libs
@@ -179,7 +179,7 @@ if __name__ == '__main__':
                 if ip_lib_info.hdl_lib_technology == technology and ip_tool_key in ip_lib_info.content:
                     # we have a match do the compilation
                     print("==> Processing {} with {}".format(ip_lib_info.ID, ip_tool))
-                    outputdir = os.path.join(os.getenv('RADIOHDL_BUILD_DIR'), '{}/{}/'.format(args.buildset, ip_tool))
+                    outputdir = os.path.join(os.getenv('HDL_BUILD_DIR'), '{}/{}/'.format(args.buildset, ip_tool))
                     mkdir(outputdir)
                     vhdl_files = [name for name in ip_lib_info[ip_tool_key].replace("\t", " ").split(" ")
                                   if name != '']
diff --git a/core/hdl_libraries_wizard.py b/core/hdl_libraries_wizard.py
index 159399b49e0537686cd8432fc6f6510939e04491..64350604b5dd71d88caaf3afa9297ad941ebb57e 100644
--- a/core/hdl_libraries_wizard.py
+++ b/core/hdl_libraries_wizard.py
@@ -417,7 +417,7 @@ class HdlLibrariesWizard:
             - project_deeper_subdir = 'p/p/p/' when project_dir_depth_<build_type> = 3, etc
         """
         # Determine build_maindir
-        build_maindir = expandvars('${RADIOHDL_BUILD_DIR}')
+        build_maindir = expandvars('${HDL_BUILD_DIR}')
         if not isabs(build_maindir):
             sys.exit('Error : The build_dir value must be an absolute path')
 
diff --git a/core/modelsim_config b/core/modelsim_config
index 4cff95d98f2a73767fdd204be8c700f7054e89ee..4d61e7cff5f45e2cd32a13d6399155398fee1a25 100755
--- a/core/modelsim_config
+++ b/core/modelsim_config
@@ -112,7 +112,7 @@ class ModelsimConfig(hdl_libraries_wizard.HdlLibrariesWizard):
         """
         fileName = 'hdl_libraries_ip_' + technologyName + '.txt'         # use fixed file name format
         if filePath is None:
-            toolDir    = os.path.expandvars('$RADIOHDL_BUILD_DIR')
+            toolDir    = os.path.expandvars('$HDL_BUILD_DIR')
             toolSubDir = self.buildset['buildset_name']
             fileNamePath = os.path.join(toolDir, toolSubDir, fileName)          # default file path
         else:
diff --git a/core/test/cdf_dir/hdlbuildset_files/hdl_buildset_rsp.cfg b/core/test/cdf_dir/hdlbuildset_files/hdl_buildset_rsp.cfg
index dd80b96466ada21647f2d6c00f1056cb08189bca..ecc91adebee59f035b08217d5461401e5f9b6650 100644
--- a/core/test/cdf_dir/hdlbuildset_files/hdl_buildset_rsp.cfg
+++ b/core/test/cdf_dir/hdlbuildset_files/hdl_buildset_rsp.cfg
@@ -14,7 +14,7 @@ project_dir_depth_sim     = 4
 project_dir_depth_synth   = 0
 
 lib_root_dir              = $RSP
-build_dir                 = $RADIOHDL_BUILD_DIR
+build_dir                 = $HDL_BUILD_DIR
 quartus_dir               = /home/software/Altera/<synth_tool_version>
 model_tech_altera_lib     = /home/software/modelsim_altera_libs/<synth_tool_version>
 model_tech_dir            = /home/software/Mentor/<sim_tool_version>/modeltech
diff --git a/core/test/cdf_dir/hdlbuildset_files/hdl_buildset_unb1.cfg b/core/test/cdf_dir/hdlbuildset_files/hdl_buildset_unb1.cfg
index 2dd24f4e1c1e52c0029aa105fd7074c60b18f2e9..12716c0fa7483c70cf73343ffeb5e72c7cb4131d 100644
--- a/core/test/cdf_dir/hdlbuildset_files/hdl_buildset_unb1.cfg
+++ b/core/test/cdf_dir/hdlbuildset_files/hdl_buildset_unb1.cfg
@@ -9,8 +9,8 @@ sim_tool_version          = 6.6c
 synth_tool_name           = quartus
 synth_tool_version        = 11.1sp2
 
-lib_root_dirs             = ${RADIOHDL_WORK}/libraries ${RADIOHDL_WORK}/applications ${RADIOHDL_WORK}/boards
-build_dir                 = $RADIOHDL_BUILD_DIR
+lib_root_dirs             = ${HDL_WORK}/libraries ${HDL_WORK}/applications ${HDL_WORK}/boards
+build_dir                 = $HDL_BUILD_DIR
 quartus_dir               = /home/software/Altera/<synth_tool_version>
 model_tech_altera_lib     = /home/software/modelsim_altera_libs/<synth_tool_version>
 model_tech_dir            = /home/software/Mentor/<sim_tool_version>/modeltech
diff --git a/core/test/cdf_dir/hdlbuildset_files/hdl_buildset_wrong.cfg b/core/test/cdf_dir/hdlbuildset_files/hdl_buildset_wrong.cfg
index 3c1db609960d1dd7eae2a10c2537bb5c1db79a00..710001c87c29deead3bef91d74a4d92c6710e81c 100644
--- a/core/test/cdf_dir/hdlbuildset_files/hdl_buildset_wrong.cfg
+++ b/core/test/cdf_dir/hdlbuildset_files/hdl_buildset_wrong.cfg
@@ -10,7 +10,7 @@ synth_tool_name           = quartus
 synth_tool_version        = 11.1sp2
 
 lib_root_dir              = $HDL
-build_dir                 = $RADIOHDL_BUILD_DIR
+build_dir                 = $HDL_BUILD_DIR
 quartus_dir               = /home/software/Altera/<synth_tool_version>
 model_tech_altera_lib     = /home/software/modelsim_altera_libs/<synth_tool_version>
 model_tech_dir            = /home/software/Mentor/<sim_tool_version>/modeltech
diff --git a/core/test/cdf_dir/hdllib_files/hdllib_wrong.cfg b/core/test/cdf_dir/hdllib_files/hdllib_wrong.cfg
index a0b4b0c89b2e3a773bd63b785df5ca399a6016de..5380c8e41f1b3629a09da3d1b6cf8fde26c6b2d8 100644
--- a/core/test/cdf_dir/hdllib_files/hdllib_wrong.cfg
+++ b/core/test/cdf_dir/hdllib_files/hdllib_wrong.cfg
@@ -6,7 +6,7 @@ hdl_lib_technology =
 
 synth_files =
     technology_pkg.vhd
-    $RADIOHDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd
+    $HDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd
 test_bench_files =
 
 regression_test_vhdl = 
@@ -15,10 +15,10 @@ regression_test_vhdl =
 
 [modelsim_project_file]
 modelsim_copy_files = 
-    technology_select_pkg_<buildset_name>.vhd $RADIOHDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd
+    technology_select_pkg_<buildset_name>.vhd $HDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd
 
 
 
 [quartus_project_file]
 quartus_copy_files =
-    technology_select_pkg_<buildset_name>.vhd $RADIOHDL_BUILD_DIR/<buildset_name>/quartus/technology/technology_select_pkg.vhd
+    technology_select_pkg_<buildset_name>.vhd $HDL_BUILD_DIR/<buildset_name>/quartus/technology/technology_select_pkg.vhd
diff --git a/core/test/cdf_dir/hdllib_files/test_hdllib.cfg b/core/test/cdf_dir/hdllib_files/test_hdllib.cfg
index 20e85f381005f8596260bd38381ed56f61c8abea..c24839355912bf3ba817609afa49095e92a84fdc 100644
--- a/core/test/cdf_dir/hdllib_files/test_hdllib.cfg
+++ b/core/test/cdf_dir/hdllib_files/test_hdllib.cfg
@@ -6,7 +6,7 @@ hdl_lib_technology =
 
 synth_files =
     technology_pkg.vhd
-    $RADIOHDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd
+    $HDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd
 test_bench_files =
 
 regression_test_vhdl = 
@@ -15,10 +15,10 @@ regression_test_vhdl =
 
 [modelsim_project_file]
 modelsim_copy_files = 
-    technology_select_pkg_<buildset_name>.vhd $RADIOHDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd
+    technology_select_pkg_<buildset_name>.vhd $HDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd
 
 
 
 [quartus_project_file]
 quartus_copy_files =
-    technology_select_pkg_<buildset_name>.vhd $RADIOHDL_BUILD_DIR/<buildset_name>/quartus/technology/technology_select_pkg.vhd
+    technology_select_pkg_<buildset_name>.vhd $HDL_BUILD_DIR/<buildset_name>/quartus/technology/technology_select_pkg.vhd
diff --git a/core/test/cdf_dir/tree/hdlbuildset/hdl_buildset_rsp.cfg b/core/test/cdf_dir/tree/hdlbuildset/hdl_buildset_rsp.cfg
index dd80b96466ada21647f2d6c00f1056cb08189bca..ecc91adebee59f035b08217d5461401e5f9b6650 100644
--- a/core/test/cdf_dir/tree/hdlbuildset/hdl_buildset_rsp.cfg
+++ b/core/test/cdf_dir/tree/hdlbuildset/hdl_buildset_rsp.cfg
@@ -14,7 +14,7 @@ project_dir_depth_sim     = 4
 project_dir_depth_synth   = 0
 
 lib_root_dir              = $RSP
-build_dir                 = $RADIOHDL_BUILD_DIR
+build_dir                 = $HDL_BUILD_DIR
 quartus_dir               = /home/software/Altera/<synth_tool_version>
 model_tech_altera_lib     = /home/software/modelsim_altera_libs/<synth_tool_version>
 model_tech_dir            = /home/software/Mentor/<sim_tool_version>/modeltech
diff --git a/core/test/cdf_dir/tree/hdlbuildset/hdl_buildset_unb1.cfg b/core/test/cdf_dir/tree/hdlbuildset/hdl_buildset_unb1.cfg
index 15ff894e504cf3843e0cbcb8f1a0bc68c9a36fa8..1efd2317b57160cd59d5d3fcc30fd7b1966946d7 100644
--- a/core/test/cdf_dir/tree/hdlbuildset/hdl_buildset_unb1.cfg
+++ b/core/test/cdf_dir/tree/hdlbuildset/hdl_buildset_unb1.cfg
@@ -10,7 +10,7 @@ synth_tool_name           = quartus
 synth_tool_version        = 11.1sp2
 
 lib_root_dir              = $HDL
-build_dir                 = $RADIOHDL_BUILD_DIR
+build_dir                 = $HDL_BUILD_DIR
 quartus_dir               = /home/software/Altera/<synth_tool_version>
 model_tech_altera_lib     = /home/software/modelsim_altera_libs/<synth_tool_version>
 model_tech_dir            = /home/software/Mentor/<sim_tool_version>/modeltech
diff --git a/core/test/cdf_dir/tree/hdllib/technology/test_hdllib.cfg b/core/test/cdf_dir/tree/hdllib/technology/test_hdllib.cfg
index 20e85f381005f8596260bd38381ed56f61c8abea..c24839355912bf3ba817609afa49095e92a84fdc 100644
--- a/core/test/cdf_dir/tree/hdllib/technology/test_hdllib.cfg
+++ b/core/test/cdf_dir/tree/hdllib/technology/test_hdllib.cfg
@@ -6,7 +6,7 @@ hdl_lib_technology =
 
 synth_files =
     technology_pkg.vhd
-    $RADIOHDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd
+    $HDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd
 test_bench_files =
 
 regression_test_vhdl = 
@@ -15,10 +15,10 @@ regression_test_vhdl =
 
 [modelsim_project_file]
 modelsim_copy_files = 
-    technology_select_pkg_<buildset_name>.vhd $RADIOHDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd
+    technology_select_pkg_<buildset_name>.vhd $HDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd
 
 
 
 [quartus_project_file]
 quartus_copy_files =
-    technology_select_pkg_<buildset_name>.vhd $RADIOHDL_BUILD_DIR/<buildset_name>/quartus/technology/technology_select_pkg.vhd
+    technology_select_pkg_<buildset_name>.vhd $HDL_BUILD_DIR/<buildset_name>/quartus/technology/technology_select_pkg.vhd
diff --git a/core/test/t_hdl_configfile.py b/core/test/t_hdl_configfile.py
index 8e3fb6fd5f86ff4650b4fc65f6249d3ed355f911..eef9f6194dd1a52d3f9a81a3bbf599e76ff11ffc 100644
--- a/core/test/t_hdl_configfile.py
+++ b/core/test/t_hdl_configfile.py
@@ -143,7 +143,7 @@ class Test_hdl_buildset_file(unittest.TestCase):
         buildset = HdlBuildset("./cdf_dir/hdlbuildset_files/hdl_buildset_unb1.cfg")
         self.assertEqual(buildset.buildset_name, "unb1")
         self.assertEqual(buildset.technology_names, "ip_stratixiv")
-        self.assertEqual(buildset.lib_root_dirs, "${RADIOHDL_WORK}/libraries ${RADIOHDL_WORK}/applications ${RADIOHDL_WORK}/boards")
+        self.assertEqual(buildset.lib_root_dirs, "${HDL_WORK}/libraries ${HDL_WORK}/applications ${HDL_WORK}/boards")
 
     def test_read_wrong_hdlbuildset_file(self):
         self.assertRaises(ConfigFileException, HdlBuildset, "./cdf_dir/hdlbuildset_files/hdl_buildset_wrong.cfg")
diff --git a/core/test/t_hdl_configtree.py b/core/test/t_hdl_configtree.py
index 14feca0effc18afc935dce9cb325c06bb943bcef..a8143fe8ebc373a727c9c950dc6f5ede0ef5f678 100644
--- a/core/test/t_hdl_configtree.py
+++ b/core/test/t_hdl_configtree.py
@@ -61,7 +61,7 @@ class Test_tree_behaviour(unittest.TestCase):
     self.assertEqual(util.synth_files, 'src/vhdl/util_logic.vhd src/vhdl/util_heater_pkg.vhd src/vhdl/util_heater.vhd')
     technology = tree.configfiles['technology']
     self.assertEqual(technology.hdl_library_clause_name, 'technology_lib')
-    self.assertEqual(technology.synth_files, 'technology_pkg.vhd $RADIOHDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd')
+    self.assertEqual(technology.synth_files, 'technology_pkg.vhd $HDL_BUILD_DIR/<buildset_name>/modelsim/technology/technology_select_pkg.vhd')
 
     def test_hdlbuildset_tree(self):
         "Test if we can read in a tree with hdlbuildset files."
diff --git a/doc/hdltool_readme.txt b/doc/hdltool_readme.txt
index 9b7a9bc2829cdbd90667bc4b77e4e769964d680d..59d33c6e78a46661beb76cb272429febba57e448 100644
--- a/doc/hdltool_readme.txt
+++ b/doc/hdltool_readme.txt
@@ -296,35 +296,35 @@ b) Generate Quartus IP key
    can then generate the IP for all libraries that have such a key. The IP can then be generated outside the SVN tree.
    The $IP_DIR path compile_ip.tcl needs to be adjusted to generated/ and the IP then gets generated in:
    
-      $RADIOHDL_BUILD_DIR/<buildset_name>/quartus/<hdl_lib_name>/generated
+      $HDL_BUILD_DIR/<buildset_name>/quartus/<hdl_lib_name>/generated
    
    For generated IP that is kept in SVN that IP could still remain there.
    
    The hdllib.cfg should then also define a IP tool name subdirectory in build dir, eg.:
     
-     $RADIOHDL_BUILD_DIR/<buildset_name>/<tool_name> = $HDL_BUILD_DIR/qsys        or
+     $HDL_BUILD_DIR/<buildset_name>/<tool_name> = $HDL_BUILD_DIR/qsys        or
                                                         $HDL_BUILD_DIR/megawizard
     
-   or more general $RADIOHDL_BUILD_DIR/ip?
-   The $RADIOHDL_BUILD_DIR now has a modelsim and quartus subdir:
+   or more general $HDL_BUILD_DIR/ip?
+   The $HDL_BUILD_DIR now has a modelsim and quartus subdir:
     
-      $RADIOHDL_BUILD_DIR/<buildset_name>/modelsim       -- made by modelsim_config.py using sim_tool_name from hdl_buildset_<buildset_name>.cfg
-      $RADIOHDL_BUILD_DIR/<buildset_name>/quartus        -- made by quartus_config.py using synth_tool_name from hdl_buildset_<buildset_name>.cfg
+      $HDL_BUILD_DIR/<buildset_name>/modelsim       -- made by modelsim_config.py using sim_tool_name from hdl_buildset_<buildset_name>.cfg
+      $HDL_BUILD_DIR/<buildset_name>/quartus        -- made by quartus_config.py using synth_tool_name from hdl_buildset_<buildset_name>.cfg
    
    The IP can be put in a subdir using eg 'tool_name_ip' = quartus_ip:
    
-      $RADIOHDL_BUILD_DIR/<buildset_name>/quartus_ip     -- made by quartus_config.py using a new tool_name_ip from hdl_buildset_<buildset_name>.cfg
+      $HDL_BUILD_DIR/<buildset_name>/quartus_ip     -- made by quartus_config.py using a new tool_name_ip from hdl_buildset_<buildset_name>.cfg
       
    or can it be put in the synth_tool_name directory:
    
-      $RADIOHDL_BUILD_DIR/<buildset_name>/quartus
+      $HDL_BUILD_DIR/<buildset_name>/quartus
       
    or do we need tool_name_megawizard and tool_name_qsys to be able to create:
                                       
-      $RADIOHDL_BUILD_DIR/<buildset_name>/<tool_name>
-      $RADIOHDL_BUILD_DIR/unb1/megawizard     -- Altera MegaWizard
-      $RADIOHDL_BUILD_DIR/unb1/qsys           -- Altera QSYS
-      $RADIOHDL_BUILD_DIR/unb1/coregen        -- Xilinx
+      $HDL_BUILD_DIR/<buildset_name>/<tool_name>
+      $HDL_BUILD_DIR/unb1/megawizard     -- Altera MegaWizard
+      $HDL_BUILD_DIR/unb1/qsys           -- Altera QSYS
+      $HDL_BUILD_DIR/unb1/coregen        -- Xilinx
       
    Probably it is not so important whether the IP is generated by MegaWizard or Qsys, because that selection is
    already covered by the generate_ip.sh scripts. In the hdl_buildset_<buildset_name>.cfg both MegaWizard and Qsys can be regarded as
@@ -399,7 +399,7 @@ by hdl_config.py, so these IP libraries will not be build.
 
 The build directory currently contains:
 
-  $RADIOHDL_BUILD_DIR/<buildset_name>/<tool_name>/<hdl_lib_name>
+  $HDL_BUILD_DIR/<buildset_name>/<tool_name>/<hdl_lib_name>
 
 This scheme is probably still sufficent to also support the FPGA technology as a triplet. However it may be necessary to rename the
 library key values in the IP hdllib.cfg to contain the full triplet information, so eg.
diff --git a/doc/radiohdl_hdl_buildset_key_descriptions.md b/doc/radiohdl_hdl_buildset_key_descriptions.md
index d34b70f700375506e26ef97bbb2b8025bc4f1e3d..4a6ddbc694e2b525663d59758081f822cb494de1 100644
--- a/doc/radiohdl_hdl_buildset_key_descriptions.md
+++ b/doc/radiohdl_hdl_buildset_key_descriptions.md
@@ -57,7 +57,7 @@ Name and version of simulation tool to use with this buildset. Used as subdirect
 Name and version of synthesis tool to use with this buildset. Used as subdirectory name in the build directory, e.g. quartus, 11.1. Note: RadioHDL will look for a key in this config file that has the name of the value of sim_tool_name extended with '_dir'. So in this example file RadioHDL expects a key with the name quartus_dir.
 
 ***lib_root_dirs***  
-List of one or more root directories from where all HDL library configuration files (hdllib.cfg) are searched. There is only a single root directory for the build tree, that is defined by $RADIOHDL_BUILD_DIR.
+List of one or more root directories from where all HDL library configuration files (hdllib.cfg) are searched. There is only a single root directory for the build tree, that is defined by $HDL_BUILD_DIR.
 
 ### 2.1 [modelsim]
 ***modelsim_dir***  
diff --git a/doc/radiohdl_hdl_buildset_uniboard1.md b/doc/radiohdl_hdl_buildset_uniboard1.md
index fed70c8b8f39f8a102c750b28173ec3d512c2d0f..0846d07f45d2dc6e82cbb9a4423f38de4b301e2b 100644
--- a/doc/radiohdl_hdl_buildset_uniboard1.md
+++ b/doc/radiohdl_hdl_buildset_uniboard1.md
@@ -87,10 +87,10 @@ The UniBoard1 HDL source code is available in a source directory tree at hdl/. S
 ```
 The init_hdl.sh defines:
 
-- RADIOHDL_WORK directory for where the source code resides
-- RADIOHDL_BUILD_DIR directory for where the targets will be build
+- HDL_WORK directory for where the source code resides
+- HDL_BUILD_DIR directory for where the targets will be build
   
-The init_hdl.sh copies version controlled ${RADIOHDL_WORK}/hdl_user_components.ipx into the Altera dir's at ```$ALTERA_DIR/<tool version>/ip/altera/user_components.ipx```. This Altera user_components.ipx contains the search paths that Altera SOPC builder and Altera QSYS use.
+The init_hdl.sh copies version controlled ${HDL_WORK}/hdl_user_components.ipx into the Altera dir's at ```$ALTERA_DIR/<tool version>/ip/altera/user_components.ipx```. This Altera user_components.ipx contains the search paths that Altera SOPC builder and Altera QSYS use.
 
 > **NOTE:** Altera says that you can use your personal user_components.ipx file in ```~/.altera.quartus/ip/<quartus_version>/ip_search_path``` for this kind of additional paths but tests show that this does not work for all tools of Altera. Therefore the user_components.ipx file is copied to the Altera installation directory.
 
@@ -103,7 +103,7 @@ The init_hdl.sh can automatically also source init_radiohdl.sh, or source these
 The init_radiohdl.sh from the RadioHDL package defines:
 
 - RADIOHDL_GEAR directory of where the init_radiohdl.sh is located
-- RADIOHDL_BUILD_DIR = ${RADIOHDL_BUILD_DIR}/build if not already defined
+- HDL_BUILD_DIR = ${HDL_BUILD_DIR}/build if not already defined
 - RADIOHDL_CONFIG = ${RADIOHDL_GEAR}/config if not already defined
                                 
 The init_radiohdl.sh extends:
@@ -170,7 +170,7 @@ Creates:
 * directories ```build/unb1/quartus/<hdllib libraries>``` with Quartus files for synthesis
 * file build/unb1/quartus/technology_select_pkg.vhd to select stratixiv technology for UniBoard1
 
-The quartus_config creates the Quartus qpf, qsf for a top level design library and Quartus qip files all libraries. If a new VHDL file is added to a library or if a filename is changed, then it is necessary to rerun the quartus_config. Typically it is not necessary to do delete the entire $RADIOHDL_BUILD_DIR library of the design directory, but it can be necessary to make sure that Quartus is not 'confused' by obsolete files in that build directory. Make sure that any image files that needs to be kept are saved elsewhere, before deleting the build directory of the design library.
+The quartus_config creates the Quartus qpf, qsf for a top level design library and Quartus qip files all libraries. If a new VHDL file is added to a library or if a filename is changed, then it is necessary to rerun the quartus_config. Typically it is not necessary to do delete the entire $HDL_BUILD_DIR library of the design directory, but it can be necessary to make sure that Quartus is not 'confused' by obsolete files in that build directory. Make sure that any image files that needs to be kept are saved elsewhere, before deleting the build directory of the design library.
 
 
 #### 2.4.5 Create an IP block design for a design library in your project
@@ -190,7 +190,7 @@ Syntax:
   > run_qsys <buildset> <project> [<qsysfile>]  
   > run_sopc <buildset> <project> [<sopcfile>]  
 ```
-Both utilities only differ in name not in functionality. The ```<project>``` is a HDL library directory that needs to exist under $RADIOHDL_BUILD_DIR/${buildset}/quartus. If no ```<qsysfile>``` respectively ```<sopcfile>``` is specified during the invocation, then the utility will look for a file with the name ```<project>.qsys``` or ```<project>.sopc``` in the project directory.
+Both utilities only differ in name not in functionality. The ```<project>``` is a HDL library directory that needs to exist under $HDL_BUILD_DIR/${buildset}/quartus. If no ```<qsysfile>``` respectively ```<sopcfile>``` is specified during the invocation, then the utility will look for a file with the name ```<project>.qsys``` or ```<project>.sopc``` in the project directory.
 
 After generating all necessary files the utility will also build the software for the NiosII application using the RadioHDL run_app script. This run_app calls run_bsp and run_reg. The run_reg calls run_mif. For the FPGA designs on UniBoard the NiosII software application is fixed, because it implements the monitoring and control protocol interface between the 1GbE port and the memory mapped bus that is generated by SOPC or QSYS. The NiosII is the master on the memory mapped bus, and the slaves are configurable dependent on the design.
 
@@ -240,9 +240,9 @@ synth_tool_version        = 11.1
 sim_tool_name             = modelsim  
 sim_tool_version          = 6.6c  
   
-lib_root_dirs             = ${RADIOHDL_WORK}/libraries  
-                            ${RADIOHDL_WORK}/applications  
-                            ${RADIOHDL_WORK}/boards  
+lib_root_dirs             = ${HDL_WORK}/libraries  
+                            ${HDL_WORK}/applications  
+                            ${HDL_WORK}/boards  
   
 [quartus]  
 quartus_dir               = ${ALTERA_DIR}/<synth_tool_version>  
diff --git a/doc/radiohdl_hdl_buildset_uniboard2.md b/doc/radiohdl_hdl_buildset_uniboard2.md
index c13f708f09bbebdf2764fe5c3a08ca9ae1fbc666..cd43c3b868d162af60b52e2f98406c337fb3db28 100644
--- a/doc/radiohdl_hdl_buildset_uniboard2.md
+++ b/doc/radiohdl_hdl_buildset_uniboard2.md
@@ -65,7 +65,7 @@ synth_tool_version        = 18.0
 sim_tool_name             = modelsim
 sim_tool_version          = 10.4
 
-lib_root_dirs             = ${RADIOHDL_WORK}/libraries ${RADIOHDL_WORK}/applications ${RADIOHDL_WORK}/boards
+lib_root_dirs             = ${HDL_WORK}/libraries ${HDL_WORK}/applications ${HDL_WORK}/boards
 
 [quartus]
 quartus_dir               = ${ALTERA_DIR}/<synth_tool_version>
diff --git a/doc/radiohdl_hdl_library_key_descriptions.md b/doc/radiohdl_hdl_library_key_descriptions.md
index 337e5b8dda40b9982e4e3cfa137b5646c571dbfe..61c06fd3b771f3f9986928da4a8e3683c50bae4d 100644
--- a/doc/radiohdl_hdl_library_key_descriptions.md
+++ b/doc/radiohdl_hdl_library_key_descriptions.md
@@ -302,7 +302,7 @@ hdl_lib_uses_sim =
 hdl_lib_technology = ip_stratixiv
 
 synth_files =
-    $RADIOHDL_BUILD_DIR/unb1/quartus/unb1_minimal_sopc/sopc_unb1_minimal.vhd
+    $HDL_BUILD_DIR/unb1/quartus/unb1_minimal_sopc/sopc_unb1_minimal.vhd
     src/vhdl/qsys_unb1_minimal_pkg.vhd
     src/vhdl/mmm_unb1_minimal.vhd
     src/vhdl/unb1_minimal.vhd
@@ -382,7 +382,7 @@ test_bench_files =
 modelsim_copy_files =  
     
 modelsim_compile_ip_files =  
-    $RADIOHDL_WORK/libraries/technology/ip_stratixiv/mac_10g/compile_ip.tcl    
+    $HDL_WORK/libraries/technology/ip_stratixiv/mac_10g/compile_ip.tcl    
   
 [quartus_project_file]  
 quartus_copy_files =  
diff --git a/doc/radiohdl_hdl_tool_modelsim.md b/doc/radiohdl_hdl_tool_modelsim.md
index bb539719ebaba9d330f8b51239a9391fd968e3bf..86b7f1c15cd932b1583270be0d84c003d5b373b2 100644
--- a/doc/radiohdl_hdl_tool_modelsim.md
+++ b/doc/radiohdl_hdl_tool_modelsim.md
@@ -53,7 +53,7 @@ If the HDL uses vendor technology libraries then run the corresponding vendor sp
 
 ---
 ## 2 Creating Modelsim project files
-The binaries for Modelsim are built in a separate directory tree under $RADIOHDL_BUILD_DIR.
+The binaries for Modelsim are built in a separate directory tree under $HDL_BUILD_DIR.
 Use modelsim_config to create the Modelsim project files (mpf) for all your HDL libraries. In this example the quick start buildset 'qs' is used:
 ```
   > modelsim_config -h
@@ -61,21 +61,21 @@ Use modelsim_config to create the Modelsim project files (mpf) for all your HDL
 ```
 The modelsim_config script puts the created files and copied files in the build directory, at:
 ```
-$RADIOHDL_BUILD_DIR/<buildset_name>/<sim_tool_name>/<hdl_lib_name>
+$HDL_BUILD_DIR/<buildset_name>/<sim_tool_name>/<hdl_lib_name>
 ```
 For 'buildset_name = qs' and 'sim_tool_name = modelsim' defined in hdl_buildset_qs.cfg this is at:
 ```
-  $RADIOHDL_BUILD_DIR/qs/modelsim
+  $HDL_BUILD_DIR/qs/modelsim
 ```
-The ```<hdl_lib_name>``` sub directories follow from the 'hdl_lib_name' key that is defined in the hdllib.cfg configuration files per HDL library. The modelsim_config script finds all hdllib.cfg files within 'lib_root_dirs = ${RADIOHDL_WORK}' that is defined in hdl_buildset_qs.cfg. The lib_root_dirs  can list one or more search trees.
+The ```<hdl_lib_name>``` sub directories follow from the 'hdl_lib_name' key that is defined in the hdllib.cfg configuration files per HDL library. The modelsim_config script finds all hdllib.cfg files within 'lib_root_dirs = ${HDL_WORK}' that is defined in hdl_buildset_qs.cfg. The lib_root_dirs  can list one or more search trees.
 
 Optionally you can clear this directory before running modelsim_config because everything is recreated:
 ```
-  > rm -rf $RADIOHDL_BUILD_DIR/qs/modelsim
+  > rm -rf $HDL_BUILD_DIR/qs/modelsim
 ```
 If the HDL library dependencies change, e.g. because a new VHDL file is added to a library, or if a filename is changed, then it is necessary to rerun the modelsim_config.
 
-In addition to the Modelsim project files the modelsim_config also generates some auxiliary files that are used by commands.do in run_modelsim as quick reference to all HDL libraries. The central modelsim_project_files.txt at $RADIOHDL_BUILD_DIR/qs/modelsim/ contains a list of the paths to all HDL libraries. Per HDL library there is a ```<lib_name>_lib_order.txt``` file that contains a list of all HDL libraries  that this HDL library depends on in order.
+In addition to the Modelsim project files the modelsim_config also generates some auxiliary files that are used by commands.do in run_modelsim as quick reference to all HDL libraries. The central modelsim_project_files.txt at $HDL_BUILD_DIR/qs/modelsim/ contains a list of the paths to all HDL libraries. Per HDL library there is a ```<lib_name>_lib_order.txt``` file that contains a list of all HDL libraries  that this HDL library depends on in order.
 
 ---
 ## 3 Using Modelsim
@@ -129,7 +129,7 @@ Load Modelsim project file for HDL library dp_repack_data:
 ```
   ModelSim> lp dp_repack_data
 ```
-Clean build directories and makefiles in $RADIOHDL_BUILD_DIR that were made for dp_repack_data:
+Clean build directories and makefiles in $HDL_BUILD_DIR that were made for dp_repack_data:
 ```
   ModelSim> mk clean all
 ```
@@ -145,7 +145,7 @@ To make only the specific common_pkg library do:
 ```
   ModelSim> mk common_pkg
 ```
-The first time 'mk all' is called the libraries are compiled and the library makefiles are made. The library makefiles are stored in the library build directories in $RADIOHDL_BUILD_DIR. It is important that all libraries compile OK, because otherwise the library makefiles are not created properly. Therefore if a library fails to compile, then load that library project with 'lp' and keep on doing 'mk compile' until the library compiles OK. Then when it compiles OK do 'mk clean' to clear the library build directory at $RADIOHDL_BUILD_DIR, and then do 'mk' or 'mk all' to compile the library again and create a proper makefile. Repeat this process until also the top level HDL library compiles OK.
+The first time 'mk all' is called the libraries are compiled and the library makefiles are made. The library makefiles are stored in the library build directories in $HDL_BUILD_DIR. It is important that all libraries compile OK, because otherwise the library makefiles are not created properly. Therefore if a library fails to compile, then load that library project with 'lp' and keep on doing 'mk compile' until the library compiles OK. Then when it compiles OK do 'mk clean' to clear the library build directory at $HDL_BUILD_DIR, and then do 'mk' or 'mk all' to compile the library again and create a proper makefile. Repeat this process until also the top level HDL library compiles OK.
 
 With the proper makefiles for all HDL libraries it is sufficient to use 'mk' to automatically recompile only the HDL source files that changed or that depend on the changed file. Similar with 'mk all' a change in some lower level library HDL file will only cause that the HDL files that depend on it will be recompiled. For a big project with many libraries using 'mk all' is much easier and faster to use than 'mk compile all'. Doing 'mk all' and again 'mk all' should show that the second 'mk all' did not need to recompile any HDL again.
 
@@ -165,7 +165,7 @@ Then the 'mk all' in the dp_repack_data library will not recompile the libraries
 ```
 Then the 'mk all' in the dp_repack_data library will recompile and recreate the makefile for the common_pkg library, and then reompile the HDL files in the higher libraries (up to dp_repack_data) that directly or indirectly depend on a HDL file in the common_pkg library.
 
-If a new VHDL file is added to a library or if a filename is changed, then it is necessary to rerun the modelsim_config and to do 'mk clean' on that library. It is important that Modelsim does not have that library open already, so either quit Modelsim first or 'lp' to another library first, before running modelsim_config. Typically it is not necessary to do 'mk clean all', nor is it necessary to delete the entire $RADIOHDL_BUILD_DIR library subdirectories.
+If a new VHDL file is added to a library or if a filename is changed, then it is necessary to rerun the modelsim_config and to do 'mk clean' on that library. It is important that Modelsim does not have that library open already, so either quit Modelsim first or 'lp' to another library first, before running modelsim_config. Typically it is not necessary to do 'mk clean all', nor is it necessary to delete the entire $HDL_BUILD_DIR library subdirectories.
 
 ### 3.3 Simulating the HDL
 
diff --git a/doc/radiohdl_user_guide.md b/doc/radiohdl_user_guide.md
index ff7525cabd7e6df7351df4949dba099efd58ef41..a2162676ce5574b3b6bf4b73eda13443294c4b77 100644
--- a/doc/radiohdl_user_guide.md
+++ b/doc/radiohdl_user_guide.md
@@ -68,7 +68,7 @@ The parameters for the HDL source libraries, the vendor IP blocks, the build too
 
 After setting up the configuration files for the tools and the source files, RadioHDL can create for the selected buildset all libraries for simulation, create all IP libraries, find out dependencies, generate project files and do a lot more of these labour-intensive tasks automatically.
 
-![Figure 1](./radiohdl_work_flow.jpg "radiohdl_work_flow.jpg")  
+![Figure 1](./HDL_WORK_flow.jpg "HDL_WORK_flow.jpg")  
 Figure 1: RadioHDL flow from source to target
 
 The main benefit of RadioHDL is that it speeds up HDL development by providing a uniform and automated way of using tools and building code. The disadvantage of using RadioHDL is that it requires an initial effort to support a vendor tool and to maintain this support with changes in vendor tool versions. However in practice it has appeared worth the effort to use and maintain RadioHDL.
@@ -109,7 +109,7 @@ Create a directory at some location $QS_DIR to store the quick start (QS) exampl
   $QS_DIR/cores/dp/dp_pkg
   $QS_DIR/cores/dp/dp_repack_data
 ```
-Source init_qs.sh from within $QS_DIR to set the RadioHDL environment variables RADIOHDL_WORK and RADIOHDL_BUILD_DIR for the quick start (qs) project.
+Source init_qs.sh from within $QS_DIR to set the RadioHDL environment variables HDL_WORK and HDL_BUILD_DIR for the quick start (qs) project.
 ```
   > . ./init_qs.sh
 ```
@@ -130,7 +130,7 @@ Use RadioHDL to build Modelsim simulation project files (*.mpf) for the quick st
 ```
 The modelsim_config script puts the created files and copied files in the build directory, at:
 ```
-  $RADIOHDL_BUILD_DIR/qs/modelsim
+  $HDL_BUILD_DIR/qs/modelsim
 ```
 
 ### 2.4 Simulate the HDL test bench in Modelsim
@@ -179,9 +179,9 @@ The utility **modify_configfiles** implements a tiny menu system that enables yo
 The following environment variables are important for RadioHDL:
 
 * RADIOHDL_GEAR : Points to the main directory where your checked out the RadioHDL package. This is the location where this init_radiohdl.sh file is located. Do not change this variable.
-* RADIOHDL_BUILD_DIR : Points to the directory where RadioHDL will store all its result files. If this variable is not already set when init_radiohdl.sh is run, then it will be set to point to $RADIOHDL_WORK/build.
+* HDL_BUILD_DIR : Points to the directory where RadioHDL will store all its result files. If this variable is not already set when init_radiohdl.sh is run, then it will be set to point to $HDL_WORK/build.
 * RADIOHDL_CONFIG : Points to the directory where RadioHDL expects the hdl_buildset and hdl_tool configuration files. If this variable is not already set when init_radiohdl.sh is run, then it will be set to point to $RADIOHDL_GEAR/config.
-* RADIOHDL_WORK : Points to the root directory of the your project that will use RadioHDL.
+* HDL_WORK : Points to the root directory of the your project that will use RadioHDL.
 
 
 ### 3.2 Configuration files kinds
@@ -306,7 +306,7 @@ This is equivalent with:
 ```
 You can use environment variables in values:
 ```
-    lib_root_dirs = ${RADIOHDL_WORK}
+    lib_root_dirs = ${HDL_WORK}
 ```
 Keys are always in lowercase even when the name of the key will be used as environment variable. RadioHDL takes care that the key names are converted to uppercase in these cases.
 
diff --git a/init_radiohdl.sh b/init_radiohdl.sh
index cfc6deffc00dca4e46d04aa50153b17b99296267..cc6654f553fe0186d8cc47e78e8f0262cea0a1b6 100755
--- a/init_radiohdl.sh
+++ b/init_radiohdl.sh
@@ -34,12 +34,12 @@ if [[ "$_" == "${0}" ]]; then
     return
 fi
 
-# check for RADIOHDL_WORK variable , if it not exists:
+# check for HDL_WORK variable , if it not exists:
 # 1) run ". ./init_hdl.sh" in the hdl source dir instead.
 # 2) or set variable manualy
 
-if [[ -z "${RADIOHDL_WORK}" ]]; then
-    echo "environ variable 'RADIOHDL_WORK' not available"
+if [[ -z "${HDL_WORK}" ]]; then
+    echo "environ variable 'HDL_WORK' not available"
     echo "source 'init_hdl.sh' script in hdl directory instead of this one"
     echo ". ./init_hdl.sh"
     return
@@ -56,14 +56,16 @@ do
     fi
 done
 
-echo "RadioHDL environment will be setup for" $RADIOHDL_WORK
+echo "RadioHDL environment will be setup for" $HDL_WORK
 
 # Figure out where this script is located and set environment variables accordingly
 export RADIOHDL_GEAR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
-#export RADIOHDL_GEAR=${RADIOHDL_GEAR}
 # setup paths to build and config dir if not already defined by the user.
-#export RADIOHDL_BUILD_DIR=${RADIOHDL_BUILD_DIR:-${RADIOHDL_WORK}/build}
 export RADIOHDL_CONFIG="${RADIOHDL_CONFIG:-${RADIOHDL_GEAR}/config}"
+export RADIOHDL_BUILD_RESULT="${HOME}/hdl_build_result"
+if [ ! -d "${RADIOHDL_BUILD_RESULT}" ]; then
+    mkdir "${RADIOHDL_BUILD_RESULT}"
+fi
 
 . ${RADIOHDL_GEAR}/generic.sh
 
diff --git a/modelsim/commands.do b/modelsim/commands.do
index 5fee58a518cb04556c2cd3fc19f7b85571adbde3..a266132a17c6333ad7b70000c5f3620be687c8be 100644
--- a/modelsim/commands.do
+++ b/modelsim/commands.do
@@ -56,7 +56,7 @@ proc hdl_env {} {
 
 proc hdl_build {} {
     global env
-    return $env(RADIOHDL_BUILD_DIR)
+    return $env(HDL_BUILD_DIR)
 }
 
 proc hdl_buildset {} {
diff --git a/quartus/build_all_images b/quartus/build_all_images
index 4dbd2ba96964cb54e12d86e69f7f88ce2cb7b0ea..4d415bd9a1002be0965fdf5981223bf1fccf8040 100755
--- a/quartus/build_all_images
+++ b/quartus/build_all_images
@@ -2,23 +2,23 @@
 # set -eu
 # -------------------------------------------------------------------------- #
 #
-# Copyright (C) 2022                                                        
+# Copyright (C) 2022
 # ASTRON (Netherlands Institute for Radio Astronomy) <http://www.astron.nl/>
-# JIVE (Joint Institute for VLBI in Europe) <http://www.jive.nl/>           
-# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands                             
-#                                                                           
-# This program is free software: you can redistribute it and/or modify      
-# it under the terms of the GNU General Public License as published by      
-# the Free Software Foundation, either version 3 of the License, or         
-# (at your option) any later version.                                       
-#                                                                           
-# This program is distributed in the hope that it will be useful,           
-# but WITHOUT ANY WARRANTY; without even the implied warranty of            
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             
-# GNU General Public License for more details.                              
-#                                                                           
-# You should have received a copy of the GNU General Public License         
-# along with this program.  If not, see <http://www.gnu.org/licenses/>.     
+# JIVE (Joint Institute for VLBI in Europe) <http://www.jive.nl/>
+# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 # -------------------------------------------------------------------------- #
 #
@@ -74,7 +74,7 @@ fi
 if [ $# -lt 1 ]; then
     exit_with_error "Wrong number of arguments specified."
 fi
-filename=$1 
+filename=$1
 
 # Build image for each line in $filename
 # skip lines starting with #
@@ -97,18 +97,6 @@ grep -v '^#' < "${filename}" | {
             else
                 hdl_exec "$0" build_image "${BUILDSET}" "${PROJECT}" --rev="${REVISION}"
             fi
-            # Copy resulting bitstream to $out directory
-            if [ -n "${out}" ]; then
-                if [ ! -d "${out}" ]; then
-                    hdl_exec "$0" mkdir "${out}"
-                fi
-                # get rbf/sof filename git hash will be expanded
-                rbf_file=("${RADIOHDL_BUILD_DIR}"/"${BUILDSET}"/quartus/"${REVISION}"/"${REVISION}"-*.rbf)
-                sof_file=("${RADIOHDL_BUILD_DIR}"/"${BUILDSET}"/quartus/"${REVISION}"/"${REVISION}"-*.sof)
-                # copy files if exist
-                [[ -f "${rbf_file}" ]] && hdl_exec "$0" cp "${rbf_file}" "${out}"
-                [[ -f "${sof_file}" ]] && hdl_exec "$0" cp "${sof_file}" "${out}"
-            fi
             STOP_TIMESTAMP=$(date +"%Y-%m-%d %H:%M:%S")
             echo "== STOP BUILD == at ${STOP_TIMESTAMP}"
         fi
diff --git a/quartus/build_image b/quartus/build_image
index b2dec0833318515b4f9cefa06c16b94cc7ab6a27..14bb9e081c3daac6db78f7d02aaaf22a9bffa29b 100755
--- a/quartus/build_image
+++ b/quartus/build_image
@@ -2,29 +2,29 @@
 set -eu
 # -------------------------------------------------------------------------- #
 #
-# Copyright (C) 2022                                                        
+# Copyright (C) 2022
 # ASTRON (Netherlands Institute for Radio Astronomy) <http://www.astron.nl/>
-# JIVE (Joint Institute for VLBI in Europe) <http://www.jive.nl/>           
-# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands                             
-#                                                                           
-# This program is free software: you can redistribute it and/or modify      
-# it under the terms of the GNU General Public License as published by      
-# the Free Software Foundation, either version 3 of the License, or         
-# (at your option) any later version.                                       
-#                                                                           
-# This program is distributed in the hope that it will be useful,           
-# but WITHOUT ANY WARRANTY; without even the implied warranty of            
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             
-# GNU General Public License for more details.                              
-#                                                                           
-# You should have received a copy of the GNU General Public License         
-# along with this program.  If not, see <http://www.gnu.org/licenses/>.     
+# JIVE (Joint Institute for VLBI in Europe) <http://www.jive.nl/>
+# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 # -------------------------------------------------------------------------- #
 #
 # Author: Reinier vd Walle
 # Purpose: Run all commands in order to compile a Quartus design.
-# Description: Executes quartus_config, run_qsys_pro, gen_rom_mmap.py, run_reg, 
+# Description: Executes quartus_config, run_qsys_pro, gen_rom_mmap.py, run_reg,
 # run_qcomp and run_rbf to do a full compilation of a quartus design. The bitstream
 # files (.sof and.rbf) will be in the corresponding build directory of the design.
 # Run this tool with at least the commandline arguments:
@@ -89,15 +89,15 @@ project=$2
 hdl_exec "$0" quartus_config "${buildset}"
 
 
-PRJS="${RADIOHDL_BUILD_DIR}"
+PRJS="${HDL_BUILD_DIR}"
 PRJ=
 for prj in ${PRJS}
     do
         echo "check if project '${project}' in dir '${prj}'"
         if [ -d "${prj}/${buildset}/quartus/${project}" ]; then
             PRJ=${prj}
-        fi  
-    done  
+        fi
+    done
 if [ -z "${project}" -o -z "${PRJ}" ]; then
     hdl_error "$0" "Please enter a valid project name"
 fi
@@ -131,7 +131,5 @@ hdl_exec "$0" run_reg "${buildset}" "${project_rev}"
 hdl_exec "$0" run_qcomp "${buildset}" "${project_rev}" --clk=CLK --seed="${SEED}"
 
 # run_rbf
-hdl_exec "$0" run_rbf "${buildset}" "${project_rev}"
-
-
-
+# for user image now done in run_qcomp
+# hdl_exec "$0" run_rbf "${buildset}" "${project_rev}"
diff --git a/quartus/compile_altera_simlibs b/quartus/compile_altera_simlibs
index f66cd3cb0cd8d648bb0d7b99f18929ba495c85f9..636f741051cbbb3b65fe842b0d308bf568606e43 100755
--- a/quartus/compile_altera_simlibs
+++ b/quartus/compile_altera_simlibs
@@ -54,9 +54,9 @@ buildset=$1
 # Select output directory for the library compilation results
 buildset_config_file="${RADIOHDL_CONFIG}/hdl_buildset_${buildset}.cfg"
 . ${RADIOHDL_GEAR}/set_config_variable $buildset_config_file synth_tool_name,synth_tool_version
-OUTPUT_DIR=${RADIOHDL_BUILD_DIR}/${SYNTH_TOOL_NAME}/${SYNTH_TOOL_VERSION}
+OUTPUT_DIR=${HDL_BUILD_DIR}/${SYNTH_TOOL_NAME}/${SYNTH_TOOL_VERSION}
 mkdir -p ${OUTPUT_DIR}
-mkdir -p ${RADIOHDL_BUILD_DIR}/${buildset}
+mkdir -p ${HDL_BUILD_DIR}/${buildset}
 
 # Select FPGA device family for the library compilation
 . ${RADIOHDL_GEAR}/set_config_variable $buildset_config_file family_names
@@ -107,7 +107,7 @@ do
     $MODELSIM_DIR/$MODELSIM_PLATFORM/vsim -c -do ${FAMILY}_vhdl.do
 
     # 5) Leave files for modelsim_config
-    libraryfile=${RADIOHDL_BUILD_DIR}/${buildset}/hdl_libraries_ip_${FAMILY}.txt
+    libraryfile=${HDL_BUILD_DIR}/${buildset}/hdl_libraries_ip_${FAMILY}.txt
     rm -f ${libraryfile}
     grep vmap ${OUTPUT_DIR}/${FAMILY}_*.do | sort | \
          sed "s?${OUTPUT_DIR}?\$MODEL_TECH_ALTERA_LIB?g" | while read vmap label location
diff --git a/quartus/run_app b/quartus/run_app
index b161746ae30ba2f1be7e00d69df24a780a66ac3f..3d1a135695e980158b1cfb72c684a30a3e173c58 100755
--- a/quartus/run_app
+++ b/quartus/run_app
@@ -120,7 +120,7 @@ if [ -z "${NIOSDIR}" ]; then
 fi
 
 # search for existing project directory
-PRJS="${RADIOHDL_BUILD_DIR}"
+PRJS="${HDL_BUILD_DIR}"
 PRJ=
 for prj in ${PRJS}
     do
@@ -142,9 +142,9 @@ fi
 quartusdir="${PRJ}/${buildset}/quartus/${project}"
 builddir="${quartusdir}/software"
 bspdstdir="${builddir}/bsp"
-unbsrcdir="${RADIOHDL_WORK}/libraries/unb_osy/modules"
+unbsrcdir="${HDL_WORK}/libraries/unb_osy/modules"
 unbdstdir="${builddir}/unb_lib"
-appsrcdir="${RADIOHDL_WORK}/libraries/unb_osy"
+appsrcdir="${HDL_WORK}/libraries/unb_osy"
 appdstdir="${builddir}/${app}"
 
 # Is the application available?
diff --git a/quartus/run_app_clean b/quartus/run_app_clean
index bf5b85a5e6a5c4db8708e56d5126d19561704e5e..f5a69c7914a08a490f1cc8a21892d07748870361 100755
--- a/quartus/run_app_clean
+++ b/quartus/run_app_clean
@@ -40,7 +40,7 @@ project=$2
 app=${3:+$3}
 . ${RADIOHDL_GEAR}/quartus/set_quartus ${buildset}
 
-PRJS="${RADIOHDL_BUILD_DIR}"
+PRJS="${HDL_BUILD_DIR}"
 PRJ=
 for prj in ${PRJS}
     do
diff --git a/quartus/run_bsp b/quartus/run_bsp
index 87a04dc6d3f371e9d95c2ae244dde6857b707d08..83ef59b87a70c116af354c6e2158ff45632583c7 100755
--- a/quartus/run_bsp
+++ b/quartus/run_bsp
@@ -1,23 +1,23 @@
 #!/bin/bash -eu
 # -------------------------------------------------------------------------- #
 #
-# Copyright (C) 2010                                                        
+# Copyright (C) 2010
 # ASTRON (Netherlands Institute for Radio Astronomy) <http://www.astron.nl/>
-# JIVE (Joint Institute for VLBI in Europe) <http://www.jive.nl/>           
-# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands                             
-#                                                                           
-# This program is free software: you can redistribute it and/or modify      
-# it under the terms of the GNU General Public License as published by      
-# the Free Software Foundation, either version 3 of the License, or         
-# (at your option) any later version.                                       
-#                                                                           
-# This program is distributed in the hope that it will be useful,           
-# but WITHOUT ANY WARRANTY; without even the implied warranty of            
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             
-# GNU General Public License for more details.                              
-#                                                                           
-# You should have received a copy of the GNU General Public License         
-# along with this program.  If not, see <http://www.gnu.org/licenses/>.     
+# JIVE (Joint Institute for VLBI in Europe) <http://www.jive.nl/>
+# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 # -------------------------------------------------------------------------- #
 
@@ -68,7 +68,7 @@ do
 	--bloat)
 	    hal_lightweight_driver=false
 	    hal_enable_small_libc=0
-	    ;;	
+	    ;;
         -*|--*)
             exit_with_error "Unknown option: "$1
             ;;
@@ -93,14 +93,14 @@ project=$2
 
 
 # check projectfile
-PRJS="${RADIOHDL_BUILD_DIR}"
+PRJS="${HDL_BUILD_DIR}"
 PRJ=
 for prj in ${PRJS}
     do
         if [ -d "${prj}/${buildset}/quartus/${project}" ]; then
             PRJ=${prj}
-        fi  
-    done  
+        fi
+    done
 if [ -z "${project}" -o -z "${PRJ}" ]; then
     hdl_error $0 "Please enter a valid project name"
 fi
@@ -113,7 +113,7 @@ bspdir="${builddir}/bsp"
 # assert the quartusdir exists
 hdl_exec $0 msg=no test -d ${quartusdir}
 
-# If we have a makefile see if no-one changed the sopcinfo 
+# If we have a makefile see if no-one changed the sopcinfo
 # (since if they did we must re-generate files).
 # Otherwise we must generate the BSP package
 
@@ -129,7 +129,7 @@ if [ -d "${bspdir}" -a -f "${bspdir}/Makefile" ]; then
     #       does not work on Windows. Winders cannot discriminate
     #       between "time-of-last-access" and "time-of-last-modification"
     #       whereas under Linux this works like a charm.
-    #       The result was that under Windows "make -n" would 
+    #       The result was that under Windows "make -n" would
     #       always indicate that the target needed to be rebuilt.
     #       Maybe there is another reason - fact is that "make"
     #       didn't work on windows. This does.
@@ -137,7 +137,7 @@ if [ -d "${bspdir}" -a -f "${bspdir}/Makefile" ]; then
     if [ -z "${sopcfile}" ]; then
         hdl_error $0 "No sopc(info) file?!!"
     fi
-    if [ ${sopcfile} -nt ${bspdir}/settings.bsp ]; then        
+    if [ ${sopcfile} -nt ${bspdir}/settings.bsp ]; then
         hdl_info $0 "Someone has been tinkering with .sopcinfo"
         hdl_info $0 "Regenerating the BSP files"
         hdl_exec $0 msg=no nios2-bsp-generate-files \
@@ -147,7 +147,7 @@ if [ -d "${bspdir}" -a -f "${bspdir}/Makefile" ]; then
 else
     # we must generate the BSP files
     hdl_info $0 "Generating BSP files for ${project}"
-    hdl_exec $0 msg=no nios2-bsp hal ${bspdir} ${quartusdir} 
+    hdl_exec $0 msg=no nios2-bsp hal ${bspdir} ${quartusdir}
 fi
 
 # check if we've already updated the BSP settings to our likings
diff --git a/quartus/run_mif b/quartus/run_mif
index 1ed1e1a0c509ec3598584aacca2dbf24fbd85e75..abcc545589bae536d9ac3cf0737af3e985e2bf73 100755
--- a/quartus/run_mif
+++ b/quartus/run_mif
@@ -81,7 +81,7 @@ project=$2
 . ${RADIOHDL_GEAR}/quartus/set_quartus ${buildset}
 
 # check projectfile
-PRJS="${RADIOHDL_BUILD_DIR}"
+PRJS="${HDL_BUILD_DIR}"
 PRJ=
 for prj in ${PRJS}
     do
diff --git a/quartus/run_qcomp b/quartus/run_qcomp
index 52a796207a4445ab1b8e212f95787298d14b65c6..295be7400027adac5fae50d614c98289c2b22a24 100755
--- a/quartus/run_qcomp
+++ b/quartus/run_qcomp
@@ -1,23 +1,23 @@
 #!/bin/bash -eu
 # -------------------------------------------------------------------------- #
 #
-# Copyright (C) 2012                                                        
+# Copyright (C) 2012
 # ASTRON (Netherlands Institute for Radio Astronomy) <http://www.astron.nl/>
-# JIVE (Joint Institute for VLBI in Europe) <http://www.jive.nl/>           
-# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands                             
-#                                                                           
-# This program is free software: you can redistribute it and/or modify      
-# it under the terms of the GNU General Public License as published by      
-# the Free Software Foundation, either version 3 of the License, or         
-# (at your option) any later version.                                       
-#                                                                           
-# This program is distributed in the hope that it will be useful,           
-# but WITHOUT ANY WARRANTY; without even the implied warranty of            
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             
-# GNU General Public License for more details.                              
-#                                                                           
-# You should have received a copy of the GNU General Public License         
-# along with this program.  If not, see <http://www.gnu.org/licenses/>.     
+# JIVE (Joint Institute for VLBI in Europe) <http://www.jive.nl/>
+# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 # -------------------------------------------------------------------------- #
 #
@@ -90,15 +90,15 @@ project=$2
 # read in the configuration based on the user arguments
 . ${RADIOHDL_GEAR}/quartus/set_quartus ${buildset}
 
-PRJS="${RADIOHDL_BUILD_DIR}"
+PRJS="${HDL_BUILD_DIR}"
 PRJ=
 for prj in ${PRJS}
     do
         hdl_info $0 "check if project '${project}' in dir '${prj}'"
         if [ -d "${prj}/${buildset}/quartus/${project}" ]; then
             PRJ=${prj}
-        fi  
-    done  
+        fi
+    done
 if [ -z "${project}" -o -z "${PRJ}" ]; then
     hdl_error $0 "Please enter a valid project name"
 fi
@@ -135,43 +135,49 @@ do
     hdl_info $0 "Adding fitter seed value of ${i} to ${project_rev}.qsf"
     echo -e "\nset_global_assignment -name SEED ${i}\n" >> ${quartusdir}/${project_rev}.qsf
     echo -e "\nset_global_assignment -name NUM_PARALLEL_PROCESSORS 6\n" >> ${quartusdir}/${project_rev}.qsf
-    
+
     hdl_info $0 "Performing full compile of project ${project_rev}"
     quartus_sh $mem_width --flow compile ${project_rev} | grep -v Info
     hdl_info $0 "compile done"
-    
+
+
     if [ $? -eq 0 ]
     then
       # Successful compile.
-      hdl_info $0 "Full compile successful"  
-      # . Add SVN rev to SOF file name
+      hdl_info $0 "Full compile successful"
+      
       if [ -n "${HDL_GIT_REVISION_SHORT}" ]; then
-        git_revision=`echo ${HDL_GIT_REVISION_SHORT}`  # ${HDL_GIT_REVISION_SHORT} looks like: "7d81650af"
-        hdl_info $0 "copy file ${quartusdir}/${project_rev}.sof to ${quartusdir}/${project_rev}-r${git_revision}.sof"
-        cp -p ${quartusdir}/${project_rev}.sof ${quartusdir}/${project_rev}-r${git_revision}.sof
+        git_revision=$(echo ${HDL_GIT_REVISION_SHORT})  # ${HDL_GIT_REVISION_SHORT} looks like: "7d81650af"
       fi
+            
+      # . Add git rev to SOF file name
+      hdl_info $0 "copy file ${quartusdir}/${project_rev}.sof to ${quartusdir}/${project_rev}-r${git_revision}.sof"
+      cp -p ${quartusdir}/${project_rev}.sof ${quartusdir}/${project_rev}-r${git_revision}.sof
+      
+      hdl_exec $0 quartus_cpf -c --option=${HOME}/.run_rbf_temp_options_file ${quartusdir}/${project_rev}.sof ${quartusdir}/${project_rev}.rbf
+      # . Add git rev to SBF file name
+      echo "copy file ${quartusdir}/${project_rev}.rbf to ${quartusdir}/${project_rev}-r${git_revision}.rbf"
+      cp ${quartusdir}/${project_rev}.rbf ${quartusdir}/${project_rev}-r${git_revision}.rbf
+      
       # . Check if user passed a clk
       if [ -z "${CLK}" ]
       then
           :
       else
-          fmax_str=`quartus_fmax.sh ${quartusdir}/${project_rev}.sta.rpt $CLK`
-          fmax=`echo $fmax_str | cut -f1 -d"." | sed 's/[^0-9]//g'` 
-          # . Report fMax 
+          fmax_str=$(quartus_fmax.sh ${quartusdir}/${project_rev}.sta.rpt $CLK)
+          fmax=$(echo $fmax_str | cut -f1 -d"." | sed 's/[^0-9]//g')
+          # . Report fMax
           hdl_info $0 "fMax of ${CLK}: ${fmax} MHz"
+          echo "fMax of ${CLK}: ${fmax} MHz" > ${quartusdir}/fmax.txt
+          time_stamp=$(date -u +"%Y-%m-%dT%H:%M")
           # . Copy quartus output dir preserving the meta file information, add fMax portfix
-          
-          resultdir="${RADIOHDL_BUILD_DIR}/quartus_results/"
-          if [ ! -d "${resultdir}" ]; then
-             mkdir "${resultdir}"
-          fi
-          cp -rp ${quartusdir} ${resultdir}/${project}_${fmax}MHz
+          cp -rp ${quartusdir} ${RADIOHDL_BUILD_RESULT}/${time_stamp}_${project_rev}_${fmax}MHz
       fi
       # Print critical warnings
       # If grep find no match it wil return 1 as exitcode and the script is killed.
       # use following format to prefend a grep with no match to kill the script, the exitcode is now always forched to 0, to avoid script abort due to running bash -e:
       #   echo "anything" | { grep e || true; }
-      #     
+      #
       cd ${quartusdir}
       hdl_warning $0 "Listing Critical Warnings"
       # Print pin location warnings, if any
@@ -183,20 +189,20 @@ do
       hdl_info $0 "Full compile successful."
     else
       # Compile failed
-      hdl_info $0 "Full compile failed"  
+      hdl_info $0 "Full compile failed"
       # . Print the errors
       cd ${quartusdir}
       hdl_warning $0 "Listing Critical Warnings"
       # Print pin location warnings, if any
       echo "." | { cat *.fit.rpt | grep -H --color=auto 'No exact pin location' | grep -H --color=auto 'Critical Warning' || true; }
       # . print corresponding info
-      echo "." | { grep -H --color=auto 'not assigned to an exact location' *.fit.rpt || true; }     
+      echo "." | { grep -H --color=auto 'not assigned to an exact location' *.fit.rpt || true; }
       # Print remaining critical warnings, EXCEPT the always presetn TSE warning
       echo "." | { cat *.rpt | grep -v 'mixed_port_feed_through_mode\" parameter of RAM atom' | grep -H --color=auto 'Critical Warning' || true; }
       hdl_error_noexit $0 "Error(s) occured"
       # Print error messages
       echo "." | { cat *.rpt | grep -v 'Error detection' | grep -H --color=auto 'Error' || true; }
-      hdl_error $0 "Full compile failed"  
+      hdl_error $0 "Full compile failed"
     fi
 
 done
diff --git a/quartus/run_qsys b/quartus/run_qsys
index eb9b24a26d26a84d0b1e0d847cc915eeaa8de902..c7883a7868eba890e066d2632fc69a98ab38096e 100755
--- a/quartus/run_qsys
+++ b/quartus/run_qsys
@@ -41,7 +41,7 @@ qsysfile=${3:+$3}
 . ${RADIOHDL_GEAR}/quartus/set_quartus ${buildset}
 
 # search for existing project directory
-PRJS="${RADIOHDL_BUILD_DIR}"
+PRJS="${HDL_BUILD_DIR}"
 PRJ=
 for prj in ${PRJS}
     do
diff --git a/quartus/run_qsys_pro b/quartus/run_qsys_pro
index 0276b55968173dc9ccdf00fae9ef95fd71c441f7..ba80d5533ec93020869edcfda24fdc311427451f 100755
--- a/quartus/run_qsys_pro
+++ b/quartus/run_qsys_pro
@@ -41,7 +41,7 @@ qsysfile=${3:+$3}
 . ${RADIOHDL_GEAR}/quartus/set_quartus ${buildset}
 
 # search for existing project directory
-PRJS="${RADIOHDL_BUILD_DIR}"
+PRJS="${HDL_BUILD_DIR}"
 PRJ=
 for prj in ${PRJS}
     do
diff --git a/quartus/run_rbf b/quartus/run_rbf
index aec28084f40336012f1c0012e821493b1f668f23..2b25079925f2e52817e3df110f3e8632f4ed6c6e 100755
--- a/quartus/run_rbf
+++ b/quartus/run_rbf
@@ -78,7 +78,7 @@ project=$2
 # read in the configuration based on the user arguments
 . ${RADIOHDL_GEAR}/quartus/set_quartus ${buildset}
 
-PRJS="${RADIOHDL_BUILD_DIR}"
+PRJS="${HDL_BUILD_DIR}"
 PRJ=
 for prj in ${PRJS}
     do
@@ -118,7 +118,7 @@ if [ -z "${arg_unb2_factory}" ]; then
   hdl_exec $0 quartus_cpf -c --option=${HOME}/.run_rbf_temp_options_file ${quartusdir}/${project_rev}.sof ${quartusdir}/${project_rev}.rbf
 else
   hdl_info $0 "-> This is a factory image for Uniboard2: Convert .SOF -> .POF -> .HEXOUT -> .RBF"
-  # for more info see: ${RADIOHDL_WORK}/libraries/io/epcs/doc/README.txt
+  # for more info see: ${HDL_WORK}/libraries/io/epcs/doc/README.txt
   hdl_exec $0 quartus_cpf -d EPCQL1024 -m ASx4 --option=${HOME}/.run_rbf_temp_options_file -c ${quartusdir}/${project_rev}.sof ${quartusdir}/${project_rev}.pof
   hdl_exec $0 quartus_cpf -c ${quartusdir}/${project_rev}.pof ${quartusdir}/${project_rev}.hexout
   hdl_exec $0 nios2-elf-objcopy -I ihex -O binary ${quartusdir}/${project_rev}.hexout ${quartusdir}/${project_rev}.rbf
@@ -135,7 +135,7 @@ fi
 
 
 if [ -n "${HDL_GIT_REVISION_SHORT}" ]; then
-  git_revision=`echo ${HDL_GIT_REVISION_SHORT}`  # ${HDL_GIT_REVISION_SHORT} looks like: "7d81650af"
+  git_revision=$(echo ${HDL_GIT_REVISION_SHORT})  # ${HDL_GIT_REVISION_SHORT} looks like: "7d81650af"
   echo "copy file ${quartusdir}/${project_rev}.rbf to ${quartusdir}/${project_rev}-r${git_revision}.rbf"
   cp ${quartusdir}/${project_rev}.rbf ${quartusdir}/${project_rev}-r${git_revision}.rbf
 fi
diff --git a/quartus/run_reg b/quartus/run_reg
index 59ae1263b7d2ebd924f1c97b0975670badd3355e..6a8c065ef55e8b42f4af0edf5f5daa2ef3dd9109 100755
--- a/quartus/run_reg
+++ b/quartus/run_reg
@@ -74,7 +74,7 @@ project=$2
 . ${RADIOHDL_GEAR}/quartus/set_quartus ${buildset}
 
 # check projectfile
-PRJS="${RADIOHDL_BUILD_DIR}"
+PRJS="${HDL_BUILD_DIR}"
 PRJ=
 for prj in ${PRJS}
     do
diff --git a/quartus/run_regtest_synth b/quartus/run_regtest_synth
index 03a6ac8c4b9b611598392dc888d20ac1e3b373d3..a4f3e5540b00326b1a6bec5d06e4e8fbf16fd44c 100755
--- a/quartus/run_regtest_synth
+++ b/quartus/run_regtest_synth
@@ -58,7 +58,7 @@ hdl_exec $0 . ${RADIOHDL_GEAR}/setup_radiohdl.sh
 
 # Generate all IP 
 hdl_info $0 "Generating all IP"
-hdl_exec $0 cd ${RADIOHDL_WORK}/libraries/technology/ip_stratixiv
+hdl_exec $0 cd ${HDL_WORK}/libraries/technology/ip_stratixiv
 #hdl_exec $0 sh generate-all-ip.sh
 
 # Run quartus_config.py
@@ -85,7 +85,7 @@ hdl_exec $0 run_rbf   unb1 apertif_unb1_bn_filterbank
 # At this point, errors may or may not have occured.  Perform checks here.
 # Check if all RBF files have been generated
 NOF_RBF_REQ=1
-FOUND_RBF=$(find ${RADIOHDL_BUILD_DIR} -name *.rbf | grep "\-r")
+FOUND_RBF=$(find ${HDL_BUILD_DIR} -name *.rbf | grep "\-r")
 NOF_RBF=$(echo ${FOUND_RBF} | grep -c "rbf")
 RESULT=FAILED
 if (( NOF_RBF == NOF_RBF_REQ )); then
diff --git a/quartus/run_sof b/quartus/run_sof
index d5b4548b870079ce1c0c692223c8a9ddfe6451a3..d185d0053443b5bd48d99eccd23dfdde0f07ad1e 100755
--- a/quartus/run_sof
+++ b/quartus/run_sof
@@ -159,7 +159,7 @@ do
 done
 
 # check projectfile
-PRJS="${RADIOHDL_BUILD_DIR}"
+PRJS="${HDL_BUILD_DIR}"
 PRJ=
 for prj in ${PRJS}
     do
diff --git a/quartus/run_sopc b/quartus/run_sopc
index 7e1b512e6abca49aab256b89eb0dad5f14ab5382..eab270066d64253576f9df39bbf3f2c008ee8204 100755
--- a/quartus/run_sopc
+++ b/quartus/run_sopc
@@ -41,7 +41,7 @@ sopcfile=${3:+$3}
 . ${RADIOHDL_GEAR}/quartus/set_quartus ${buildset}
 
 # search for existing project directory
-PRJS="${RADIOHDL_BUILD_DIR}"
+PRJS="${HDL_BUILD_DIR}"
 PRJ=
 for prj in ${PRJS}
     do
diff --git a/quartus/set_quartus b/quartus/set_quartus
index ceb2e3b0515a5a9ca0f4472b03ad83a712dcc374..ee4ede2080affc36cf680c5527a9efe0809927a5 100755
--- a/quartus/set_quartus
+++ b/quartus/set_quartus
@@ -75,15 +75,15 @@ done
 # TODO: move to hdl_tool_quartus.cfg : user_environment_variables ???
 # HDL_GIT_REVISION (first 32 digits of full 40-digits hash) is used in firmware
 # HDL_GIT_REVISION_SHORT (first 9 digits of full hash) is used in file-naming
-if [[ -n "${RADIOHDL_WORK}" ]]; then
-    git_rev=`cd $RADIOHDL_WORK; git rev-parse HEAD; cd -`
+if [[ -n "${HDL_WORK}" ]]; then
+    git_rev=`cd $HDL_WORK; git rev-parse HEAD; cd -`
     export HDL_GIT_REVISION=${git_rev}
     export HDL_GIT_REVISION_SHORT=${git_rev:0:9}
     #export HDL_GIT_REVISION=1010101
     #export HDL_GIT_REVISION_SHORT=101
     echo "set GIT revision to '${HDL_GIT_REVISION}' and as short '${HDL_GIT_REVISION_SHORT}'"
 else
-    echo "GIT revision not set (RADIOHDL_WORK not available), run first '. ./init_hdl.sh' in hdl dir"
+    echo "GIT revision not set (HDL_WORK not available), run first '. ./init_hdl.sh' in hdl dir"
 fi
 export UNB_COMPILE_STAMPS=1
 
diff --git a/regressiontest/modelsim_regression_test_vhdl.py b/regressiontest/modelsim_regression_test_vhdl.py
index 9c061254534e93b258cce28b6130b4563446e69e..b2d866175d8b08ba719958d1ef5422bfc7febc5a 100755
--- a/regressiontest/modelsim_regression_test_vhdl.py
+++ b/regressiontest/modelsim_regression_test_vhdl.py
@@ -170,7 +170,7 @@ def main():
     run_start_time = time.time()
 
     # put all tb tests in the task-queue
-    lock = os.path.join(os.getenv("RADIOHDL_BUILD_DIR"), buildset, "modelsim/easics/work", "_lock")
+    lock = os.path.join(os.getenv("HDL_BUILD_DIR"), buildset, "modelsim/easics/work", "_lock")
     logger.info("lockfile='%s'", lock)
     open_tasks = []
 
@@ -410,7 +410,7 @@ class TestBenchWorker(multiprocessing.Process):
         self.sim_errors = []
         self.n_tb = 0
         self.run_time = 0
-        sim_dir = os.path.join(os.getenv("RADIOHDL_BUILD_DIR"), f"sim_worker{self._id}")
+        sim_dir = os.path.join(os.getenv("HDL_BUILD_DIR"), f"sim_worker{self._id}")
         if not os.path.exists(sim_dir):
             os.mkdir(sim_dir)
 
@@ -885,7 +885,7 @@ if __name__ == "__main__":
 
     args.buildset_file = "hdl_buildset_" + args.buildset + ".cfg"
 
-    out_dir = os.path.join(os.getenv("RADIOHDL_BUILD_DIR"), args.buildset, "modelsim")
+    out_dir = os.path.join(os.getenv("HDL_BUILD_DIR"), args.buildset, "modelsim")
     file_name = f"regression_test_{args.buildset}"
 
     my_logger = MyLogger(log_path=out_dir, file_name=file_name, name_size=15)
diff --git a/regressiontest/modelsim_regression_test_vhdl_cron.sh b/regressiontest/modelsim_regression_test_vhdl_cron.sh
index e45cc4bfdc124b572e549fac95d00eeb8b5e39b7..784eb963b959f82a0935f17d3d290b8eeb300fd5 100755
--- a/regressiontest/modelsim_regression_test_vhdl_cron.sh
+++ b/regressiontest/modelsim_regression_test_vhdl_cron.sh
@@ -62,7 +62,7 @@ hdl_exec "$0" git pull
 
 # get hash from last test if file excists
 git_prev_hash="none"
-git_hash_filename="${RADIOHDL_WORK}"/previous_git_hash.txt
+git_hash_filename="${HDL_WORK}"/previous_git_hash.txt
 [[ -f "${git_hash_filename}" ]] && git_prev_hash=$(cat "${git_hash_filename}")
 git_active_hash=$(git rev-parse HEAD) 
 
@@ -92,7 +92,7 @@ grep -v '^#' < "${buildset_filename}" | {
 
             echo "cleanup last build"
             # Cleanup last build if exists
-            hdl_exec "$0" rm -rf "${RADIOHDL_BUILD_DIR:?}"/"${buildset}"
+            hdl_exec "$0" rm -rf "${HDL_BUILD_DIR:?}"/"${buildset}"
 
             # Build all IP 
             echo "call compile_altera_simlibs"
diff --git a/regressiontest/modelsim_regression_test_vhdl_mail.py b/regressiontest/modelsim_regression_test_vhdl_mail.py
index 16a1af7774c17dc7f4784bb9f7ea57dc2cbbadae..aa845f584eabaec46077b3ba3679c01426ee40ab 100755
--- a/regressiontest/modelsim_regression_test_vhdl_mail.py
+++ b/regressiontest/modelsim_regression_test_vhdl_mail.py
@@ -81,7 +81,7 @@ def get_host_ip():
 
 def get_git_hash():
     # Get the GIT revision to put in the email subject
-    os.chdir(os.getenv("RADIOHDL_WORK"))
+    os.chdir(os.getenv("HDL_WORK"))
     p = Popen("git rev-parse HEAD", shell=True, stdout=PIPE, stderr=PIPE)
     stdout, stderr = p.communicate()
     git_revision = stdout.decode("utf-8")
@@ -137,7 +137,7 @@ if __name__ == "__main__":
     )
     args = argparser.parse_args()
 
-    out_dir = os.path.join(os.getenv("RADIOHDL_BUILD_DIR"), args.buildset, "modelsim")
+    out_dir = os.path.join(os.getenv("HDL_BUILD_DIR"), args.buildset, "modelsim")
 
     result_file_name = "regression_test_" + args.buildset + ".log"
     result_file_path = os.path.join(out_dir, result_file_name)
diff --git a/regressiontest/quartus_build_images_cron.sh b/regressiontest/quartus_build_images_cron.sh
index 506a0d6c944f6f753359024ed607136bba878aad..246f6b6a860d92139863861902d6f8d41a5ecb8a 100755
--- a/regressiontest/quartus_build_images_cron.sh
+++ b/regressiontest/quartus_build_images_cron.sh
@@ -49,6 +49,7 @@ hdl_info "$0" "Build all images in file: ${BUILDFILE}"
 
 LOGFILE="${HOME}"/quartus_build_images_cron.log
 OUT_DIR="${HOME}"/bitstream
+
 # Delete any previous log files
 if [ -f "${LOGFILE}" ]; then
     hdl_exec "$0" rm "${LOGFILE}"
@@ -66,7 +67,7 @@ echo "initialize all systems"
 
 echo "cleanup last build"
 # Cleanup last build if excists
-hdl_exec "$0" rm -rf "${RADIOHDL_BUILD_DIR:?}"/*
+hdl_exec "$0" rm -rf "${HDL_BUILD_DIR:?}"/*
 
 # Build all IP 
 echo "call generate_ip_libs"
diff --git a/regressiontest/quartus_build_images_mail.py b/regressiontest/quartus_build_images_mail.py
index 7c74f242d5920d83c0731d393935a68d86194879..1b2fc53acdeaa07549abcbdec0110357a46a2d86 100755
--- a/regressiontest/quartus_build_images_mail.py
+++ b/regressiontest/quartus_build_images_mail.py
@@ -79,7 +79,7 @@ def get_host_ip():
 
 def get_git_hash():
     # Get the GIT revision to put in the email subject
-    os.chdir(os.getenv("RADIOHDL_WORK"))
+    os.chdir(os.getenv("HDL_WORK"))
     p = Popen("git rev-parse HEAD", shell=True, stdout=PIPE, stderr=PIPE)
     stdout, stderr = p.communicate()
     git_revision = stdout.decode("utf-8")