Building on Debian x64

Discussion and help for Compilation problems and platform portability.

Moderator: coordinators

Building on Debian x64

Postby Varyag » Thu Feb 03, 2011 8:55 am

1) Compile Boost 1.43.
2) Install OpenCL (Nvidia current Dev_driver and Cuda)
3) Install dependencies.
4) Compile luxrays from src.luxrender.net/luxrays. "make" returns error on strings 72 and 74.
Code: Select all
/build/luxrays/src/idevices/openclidevice.cpp: In function ‘std::string oclErrorString(cl_int)’:                                           
/build/luxrays/src/idevices/openclidevice.cpp:72: error: ‘CL_MISALIGNED_SUB_BUFFER_OFFSET’ was not declared in this scope
/build/luxrays/src/idevices/openclidevice.cpp:74: error: ‘CL_EXEC_STATUS_ERROR_FOR_EVENTS_IN_WAIT_LIST’ was not declared in this scope
Just removed strings from #71 to #76 to make it OK. Is it correct enough?
5) Compile Luxrender and pylux (with python3.1) from current sources.
6) Copy compiled pylux.so and "src/luxrender" folder from luxblend25 package to Blender 2.56beta (compiled from svn) addons folder.
7) Turn on luxrender addon in Blender and render a scene. (Luxblend25 newer than changeset #628 'b228506f0968' exports nothing. Can only work with builds #627 and earlier)
Here is the errorcode which appears at Blender "info" panel, when exporting a scene with new luxblend25:
Code: Select all
Traceback (most recent call last):
  File "/usr/share/blender-beta/2.56/scripts/addons/luxrender/core/__init__.py", line 360, in render
    if self.render_scene(scene) == False:
  File "/usr/share/blender-beta/2.56/scripts/addons/luxrender/core/__init__.py", line 554, in render_scene
    export_result = scene_exporter.export()
  File "/usr/share/blender-beta/2.56/scripts/addons/luxrender/export/scene.py", line 152, in export
    lux_context.surfaceIntegrator(   *scene.luxrender_integrator.api_output(scene.luxrender_engine)   )
  File "/usr/share/blender-beta/2.56/scripts/addons/luxrender/properties/integrator.py", line 689, in api_output
    self.advanced = True
RuntimeError: Writing to ID classes in this context is not allowed: Scene, Scene datablock, error setting luxrender_integrator.advanced


Intel Core2 3.2GHz, NVidia 250 GTS, 4Gb RAM, GCC 4.4.5
User avatar
Varyag
 
Posts: 23
Joined: Mon Jan 24, 2011 7:20 am
Location: Russia

Re: Building on Debian x64

Postby Dade » Fri Feb 04, 2011 3:43 am

Varyag wrote:4) Compile luxrays from src.luxrender.net/luxrays. "make" returns error on strings 72 and 74.
Code: Select all
/build/luxrays/src/idevices/openclidevice.cpp: In function ‘std::string oclErrorString(cl_int)’:                                           
/build/luxrays/src/idevices/openclidevice.cpp:72: error: ‘CL_MISALIGNED_SUB_BUFFER_OFFSET’ was not declared in this scope
/build/luxrays/src/idevices/openclidevice.cpp:74: error: ‘CL_EXEC_STATUS_ERROR_FOR_EVENTS_IN_WAIT_LIST’ was not declared in this scope
Just removed strings from #71 to #76 to make it OK. Is it correct enough?


The real correct fix should be to replace the "#ifndef __APPLE__" with a "#ifdef CL_VERSION_1_1" (because NVIDIA and Apple OpenCL are still 1.0-only). Anyway, just removing the lines will do the job for you.
User avatar
Dade
Developer
 
Posts: 4794
Joined: Sat Apr 19, 2008 6:04 pm
Location: Italy

Re: Building on Debian x64

Postby Varyag » Fri Feb 04, 2011 6:11 am

Thanks for the answer, my thoughts was on the same way. And thank you for adding your fix to the source :)
User avatar
Varyag
 
Posts: 23
Joined: Mon Jan 24, 2011 7:20 am
Location: Russia

Re: Building on Debian x64

Postby Varyag » Sat Feb 05, 2011 1:26 am

7) Turn on luxrender addon in Blender and render a scene. (Luxblend25 newer than changeset #628 'b228506f0968' exports nothing. Can only work with builds #627 and earlier)

Updating Blender from Blender svn solve the problem, but not complete. Now the new versions of luxblend25 work, so not the old. In the new version of luxblend export in hybrid mode returns the same error, but not always. Sampler mode works perfectly.
Last edited by Varyag on Mon Feb 07, 2011 4:58 am, edited 1 time in total.
User avatar
Varyag
 
Posts: 23
Joined: Mon Jan 24, 2011 7:20 am
Location: Russia

Re: Building on Debian x64

Postby Varyag » Sun Feb 06, 2011 7:08 am

Seems like problem completely solved. I didn't check "Advanced" checkbox in "Surface Integrator" settings, so I couldn't see Light strategy option.
Now I found the "secret spaces" =)) My fault, the program works.
May be it worth to make "Surface integrator - Advanced" option checked permanently in hybrid mode?

