diff --git a/.gitignore b/.gitignore
index 9948ccaf0f2863a2a05e1f8a557fdb572c337d9f..04c6661f2d7f50305f3984c67e427e33216f7a1c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,9 +1,13 @@
-.gitignore
-bin/
-binWSL/
+# build directories
 build/
-source/MSVC2015/
-source/Applications/DLR-F16-Solid/f16-solid-coarse.cfg
-.vscode/
+bin/
 MSVC2017/
 VS2017/
+
+# IDE
+.vscode/
+.sync/
+.idea/
+
+# MacOS
+.DS_Store
diff --git a/3rdParty/jsoncpp/amalgamate.py b/3rdParty/jsoncpp/amalgamate.py
index 9cb2d08ccda7c7d8e87c2e7c54de4a42353812fd..a8ab3894c632845ee620e8f8eef3e35301d56eec 100644
--- a/3rdParty/jsoncpp/amalgamate.py
+++ b/3rdParty/jsoncpp/amalgamate.py
@@ -48,13 +48,13 @@ class AmalgamationFile:
         f.close()
 
 def amalgamate_source(source_top_dir=None,
-                       target_source_path=None,
+                       target_VF_SRC_DIR=None,
                        header_include_path=None):
     """Produces amalgated source.
        Parameters:
            source_top_dir: top-directory
-           target_source_path: output .cpp path
-           header_include_path: generated header path relative to target_source_path.
+           target_VF_SRC_DIR: output .cpp path
+           header_include_path: generated header path relative to target_VF_SRC_DIR.
     """
     print("Amalgating header...")
     header = AmalgamationFile(source_top_dir)
