Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New package: radiance-5.2 #18853

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 41 additions & 0 deletions srcpkgs/radiance/patches/001-rem_qt5deps.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
--- /CMakeLists.txt
+++ /CMakeLists.txt
@@ -34,12 +34,12 @@
if(NOT WIN32)
set(CPACK_INCLUDE_TOPLEVEL_DIRECTORY 1)
install(DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/doc/man/" DESTINATION man)
- set(qt_plugin_term "PLUGIN")
+ #set(qt_plugin_term "PLUGIN")
endif()

if(WIN32)
set(CPACK_NSIS_MODIFY_PATH 1)
- set(qt_plugin_term "LIBRARY")
+ #set(qt_plugin_term "LIBRARY")

# Set RAYPATH on install
set(CPACK_NSIS_EXTRA_INSTALL_COMMANDS
@@ -116,10 +116,10 @@
include(CPack)

if(NOT BUILD_HEADLESS)
- find_package(Qt5Widgets)
- get_target_property(QT_LIBRARY_DIR Qt5::Core LOCATION)
- get_filename_component(QT_LIBRARY_DIR ${QT_LIBRARY_DIR} PATH)
- get_filename_component(QT_LIBRARY_DIR "${QT_LIBRARY_DIR}/.." ABSOLUTE)
+ # find_package(Qt5Widgets)
+ #get_target_property(QT_LIBRARY_DIR Qt5::Core LOCATION)
+ #get_filename_component(QT_LIBRARY_DIR ${QT_LIBRARY_DIR} PATH)
+ #get_filename_component(QT_LIBRARY_DIR "${QT_LIBRARY_DIR}/.." ABSOLUTE)
find_package(X11)
if(APPLE)
include_directories(${X11_INCLUDE_DIR})
@@ -145,7 +145,7 @@

set(test_dir "${CMAKE_CURRENT_SOURCE_DIR}/test/test data")

-add_subdirectory(resources)
+#add_subdirectory(resources)

install(DIRECTORY "${CMAKE_BINARY_DIR}/lib/"
DESTINATION "lib"
26 changes: 26 additions & 0 deletions srcpkgs/radiance/patches/002-rem_qt5deps.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
--- /InstallRules/CMakeLists.txt
+++ /InstallRules/CMakeLists.txt
@@ -16,6 +16,9 @@

if(NOT BUILD_HEADLESS)
#plugins loaded by rvu at runtime
+
+
+ if(WIN32)
get_target_property(GIF_PLUGIN Qt5::QGifPlugin LOCATION)
get_target_property(ICO_PLUGIN Qt5::QICOPlugin LOCATION)
get_target_property(JPEG_PLUGIN Qt5::QJpegPlugin LOCATION)
@@ -25,12 +28,11 @@
get_filename_component(JPEG_PLUGIN_NAME "${JPEG_PLUGIN}" NAME)
get_filename_component(TIFF_PLUGIN_NAME "${TIFF_PLUGIN}" NAME)

- if(WIN32)
get_target_property(QPA_PLUGIN Qt5::QWindowsIntegrationPlugin LOCATION)
elseif(APPLE)
get_target_property(QPA_PLUGIN Qt5::QCocoaIntegrationPlugin LOCATION)
elseif(UNIX)
- get_target_property(QPA_PLUGIN Qt5::QXcbIntegrationPlugin LOCATION)
+ # get_target_property(QPA_PLUGIN Qt5::QXcbIntegrationPlugin LOCATION)
endif()
get_filename_component(QPA_PLUGIN_NAME "${QPA_PLUGIN}" NAME)

53 changes: 53 additions & 0 deletions srcpkgs/radiance/patches/003-rem_qt5deps.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
--- /src/rt/CMakeLists.txt
+++ /src/rt/CMakeLists.txt
@@ -147,27 +147,28 @@
)

#install qt.conf & Qt plugins loaded by rvu at runtime. Ignore if we are building as headless
-if(NOT BUILD_HEADLESS)
- get_target_property(GIF_PLUGIN Qt5::QGifPlugin LOCATION)
- get_target_property(ICO_PLUGIN Qt5::QICOPlugin LOCATION)
- get_target_property(JPEG_PLUGIN Qt5::QJpegPlugin LOCATION)
- get_target_property(TIFF_PLUGIN Qt5::QTiffPlugin LOCATION)
- install(PROGRAMS "${GIF_PLUGIN}" "${ICO_PLUGIN}" "${JPEG_PLUGIN}" "${TIFF_PLUGIN}"
- DESTINATION "bin/plugins/imageformats"
- )
- install(FILES "${CMAKE_SOURCE_DIR}/InstallRules/qt.conf"
- DESTINATION "bin"
- )
+#if(NOT BUILD_HEADLESS)
+ # if(WIN32)

- if(WIN32)
- get_target_property(QPA_PLUGIN Qt5::QWindowsIntegrationPlugin LOCATION)
- elseif(APPLE)
- get_target_property(QPA_PLUGIN Qt5::QCocoaIntegrationPlugin LOCATION)
- elseif(UNIX)
- get_target_property(QPA_PLUGIN Qt5::QXcbIntegrationPlugin LOCATION)
- endif()
+ # get_target_property(GIF_PLUGIN Qt5::QGifPlugin LOCATION)
+ #get_target_property(ICO_PLUGIN Qt5::QICOPlugin LOCATION)
+ #get_target_property(JPEG_PLUGIN Qt5::QJpegPlugin LOCATION)
+ #get_target_property(TIFF_PLUGIN Qt5::QTiffPlugin LOCATION)
+ #install(PROGRAMS "${GIF_PLUGIN}" "${ICO_PLUGIN}" "${JPEG_PLUGIN}" "${TIFF_PLUGIN}"
+ # DESTINATION "bin/plugins/imageformats"
+ #)
+ #install(FILES "${CMAKE_SOURCE_DIR}/InstallRules/qt.conf"
+ # DESTINATION "bin"
+ #)

- install(PROGRAMS "${QPA_PLUGIN}"
- DESTINATION "bin/plugins/platforms"
- )
-endif()
+ # get_target_property(QPA_PLUGIN Qt5::QWindowsIntegrationPlugin LOCATION)
+ # elseif(APPLE)
+ # get_target_property(QPA_PLUGIN Qt5::QCocoaIntegrationPlugin LOCATION)
+ # elseif(UNIX)
+ # get_target_property(QPA_PLUGIN Qt5::QXcbIntegrationPlugin LOCATION)
+ #endif()
+
+ # install(PROGRAMS "${QPA_PLUGIN}"
+ # DESTINATION "bin/plugins/platforms"
+ # )
+#endif()
24 changes: 24 additions & 0 deletions srcpkgs/radiance/patches/004-rem_qt5deps.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
--- /InstallRules/dependencies.cmake.in
+++ /InstallRules/dependencies.cmake.in
@@ -2,13 +2,13 @@
set(path "@executable_path" PARENT_SCOPE)
endfunction()

-include(BundleUtilities)
+#include(BundleUtilities)

-set(plugins "")
-list(APPEND plugins "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/plugins/imageformats/@GIF_PLUGIN_NAME@")
-list(APPEND plugins "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/plugins/imageformats/@ICO_PLUGIN_NAME@")
-list(APPEND plugins "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/plugins/imageformats/@JPEG_PLUGIN_NAME@")
-list(APPEND plugins "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/plugins/imageformats/@TIFF_PLUGIN_NAME@")
-list(APPEND plugins "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/plugins/platforms/@QPA_PLUGIN_NAME@")
+#set(plugins "")
+#list(APPEND plugins "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/plugins/imageformats/@GIF_PLUGIN_NAME@")
+#list(APPEND plugins "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/plugins/imageformats/@ICO_PLUGIN_NAME@")
+#list(APPEND plugins "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/plugins/imageformats/@JPEG_PLUGIN_NAME@")
+#list(APPEND plugins "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/plugins/imageformats/@TIFF_PLUGIN_NAME@")
+#list(APPEND plugins "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/plugins/platforms/@QPA_PLUGIN_NAME@")

-fixup_bundle("${CMAKE_INSTALL_PREFIX}/bin/rvu@CMAKE_EXECUTABLE_SUFFIX@" "${plugins}" "@QT_LIBRARY_DIR@;@X11_LIBRARY_DIR@")
+#fixup_bundle("${CMAKE_INSTALL_PREFIX}/bin/rvu@CMAKE_EXECUTABLE_SUFFIX@" "${plugins}" "@QT_LIBRARY_DIR@;@X11_LIBRARY_DIR@")
33 changes: 33 additions & 0 deletions srcpkgs/radiance/template
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Template file for 'radiance'
pkgname=radiance
version=5.2
revision=1
#archs="i686 x86_64"
wrksrc=Radiance-5.2
#create_wrksrc=yes
build_style=cmake
configure_args="
-DOpenGL_GL_PREFERENCE=GLVND
-DCMAKE_EXE_LINKER_FLAGS_RELEASE=-lGLU
"
patch_args="-Np1"
#make_build_args=""
#make_install_args=""
#conf_files=""
#make_dirs="/var/log/dir 0755 root root"
hostmakedepends=""
makedepends="tiff-devel slurm libglvnd-devel freetype-devel fontconfig-devel glu-devel"
depends="tiff freetype fontconfig glu"
short_desc="Radiance is a suite of programs for the analysis and visualization of lighting in design."
maintainer="Sander Boer <sanderboer@mauc.nl>"
license="Radiance Software License, Version 1.0"
homepage="https://www.radiance-online.org"

distfiles="https://github.com/NREL/Radiance/archive/5.2.tar.gz"
checksum=1a962d19680e9146f0d6d79e60fb81d6850b7aca83b4e238dc176cac873049c2

post_install(){
echo "export RAYPATH=.:/usr/lib" > /etc/profile.d/radiance.sh
mkdir ${DESTDIR}/usr/share
mv ${DESTDIR}/usr/man ${DESTDIR}/usr/share/man
}