Export from Blender to slg is OK.
SmallLuxGPU crashes in mode (3) path tracing GPU rendering. All other features are OK.

Starting slg from terminal returns error
Code: Select all
#bin/slg -f /build/luxrays/samples/luxmark/scenes/luxball/luxball.scn
Usage: bin/slg [options] [configuration file]
-o [configuration file]
-f [scene file]
-w [window width]
-e [window height]
-g <disable OpenCL GPU device>
-p <enable OpenCL CPU device>
-n [native thread count]
-r [gpu thread count]
-l [set high/low latency mode]
-b <enable high latency mode>
-s [GPU workgroup size]
-t [halt time in secs]
-T <enable the telnet server>
-D [property name] [property value]
-d [current directory path]
-h <display this help and exit>
Reading configuration file: scenes/luxball/render-fast.cfg
Configuration:
  batch.halttime = 0
  film.gamma = 2.2
  image.height = 480
  image.width = 640
  opencl.cpu.use = 0
  opencl.gpu.use = 1
  opencl.gpu.workgroup.size = 64
  opencl.latency.mode = 1
  opencl.nativethread.count = 2
  opencl.platform.index = 0
  path.maxdepth = 6
  path.russianroulette.depth = 5
  path.russianroulette.prob = 0.75
  path.shadowrays = 1
  scene.fieldofview = 45
  scene.file = scenes/luxball/luxball.scn
  screen.refresh.interval = 100
No protocol specified
freeglut (bin/slg): failed to open display ':0'
Last edited by Varyag on Sun Feb 06, 2011 6:28 pm, edited 1 time in total.
User avatar
Varyag
 
Posts: 23
Joined: Mon Jan 24, 2011 7:20 am
Location: Russia

Re: Building on Debian x64

Postby Dade » Mon Feb 07, 2011 3:35 am

Varyag wrote:SmallLuxGPU crashes in mode (3) path tracing GPU rendering. All other features are OK.


NVIDIA or ATI ? If NVIDIA, be sure to use the latest drivers, if ATI, use low latency mode because their SDK 2.3 compiler crashes otherwise.
User avatar
Dade
Developer
 
Posts: 4794
Joined: Sat Apr 19, 2008 6:04 pm
Location: Italy

Re: Building on Debian x64

Postby Varyag » Mon Feb 07, 2011 4:50 am

NVIDIA, latest drivers with openCL support - developer drivers for Linux 260.19.26.
User avatar
Varyag
 
Posts: 23
Joined: Mon Jan 24, 2011 7:20 am
Location: Russia

Re: Building on Debian x64

Postby Dade » Mon Feb 07, 2011 6:05 am

Varyag wrote:NVIDIA, latest drivers with openCL support - developer drivers for Linux 260.19.26.


260.x is known to have a bugged OpenCL driver. SLG works fine with 266.58 under Windows. You may want to try the 270.18 beta (it seems the only version newer than 260.19.26 available for Linux).
User avatar
Dade
Developer
 
Posts: 4794
Joined: Sat Apr 19, 2008 6:04 pm
Location: Italy

Re: Building on Debian x64

Postby Varyag » Mon Feb 07, 2011 6:55 am

270.18 beta is available, but i'm not sure that it contains openCL driver. I'll try.

Update: with 270.18 beta NVidia drivers and previous openCL module it works, but more than 10 times slower than in CPU+GPU mode, and, even more, it kills OpenGL desktop effects for current X-server session =)
So, I think I have no need to use this option (at least until NVidia will make a suitable driver).

Problem with command-line slg executing, noted 4 posts above, was caused by starting slg from root. From user it starts normally.
Last edited by Varyag on Thu Mar 31, 2011 6:03 pm, edited 3 times in total.
User avatar
Varyag
 
Posts: 23
Joined: Mon Jan 24, 2011 7:20 am
Location: Russia

Re: Building on Debian x64

Postby Varyag » Wed Feb 09, 2011 2:06 am

And (may be it's for another topic) I prefer to use Luxrender-logo icon Image in render tab instead of "toxic" sign.
It looks to me more appropriate.
Image
User avatar
Varyag
 
Posts: 23
Joined: Mon Jan 24, 2011 7:20 am
Location: Russia

Next

Return to Compilation & Portability

Who is online

Users browsing this forum: No registered users and 0 guests