@@ -77,7 +77,7 @@ def amalgamate_source(source_top_dir=None,
     header.add_file("include/json/assertions.h")
     header.add_text("#endif //ifndef JSON_AMALGATED_H_INCLUDED")
 
-    target_header_path = os.path.join(os.path.dirname(target_source_path), header_include_path)
+    target_header_path = os.path.join(os.path.dirname(target_VF_SRC_DIR), header_include_path)
     print("Writing amalgated header to %r" % target_header_path)
     header.write_to(target_header_path)
 
@@ -98,7 +98,7 @@ def amalgamate_source(source_top_dir=None,
     header.add_file("include/json/forwards.h")
     header.add_text("#endif //ifndef JSON_FORWARD_AMALGATED_H_INCLUDED")
 
-    target_forward_header_path = os.path.join(os.path.dirname(target_source_path),
+    target_forward_header_path = os.path.join(os.path.dirname(target_VF_SRC_DIR),
                                                forward_header_include_path)
     print("Writing amalgated forward header to %r" % target_forward_header_path)
     header.write_to(target_forward_header_path)
@@ -123,8 +123,8 @@ def amalgamate_source(source_top_dir=None,
     source.add_file(os.path.join(lib_json, "json_value.cpp"))
     source.add_file(os.path.join(lib_json, "json_writer.cpp"))
 
-    print("Writing amalgated source to %r" % target_source_path)
-    source.write_to(target_source_path)
+    print("Writing amalgated source to %r" % target_VF_SRC_DIR)
+    source.write_to(target_VF_SRC_DIR)
 
 def main():
     usage = """%prog [options]
@@ -133,7 +133,7 @@ Generate a single amalgated source and header file from the sources.
     from optparse import OptionParser
     parser = OptionParser(usage=usage)
     parser.allow_interspersed_args = False
-    parser.add_option("-s", "--source", dest="target_source_path", action="store", default="dist/jsoncpp.cpp",
+    parser.add_option("-s", "--source", dest="target_VF_SRC_DIR", action="store", default="dist/jsoncpp.cpp",
         help="""Output .cpp source path. [Default: %default]""")
     parser.add_option("-i", "--include", dest="header_include_path", action="store", default="json/json.h",
         help="""Header include path. Used to include the header from the amalgated source file. [Default: %default]""")
@@ -143,7 +143,7 @@ Generate a single amalgated source and header file from the sources.
     options, args = parser.parse_args()
 
     msg = amalgamate_source(source_top_dir=options.top_dir,
-                             target_source_path=options.target_source_path,
+                             target_VF_SRC_DIR=options.target_VF_SRC_DIR,
                              header_include_path=options.header_include_path)
     if msg:
         sys.stderr.write(msg + "\n")
diff --git a/3rdParty/jsoncpp/devtools/tarball.py b/3rdParty/jsoncpp/devtools/tarball.py
index 3c0ba65e711c07172f562eac0960af9abf289f3e..27a9b6f4975d27534b065192c69d9e444556aa67 100644
--- a/3rdParty/jsoncpp/devtools/tarball.py
+++ b/3rdParty/jsoncpp/devtools/tarball.py
@@ -37,13 +37,13 @@ def make_tarball(tarball_path, sources, base_dir, prefix_dir=''):
     with closing(tarfile.TarFile.open(tarball_path, 'w:gz',
             compresslevel=compression)) as tar:
         for source in sources:
-            source_path = source
+            VF_SRC_DIR = source
             if os.path.isdir(source):
-                for dirpath, dirnames, filenames in os.walk(source_path):
+                for dirpath, dirnames, filenames in os.walk(VF_SRC_DIR):
                     visit(tar, dirpath, filenames)
             else:
-                path_in_tar = archive_name(source_path)
-                tar.add(source_path, path_in_tar)      # filename, arcname
+                path_in_tar = archive_name(VF_SRC_DIR)
+                tar.add(VF_SRC_DIR, path_in_tar)      # filename, arcname
 
 def decompress(tarball_path, base_dir):
     """Decompress the gzipped tarball into directory base_dir.
diff --git a/CMake/CMakeCABMacros.cmake b/CMake/CMakeCABMacros.cmake
index 85cd2eaa28bd417ee3a5cc5cc9b2082db526b4ba..32e8c1e0fba34debf5dddbce3e19788aa9c24d44 100644
--- a/CMake/CMakeCABMacros.cmake
+++ b/CMake/CMakeCABMacros.cmake
@@ -18,15 +18,7 @@ SET(CAB_ADDITIONAL_LINK_FLAGS_RELEASE)
 SET(CAB_ADDITIONAL_LINK_LIBRARIES)
 
 
-###############################################################
-# SOURCE_DIR variable wird beim einbinden automatisch gesetzt - ebenso das include dir!!!
-# SOURCE_DIR wird dem Projekt als Standardincludepfad hinzugefuegt
-###############################################################
-#CMakeCABMacros.txt liegt direkt im source-Ordner -> pfad == SOURCE_ROOT
-GET_FILENAME_COMPONENT( SOURCE_ROOT  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-STRING(REGEX REPLACE "(.*)/CMake" "\\1" SOURCE_ROOT "${SOURCE_ROOT}" )
-INCLUDE_DIRECTORIES(${SOURCE_ROOT})
-LIST(APPEND CAB_ADDTIONAL_COMPILER_FLAGS -DSOURCE_ROOT=${SOURCE_ROOT} )
+LIST(APPEND CAB_ADDTIONAL_COMPILER_FLAGS -DSOURCE_ROOT=${VF_ROOT_DIR} )
 
 ###############################################################
 # hostename ermitteln -> CAB_MACHINE
@@ -63,8 +55,8 @@ ENDIF()
 ############################################################################
 # externe (ACHTUNG: die darin enthaltenen benoetigen teils noch macros die 
 # hier im Anschluss folgen
-INCLUDE("${SOURCE_ROOT}/CMake/CMakeSetCompilerFlags.cmake")
-INCLUDE("${SOURCE_ROOT}/CMake/CMakeCompilerMacros.cmake")
+INCLUDE("${VF_CMAKE_DIR}/CMakeSetCompilerFlags.cmake")
+INCLUDE("${VF_CMAKE_DIR}/CMakeCompilerMacros.cmake")
 
 ################################################################
 ###               ADD_TARGET_PROPERTIES                      ###
@@ -319,7 +311,7 @@ SET_CAB_COMPILER()
 CHECK_FOR_VARIABLE(CAB_MACHINE "machine name, e.g. ALTIX, ARWEN")
 LIST(APPEND CAB_ADDTIONAL_COMPILER_FLAGS -DCAB_MACHINE_${CAB_MACHINE})
 LIST(APPEND CAB_ADDTIONAL_COMPILER_FLAGS -DCAB_MACHINE=${CAB_MACHINE})
-SET(CMAKE_CONFIG_FILE "${SOURCE_ROOT}/CMake/cmake_config_files/${CAB_MACHINE}.config.cmake")
+SET(CMAKE_CONFIG_FILE "${VF_CMAKE_DIR}/cmake_config_files/${CAB_MACHINE}.config.cmake")
 
 IF(NOT EXISTS ${CMAKE_CONFIG_FILE})
   MESSAGE(FATAL_ERROR "${CMAKE_CONFIG_FILE} does not exists... maybe false CAB_MACHINE = ${CAB_MACHINE}")
diff --git a/CMake/CMakePackages.txt b/CMake/CMakePackages.txt
deleted file mode 100644
index f1f371400b880aa027a6ae47a1c62f7a5ef15ae5..0000000000000000000000000000000000000000
--- a/CMake/CMakePackages.txt
+++ /dev/null
@@ -1,12 +0,0 @@
-#SUBDIRS(numerics/algebra/examples/tutorial)
-#SUBDIRS(numerics/geometry3d/examples/stl2inp)
-#SUBDIRS(lbmd2q9/a2pII/testcases/inputfile)
-SUBDIRS(lbmd2q9/a2pII/testcases/SFC_arne)
-IF(NEED_METIS)
- MESSAGE(${NEED_METIS})
-ENDIF(NEED_METIS)
-SUBDIRS(lbmd2q9/a2pIIparallel/testcases/inputfile)
-#SUBDIRS(lbmd3q19/a2pII/testcases/inputfile)
-#SUBDIRS(lbmd3q19/OctLBM/testcases/inputfile)
-#SUBDIRS(lbmd3q19/OctLBMparallel/testcases/inputfile)
-#SUBDIRS(basics/network/examples/FourInOne)
diff --git a/CMake/CMakeSetCompilerFlags.cmake b/CMake/CMakeSetCompilerFlags.cmake
index 10a277299b1124026dc110c9dc06824603863346..7197caaa64838edbcfbd421af334dd29fe4362ba 100644
--- a/CMake/CMakeSetCompilerFlags.cmake
+++ b/CMake/CMakeSetCompilerFlags.cmake
@@ -38,8 +38,8 @@ MACRO(SET_COMPILER_SPECIFIC_FLAGS compiler_type build_type)
    ###############################################################################################################
    ## standard compiler flags
    ###############################################################################################################
-   ELSEIF( EXISTS "${SOURCE_ROOT}/CMake/compilerflags/${CAB_COMPILER}.cmake" )
-	   INCLUDE( ${SOURCE_ROOT}/CMake/compilerflags/${CAB_COMPILER}.cmake)
+   ELSEIF( EXISTS "${VF_CMAKE_DIR}/compilerflags/${CAB_COMPILER}.cmake" )
+	   INCLUDE( ${VF_CMAKE_DIR}/compilerflags/${CAB_COMPILER}.cmake)
 	###############################################################################################################
 	## unknown compiler
 	###############################################################################################################
@@ -47,7 +47,7 @@ MACRO(SET_COMPILER_SPECIFIC_FLAGS compiler_type build_type)
 	   #MESSAGE(FATAL_ERROR "CAB_COMPILER=${CAB_COMPILER} seems to be a not supported compiler")
 	   #MESSAGE(WARNING "CAB_COMPILER=${CAB_COMPILER} seems to be a not supported compiler; set to generic")
 	   SET(CAB_COMPILER "gccGeneric")
-	   INCLUDE( ${SOURCE_ROOT}/CMake/compilerflags/${CAB_COMPILER}.cmake)
+	   INCLUDE( ${VF_CMAKE_DIR}/compilerflags/${CAB_COMPILER}.cmake)
 	ENDIF()
    
 
diff --git a/CMake/VirtualFluidsMacros.cmake b/CMake/VirtualFluidsMacros.cmake
index 5b059d4fe01d3e7485a1bf70276a91aca218ab41..de563d28fbbbc959f96f29fa69470dc74e713556 100644
--- a/CMake/VirtualFluidsMacros.cmake
+++ b/CMake/VirtualFluidsMacros.cmake
@@ -165,7 +165,7 @@ function(vf_add_library)
 
     target_include_directories(${library_name} PRIVATE ${CMAKE_BINARY_DIR})
     target_include_directories(${library_name} PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
-    target_include_directories(${library_name} PRIVATE ${CMAKE_SOURCE_DIR}/src)
+    target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR})
 
 
     #status("... configuring target: ${library_name} (type=${ARG_BUILDTYPE}) done")
@@ -215,10 +215,10 @@ function(vf_add_tests)
     # link tested library
     target_include_directories(${library_test_name} PRIVATE ${CMAKE_BINARY_DIR})
     target_include_directories(${library_test_name} PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
-    target_include_directories(${library_test_name} PRIVATE ${CMAKE_SOURCE_DIR}/src)
+    target_include_directories(${library_test_name} PRIVATE ${VF_SRC_DIR})
 
     # link googlemock
-    include(${CMAKE_PATH}/3rd/gmock.cmake)
+    include(${VF_CMAKE_DIR}/3rd/gmock.cmake)
 
 endfunction()
 
diff --git a/CMake/cmake_config_files/BILBO.config.cmake b/CMake/cmake_config_files/BILBO.config.cmake
index e9757065cd956c8ab7f57d0a95388bc3df6c6dd1..ead4ef15bcfe529d4b6a5a2d9d5e6f5211f04a66 100644
--- a/CMake/cmake_config_files/BILBO.config.cmake
+++ b/CMake/cmake_config_files/BILBO.config.cmake
@@ -39,6 +39,3 @@ IF(${USE_METIS})
     SET(METIS_DEBUG_LIBRARY "/usr/local/lib/libmetis.a")
     SET(METIS_RELEASE_LIBRARY "/usr/local/lib/libmetis.a")
 ENDIF()
-#set(SOURCE_ROOT "/host/Projects/pFluid/source")
-
-SET(GMOCK_ROOT "~/Libraries/googletest-release-1.10.0" CACHE PATH "GMOCK ROOT")
\ No newline at end of file
diff --git a/CMake/cmake_config_files/ELLADAN.config.cmake b/CMake/cmake_config_files/ELLADAN.config.cmake
index 3729898e3b9f105232db5d8552fbb9e87c85e2d3..7896929276a2969029937ab819b7a59b8132a7c6 100644
--- a/CMake/cmake_config_files/ELLADAN.config.cmake
+++ b/CMake/cmake_config_files/ELLADAN.config.cmake
@@ -42,6 +42,3 @@ IF(${USE_METIS})
     SET(METIS_DEBUG_LIBRARY "/usr/lib/x86_64-linux-gnu/libmetis.so")
     SET(METIS_RELEASE_LIBRARY "/usr/lib/x86_64-linux-gnu/libmetis.so")
 ENDIF()
-#set(SOURCE_ROOT "/host/Projects/pFluid/source")
-
-SET(GMOCK_ROOT /usr/src/googletest CACHE PATH "GMOCK ROOT")
\ No newline at end of file
diff --git a/CMake/cmake_config_files/TESLA01.config.cmake b/CMake/cmake_config_files/TESLA01.config.cmake
index 4301bd774cb2a8aa43c0926a03a8e9ade628c2a0..adebd6af01a6fbe44952cdf39f398aa9d7abb49d 100644
--- a/CMake/cmake_config_files/TESLA01.config.cmake
+++ b/CMake/cmake_config_files/TESLA01.config.cmake
@@ -1,10 +1,9 @@
 #Don't change:
-SET(METIS_ROOT ${CMAKE_SOURCE_DIR}/3rdParty/metis/metis-5.1.0 CACHE PATH "METIS ROOT")
-#SET(GMOCK_ROOT ${CMAKE_SOURCE_DIR}/3rdParty/googletest CACHE PATH "GMOCK ROOT")
-SET(JSONCPP_ROOT ${CMAKE_SOURCE_DIR}/3rdParty/jsoncpp CACHE PATH "JSONCPP ROOT")
-SET(FFTW_ROOT ${CMAKE_SOURCE_DIR}/3rdParty/fftw/fftw-3.3.7 CACHE PATH "JSONCPP ROOT")
+SET(METIS_ROOT ${VF_THIRD_DIR}/metis/metis-5.1.0 CACHE PATH "METIS ROOT")
+SET(GMOCK_ROOT ${VF_THIRD_DIR}/googletest CACHE PATH "GMOCK ROOT")
+SET(JSONCPP_ROOT ${VF_THIRD_DIR}/jsoncpp CACHE PATH "JSONCPP ROOT")
+SET(FFTW_ROOT ${VF_THIRD_DIR}/fftw/fftw-3.3.7 CACHE PATH "JSONCPP ROOT")
 
-SET(GMOCK_ROOT C:\\Libraries\\googletest-release-1.10.0 CACHE PATH "GMOCK ROOT")
 
 #SET TO CORRECT PATH:
 SET(BOOST_ROOT  "C:\\Libraries\\boost_1_65_1"  CACHE PATH "BOOST_ROOT")
diff --git a/CMakeLists.txt b/CMakeLists.txt
index f96898b83ba569e788d94dbaf40c98642e31b7ed..4219695ee306e8fc48c8ac210521a36a460d203b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -9,7 +9,7 @@
 #  required cmake versions
 #  CMAKE 3.9: CUDA support
 #################################################################################
-cmake_minimum_required(VERSION 3.13..3.17 FATAL_ERROR)
+cmake_minimum_required(VERSION 3.13..3.18 FATAL_ERROR)
 
 project(VirtualFluids CXX)
 
@@ -22,6 +22,11 @@ set(testFolder    "tests")
 set(appFolder     "apps")
 set(thirdFolder   "3rd")
 
+set (VF_CMAKE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/CMake)
+set (VF_THIRD_DIR ${CMAKE_CURRENT_SOURCE_DIR}/3rdParty)
+set (VF_SRC_DIR   ${CMAKE_CURRENT_SOURCE_DIR}/src)
+set (VF_ROOT_DIR  ${CMAKE_CURRENT_SOURCE_DIR})
+
 #################################################################################
 #  OPTIONS
 #################################################################################
@@ -30,17 +35,27 @@ option(BUILD_VF_GPU "Build VirtualFluids gpu variant" OFF)
 option(BUILD_VF_UNIT_TESTS "Build VirtualFluids unit tests" OFF)
 
 option(BUILD_SHARED_LIBS "" ON)
+
+#################################################################################
+#  CMAKE POLICIES
+#################################################################################
+# CMAKE_CUDA_ARCHITECTURES
+# https://cmake.org/cmake/help/git-stage/policy/CMP0104.htmls
+if(POLICY CMP0104)
+    cmake_policy(SET CMP0104 NEW)
+    set(CMAKE_CUDA_ARCHITECTURES 30)
+endif()
+
 #################################################################################
 #  MACROS
 #################################################################################
 include(CMakePrintHelpers)
-set (CMAKE_PATH "${CMAKE_SOURCE_DIR}/CMake")
-include("${CMAKE_PATH}/CMakeCABMacros.cmake")
-include("${CMAKE_PATH}/FileUtilities.cmake")
-include("${CMAKE_PATH}/VirtualFluidsMacros.cmake")
+include(${VF_CMAKE_DIR}/CMakeCABMacros.cmake)
+include(${VF_CMAKE_DIR}/FileUtilities.cmake)
+include(${VF_CMAKE_DIR}/VirtualFluidsMacros.cmake)
 
-include(${CMAKE_PATH}/CMakeMacros_old/general/FindCompiler.cmake)
-configure_file(src/basics/VirtualFluidsDefinitions.in.h VirtualFluidsDefinitions.h)
+include(${VF_CMAKE_DIR}/CMakeMacros_old/general/FindCompiler.cmake)
+configure_file(src/basics/VirtualFluidsDefinitions.in.h ${CMAKE_BINARY_DIR}/VirtualFluidsDefinitions.h)
 
 #################################################################################
 #  COMMON LIBRARIES
@@ -61,5 +76,5 @@ endif()
 #  3rd Party Libraries
 #################################################################################
 if(BUILD_VF_UNIT_TESTS)
-    add_subdirectory(${CMAKE_SOURCE_DIR}/3rdParty/googletest)
+    add_subdirectory(${VF_THIRD_DIR}/googletest)
 endif()
diff --git a/apps/cpu/IncludsList.cmake b/apps/cpu/IncludsList.cmake
index d5ceb5de7764c40bb3fc2bc8e58de6ef9dd8c3dc..9c118e06709823bf4e51837ad4cc58fbd61efcac 100644
--- a/apps/cpu/IncludsList.cmake
+++ b/apps/cpu/IncludsList.cmake
@@ -1,11 +1,14 @@
 INCLUDE_DIRECTORIES(${APPS_ROOT_CPU})
-INCLUDE(${CMAKE_SOURCE_DIR}/src/cpu/VirtualFluidsCore/IncludsList.cmake)
+INCLUDE(${VF_SRC_DIR}/cpu/VirtualFluidsCore/IncludsList.cmake)
 
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/src/basics)
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/src/basics/geometry3d)
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/src/basics/basics/container)
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/src/basics/basics/memory)
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/src/basics/basics/objects)
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/src/basics/basics/transmiitter)
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/src/basics/basics/utilities)
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/src/basics/basics/writer)
\ No newline at end of file
+INCLUDE_DIRECTORIES(${VF_SRC_DIR}/cpu/VirtualFluidsCore)
+INCLUDE_DIRECTORIES(${VF_SRC_DIR}/basics)
+INCLUDE_DIRECTORIES(${VF_SRC_DIR}/basics/geometry3d)
+INCLUDE_DIRECTORIES(${VF_SRC_DIR}/basics/geometry3d/Creator)
+INCLUDE_DIRECTORIES(${VF_SRC_DIR}/basics/geometry3d/KdTree)
+INCLUDE_DIRECTORIES(${VF_SRC_DIR}/basics/basics/container)
+INCLUDE_DIRECTORIES(${VF_SRC_DIR}/basics/basics/memory)
+INCLUDE_DIRECTORIES(${VF_SRC_DIR}/basics/basics/objects)
+INCLUDE_DIRECTORIES(${VF_SRC_DIR}/basics/basics/transmiitter)
+INCLUDE_DIRECTORIES(${VF_SRC_DIR}/basics/basics/utilities)
+INCLUDE_DIRECTORIES(${VF_SRC_DIR}/basics/basics/writer)
diff --git a/apps/gpu/LidDrivenCavity/LidDrivenCavity.cpp b/apps/gpu/LidDrivenCavity/LidDrivenCavity.cpp
index 842c34389bc6ba79d55443b369876ceed232d2bd..8f11d8a197be080e59ab1e445596341b579ea66d 100644
--- a/apps/gpu/LidDrivenCavity/LidDrivenCavity.cpp
+++ b/apps/gpu/LidDrivenCavity/LidDrivenCavity.cpp
@@ -43,7 +43,7 @@
 //////////////////////////////////////////////////////////////////////////
 
 #include "Core/DataTypes.h"
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/LbmOrGks.h"
 #include "Core/VectorTypes.h"
 #include "Core/Logger/Logger.h"
