Skip to content

Commit

Permalink
[cmake] fine-tune the builtin-afterimage flag removal (root-project#1…
Browse files Browse the repository at this point in the history
…5195)

* [cmake] only build afterimage if asimage is ON

Fine-tunes commit root-project@0992621

* [cmake] mention builtin_afterimage as removed

And clarify warning, rather than saying that it is not supported, as someone might think that things that are now ON by default are no longer supported.
  • Loading branch information
ferdymercury authored and vepadulano committed Apr 11, 2024
1 parent 2e53ed2 commit c08ae13
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 19 deletions.
4 changes: 2 additions & 2 deletions cmake/modules/RootBuildOptions.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -394,13 +394,13 @@ if(NOT webgui)
endif()

#---Removed options------------------------------------------------------------
foreach(opt afdsmgrd afs alien bonjour castor chirp cxx11 cxx14 cxx17
foreach(opt afdsmgrd afs alien bonjour builtin_afterimage castor chirp cxx11 cxx14 cxx17
exceptions geocad gfal glite globus gsl_shared hdfs ios jemalloc krb5
ldap memstat minuit2 monalisa oracle pyroot-python2 pyroot_legacy
pythia6 pythia6_nolink python qt qtgsi rfio ruby sapdb srp table
tcmalloc vmc xproofd)
if(${opt})
message(FATAL_ERROR ">>> Option '${opt}' is no longer supported in ROOT ${ROOT_VERSION}.")
message(FATAL_ERROR ">>> '${opt}' is no longer part of ROOT ${ROOT_VERSION} build options.")
endif()
endforeach()

Expand Down
18 changes: 1 addition & 17 deletions cmake/modules/SearchInstalledSoftware.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -406,23 +406,8 @@ if(asimage)
if(JPEG_FOUND)
set(ASEXTRA_LIBRARIES ${ASEXTRA_LIBRARIES} ${JPEG_LIBRARIES})
endif()
endif()

#---Check for AfterImage---------------------------------------------------------------
if(asimage AND NOT builtin_afterimage)
message(STATUS "Looking for AfterImage")
if(fail-on-missing)
find_package(AfterImage REQUIRED)
else()
find_package(AfterImage)
if(NOT AFTERIMAGE_FOUND)
message(STATUS "AfterImage not found. Switching on builtin_afterimage option")
set(builtin_afterimage ON CACHE BOOL "Enabled because asimage requested and AfterImage not found (${builtin_afterimage_description})" FORCE)
endif()
endif()
endif()

if(builtin_afterimage)
#---AfterImage---------------------------------------------------------------
set(AFTERIMAGE_LIBRARIES ${CMAKE_BINARY_DIR}/lib/libAfterImage${CMAKE_STATIC_LIBRARY_SUFFIX})
if(WIN32)
if(winrtdebug)
Expand All @@ -443,7 +428,6 @@ if(builtin_afterimage)
)
set(AFTERIMAGE_INCLUDE_DIR ${CMAKE_BINARY_DIR}/AFTERIMAGE-prefix/src/AFTERIMAGE)
else()
message(STATUS "Building AfterImage library included in ROOT itself")
if(JPEG_FOUND)
set(_jpeginclude --with-jpeg-includes=${JPEG_INCLUDE_DIR})
else()
Expand Down

0 comments on commit c08ae13

Please sign in to comment.