Skip to content

Commit

Permalink
[ 423: Non RHEL building ] (#424)
Browse files Browse the repository at this point in the history
Fixes #423

### Summarize your change.
Have removed the blocking of trying to build on non-RHEL distro and
changed to only use lib64 on RHEL distros.

### Describe the reason for the change.
Unable to build on eg. Ubuntu

### Describe what you have tested and on which operating system.
Have tested with Ubuntu 20.04 using a custom build of Qt5 (and rest is
standard repo packages)

### Add a list of changes, and note any that might need special
attention during the review.
Have not (yet) tested on a RHEL distro, but have made changes that
differentiate between RHEL and non-RHEL Linux distros

---------

Signed-off-by: Jimmy Christensen <[email protected]>
Co-authored-by: Bernard Laberge <[email protected]>
  • Loading branch information
lithorus and bernie-laberge authored May 29, 2024
1 parent 3ec54d2 commit 9844fa4
Show file tree
Hide file tree
Showing 9 changed files with 16 additions and 12 deletions.
2 changes: 0 additions & 2 deletions cmake/defaults/rv_targets.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,6 @@ ELSEIF(UNIX)
SET(RV_TARGET_IS_RHEL${RHEL_VERSION_MAJOR}
BOOL TRUE "Detected a Redhat Entreprise Linux OS"
)
ELSE()
MESSAGE(FATAL_ERROR "Unknown or unsupported Linux distribution version; stopping configuration!")
ENDIF()
ELSEIF(WIN32)
MESSAGE(STATUS "Building RV for Microsoft Windows")
Expand Down
10 changes: 8 additions & 2 deletions cmake/dependencies/dav1d.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,17 @@ SET(_install_dir
SET(_include_dir
${_install_dir}/include
)
IF(RV_TARGET_LINUX)
IF(RHEL_VERBOSE)
SET(_lib_dir_name
lib64
)
SET(_lib_dir
${_install_dir}/lib64
)
ELSE()
SET(_lib_dir_name
lib
)
SET(_lib_dir
${_install_dir}/lib
)
Expand Down Expand Up @@ -81,7 +87,7 @@ EXTERNALPROJECT_ADD(
INSTALL_DIR ${_install_dir}
URL ${_download_url}
URL_MD5 ${_download_hash}
CONFIGURE_COMMAND ${_configure_command} ./_build --default-library=${_default_library} --prefix=${_install_dir} -Denable_tests=false -Denable_tools=false
CONFIGURE_COMMAND ${_configure_command} ./_build --libdir=${_lib_dir_name} --default-library=${_default_library} --prefix=${_install_dir} -Denable_tests=false -Denable_tools=false
BUILD_COMMAND ${_make_command} -C _build
INSTALL_COMMAND ${_make_command} -C _build install
COMMAND ${CMAKE_COMMAND} -E copy_directory ${_lib_dir} ${RV_STAGE_LIB_DIR}
Expand Down
4 changes: 2 additions & 2 deletions cmake/dependencies/glew.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ SET(_install_dir
${RV_DEPS_BASE_DIR}/${_target}/install
)

IF(RV_TARGET_LINUX)
IF(RHEL_VERBOSE)
SET(_lib_dir
${_install_dir}/lib64
)
Expand Down Expand Up @@ -74,7 +74,7 @@ EXTERNALPROJECT_ADD(
DOWNLOAD_DIR ${RV_DEPS_DOWNLOAD_DIR}
CONFIGURE_COMMAND cd auto && ${_make_command}
BUILD_COMMAND ${_make_command} -j${_cpu_count} GLEW_DEST=${_install_dir}
INSTALL_COMMAND ${_make_command} install GLEW_DEST=${_install_dir}
INSTALL_COMMAND ${_make_command} install LIBDIR=${_lib_dir} GLEW_DEST=${_install_dir}
BUILD_IN_SOURCE TRUE
BUILD_ALWAYS FALSE
BUILD_BYPRODUCTS ${_glew_lib}
Expand Down
2 changes: 1 addition & 1 deletion cmake/dependencies/imath.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ ELSEIF(RV_TARGET_WINDOWS)
)
ENDIF()

IF(RV_TARGET_LINUX)
IF(RHEL_VERBOSE)
SET(_lib_dir
${_install_dir}/lib64
)
Expand Down
2 changes: 1 addition & 1 deletion cmake/dependencies/ocio.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ IF(RV_TARGET_WINDOWS)
"${RV_DEPS_OCIO_DIST_DIR}/lib"
)
ENDIF()
IF(RV_TARGET_LINUX)
IF(RHEL_VERBOSE)
SET(_ociolib_dir
"${RV_DEPS_OCIO_DIST_DIR}/lib64"
)
Expand Down
2 changes: 1 addition & 1 deletion cmake/dependencies/openexr.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ SET(${_target}_ROOT_DIR
${_install_dir}
)

IF(RV_TARGET_LINUX)
IF(RHEL_VERBOSE)
SET(_lib_dir
${_install_dir}/lib64
)
Expand Down
2 changes: 1 addition & 1 deletion cmake/dependencies/spdlog.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ SET(_include_dir
${_install_dir}/include
)

IF(RV_TARGET_LINUX)
IF(RHEL_VERBOSE)
SET(_lib_dir
${_install_dir}/lib64
)
Expand Down
2 changes: 1 addition & 1 deletion cmake/dependencies/yaml-cpp.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ ELSE()
)
ENDIF()

IF(RV_TARGET_LINUX)
IF(RHEL_VERBOSE)
SET(_lib_dir
${RV_DEPS_OCIO_DIST_DIR}/lib64
)
Expand Down
2 changes: 1 addition & 1 deletion cmake/macros/rv_create_std_deps_vars.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ MACRO(RV_CREATE_STANDARD_DEPS_VARIABLES target_name version make_command configu
SET(_source_dir
${_base_dir}/src
)
IF(RV_TARGET_LINUX)
IF(RHEL_VERBOSE)
SET(_lib_dir
${_install_dir}/lib64
)
Expand Down

0 comments on commit 9844fa4

Please sign in to comment.