diff --git a/cpu.cmake b/cpu.cmake
index 30b3254457c56120fb90ad150dbb3a88fa60b4af..d554c74a068c7711a7b7c02c0e67d1179a8f7dc3 100644
--- a/cpu.cmake
+++ b/cpu.cmake
@@ -4,13 +4,10 @@ SET(USE_INTEL OFF CACHE BOOL "include Intel compiler support")
 SET(USE_GCC OFF CACHE BOOL "include gcc compiler support")
 
 
-set (SOURCE_DIR ${PROJECT_SOURCE_DIR})
-set(SOURCE_ROOT ${CMAKE_SOURCE_DIR})
-
 #CAB
 include("CMake/CMakeCABMacros.cmake") #TODO: Currently we have to include the CABMacros also here, so that the USE_* are defined in the config files for the cpu version
 
-add_subdirectory(3rdParty/MuParser)
+add_subdirectory(${VF_THIRD_DIR}/MuParser)
 
 add_subdirectory(src/cpu/VirtualFluidsCore)
 
diff --git a/gpu.cmake b/gpu.cmake
index a49f517d03597b1aa9fe9c1de7412753c009946e..1d6ab6f2db516931d74f1fdc2718fd49d6560591 100644
--- a/gpu.cmake
+++ b/gpu.cmake
@@ -41,7 +41,6 @@ endif()
 
 project(VirtualFluidsGPU)
 
-set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
 set(CMAKE_INCLUDE_CURRENT_DIR ON)
 include_directories(${CMAKE_BINARY_DIR}/gpu)
 #
diff --git a/src/basics/CMakeLists.txt b/src/basics/CMakeLists.txt
index 476cbdc75b100d91a8659f2292bcd457d7d0b8c9..0b14ad606e7744aee9d0a00e81652353ae37ab78 100644
--- a/src/basics/CMakeLists.txt
+++ b/src/basics/CMakeLists.txt
@@ -1,59 +1,20 @@
 
-INCLUDE_DIRECTORIES(${CMAKE_CURRENT_LIST_DIR})
-INCLUDE_DIRECTORIES(${CMAKE_CURRENT_LIST_DIR}/geometry3d)
-INCLUDE_DIRECTORIES(${CMAKE_CURRENT_LIST_DIR}/geometry3d/Creator)
-INCLUDE_DIRECTORIES(${CMAKE_CURRENT_LIST_DIR}/geometry3d/KdTree)
-INCLUDE_DIRECTORIES(${CMAKE_CURRENT_LIST_DIR}/basics/container)
-INCLUDE_DIRECTORIES(${CMAKE_CURRENT_LIST_DIR}/basics/memory)
-INCLUDE_DIRECTORIES(${CMAKE_CURRENT_LIST_DIR}/basics/objects)
-INCLUDE_DIRECTORIES(${CMAKE_CURRENT_LIST_DIR}/basics/transmiitter)
-INCLUDE_DIRECTORIES(${CMAKE_CURRENT_LIST_DIR}/utilities)
-INCLUDE_DIRECTORIES(${CMAKE_CURRENT_LIST_DIR}/basics/writer)
-
-
-include (${CMAKE_SOURCE_DIR}/CMake/VirtualFluidsMacros.cmake)
-#SET(CAB_ADDITIONAL_LINK_LIBRARIES ${MPI_CXX_LIBRARIES})
-
 include(Core/buildInfo.cmake)
 
-INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/VirtualFluidsCore)
-INCLUDE_DIRECTORIES(${MPI_INCLUDE_PATH})
-
-
-
-vf_add_library(BUILDTYPE static
-               FOLDER
-        ${CMAKE_CURRENT_LIST_DIR}/geometry3d
-        ${CMAKE_CURRENT_LIST_DIR}/geometry3d/creator
-        ${CMAKE_CURRENT_LIST_DIR}/geometry3d/KdTree
-        ${CMAKE_CURRENT_LIST_DIR}/basics/container
-        ${CMAKE_CURRENT_LIST_DIR}/basics/memory
-        ${CMAKE_CURRENT_LIST_DIR}/basics/objects
-        ${CMAKE_CURRENT_LIST_DIR}/basics/transmiitter
-        ${CMAKE_CURRENT_LIST_DIR}/basics/utilities
-        ${CMAKE_CURRENT_LIST_DIR}/basics/writer
-        ${CMAKE_CURRENT_LIST_DIR}/Core
-        ${CMAKE_CURRENT_LIST_DIR}/Core/Logger
-        ${CMAKE_CURRENT_LIST_DIR}/Core/Logger/implementations
-        ${CMAKE_CURRENT_LIST_DIR}/Core/Input
-        ${CMAKE_CURRENT_LIST_DIR}/Core/Input/ConfigData
-        ${CMAKE_CURRENT_LIST_DIR}/Core/Input/ConfigFileReader
-        ${CMAKE_CURRENT_LIST_DIR}/Core/Input/ConfigInput
-        ${CMAKE_CURRENT_LIST_DIR}/Core/Input/JsonInput
-        ${CMAKE_CURRENT_LIST_DIR}/Core/StringUtilities
-        ${CMAKE_CURRENT_LIST_DIR}/Core/Timer
-
-        EXCLUDE buildInfo.in.cpp
-        )
+vf_add_library(BUILDTYPE static EXCLUDE buildInfo.in.cpp)
 
 vf_get_library_name (library_name)
 target_include_directories(${library_name} PRIVATE ${CMAKE_CURRENT_LIST_DIR}/Core)
-target_include_directories(${library_name} PRIVATE ${CMAKE_CURRENT_BINARY_DIR})
+target_include_directories(${library_name} PRIVATE ${CMAKE_CURRENT_LIST_DIR}/geometry3d)
+target_include_directories(${library_name} PRIVATE ${CMAKE_CURRENT_LIST_DIR}/basics/container)
+target_include_directories(${library_name} PRIVATE ${CMAKE_CURRENT_LIST_DIR}/basics/objects)
+target_include_directories(${library_name} PRIVATE ${CMAKE_CURRENT_LIST_DIR}/utilities)
+target_include_directories(${library_name} PRIVATE ${CMAKE_CURRENT_LIST_DIR}/basics/writer)
 
 IF(MSVC)
     target_compile_definitions(${library_name} PUBLIC NOMINMAX) # Disable Min/Max-Macros
 ENDIF(MSVC)
 
-include (${CMAKE_PATH}/3rd/mpi.cmake)
+include (${VF_CMAKE_DIR}/3rd/mpi.cmake)
 
 vf_add_tests()
\ No newline at end of file
diff --git a/src/basics/Core/buildInfo.cmake b/src/basics/Core/buildInfo.cmake
index 91972c43d54037beb194b7c8a30c3aca43784edb..bbad317e989f670e05eb663a74123343035daa63 100644
--- a/src/basics/Core/buildInfo.cmake
+++ b/src/basics/Core/buildInfo.cmake
@@ -2,7 +2,7 @@ set(buildInfoPath ${CMAKE_BINARY_DIR}/buildInfo)
 set(buildInfoFile buildInfo.cpp)
 set(buildInfoInput ${CMAKE_CURRENT_LIST_DIR}/buildInfo.in.cpp)
 
-include(${CMAKE_PATH}/3rd/git/GetGitRevisionDescription.cmake)
+include(${VF_CMAKE_DIR}/3rd/git/GetGitRevisionDescription.cmake)
 get_git_head_revision(git_branch git_commit_hash)
 
 set(COMPILER_FLAGS "${CMAKE_CXX_FLAGS_${CMAKE_BUILD_TYPE}} ${CMAKE_CXX_FLAGS}")
diff --git a/src/basics/Core/PointerDefinitions.h b/src/basics/PointerDefinitions.h
similarity index 88%
rename from src/basics/Core/PointerDefinitions.h
rename to src/basics/PointerDefinitions.h
index d3257e2ed85b8fb9c8fdf530185e1410259fd355..07462b89eca7f3248ee311a849ba185261597204 100644
--- a/src/basics/Core/PointerDefinitions.h
+++ b/src/basics/PointerDefinitions.h
@@ -23,6 +23,6 @@ using RPtr = T*;
 template <class T>
 using enableSharedFromThis = std::enable_shared_from_this<T>;
 
-#define dynamicPointerCast dynamic_pointer_cast
+#define dynamicPointerCast std::dynamic_pointer_cast
 
 #endif
