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
Linux install? #1
Comments
Hi Antoine, From this source code repository, you can build Daysim for Linux. I recommend using CMake. The program rtrace_dc is currently not built automatically. To create it, you need to set the DAYSIM flag in CMake, build rtrace, and then rename the rtrace program to rtrace_dc. Nathaniel |
PS: I also moved a bunch of lib files from my windows distributions of radiance and daysim into this docker image as I couldn't find them when installing from this repo + "apt-get install radiance". |
The error you received in your make command is from not having libtiff. There are instructions on the main page for buiding libtiff for Windows, and I imagine that you could do something similar for Linux, but the resulting programs (pabop2xyz and ra_tiff) are not critical to Daysim. You need to set the DAYSIM flag in CMake to avoid the error you got in your test. Basically, rtrace and rtrace_dc are two separate programs that share significant overlap in source code. Setting the DAYSIM flag switches the build process from one to the other. Currently this is not automated, and the default is to build rtrace, not rtrace_dc. Nathaniel |
I'm really sorry to drag this on further than it needs to be but I'm not super familiar with cmake. My understanding is that I need to set the DAYSIM flag when creating the Daysim project. Is this done by adding some lines to the CMakeLists.txt file or rather by passing a command when running "cmake" in bash? |
Either is possible. In CMakeLists.txt, you can add Note that this only applies to compiling rtrace_dc. For all other programs, this will either have no effect or create junk. |
Hey guys, did you get it work? I have just been interested in the project, |
diff.txt I compiled Daysim on a kubuntu 16.04 server, to generate the makefiles I used ccmake. I put the source in directory "Daysim", I create directory "build", then in build (cd build ) I issued the command ccmake ../Daysim. This opens an ncurses interfaces. check that the "BUILD_HEADLESS" option is "ON", then configure with key "c", generate Makefiles with key "g". Then you can build Daysim with "make". I hope this helps |
Some of these changes have been made in the latest commit. Make sure that you are compiling from the "combined" branch. |
dear nljones, I apologize. I applied commits, but now I have a problem with cmake command "install_without_extension" in src/daysim. I replaced it replicating the install command for WIN32 above. |
Can you show the specific errors you receive when you run CMake? I'm not able to find "install_without_extension" in src/daysim, and c++11 hasn't generally been needed for Radiance. |
the problems are linux specific, if you compile in windows no patch is required, c++11 is required when compiling climateFile.cpp line 246 " auto res = m_ptIdh[pointer] + diff*ratio;" g++ ( I'm using gcc version 5.4.0 ) requires the option to compile the "auto" keyword. |
The CMake command "install_without_extension" is part of the Radiance distribution. Please bring up this issue with them. |
macro "install_without_extension" is a macro defined inside radiance tree inside src/CMakefile.txt macro(install_without_extension) adding the macro to src/CMakeLists.txt solves the problem |
The latest commit includes the new Radiance CMake files. Note that "master" is now the main branch of Daysim. The "combined" branch will no longer be updated. |
Hi @MarcoManzan I wonder if you can give us an overview of the steps you undertook to get Daysim running in your Ubuntu. I assume we can use the master branch for this. I much appreciate it!. |
install ccmake edit CMakelist.txt end add somewere the following line change directory and create a build directory run ccmake configure the project by typing "c". Some errors are issued, press "e" to exit daysim executables are not installed in destination directory, to install uncomment the last line of the fie ../Daysim/src/daysim/CMakeLists.txt |
To amend @MarcoManzan's instructions, use add_definitions(-DDAYSIM) only to compile rtrace_dc. This definition may break other programs. A better solution is to use target_compile_definitions instead. Also, if you follow the directions, rtrace_dc should be created in $HOME/build/bin, not $HOME/Daysim/bin. It is generally not recommended to place the bin directory within the git project directory. |
I added the line |
Thanks for the clarification. I suspect the target_compile_definitions with -DDAYSIM would also need to be applied to the rtrace_dc target, and of course building the radiance library with -DDAYSIM would only apply to rtrace_dc, not to other uses of the radiance library. Radiance wasn't really designed to support this kind of customization (part of the reason why compiling rtrace_dc remains a manual process). |
At the moment I see only a solution: building daysim in two steps: |
Thank you very much @MarcoManzan and @nljones . |
Hi, I'm interested in running daysim on linux for the purposes of putting it in a docker container. Very happy to contribute set up and image once done but was wondering how I should go about installing Daysim for linux (ubuntu preferably)? I've seen the question asked on forums and have seen some discussions about using linux to run some parametric studies but not seen any information concerning how to go about this. Any help much appreciated!
Antoine
The text was updated successfully, but these errors were encountered: