~ubuntu-branches/ubuntu/trusty/blender/trusty

« back to all changes in this revision

Viewing changes to intern/cycles/kernel/SConscript

  • Committer: Package Import Robot
  • Author(s): Jeremy Bicha
  • Date: 2013-03-06 12:08:47 UTC
  • mfrom: (1.5.1) (14.1.8 experimental)
  • Revision ID: package-import@ubuntu.com-20130306120847-frjfaryb2zrotwcg
Tags: 2.66a-1ubuntu1
* Resynchronize with Debian (LP: #1076930, #1089256, #1052743, #999024,
  #1122888, #1147084)
* debian/control:
  - Lower build-depends on libavcodec-dev since we're not
    doing the libav9 transition in Ubuntu yet

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/usr/bin/python
 
1
#!/usr/bin/env python
 
2
#
 
3
# ***** BEGIN GPL LICENSE BLOCK *****
 
4
#
 
5
# This program is free software; you can redistribute it and/or
 
6
# modify it under the terms of the GNU General Public License
 
7
# as published by the Free Software Foundation; either version 2
 
8
# of the License, or (at your option) any later version.
 
9
#
 
10
# This program is distributed in the hope that it will be useful,
 
11
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
12
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
13
# GNU General Public License for more details.
 
14
#
 
15
# You should have received a copy of the GNU General Public License
 
16
# along with this program; if not, write to the Free Software Foundation,
 
17
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
 
18
#
 
19
# The Original Code is Copyright (C) 2011, Blender Foundation
 
20
# All rights reserved.
 
21
#
 
22
# The Original Code is: all of this file.
 
23
#
 
24
# Contributor(s): Nathan Letwory.
 
25
#
 
26
# ***** END GPL LICENSE BLOCK *****
 
27
 
2
28
import sys
3
29
import os
4
30
import Blender as B
32
58
    kernel_file = os.path.join(source_dir, "kernel.cu")
33
59
    util_dir = os.path.join(source_dir, "../util")
34
60
    svm_dir = os.path.join(source_dir, "../svm")
 
61
    closure_dir = os.path.join(source_dir, "../closure")
35
62
 
36
63
    # nvcc flags
37
64
    nvcc_flags = "-m%s" % (bits)
38
 
    nvcc_flags += " --cubin -use_fast_math --ptxas-options=\"-v\" --maxrregcount=24"
 
65
    nvcc_flags += " --cubin --ptxas-options=\"-v\" --maxrregcount=24"
39
66
    nvcc_flags += " --opencc-options -OPT:Olimit=0"
40
67
    nvcc_flags += " -DCCL_NAMESPACE_BEGIN= -DCCL_NAMESPACE_END= -DNVCC"
41
 
    nvcc_flags += " -I \"%s\" -I \"%s\"" % (util_dir, svm_dir)
 
68
    nvcc_flags += " -I \"%s\" -I \"%s\" -I \"%s\"" % (util_dir, svm_dir, closure_dir)
42
69
 
43
70
    # dependencies
44
 
    dependencies = ['kernel.cu'] + kernel.Glob('*.h') + kernel.Glob('../util/*.h') + kernel.Glob('svm/*.h')
 
71
    dependencies = ['kernel.cu'] + kernel.Glob('*.h') + kernel.Glob('../util/*.h') + kernel.Glob('svm/*.h') + kernel.Glob('closure/*.h')
45
72
    last_cubin_file = None
46
73
 
47
74
    # add command for each cuda architecture