diff --git a/src/basics/basics/container/CMakePackage.txt b/src/basics/basics/container/CMakePackage.txt
deleted file mode 100644
index b2d974b49ca72178a8823a1e2e06fc7087205c88..0000000000000000000000000000000000000000
--- a/src/basics/basics/container/CMakePackage.txt
+++ /dev/null
@@ -1,4 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES)
-
-
diff --git a/src/basics/basics/objects/CMakePackage.txt b/src/basics/basics/objects/CMakePackage.txt
deleted file mode 100644
index 1b8416f010d2a7de30b8f70c9abf19a96dd8cf8f..0000000000000000000000000000000000000000
--- a/src/basics/basics/objects/CMakePackage.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES)
diff --git a/src/basics/basics/utilities/CMakePackage.txt b/src/basics/basics/utilities/CMakePackage.txt
deleted file mode 100644
index 0127c6fb70ba58900bfa7e273ffb1e02ece1c37e..0000000000000000000000000000000000000000
--- a/src/basics/basics/utilities/CMakePackage.txt
+++ /dev/null
@@ -1,21 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES outOption)
-
-IF(${outOption})
-   IF(WIN32)
-      ADD_DEFINITIONS( -DNOMINMAX )
-   ENDIF(WIN32) 
-   
-   IF(BOOST_VERSION)
-    OPTION(USE_THREADSAFE_LOGGER "ON=thread safe, OFF=not thread safe" ON)
-    IF(NOT ${outOption})
-      ADD_DEFINITIONS( -DNO_THREADSAFE_LOGGING)
-    ELSE()
-      SET(NECESSARY_BOOST_LIBS ${NECESSARY_BOOST_LIBS} thread)
-    ENDIF()
-   ELSE()
-    #um die thread safe zu machen benoetigt man boost
-    ADD_DEFINITIONS( -DNO_THREADSAFE_LOGGING)
-   ENDIF()
-  
-ENDIF()
\ No newline at end of file
diff --git a/src/basics/basics/utilities/UbTuple.h b/src/basics/basics/utilities/UbTuple.h
index 4643a08e9aa1389ad141e68f493886bc39540020..6b9b8b52aef2cb498c127506125b644113456aad 100644
--- a/src/basics/basics/utilities/UbTuple.h
+++ b/src/basics/basics/utilities/UbTuple.h
@@ -616,6 +616,7 @@ typedef UbTuple<int,int,int,int>                           UbTupleInt4;
 typedef UbTuple<int,int,int,int,int>                       UbTupleInt5;
 typedef UbTuple<int,int,int,int,int,int>                   UbTupleInt6;
 typedef UbTuple<int,int,int,int,int,int,int,int>           UbTupleInt8;
+typedef UbTuple<unsigned int,unsigned int,unsigned int,unsigned int,unsigned int,unsigned int,unsigned int,unsigned int> UbTupleUInt8;
 typedef UbTuple<double,double>                             UbTupleDouble2;
 typedef UbTuple<double,double,double>                      UbTupleDouble3;
 typedef UbTuple<double,double,double,double>               UbTupleDouble4;
diff --git a/src/basics/basics/writer/CMakePackage.txt b/src/basics/basics/writer/CMakePackage.txt
deleted file mode 100644
index 6ef17942b856d69df194c11f63050e950564927b..0000000000000000000000000000000000000000
--- a/src/basics/basics/writer/CMakePackage.txt
+++ /dev/null
@@ -1,3 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES)
-
diff --git a/src/basics/basics/writer/WbWriter.h b/src/basics/basics/writer/WbWriter.h
index b8d68db7d232990df738b23c6b2d00a95103c40d..510c160a9d0bde85fddd0ff1137a81a05130d0a7 100644
--- a/src/basics/basics/writer/WbWriter.h
+++ b/src/basics/basics/writer/WbWriter.h
@@ -105,7 +105,7 @@ public:
    //   0 ---- 1
    virtual std::string writeOcts(const std::string& filename,std::vector< UbTupleFloat3 >& nodes, std::vector< UbTupleInt8 >& cells){ throw UbException(UB_EXARGS,"not implemented for "+(std::string)typeid(*this).name() );  }
    virtual std::string writeOctsWithCellData(const std::string& filename,std::vector<UbTupleFloat3 >& nodes, std::vector<UbTupleInt8 >& cells, std::vector<std::string >& datanames, std::vector<std::vector<double > >& celldata){ throw UbException(UB_EXARGS,"not implemented for "+(std::string)typeid(*this).name() );  }
-   virtual std::string writeOctsWithNodeData(const std::string& filename,std::vector<UbTupleFloat3 >& nodes, std::vector<UbTupleInt8 >& cells, std::vector<std::string >& datanames, std::vector<std::vector<double > >& nodedata){ throw UbException(UB_EXARGS,"not implemented for "+(std::string)typeid(*this).name() );  }
+   virtual std::string writeOctsWithNodeData(const std::string& filename,std::vector<UbTupleFloat3 >& nodes, std::vector<UbTupleUInt8 >& cells, std::vector<std::string >& datanames, std::vector<std::vector<double > >& nodedata){ throw UbException(UB_EXARGS,"not implemented for "+(std::string)typeid(*this).name() );  }
 
 private:
 
diff --git a/src/basics/basics/writer/WbWriterVtkXmlASCII.cpp b/src/basics/basics/writer/WbWriterVtkXmlASCII.cpp
index 880fae2bf99d62bc7fa6d0336dfaf3cf9aacabb6..47b5d1fb26243d5c8b5d051ba2459e4219d5fe75 100644
--- a/src/basics/basics/writer/WbWriterVtkXmlASCII.cpp
+++ b/src/basics/basics/writer/WbWriterVtkXmlASCII.cpp
@@ -839,7 +839,7 @@ std::string WbWriterVtkXmlASCII::writeOctsWithCellData(const string& filename,ve
    return vtkfilename;
 }
 /*===============================================================================*/
-std::string WbWriterVtkXmlASCII::writeOctsWithNodeData(const string& filename,vector< UbTupleFloat3 >& nodes, vector< UbTupleInt8 >& cells, vector< string >& datanames, vector< vector< double > >& nodedata)
+std::string WbWriterVtkXmlASCII::writeOctsWithNodeData(const string& filename,vector< UbTupleFloat3 >& nodes, vector< UbTupleUInt8 >& cells, vector< string >& datanames, vector< vector< double > >& nodedata)
 {
    string vtkfilename=filename+getFileExtension();
    UBLOG(logDEBUG1,"WbWriterVtkXmlASCII::writeOctsWithNodeData to "<<vtkfilename<<" - start");
diff --git a/src/basics/basics/writer/WbWriterVtkXmlASCII.h b/src/basics/basics/writer/WbWriterVtkXmlASCII.h
index c2d908e14d14de71a9295b533c8b954baa2d155f..97e60486fc82deee1c634c4c5472781f48924b3a 100644
--- a/src/basics/basics/writer/WbWriterVtkXmlASCII.h
+++ b/src/basics/basics/writer/WbWriterVtkXmlASCII.h
@@ -113,7 +113,7 @@ public:
    //   0 ---- 1
    std::string writeOcts(const std::string& filename,std::vector< UbTupleFloat3 >& nodes, std::vector< UbTupleInt8 >& cells);
    std::string writeOctsWithCellData(const std::string& filename,std::vector< UbTupleFloat3 >& nodes, std::vector< UbTupleInt8 >& cells, std::vector< std::string >& datanames, std::vector< std::vector< double > >& celldata);
-   std::string writeOctsWithNodeData(const std::string& filename,std::vector< UbTupleFloat3 >& nodes, std::vector< UbTupleInt8 >& cells, std::vector< std::string >& datanames, std::vector< std::vector< double > >& nodedata);
+   std::string writeOctsWithNodeData(const std::string& filename,std::vector< UbTupleFloat3 >& nodes, std::vector< UbTupleUInt8 >& cells, std::vector< std::string >& datanames, std::vector< std::vector< double > >& nodedata);
 
 private:
 
diff --git a/src/basics/basics/writer/WbWriterVtkXmlBinary.cpp b/src/basics/basics/writer/WbWriterVtkXmlBinary.cpp
index 94e134e89720eb9b5aa3fd3bb40ed8143f228d62..a1133890e43538affe6d84eaa134b97706198a89 100644
--- a/src/basics/basics/writer/WbWriterVtkXmlBinary.cpp
+++ b/src/basics/basics/writer/WbWriterVtkXmlBinary.cpp
@@ -1190,7 +1190,7 @@ string WbWriterVtkXmlBinary::writeOctsWithCellData(const string& filename,vector
    return vtkfilename;
 }
 /*===============================================================================*/
-string WbWriterVtkXmlBinary::writeOctsWithNodeData(const string& filename,vector<UbTupleFloat3 >& nodes, vector<UbTupleInt8 >& cells, vector<string >& datanames, vector<vector<double > >& nodedata)
+string WbWriterVtkXmlBinary::writeOctsWithNodeData(const string& filename,vector<UbTupleFloat3 >& nodes, vector<UbTupleUInt8 >& cells, vector<string >& datanames, vector<vector<double > >& nodedata)
 {
    string vtkfilename = filename+getFileExtension();
    UBLOG(logDEBUG1,"WbWriterVtkXmlBinary::writeOctsWithNodeData to "<<vtkfilename<<" - start");
diff --git a/src/basics/basics/writer/WbWriterVtkXmlBinary.h b/src/basics/basics/writer/WbWriterVtkXmlBinary.h
index 6ad1ab7fcac4f36c6dcce7358ef94257b9057dbf..b4b03cf68efe298d42a64d003ef6cb9d495e95ba 100644
--- a/src/basics/basics/writer/WbWriterVtkXmlBinary.h
+++ b/src/basics/basics/writer/WbWriterVtkXmlBinary.h
@@ -112,7 +112,7 @@ public:
    //   0 ---- 1
    std::string writeOcts(const std::string& filename,std::vector< UbTupleFloat3 >& nodes, std::vector< UbTupleInt8 >& cells);
    std::string writeOctsWithCellData(const std::string& filename,std::vector<UbTupleFloat3 >& nodes, std::vector<UbTupleInt8 >& cells, std::vector<std::string >& datanames, std::vector<std::vector<double > >& celldata);
-   std::string writeOctsWithNodeData(const std::string& filename,std::vector<UbTupleFloat3 >& nodes, std::vector<UbTupleInt8 >& cells, std::vector<std::string >& datanames, std::vector<std::vector<double > >& nodedata);
+   std::string writeOctsWithNodeData(const std::string& filename,std::vector<UbTupleFloat3 >& nodes, std::vector<UbTupleUInt8 >& cells, std::vector<std::string >& datanames, std::vector<std::vector<double > >& nodedata);
    
 private:
 
diff --git a/src/cpu/VirtualFluidsCore/BoundaryConditions/CMakePackage.txt b/src/cpu/VirtualFluidsCore/BoundaryConditions/CMakePackage.txt
deleted file mode 100644
index e3e3f9a387b022a62ecc0d63c3ef0210313e906d..0000000000000000000000000000000000000000
--- a/src/cpu/VirtualFluidsCore/BoundaryConditions/CMakePackage.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES)
\ No newline at end of file
diff --git a/src/cpu/VirtualFluidsCore/CMakeLists.txt b/src/cpu/VirtualFluidsCore/CMakeLists.txt
index d8bf322defe33c528c929797cf8f838c941ee2e9..889c09c539f62eeef34704cdadb5bb9a3a3f4e60 100644
--- a/src/cpu/VirtualFluidsCore/CMakeLists.txt
+++ b/src/cpu/VirtualFluidsCore/CMakeLists.txt
@@ -15,12 +15,12 @@ ENDIF()
 vf_add_library(BUILDTYPE static DEPENDS basics MuParser ${CAB_ADDITIONAL_LINK_LIBRARIES})
 
 vf_get_library_name(library_name)
-target_include_directories(${library_name} PRIVATE ${CMAKE_SOURCE_DIR}/src/basics)
-target_include_directories(${library_name} PRIVATE ${CMAKE_SOURCE_DIR}/src/basics/geometry3d)
-target_include_directories(${library_name} PRIVATE ${CMAKE_SOURCE_DIR}/src/basics/basics/container)
-target_include_directories(${library_name} PRIVATE ${CMAKE_SOURCE_DIR}/src/basics/basics/memory)
-target_include_directories(${library_name} PRIVATE ${CMAKE_SOURCE_DIR}/src/basics/basics/objects)
-target_include_directories(${library_name} PRIVATE ${CMAKE_SOURCE_DIR}/src/basics/basics/transmitter)
-target_include_directories(${library_name} PRIVATE ${CMAKE_SOURCE_DIR}/src/basics/basics/utilities)
-target_include_directories(${library_name} PRIVATE ${CMAKE_SOURCE_DIR}/src/basics/basics/writer)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/basics)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/basics/geometry3d)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/basics/basics/container)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/basics/basics/memory)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/basics/basics/objects)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/basics/basics/transmitter)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/basics/basics/utilities)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/basics/basics/writer)
 
