diff --git a/DDEve/CMakeLists.txt b/DDEve/CMakeLists.txt
index 255e350d8dad68ae3f9289cc44080c5b3c5926e5..9f865d1d273c9bbc9b1fc6cb9bcd9b0740b849b9 100644
--- a/DDEve/CMakeLists.txt
+++ b/DDEve/CMakeLists.txt
@@ -17,7 +17,7 @@ target_include_directories(DDEve_Interface
   $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
   $<INSTALL_INTERFACE:include>
 )
-target_link_libraries(DDEve_Interface INTERFACE ROOT::Core ROOT::Rint ROOT::Eve ROOT::Gui ROOT::Graf3d ROOT::RGL ROOT::EG ROOT::ROOTEve)
+target_link_libraries(DDEve_Interface INTERFACE ROOT::Core ROOT::Rint ROOT::Eve ROOT::Gui ROOT::Graf3d ROOT::RGL ROOT::EG)
 
 dd4hep_add_dictionary(G__DDEve
   SOURCES ../DDCore/include/ROOT/Warnings.h include/DDEve/*.h
@@ -29,14 +29,20 @@ dd4hep_add_dictionary(G__DDEve
   USES DD4hep::DDCore
   )
 
+if(TARGET ROOT::ROOTEve)
+  dd4hep_print("Building the web display using ROOT7")
+  SET(DDEVE_ROOT7_SOURCES root7/WebDisplay.cpp)
+  SET(DDEVE_ROOT7_LINK ROOT::ROOTEve)
+endif()
+
 if(TARGET LCIO::LCIO)
   SET(DDEVE_LCIO_SOURCES lcio/LCIOEventHandler.cpp)
   SET(DDEVE_LCIO_LINK LCIO::LCIO)
 endif()
 
-dd4hep_add_plugin(DDEvePlugins SOURCES src/*.cpp ${DDEVE_LCIO_SOURCES}
+dd4hep_add_plugin(DDEvePlugins SOURCES src/*.cpp ${DDEVE_LCIO_SOURCES} ${DDEVE_ROOT7_SOURCES}
   GENERATED G__DDEve.cxx
-  USES      DD4hep::DDCore DD4hep::DDEve_Interface ${DDEVE_LCIO_LINK}
+  USES      DD4hep::DDCore DD4hep::DDEve_Interface ${DDEVE_LCIO_LINK} ${DDEVE_ROOT7_LINK}
   )
 
 if(DD4HEP_USE_GEANT4)
diff --git a/DDEve/src/WebDisplay.cpp b/DDEve/root7/WebDisplay.cpp
similarity index 100%
rename from DDEve/src/WebDisplay.cpp
rename to DDEve/root7/WebDisplay.cpp
diff --git a/UtilityApps/CMakeLists.txt b/UtilityApps/CMakeLists.txt
index 6fcdac99fd3faa0ce9f0841f3cd0c7f22bca3ecd..d68277a7837a95506ad27678dd3f37c60b0a6c7b 100644
--- a/UtilityApps/CMakeLists.txt
+++ b/UtilityApps/CMakeLists.txt
@@ -13,9 +13,6 @@ SET_PROPERTY(DIRECTORY . PROPERTY PACKAGE_NAME UtilityApps)
 add_executable(geoDisplay src/display.cpp)
 target_link_libraries(geoDisplay DD4hep::DDCore)
 #-----------------------------------------------------------------------------------
-add_executable(geoWebDisplay src/webdisplay.cpp)
-target_link_libraries(geoWebDisplay DD4hep::DDCore)
-#-----------------------------------------------------------------------------------
 add_executable(geoConverter src/converter.cpp)
 target_link_libraries(geoConverter DD4hep::DDCore)
 #-----------------------------------------------------------------------------------
@@ -44,6 +41,12 @@ if(TARGET Geant4::Interface)
   LIST(APPEND OPTIONAL_EXECUTABLES dumpdetector)
 endif()
 
+# the web display tool depends on the ROOT7 version of DDEve
+if(TARGET ROOT::ROOTEve)
+  add_executable(geoWebDisplay src/webdisplay.cpp)
+  target_link_libraries(geoWebDisplay DD4hep::DDCore)
+endif()
+
 # #-----------------------------------------------------------------------------------
 if(BUILD_TESTING)
   if(DD4HEP_USE_LCIO)