diff --git a/src/cpu/VirtualFluidsCore/CoProcessors/CMakePackage.txt b/src/cpu/VirtualFluidsCore/CoProcessors/CMakePackage.txt
deleted file mode 100644
index 1b8416f010d2a7de30b8f70c9abf19a96dd8cf8f..0000000000000000000000000000000000000000
--- a/src/cpu/VirtualFluidsCore/CoProcessors/CMakePackage.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES)
diff --git a/src/cpu/VirtualFluidsCore/CoProcessors/WriteBoundaryConditionsCoProcessor.cpp b/src/cpu/VirtualFluidsCore/CoProcessors/WriteBoundaryConditionsCoProcessor.cpp
index 4738e1c0101928fa540a62b8b90812cc381cd30a..dc9549c205beacbaa931913def35c5e10b79a90f 100644
--- a/src/cpu/VirtualFluidsCore/CoProcessors/WriteBoundaryConditionsCoProcessor.cpp
+++ b/src/cpu/VirtualFluidsCore/CoProcessors/WriteBoundaryConditionsCoProcessor.cpp
@@ -166,7 +166,7 @@ void WriteBoundaryConditionsCoProcessor::addDataGeo(SPtr<Block3D> block)
    SPtr<BCArray3D> bcArray = kernel->getBCProcessor()->getBCArray();
 
    //knotennummerierung faengt immer bei 0 an!
-   int SWB, SEB, NEB, NWB, SWT, SET, NET, NWT;
+   unsigned int SWB, SEB, NEB, NWB, SWT, SET, NET, NWT;
 
    int minX1 = 0;
    int minX2 = 0;
diff --git a/src/cpu/VirtualFluidsCore/CoProcessors/WriteBoundaryConditionsCoProcessor.h b/src/cpu/VirtualFluidsCore/CoProcessors/WriteBoundaryConditionsCoProcessor.h
index e35868af0d9a6a86592a34849283314ae960e99e..5786f038989f455236ff79b075219bea66fcd1e2 100644
--- a/src/cpu/VirtualFluidsCore/CoProcessors/WriteBoundaryConditionsCoProcessor.h
+++ b/src/cpu/VirtualFluidsCore/CoProcessors/WriteBoundaryConditionsCoProcessor.h
@@ -74,7 +74,7 @@ protected:
 
 private:
    std::vector<UbTupleFloat3> nodes;
-   std::vector<UbTupleInt8> cells;
+   std::vector<UbTupleUInt8> cells;
    std::vector<std::string> datanames;
    std::vector<std::vector<double> > data;
    std::string path;
diff --git a/src/cpu/VirtualFluidsCore/CoProcessors/WriteMacroscopicQuantitiesCoProcessor.cpp b/src/cpu/VirtualFluidsCore/CoProcessors/WriteMacroscopicQuantitiesCoProcessor.cpp
index 59782e680a6f2922322344b941ea8fd4d7942363..6789ff59e0dc115c36a229253def15326d39fede 100644
--- a/src/cpu/VirtualFluidsCore/CoProcessors/WriteMacroscopicQuantitiesCoProcessor.cpp
+++ b/src/cpu/VirtualFluidsCore/CoProcessors/WriteMacroscopicQuantitiesCoProcessor.cpp
@@ -168,7 +168,7 @@ void WriteMacroscopicQuantitiesCoProcessor::addDataMQ(SPtr<Block3D> block)
    LBMReal vx1,vx2,vx3,drho,press;
 
    //node numbering always starts at 0!
-   int SWB,SEB,NEB,NWB,SWT,SET,NET,NWT;
+   unsigned int SWB,SEB,NEB,NWB,SWT,SET,NET,NWT;
 
    if(block->getKernel()->getCompressible())
    {
diff --git a/src/cpu/VirtualFluidsCore/CoProcessors/WriteMacroscopicQuantitiesCoProcessor.h b/src/cpu/VirtualFluidsCore/CoProcessors/WriteMacroscopicQuantitiesCoProcessor.h
index 0b113ffe40f5e03d5fb9b1a50310c905e8f5592b..67a1c61f3be38a91d2feb01657492508d523aa83 100644
--- a/src/cpu/VirtualFluidsCore/CoProcessors/WriteMacroscopicQuantitiesCoProcessor.h
+++ b/src/cpu/VirtualFluidsCore/CoProcessors/WriteMacroscopicQuantitiesCoProcessor.h
@@ -82,7 +82,7 @@ protected:
 private:
    void init();
    std::vector<UbTupleFloat3> nodes;
-   std::vector<UbTupleInt8> cells;
+   std::vector<UbTupleUInt8> cells;
    std::vector<std::string> datanames;
    std::vector<std::vector<double> > data; 
    std::string path;
diff --git a/src/cpu/VirtualFluidsCore/Connectors/CMakePackage.txt b/src/cpu/VirtualFluidsCore/Connectors/CMakePackage.txt
deleted file mode 100644
index e3e3f9a387b022a62ecc0d63c3ef0210313e906d..0000000000000000000000000000000000000000
--- a/src/cpu/VirtualFluidsCore/Connectors/CMakePackage.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES)
\ No newline at end of file
diff --git a/src/cpu/VirtualFluidsCore/Data/CMakePackage.txt b/src/cpu/VirtualFluidsCore/Data/CMakePackage.txt
deleted file mode 100644
index 1b8416f010d2a7de30b8f70c9abf19a96dd8cf8f..0000000000000000000000000000000000000000
--- a/src/cpu/VirtualFluidsCore/Data/CMakePackage.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES)
diff --git a/src/cpu/VirtualFluidsCore/Grid/CMakePackage.txt b/src/cpu/VirtualFluidsCore/Grid/CMakePackage.txt
deleted file mode 100644
index 1b8416f010d2a7de30b8f70c9abf19a96dd8cf8f..0000000000000000000000000000000000000000
--- a/src/cpu/VirtualFluidsCore/Grid/CMakePackage.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES)
diff --git a/src/cpu/VirtualFluidsCore/IncludsList.cmake b/src/cpu/VirtualFluidsCore/IncludsList.cmake
index 13812a8337d67e4359afb097bd46368f2c2eda2a..57eff2ed980f469b3a9913948fa31e9a3e5bf3d1 100644
--- a/src/cpu/VirtualFluidsCore/IncludsList.cmake
+++ b/src/cpu/VirtualFluidsCore/IncludsList.cmake
@@ -1,18 +1,20 @@
 #directory pathes for header files
 
+set(VirtualFluidsCore_source_dir ${VF_SRC_DIR}/cpu/VirtualFluidsCore)
+vf_get_library_name(library_name)
+
 set (SOURCE_DIR "${CMAKE_SOURCE_DIR}/src/cpu/")
+INCLUDE_DIRECTORIES(${VirtualFluidsCore_source_dir}/BoundaryConditions)
+INCLUDE_DIRECTORIES(${VirtualFluidsCore_source_dir}/Connectors)
+INCLUDE_DIRECTORIES(${VirtualFluidsCore_source_dir}/Data)
+INCLUDE_DIRECTORIES(${VirtualFluidsCore_source_dir}/Interactors)
+INCLUDE_DIRECTORIES(${VirtualFluidsCore_source_dir}/LBM)
+INCLUDE_DIRECTORIES(${VirtualFluidsCore_source_dir}/Parallel)
+INCLUDE_DIRECTORIES(${VirtualFluidsCore_source_dir}/Grid)
+INCLUDE_DIRECTORIES(${VirtualFluidsCore_source_dir}/Visitors)
+INCLUDE_DIRECTORIES(${VirtualFluidsCore_source_dir}/CoProcessors)
+INCLUDE_DIRECTORIES(${VirtualFluidsCore_source_dir}/Utilities)
 
-INCLUDE_DIRECTORIES(${SOURCE_DIR}/VirtualFluidsCore)
-INCLUDE_DIRECTORIES(${SOURCE_DIR}/VirtualFluidsCore/BoundaryConditions)
-INCLUDE_DIRECTORIES(${SOURCE_DIR}/VirtualFluidsCore/Connectors)
-INCLUDE_DIRECTORIES(${SOURCE_DIR}/VirtualFluidsCore/Data)
-INCLUDE_DIRECTORIES(${SOURCE_DIR}/VirtualFluidsCore/Interactors)
-INCLUDE_DIRECTORIES(${SOURCE_DIR}/VirtualFluidsCore/LBM)
-INCLUDE_DIRECTORIES(${SOURCE_DIR}/VirtualFluidsCore/Parallel)
-INCLUDE_DIRECTORIES(${SOURCE_DIR}/VirtualFluidsCore/Grid)
-INCLUDE_DIRECTORIES(${SOURCE_DIR}/VirtualFluidsCore/Visitors)
-INCLUDE_DIRECTORIES(${SOURCE_DIR}/VirtualFluidsCore/CoProcessors)
-INCLUDE_DIRECTORIES(${SOURCE_DIR}/VirtualFluidsCore/Utilities)
+INCLUDE_DIRECTORIES(${VF_THIRD_DIR})
 
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/3rdParty)
 
diff --git a/src/cpu/VirtualFluidsCore/Interactors/CMakePackage.txt b/src/cpu/VirtualFluidsCore/Interactors/CMakePackage.txt
deleted file mode 100644
index 1b8416f010d2a7de30b8f70c9abf19a96dd8cf8f..0000000000000000000000000000000000000000
--- a/src/cpu/VirtualFluidsCore/Interactors/CMakePackage.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES)
diff --git a/src/cpu/VirtualFluidsCore/LBM/CMakePackage.txt b/src/cpu/VirtualFluidsCore/LBM/CMakePackage.txt
deleted file mode 100644
index 1b8416f010d2a7de30b8f70c9abf19a96dd8cf8f..0000000000000000000000000000000000000000
--- a/src/cpu/VirtualFluidsCore/LBM/CMakePackage.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES)
diff --git a/src/cpu/VirtualFluidsCore/Parallel/CMakePackage.txt b/src/cpu/VirtualFluidsCore/Parallel/CMakePackage.txt
deleted file mode 100644
index 1b8416f010d2a7de30b8f70c9abf19a96dd8cf8f..0000000000000000000000000000000000000000
--- a/src/cpu/VirtualFluidsCore/Parallel/CMakePackage.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES)
diff --git a/src/cpu/VirtualFluidsCore/PointerDefinitions.h b/src/cpu/VirtualFluidsCore/PointerDefinitions.h
deleted file mode 100644
index 09f9b1ac2bf04e2873d73e15b9f0b71f28290bde..0000000000000000000000000000000000000000
--- a/src/cpu/VirtualFluidsCore/PointerDefinitions.h
+++ /dev/null
@@ -1,53 +0,0 @@
-//=======================================================================================
-// ____          ____    __    ______     __________   __      __       __        __         
-// \    \       |    |  |  |  |   _   \  |___    ___| |  |    |  |     /  \      |  |        
-//  \    \      |    |  |  |  |  |_)   |     |  |     |  |    |  |    /    \     |  |        
-//   \    \     |    |  |  |  |   _   /      |  |     |  |    |  |   /  /\  \    |  |        
-//    \    \    |    |  |  |  |  | \  \      |  |     |   \__/   |  /  ____  \   |  |____    
-//     \    \   |    |  |__|  |__|  \__\     |__|      \________/  /__/    \__\  |_______|   
-//      \    \  |    |   ________________________________________________________________    
-//       \    \ |    |  |  ______________________________________________________________|   
-//        \    \|    |  |  |         __          __     __     __     ______      _______    
-//         \         |  |  |_____   |  |        |  |   |  |   |  |   |   _  \    /  _____)   
-//          \        |  |   _____|  |  |        |  |   |  |   |  |   |  | \  \   \_______    
-//           \       |  |  |        |  |_____   |   \_/   |   |  |   |  |_/  /    _____  |
-//            \ _____|  |__|        |________|   \_______/    |__|   |______/    (_______/   
-//
-//  This file is part of VirtualFluids. VirtualFluids 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.
-//  
-//  VirtualFluids 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 VirtualFluids (see COPYING.txt). If not, see <http://www.gnu.org/licenses/>.
-//
-//! \file PointerDefinitions.h
-//! \ingroup Core
-//! \author Soeren Peters
-//=======================================================================================
-#ifndef SHARED_POINTER_H
-#define SHARED_POINTER_H
-
-#include <memory>
-
-template <class T>
-using SPtr = std::shared_ptr<T>;
-
-template <class T>
-using WPtr = std::weak_ptr<T>;
-
-template <class T>
-using UPtr = std::unique_ptr<T>;
-
-template <class T>
-using RPtr = T*;
-
-template <class T>
-using enableSharedFromThis = std::enable_shared_from_this<T>;
-
-#endif
diff --git a/src/cpu/VirtualFluidsCore/Utilities/CMakePackage.txt b/src/cpu/VirtualFluidsCore/Utilities/CMakePackage.txt
deleted file mode 100644
index 1b8416f010d2a7de30b8f70c9abf19a96dd8cf8f..0000000000000000000000000000000000000000
--- a/src/cpu/VirtualFluidsCore/Utilities/CMakePackage.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES)
diff --git a/src/cpu/VirtualFluidsCore/Visitors/CMakePackage.txt b/src/cpu/VirtualFluidsCore/Visitors/CMakePackage.txt
deleted file mode 100644
index 1b8416f010d2a7de30b8f70c9abf19a96dd8cf8f..0000000000000000000000000000000000000000
--- a/src/cpu/VirtualFluidsCore/Visitors/CMakePackage.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-GET_FILENAME_COMPONENT( CURRENT_DIR  ${CMAKE_CURRENT_LIST_FILE} PATH) 
-COLLECT_PACKAGE_DATA_WITH_OPTION(${CURRENT_DIR} ALL_SOURCES)
diff --git a/src/gpu/GksGpu/Analyzer/ConvergenceAnalyzer.h b/src/gpu/GksGpu/Analyzer/ConvergenceAnalyzer.h
index 789ba1c286b1282ae8d36f1724a060cddf9c33d9..15b7567977c172fec95221ed5a5ce85f2dd30909 100644
--- a/src/gpu/GksGpu/Analyzer/ConvergenceAnalyzer.h
+++ b/src/gpu/GksGpu/Analyzer/ConvergenceAnalyzer.h
@@ -37,7 +37,7 @@
 
 #include "VirtualFluidsDefinitions.h"
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/DataTypes.h"
 #include "Core/Timer/Timer.h"
 
diff --git a/src/gpu/GksGpu/Analyzer/CupsAnalyzer.h b/src/gpu/GksGpu/Analyzer/CupsAnalyzer.h
index ae36d86c6433cc70c059c2b4914f010130cee3bf..e221f085ae128948dd58dc7ba9b2a92986cc9e19 100644
--- a/src/gpu/GksGpu/Analyzer/CupsAnalyzer.h
+++ b/src/gpu/GksGpu/Analyzer/CupsAnalyzer.h
@@ -37,7 +37,7 @@
 
 #include "VirtualFluidsDefinitions.h"
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/DataTypes.h"
 #include "Core/Timer/Timer.h"
 
diff --git a/src/gpu/GksGpu/Analyzer/package.include b/src/gpu/GksGpu/Analyzer/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GksGpu/BoundaryConditions/BoundaryCondition.h b/src/gpu/GksGpu/BoundaryConditions/BoundaryCondition.h
index 9778745018af8600d129425f99610e65078be3dd..7c54de47e9918a6bec5a61513c4f122247e1b3e7 100644
--- a/src/gpu/GksGpu/BoundaryConditions/BoundaryCondition.h
+++ b/src/gpu/GksGpu/BoundaryConditions/BoundaryCondition.h
@@ -40,7 +40,7 @@
 
 #include "VirtualFluidsDefinitions.h"
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/DataTypes.h"
 #include "Core/VectorTypes.h"
 
diff --git a/src/gpu/GksGpu/BoundaryConditions/IsothermalWall.cu b/src/gpu/GksGpu/BoundaryConditions/IsothermalWall.cu
index 76e451818f657af2cf435d27e03d24ac3db02746..9c5587c83353759d9c0205371ae69cae6c44ceb2 100644
--- a/src/gpu/GksGpu/BoundaryConditions/IsothermalWall.cu
+++ b/src/gpu/GksGpu/BoundaryConditions/IsothermalWall.cu
@@ -39,7 +39,7 @@
 #include <cuda_runtime.h>
 #include <helper_cuda.h>
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/RealConstants.h"
 
 #include "DataBase/DataBase.h"
diff --git a/src/gpu/GksGpu/BoundaryConditions/IsothermalWall.h b/src/gpu/GksGpu/BoundaryConditions/IsothermalWall.h
index 21fda60d0b3a077257c628fb41f66c17232a8efb..e835f7fa2892a9d94f0c81845b65e47d9b8839cd 100644
--- a/src/gpu/GksGpu/BoundaryConditions/IsothermalWall.h
+++ b/src/gpu/GksGpu/BoundaryConditions/IsothermalWall.h
@@ -37,7 +37,7 @@
 
 #include "VirtualFluidsDefinitions.h"
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/DataTypes.h"
 #include "Core/VectorTypes.h"
 
diff --git a/src/gpu/GksGpu/BoundaryConditions/package.include b/src/gpu/GksGpu/BoundaryConditions/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GksGpu/CMakeLists.txt b/src/gpu/GksGpu/CMakeLists.txt
index 5389a294f75a5f5c6c9b96009b22647c914047c8..1ba2960e122963a921c363cf7aa8697e3117a629 100644
--- a/src/gpu/GksGpu/CMakeLists.txt
+++ b/src/gpu/GksGpu/CMakeLists.txt
@@ -1,9 +1,9 @@
 
 vf_add_library(BUILDTYPE shared DEPENDS basics GksMeshAdapter)
 
-include (${CMAKE_PATH}/3rd/cuda.cmake)
-include (${CMAKE_PATH}/3rd/mpi.cmake)
-include (${CMAKE_PATH}/3rd/OpenMP.cmake)
+include (${VF_CMAKE_DIR}/3rd/cuda.cmake)
+include (${VF_CMAKE_DIR}/3rd/mpi.cmake)
+include (${VF_CMAKE_DIR}/3rd/OpenMP.cmake)
 
 vf_get_library_name(library_name)
 target_include_directories(${library_name} PRIVATE "${CMAKE_SOURCE_DIR}/src/basics")
diff --git a/src/gpu/GksGpu/CellProperties/package.include b/src/gpu/GksGpu/CellProperties/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GksGpu/CellUpdate/CellUpdate.cu b/src/gpu/GksGpu/CellUpdate/CellUpdate.cu
index 71c6b68f8505baa4431b9bfe71c9a032ab408399..b62585a8c522b25204f38ad9690cc88bf6d761e0 100644
--- a/src/gpu/GksGpu/CellUpdate/CellUpdate.cu
+++ b/src/gpu/GksGpu/CellUpdate/CellUpdate.cu
@@ -37,7 +37,7 @@
 #include <helper_cuda.h>
 #include <math.h>
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/RealConstants.h"
 
 #include "DataBase/DataBaseStruct.h"
diff --git a/src/gpu/GksGpu/CellUpdate/CellUpdate.h b/src/gpu/GksGpu/CellUpdate/CellUpdate.h
index c7d2f2c1ab14cab73608c1693d6865926860dc8b..836443b4b37f24d4d37ea082a6236bf39a8f1ff9 100644
--- a/src/gpu/GksGpu/CellUpdate/CellUpdate.h
+++ b/src/gpu/GksGpu/CellUpdate/CellUpdate.h
@@ -35,7 +35,7 @@
 
 #include "VirtualFluidsDefinitions.h"
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/DataTypes.h"
 
 #include "DataBase/DataBase.h"
diff --git a/src/gpu/GksGpu/CellUpdate/package.include b/src/gpu/GksGpu/CellUpdate/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GksGpu/CudaUtility/package.include b/src/gpu/GksGpu/CudaUtility/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GksGpu/DataBase/DataBase.h b/src/gpu/GksGpu/DataBase/DataBase.h
index bd34c936fe83088ba8d123b25a42835e12560a07..5b728120d827ccb175cb8ae902607e07288d42ce 100644
--- a/src/gpu/GksGpu/DataBase/DataBase.h
+++ b/src/gpu/GksGpu/DataBase/DataBase.h
@@ -38,7 +38,7 @@
 #include <vector>
 #include <array>
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/DataTypes.h"
 #include "Core/VectorTypes.h"
 #include "Core/ArrayTypes.h"
diff --git a/src/gpu/GksGpu/DataBase/DataBaseAllocator.h b/src/gpu/GksGpu/DataBase/DataBaseAllocator.h
index d44672c647fdde22bcb9a3edc45d5ba8b353951e..6173969ad52a9715296bd9eedb98ad180726b6c0 100644
--- a/src/gpu/GksGpu/DataBase/DataBaseAllocator.h
+++ b/src/gpu/GksGpu/DataBase/DataBaseAllocator.h
@@ -37,7 +37,7 @@
 #include <vector>
 
 #include "Core/DataTypes.h"
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 
 #include "VirtualFluidsDefinitions.h"
 
diff --git a/src/gpu/GksGpu/DataBase/DataBaseAllocatorCPU.cpp b/src/gpu/GksGpu/DataBase/DataBaseAllocatorCPU.cpp
index 5b5a144843626fcd48c6feac78fe3ae176b80b4a..93c8647df0fa04a3336a0404a98931d2c8149816 100644
--- a/src/gpu/GksGpu/DataBase/DataBaseAllocatorCPU.cpp
+++ b/src/gpu/GksGpu/DataBase/DataBaseAllocatorCPU.cpp
@@ -35,7 +35,7 @@
 #include <cstring>
 
 #include "Core/DataTypes.h"
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 
 #include "GksMeshAdapter/GksMeshAdapter.h"
 
diff --git a/src/gpu/GksGpu/DataBase/DataBaseAllocatorCPU.h b/src/gpu/GksGpu/DataBase/DataBaseAllocatorCPU.h
index afaf9e423ed517d8631f9fe05acfe7c47f087af5..19464aa98fbf30206c04adf540b28416139f5d66 100644
--- a/src/gpu/GksGpu/DataBase/DataBaseAllocatorCPU.h
+++ b/src/gpu/GksGpu/DataBase/DataBaseAllocatorCPU.h
@@ -34,7 +34,7 @@
 #define DatabaseAllocatorCPU_H
 
 #include "Core/DataTypes.h"
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 
 #include "DataBaseAllocator.h"
 
diff --git a/src/gpu/GksGpu/DataBase/DataBaseAllocatorGPU.cpp b/src/gpu/GksGpu/DataBase/DataBaseAllocatorGPU.cpp
index cb3df88ea0eb55436accbab9eea786d6e38f7aa9..31c848cdbd7165af348d8206569d7f7c41549f31 100644
--- a/src/gpu/GksGpu/DataBase/DataBaseAllocatorGPU.cpp
+++ b/src/gpu/GksGpu/DataBase/DataBaseAllocatorGPU.cpp
@@ -38,7 +38,7 @@
 #include <helper_cuda.h>
 
 #include "Core/DataTypes.h"
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 
 #include "GksMeshAdapter/GksMeshAdapter.h"
 
diff --git a/src/gpu/GksGpu/DataBase/DataBaseAllocatorGPU.h b/src/gpu/GksGpu/DataBase/DataBaseAllocatorGPU.h
index 4c72ee3669423f6a7aeeee137174b1eb28a9c95d..5ed4c14329b1f4b342c7d609803db3b17bbf9dcb 100644
--- a/src/gpu/GksGpu/DataBase/DataBaseAllocatorGPU.h
+++ b/src/gpu/GksGpu/DataBase/DataBaseAllocatorGPU.h
@@ -34,7 +34,7 @@
 #define DatabaseAllocatorGPU_H
 
 #include "Core/DataTypes.h"
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 
 #include "DataBaseAllocator.h"
 
diff --git a/src/gpu/GksGpu/DataBase/package.include b/src/gpu/GksGpu/DataBase/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GksGpu/Definitions/package.include b/src/gpu/GksGpu/Definitions/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GksGpu/FlowStateData/package.include b/src/gpu/GksGpu/FlowStateData/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GksGpu/FluxComputation/FluxComputation.cu b/src/gpu/GksGpu/FluxComputation/FluxComputation.cu
index 9fdd102c45e60c48fc3a5fa3f2170ee58fd5b737..b013bdfcee464e836aca5250be2dd2ae1bd07d62 100644
--- a/src/gpu/GksGpu/FluxComputation/FluxComputation.cu
+++ b/src/gpu/GksGpu/FluxComputation/FluxComputation.cu
@@ -36,7 +36,7 @@
 #include <cuda_runtime.h>
 #include <helper_cuda.h>
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 
 #include "DataBase/DataBaseStruct.h"
 
diff --git a/src/gpu/GksGpu/FluxComputation/FluxComputation.h b/src/gpu/GksGpu/FluxComputation/FluxComputation.h
index 1202c38f9bc5646ffcfb2dc90bbfc2efd6db5350..0f49cff41bac650c2b4dbed81839a29fc4d7507f 100644
--- a/src/gpu/GksGpu/FluxComputation/FluxComputation.h
+++ b/src/gpu/GksGpu/FluxComputation/FluxComputation.h
@@ -35,7 +35,7 @@
 
 #include "VirtualFluidsDefinitions.h"
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/DataTypes.h"
 
 #include "DataBase/DataBase.h"
diff --git a/src/gpu/GksGpu/FluxComputation/package.include b/src/gpu/GksGpu/FluxComputation/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GksGpu/Initializer/Initializer.cpp b/src/gpu/GksGpu/Initializer/Initializer.cpp
index 15bf9dbd6f40afbe0aa822cac447452daa9f621c..cdeeed1205cd386acb8763761f23f555ddfb8cfc 100644
--- a/src/gpu/GksGpu/Initializer/Initializer.cpp
+++ b/src/gpu/GksGpu/Initializer/Initializer.cpp
@@ -36,7 +36,7 @@
 #define _USE_MATH_DEFINES
 #include <math.h>
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/RealConstants.h"
 
 #include "DataBase/DataBaseStruct.h"
diff --git a/src/gpu/GksGpu/Initializer/Initializer.h b/src/gpu/GksGpu/Initializer/Initializer.h
index 249cd7cf49c0246d8401965d46bab5ae6177501e..0397af3f0c7d5169fd93d246655e7289d27a8aae 100644
--- a/src/gpu/GksGpu/Initializer/Initializer.h
+++ b/src/gpu/GksGpu/Initializer/Initializer.h
@@ -39,7 +39,7 @@
 
 #include "VirtualFluidsDefinitions.h"
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/DataTypes.h"
 #include "Core/VectorTypes.h"
 
diff --git a/src/gpu/GksGpu/Initializer/InitializerKernel.cu b/src/gpu/GksGpu/Initializer/InitializerKernel.cu
index 38a96ef1d4f6cef2dac9f62a9a20c43012377315..655ce8a1e79c9299fa6af0b2317272a33b7738fd 100644
--- a/src/gpu/GksGpu/Initializer/InitializerKernel.cu
+++ b/src/gpu/GksGpu/Initializer/InitializerKernel.cu
@@ -36,7 +36,7 @@
 #include <cuda_runtime.h>
 #include <helper_cuda.h>
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/RealConstants.h"
 
 #include "DataBase/DataBaseStruct.h"
diff --git a/src/gpu/GksGpu/Initializer/package.include b/src/gpu/GksGpu/Initializer/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GksGpu/Output/package.include b/src/gpu/GksGpu/Output/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GksGpu/Parameters/package.include b/src/gpu/GksGpu/Parameters/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GksGpu/TimeStepping/NestedTimeStep.h b/src/gpu/GksGpu/TimeStepping/NestedTimeStep.h
index 8b31dbac4fe06a5cb770169a863aa9a441d7ed7c..cb2ded487d2bd1148c74763cae436a9331b4fb62 100644
--- a/src/gpu/GksGpu/TimeStepping/NestedTimeStep.h
+++ b/src/gpu/GksGpu/TimeStepping/NestedTimeStep.h
@@ -35,7 +35,7 @@
 
 #include "VirtualFluidsDefinitions.h"
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/DataTypes.h"
 
 #include "DataBase/DataBase.h"
diff --git a/src/gpu/GksGpu/TimeStepping/package.include b/src/gpu/GksGpu/TimeStepping/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GksMeshAdapter/GksMeshAdapter.h b/src/gpu/GksMeshAdapter/GksMeshAdapter.h
index cffb9c89ed557455d72fcb8f65027054bbce2c20..6a51d206deea911a5e95ec01f818c3d5622027c8 100644
--- a/src/gpu/GksMeshAdapter/GksMeshAdapter.h
+++ b/src/gpu/GksMeshAdapter/GksMeshAdapter.h
@@ -38,7 +38,7 @@
 #include <vector>
 
 #include "Core/DataTypes.h"
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 
 #include "MeshCell.h"
 #include "MeshFace.h"
diff --git a/src/gpu/GridGenerator/CMakeLists.txt b/src/gpu/GridGenerator/CMakeLists.txt
index 7ec3d01d871944022e73d5064f0352958014836a..92f83cc1b27bbb7c130e24c55042ed6f27a841ec 100644
--- a/src/gpu/GridGenerator/CMakeLists.txt
+++ b/src/gpu/GridGenerator/CMakeLists.txt
@@ -1,26 +1,15 @@
 
 
-#include (${CMAKE_SOURCE_DIR}/${cmakeMacroPath}/Cuda/Link.cmake)
-#linkCuda(${targetName})
-#include (${CMAKE_SOURCE_DIR}/${cmakeMacroPath}/MPI/Link.cmake)
-#linkMPI(${targetName})
-#include (${CMAKE_SOURCE_DIR}/${cmakeMacroPath}/Boost/Link.cmake)
-#linkBoost(${targetName} "serialization")
-#include (${CMAKE_SOURCE_DIR}/${cmakeMacroPath}/Metis/Link.cmake)
-#linkMetis(${targetName})
-#include (${CMAKE_SOURCE_DIR}/${cmakeMacroPath}/OpenMP/Link.cmake)
-#linkOpenMP(${targetName})
-
-
 vf_add_library(BUILDTYPE shared DEPENDS basics)
 
-include (${CMAKE_PATH}/3rd/cuda.cmake)
-include (${CMAKE_PATH}/3rd/OpenMP.cmake)
+include (${VF_CMAKE_DIR}/3rd/cuda.cmake)
+include (${VF_CMAKE_DIR}/3rd/OpenMP.cmake)
 
 vf_get_library_name(library_name)
-target_include_directories(${library_name} PRIVATE "${CMAKE_SOURCE_DIR}/src/basics")
-target_include_directories(${library_name} PRIVATE "${CMAKE_SOURCE_DIR}/src/gpu")
-target_include_directories(${library_name} PRIVATE "${CMAKE_SOURCE_DIR}/src/basics/Core")
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/basics)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/basics/geometry3d)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/gpu)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/basics/Core)
 
 
 set_property(TARGET ${library_name} PROPERTY CUDA_SEPARABLE_COMPILATION ON)
\ No newline at end of file
diff --git a/src/gpu/GridGenerator/geometries/BoundingBox/package.include b/src/gpu/GridGenerator/geometries/BoundingBox/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GridGenerator/geometries/Cuboid/package.include b/src/gpu/GridGenerator/geometries/Cuboid/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GridGenerator/geometries/Vertex/package.include b/src/gpu/GridGenerator/geometries/Vertex/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GridGenerator/geometries/package.include b/src/gpu/GridGenerator/geometries/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GridGenerator/global.h b/src/gpu/GridGenerator/global.h
index cb7b08bdcd7a676bc8eec24307be79ee389aef51..248e3aeddfac9141fab3b3e84c29110d54873f5f 100644
--- a/src/gpu/GridGenerator/global.h
+++ b/src/gpu/GridGenerator/global.h
@@ -43,7 +43,7 @@
 
 #include "GridGenerator_export.h"
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/DataTypes.h"
 
 #include "Core/Logger/Logger.h"
diff --git a/src/gpu/GridGenerator/grid/BoundaryConditions/package.include b/src/gpu/GridGenerator/grid/BoundaryConditions/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GridGenerator/grid/GridBuilder/package.include b/src/gpu/GridGenerator/grid/GridBuilder/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GridGenerator/grid/GridStrategy/GridCpuStrategy/package.include b/src/gpu/GridGenerator/grid/GridStrategy/GridCpuStrategy/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GridGenerator/grid/GridStrategy/package.include b/src/gpu/GridGenerator/grid/GridStrategy/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GridGenerator/grid/distributions/package.include b/src/gpu/GridGenerator/grid/distributions/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GridGenerator/grid/package.include b/src/gpu/GridGenerator/grid/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GridGenerator/utilities/math/package.include b/src/gpu/GridGenerator/utilities/math/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/GridGenerator/utilities/package.include b/src/gpu/GridGenerator/utilities/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/VirtualFluids_GPU/CMakeLists.txt b/src/gpu/VirtualFluids_GPU/CMakeLists.txt
index 22399d093f694e60171b5f58b304b8b12a1027a5..2098866b608bdaee1d9471393e14b779b7b1384a 100644
--- a/src/gpu/VirtualFluids_GPU/CMakeLists.txt
+++ b/src/gpu/VirtualFluids_GPU/CMakeLists.txt
@@ -9,13 +9,13 @@ ENDIF(MSVC)
 
 vf_add_library(BUILDTYPE shared DEPENDS ${libsToLink})
 
-include (${CMAKE_PATH}/3rd/cuda.cmake)
+include (${VF_CMAKE_DIR}/3rd/cuda.cmake)
 
 vf_get_library_name(library_name)
-target_include_directories(${library_name} PRIVATE "${CMAKE_SOURCE_DIR}/src/basics")
-target_include_directories(${library_name} PRIVATE "${CMAKE_SOURCE_DIR}/src/gpu")
-target_include_directories(${library_name} PRIVATE "${CMAKE_SOURCE_DIR}/src/gpu/GridGenerator")
-target_include_directories(${library_name} PRIVATE "${CMAKE_SOURCE_DIR}/src/basics/Core")
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/basics)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/gpu)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/gpu/GridGenerator)
+target_include_directories(${library_name} PRIVATE ${VF_SRC_DIR}/basics/Core)
 
 
 #SET(TPN_WIN32 "/EHsc")
diff --git a/src/gpu/VirtualFluids_GPU/DataStructureInitializer/GridProvider.h b/src/gpu/VirtualFluids_GPU/DataStructureInitializer/GridProvider.h
index eb16652deb94f7f84a68742cd0b8a80cddc8f6ab..a4224b4ef5f19eaae1e2000e1abcc0cf65ac4710 100644
--- a/src/gpu/VirtualFluids_GPU/DataStructureInitializer/GridProvider.h
+++ b/src/gpu/VirtualFluids_GPU/DataStructureInitializer/GridProvider.h
@@ -36,7 +36,7 @@
 #include <memory>
 
 #include <VirtualFluidsDefinitions.h>
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "VirtualFluids_GPU_export.h"
 
 //! \brief Class forwarding for CudaMemoryManager, GridBuilder and Parameter
diff --git a/src/gpu/VirtualFluids_GPU/DataStructureInitializer/GridReaderGenerator/package.include b/src/gpu/VirtualFluids_GPU/DataStructureInitializer/GridReaderGenerator/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/VirtualFluids_GPU/DataStructureInitializer/package.include b/src/gpu/VirtualFluids_GPU/DataStructureInitializer/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/VirtualFluids_GPU/GPU/CudaMemoryManager.h b/src/gpu/VirtualFluids_GPU/GPU/CudaMemoryManager.h
index 322c5592f2c4b1162f5033f6d68d356cf11d5950..e5e3ab91dfec5b85b4c753fe5ae90518bd22511c 100644
--- a/src/gpu/VirtualFluids_GPU/GPU/CudaMemoryManager.h
+++ b/src/gpu/VirtualFluids_GPU/GPU/CudaMemoryManager.h
@@ -34,7 +34,7 @@
 #define CudamemoryManager_H
 
 #include <memory>
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "VirtualFluids_GPU_export.h"
 
 //! \brief Class forwarding for Parameter
diff --git a/src/gpu/VirtualFluids_GPU/GPU/package.include b/src/gpu/VirtualFluids_GPU/GPU/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/VirtualFluids_GPU/Init/InitLattice.h b/src/gpu/VirtualFluids_GPU/Init/InitLattice.h
index ceb8e200b23dc063c9bb7728e3a2794a942c2ea8..4c51d2ee0a4f500aaa3dd4d49217fe603059e9d5 100644
--- a/src/gpu/VirtualFluids_GPU/Init/InitLattice.h
+++ b/src/gpu/VirtualFluids_GPU/Init/InitLattice.h
@@ -33,7 +33,7 @@
 #ifndef INIT_LATTICE_H
 #define INIT_LATTICE_H
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 
 //! \brief Class forwarding for Parameter
 class Parameter;
diff --git a/src/gpu/VirtualFluids_GPU/Init/package.include b/src/gpu/VirtualFluids_GPU/Init/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/VirtualFluids_GPU/LBM/Simulation.h b/src/gpu/VirtualFluids_GPU/LBM/Simulation.h
index bd1760ce39ab7a2f3103411bfdc5350850c79a3a..791ce78f7f1a2313f8b365b8f92059665fcd744a 100644
--- a/src/gpu/VirtualFluids_GPU/LBM/Simulation.h
+++ b/src/gpu/VirtualFluids_GPU/LBM/Simulation.h
@@ -33,7 +33,7 @@
 #ifndef _SIMULATION_H_
 #define _SIMULATION_H_
 
-#include <Core/PointerDefinitions.h>
+#include <PointerDefinitions.h>
 #include <VirtualFluidsDefinitions.h>
 #include "Output/LogWriter.hpp"
 #include "VirtualFluids_GPU_export.h"
diff --git a/src/gpu/VirtualFluids_GPU/LBM/package.include b/src/gpu/VirtualFluids_GPU/LBM/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/VirtualFluids_GPU/Output/DataWriter.h b/src/gpu/VirtualFluids_GPU/Output/DataWriter.h
index 6406cad772056bf243f609174f4b10d9e145d45a..6c10ea2f4b27f2553d8c827a4426172efda7dc8e 100644
--- a/src/gpu/VirtualFluids_GPU/Output/DataWriter.h
+++ b/src/gpu/VirtualFluids_GPU/Output/DataWriter.h
@@ -33,7 +33,7 @@
 #ifndef DATA_WRITER_H
 #define DATA_WRITER_H
 
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "Core/DataTypes.h"
 #include "VirtualFluids_GPU_export.h"
 
diff --git a/src/gpu/VirtualFluids_GPU/Output/package.include b/src/gpu/VirtualFluids_GPU/Output/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000
diff --git a/src/gpu/VirtualFluids_GPU/Parameter/Parameter.h b/src/gpu/VirtualFluids_GPU/Parameter/Parameter.h
index 6826684103e99315620fc979c875544315841366..5afd9aed76f3c6d061f9d36b29e43932aee6c46b 100644
--- a/src/gpu/VirtualFluids_GPU/Parameter/Parameter.h
+++ b/src/gpu/VirtualFluids_GPU/Parameter/Parameter.h
@@ -34,7 +34,7 @@
 #define PARAMETER_H
 
 #include "LBM/LB.h"
-#include "Core/PointerDefinitions.h"
+#include "PointerDefinitions.h"
 #include "VirtualFluidsDefinitions.h"
 #include "VirtualFluids_GPU_export.h"
 
diff --git a/src/gpu/VirtualFluids_GPU/Parameter/package.include b/src/gpu/VirtualFluids_GPU/Parameter/package.include
deleted file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000