/[Slicer3]/oldtrunk/slicer_variables.tcl
ViewVC logotype

Annotation of /oldtrunk/slicer_variables.tcl

Parent Directory Parent Directory | Revision Log Revision Log


Revision 11010 - (hide annotations) (download) (as text)
Fri Nov 20 12:31:12 2009 UTC (7 years, 10 months ago) by pieper
Original Path: trunk/slicer_variables.tcl
File MIME type: application/x-tcl
File size: 26108 byte(s)
COMP: apply path info supplied by Andras Lasso
1 pieper 376
2     #
3     # Note: this local vars file overrides sets the default environment for :
4     # Scripts/genlib.tcl -- make all the support libs
5     # Scripts/cmaker.tcl -- makes slicer code
6     # launch.tcl -- sets up the runtime env and starts slicer
7     # Scripts/tarup.tcl -- makes a tar.gz files with all the support files
8     #
9     # - use this file to set your local environment and then your change won't
10     # be overwritten when those files are updated through CVS
11     #
12    
13    
14     ## variables that are the same for all systems
15 barre 6777 set ::Slicer3_DATA_ROOT ""
16 pieper 376
17 barre 6777 if {[info exists ::env(Slicer3_HOME)]} {
18 pieper 376 # already set by the launcher
19 barre 6777 set ::Slicer3_HOME $::env(Slicer3_HOME)
20 pieper 376 } else {
21 barre 6777 # if sourcing this into cmaker, Slicer3_HOME may not be set
22     # set the Slicer3_HOME directory to the one in which this script resides
23 pieper 376 set cwd [pwd]
24     cd [file dirname [info script]]
25 barre 6777 set ::Slicer3_HOME [pwd]
26     set ::env(Slicer3_HOME) $::Slicer3_HOME
27 pieper 376 cd $cwd
28     }
29    
30     # set up variables for the OS Builds, to facilitate the move to solaris9
31     # - solaris can be solaris8 or solaris9
32 pieper 435 set ::SOLARIS "solaris8"
33     set ::LINUX "linux-x86"
34     set ::LINUX_64 "linux-x86_64"
35     set ::DARWIN "darwin-ppc"
36 naucoin 2494 set ::DARWIN_X86 "darwin-x86"
37 pieper 435 set ::WINDOWS "win32"
38    
39 pieper 376 #
40     # set the default locations for the main components
41     #
42     switch $::tcl_platform(os) {
43 pieper 435 "SunOS" { set ::env(BUILD) $::SOLARIS }
44 pieper 376 "Linux" {
45     if {$::tcl_platform(machine) == "x86_64"} {
46 pieper 435 set ::env(BUILD) $::LINUX_64
47 pieper 376 } else {
48 pieper 435 set ::env(BUILD) $::LINUX
49 pieper 376 }
50     }
51 naucoin 2494 "Darwin" {
52 lauren 2510 if {$::tcl_platform(machine) == "i386"} {
53 naucoin 2494 set ::env(BUILD) $::DARWIN_X86
54     } else {
55     set ::env(BUILD) $::DARWIN
56     }
57     }
58 pieper 376 default {
59 pieper 435 set ::env(BUILD) $::WINDOWS
60 barre 6777 set ::Slicer3_HOME [file attributes $::Slicer3_HOME -shortname]
61     set ::env(Slicer3_HOME) $::Slicer3_HOME
62 pieper 376 }
63     }
64    
65 pieper 8971 puts "Slicer3_HOME is $::Slicer3_HOME"
66 pieper 376
67     # Choose which library versions you want to compile against. These
68     # shouldn't be changed between releases except for testing purposes.
69     # If you change them and Slicer breaks, you get to keep both pieces.
70     #
71     # When modifying these variables, make sure to make appropriate
72     # changes in the "Files to test if library has already been built"
73     # section below, or genlib will happily build the library again.
74    
75 pieper 10863 set ::Slicer3_TAG "http://svn.slicer.org/Slicer3/trunk"
76 partyd 10950 set ::CMAKE_TAG "CMake-2-8-0"
77 pieper 8506 set ::Teem_TAG http://teem.svn.sourceforge.net/svnroot/teem/teem/tags/1.10.0
78 pieper 8631 set ::KWWidgets_TAG "Slicer-3-4"
79 naucoin 10227 set ::VTK_TAG "VTK-5-4"
80 fedorov 10689 set ::ITK_TAG ITK-3-16
81 hjohnson 10422 set ::PYTHON_TAG "http://svn.python.org/projects/python/branches/release26-maint"
82 pieper 7537 set ::BLAS_TAG http://svn.slicer.org/Slicer3-lib-mirrors/trunk/netlib/BLAS
83     set ::LAPACK_TAG http://svn.slicer.org/Slicer3-lib-mirrors/trunk/netlib/lapack-3.1.1
84 hjohnson 10422 set ::NUMPY_TAG "http://svn.scipy.org/svn/numpy/branches/1.3.x"
85 pieper 8881 set ::SCIPY_TAG "http://svn.scipy.org/svn/scipy/branches/0.7.x"
86 pieper 10443 #set ::BatchMake_TAG "BatchMake-1-2"
87 hjohnson 10422 set ::BatchMake_TAG "HEAD"
88 naucoin 6040 set ::SLICERLIBCURL_TAG "HEAD"
89 tokuda 8495 set ::OpenIGTLink_TAG "http://svn.na-mic.org/NAMICSandBox/branches/OpenIGTLink-1-0"
90 hliu 10539 #set ::OpenCV_TAG "http://sourceforge.net/projects/opencvlibrary/files/opencv-linux/1.0/opencv-1.0.0.tar.gz/download"
91     set ::OpenCV_TAG "http://sourceforge.net/projects/opencvlibrary/files/opencv-unix/1.0/opencv-1.0.0.tar.gz/download"
92 pieper 9316
93 pieper 7489 # set TCL_VERSION to "tcl" to get 8.4, otherwise use tcl85 get 8.5
94 pieper 9316 # set 8.5 for Solaris explicitly, because 8.4 complains
95     # when built 64 bit with gcc. Suncc/CC is fine, however.
96 pieper 10692 if {$tcl_platform(os) == "SunOS"} {
97     set ::TCL_VERSION tcl85
98     set ::TCL_MINOR_VERSION 5
99     } else {
100     set ::TCL_VERSION tcl
101     set ::TCL_MINOR_VERSION 4
102     }
103 pieper 376
104     # Set library, binary, etc. paths...
105    
106 davisb 7539 # if Slicer3_LIB and Slicer3_BUILD haven't been set, first check
107     # enviornment variables, then assume they are in the 'standard' places
108     # next to the source tree (as created by getbuildtest.tcl
109 barre 6777 if { ![info exists ::Slicer3_LIB] } {
110 davisb 7539 if { [info exists ::env(Slicer3_LIB)] } {
111     set ::Slicer3_LIB $::env(Slicer3_LIB)
112     } else {
113     set wd [pwd]
114     cd $::Slicer3_HOME/../Slicer3-lib
115     set ::Slicer3_LIB [pwd]
116     cd $wd
117     }
118 pieper 433 }
119 barre 6777 if { ![info exists ::Slicer3_BUILD] } {
120 davisb 7539 if { [info exists ::env(Slicer3_BUILD)] } {
121 davisb 7540 set ::Slicer3_BUILD $::env(Slicer3_BUILD)
122 davisb 7539 } else {
123     set wd [pwd]
124     cd $::Slicer3_HOME/../Slicer3-build
125     set ::Slicer3_BUILD [pwd]
126     cd $wd
127     }
128 pieper 433 }
129    
130 pieper 7799 set ::Teem_SRC_DIR $::Slicer3_LIB/teem
131     set ::Teem_BUILD_DIR $::Slicer3_LIB/teem-build
132 barre 6777 set ::VTK_DIR $::Slicer3_LIB/VTK-build
133     set ::VTK_SRC_DIR $::Slicer3_LIB/VTK
134 pieper 5199 if { ![info exists ::VTK_BUILD_TYPE] } {
135     # set a default if it hasn't already been specified
136     set ::VTK_BUILD_TYPE "Debug" ;# options: Release, RelWithDebInfo, Debug
137     }
138     set ::VTK_BUILD_SUBDIR $::VTK_BUILD_TYPE
139 pieper 376 set ::env(VTK_BUILD_TYPE) $::VTK_BUILD_TYPE
140 barre 6777 set ::KWWidgets_BUILD_DIR $::Slicer3_LIB/KWWidgets-build
141     set ::KWWIDGETS_DIR $::Slicer3_LIB/KWWidgets
142     set ::ITK_BINARY_PATH $::Slicer3_LIB/Insight-build
143     set ::TCL_BIN_DIR $::Slicer3_LIB/tcl-build/bin
144     set ::TCL_LIB_DIR $::Slicer3_LIB/tcl-build/lib
145     set ::TCL_INCLUDE_DIR $::Slicer3_LIB/tcl-build/include
146 blezek 6869 set ::PYTHON_BIN_DIR $::Slicer3_LIB/python-build
147 barre 6777 set ::CMAKE_PATH $::Slicer3_LIB/CMake-build
148 pieper 376 set ::SOV_BINARY_DIR ""
149     set ::XVNC_EXECUTABLE " "
150 hliu 7835 set ::OpenIGTLink_DIR $::Slicer3_LIB/OpenIGTLink-build
151 hliu 10000 set ::OpenCV_DIR $::Slicer3_LIB/OpenCV-build
152 pieper 8442 set ::BatchMake_SRC_DIR $::Slicer3_LIB/BatchMake
153     set ::BatchMake_BUILD_DIR $::Slicer3_LIB/BatchMake-build
154 barre 6777 set ::SLICERLIBCURL_SRC_DIR $::Slicer3_LIB/cmcurl
155     set ::SLICERLIBCURL_BUILD_DIR $::Slicer3_LIB/cmcurl-build
156 pieper 376
157    
158 pieper 7911 # getbuildtest Option for build using system Python, should be "true" or "false"
159 blezek 7453 set ::USE_SYSTEM_PYTHON "false"
160 pieper 8632 # CMake option for Python, must be "OFF" on "ON", default is "ON"
161 alexy 10624 set ::USE_PYTHON "ON"
162 pieper 8625
163 pieper 7556 # CMake option for numerical Python, only matters if Python is on
164 alexy 10624 set ::USE_NUMPY "ON"
165 pieper 7911 # getbuildtest option for SCIPY - also build support libraries (blas and lapack) needed for scipy
166     # - should be off except for experimentation (does not work on all plaftorms - requires fortran)
167     # - should be "true" or "false"
168     set ::USE_SCIPY "false"
169 hliu 7835 # CMake Option for using OpenIGTLink library. Must be "OFF" or "ON", default is "OFF"
170 hliu 8069 set ::USE_OPENIGTLINK "ON"
171 hliu 10000 # CMake Option for using OpenCV library. Must be "OFF" or "ON", default is "OFF"
172 hliu 10295 set ::USE_OPENCV "OFF"
173 hliu 7835
174 pieper 376 switch $::tcl_platform(os) {
175 pieper 7336 "SunOS" {
176     set shared_lib_ext "so"
177     }
178 pieper 376 "Linux" {
179     set shared_lib_ext "so"
180     }
181     "Darwin" {
182     set shared_lib_ext "dylib"
183     }
184     "Windows NT" {
185     set shared_lib_ext "dll"
186     }
187     }
188    
189     # TODO: identify files for each platform
190    
191     switch $::tcl_platform(os) {
192 pieper 7336 "SunOS" {
193     set ::VTK_BUILD_SUBDIR ""
194 pieper 7799 set ::Teem_BIN_DIR $::Teem_BUILD_DIR/bin
195 pieper 7336
196     set ::INCR_TCL_LIB $::TCL_LIB_DIR/lib/libitcl3.2.so
197     set ::INCR_TK_LIB $::TCL_LIB_DIR/lib/libitk3.2.so
198    
199 pieper 9316 set ::TCL_TEST_FILE $::TCL_BIN_DIR/tclsh8.5
200 pieper 7447 if { $::USE_SYSTEM_PYTHON } {
201     error "need to define system python path for $::tcl_platform(os)"
202     }
203 pieper 7336 set ::PYTHON_TEST_FILE $::PYTHON_BIN_DIR/bin/python
204 hjohnson 10422 set ::PYTHON_LIB $::PYTHON_BIN_DIR/lib/libpython2.6.so
205     set ::PYTHON_INCLUDE $::PYTHON_BIN_DIR/include/python2.6
206 pieper 7537 set ::NETLIB_TEST_FILE $::Slicer3_LIB/netlib-build/BLAS-build/libblas.a
207 hjohnson 10422 set ::NUMPY_TEST_FILE $::PYTHON_BIN_DIR/lib/python2.6/site-packages/numpy/core/numeric.pyc
208     set ::SCIPY_TEST_FILE $::PYTHON_BIN_DIR/lib/python2.6/site-packages/scipy/version.pyc
209 pieper 9316 set ::TK_TEST_FILE $::TCL_BIN_DIR/wish8.5
210     set ::ITCL_TEST_FILE $::TCL_LIB_DIR/itcl3.4/libitcl3.4.so
211 pieper 7799 set ::Teem_TEST_FILE $::Teem_BIN_DIR/unu
212 pieper 7336 set ::VTK_TEST_FILE $::VTK_DIR/bin/vtk
213     set ::KWWidgets_TEST_FILE $::KWWidgets_BUILD_DIR/bin/libKWWidgets.so
214 pieper 10163 set ::OpenCV_TEST_FILE $::OpenCV_DIR/lib/libcv.so
215 pieper 9316 set ::VTK_TCL_LIB $::TCL_LIB_DIR/libtcl8.5.$shared_lib_ext
216     set ::VTK_TK_LIB $::TCL_LIB_DIR/libtk8.5.$shared_lib_ext
217     set ::VTK_TCLSH $::TCL_BIN_DIR/tclsh8.5
218 pieper 7336 set ::ITK_TEST_FILE $::ITK_BINARY_PATH/bin/libITKCommon.$shared_lib_ext
219     set ::TK_EVENT_PATCH $::Slicer3_HOME/tkEventPatch.diff
220     set ::env(VTK_BUILD_SUBDIR) $::VTK_BUILD_SUBDIR
221 hliu 7835 set ::OPENIGTLINK_TEST_FILE $::OpenIGTLink_DIR/bin/libOpenIGTLink.$shared_lib_ext
222 pieper 8442 set ::BatchMake_TEST_FILE $::BatchMake_BUILD_DIR/bin/BatchMake
223 pieper 7336 set ::SLICERLIBCURL_TEST_FILE $::SLICERLIBCURL_BUILD_DIR/bin/libslicerlibcurl.$shared_lib_ext
224 pieper 9316 set ::IWIDGETS_TEST_FILE $::TCL_LIB_DIR/iwidgets4.0.2/iwidgets.tcl
225     set ::BLT_TEST_FILE $::TCL_BIN_DIR/bltwish30
226 pieper 7489
227     # We need a workaround here, because gcc does not pick up libraries in /lib
228     # on Solaris.
229     # The bug, and it's resolution can be found here:
230     # http://bugs.opensolaris.org/view_bug.do?bug_id=6619485
231     set ::env(LDFLAGS) -L/lib
232 pieper 7336 }
233 pieper 376 "Darwin" {
234 pieper 5261 set ::VTK_BUILD_SUBDIR ""
235 pieper 7799 set ::Teem_BIN_DIR $::Teem_BUILD_DIR/bin
236 pieper 376
237 pieper 10692 set ::TCL_TEST_FILE $::TCL_BIN_DIR/tclsh8.$::TCL_MINOR_VERSION
238     set ::TK_TEST_FILE $::TCL_BIN_DIR/wish8.$::TCL_MINOR_VERSION
239 pieper 6875 set ::INCR_TCL_LIB $::TCL_LIB_DIR/lib/libitcl3.2.dylib
240     set ::INCR_TK_LIB $::TCL_LIB_DIR/lib/libitk3.2.dylib
241 pieper 7447 if { $::USE_SYSTEM_PYTHON } {
242     set ::PYTHON_BIN_DIR /usr
243     }
244 blezek 6869 set ::PYTHON_TEST_FILE $::PYTHON_BIN_DIR/bin/python
245 hjohnson 10422 set ::PYTHON_LIB $::PYTHON_BIN_DIR/lib/libpython2.6.dylib
246     set ::PYTHON_INCLUDE $::PYTHON_BIN_DIR/include/python2.6
247 pieper 7537 set ::NETLIB_TEST_FILE $::Slicer3_LIB/netlib-build/BLAS-build/libblas.a
248 hjohnson 10422 set ::NUMPY_TEST_FILE $::PYTHON_BIN_DIR/lib/python2.6/site-packages/numpy/core/numeric.pyc
249     set ::SCIPY_TEST_FILE $::PYTHON_BIN_DIR/lib/python2.6/site-packages/scipy/version.pyc
250 pieper 6641 set ::ITCL_TEST_FILE $::TCL_LIB_DIR/libitcl3.2.dylib
251 naucoin 7113 set ::IWIDGETS_TEST_FILE $::TCL_LIB_DIR/iwidgets4.0.1/iwidgets.tcl
252     set ::BLT_TEST_FILE $::TCL_BIN_DIR/bltwish24
253 pieper 7799 set ::Teem_TEST_FILE $::Teem_BIN_DIR/unu
254 pieper 376 set ::VTK_TEST_FILE $::VTK_DIR/bin/vtk
255 pieper 435 set ::KWWidgets_TEST_FILE $::KWWidgets_BUILD_DIR/bin/libKWWidgets.$shared_lib_ext
256 hliu 10000 set ::OpenCV_TEST_FILE $::OpenCV_DIR/lib/libcv.$shared_lib_ext
257 pieper 10692 set ::VTK_TCL_LIB $::TCL_LIB_DIR/libtcl8.$::TCL_MINOR_VERSION.$shared_lib_ext
258     set ::VTK_TK_LIB $::TCL_LIB_DIR/libtk8.$::TCL_MINOR_VERSION.$shared_lib_ext
259     set ::VTK_TCLSH $::TCL_BIN_DIR/tclsh8.$::TCL_MINOR_VERSION
260 pieper 376 set ::ITK_TEST_FILE $::ITK_BINARY_PATH/bin/libITKCommon.$shared_lib_ext
261 barre 6777 set ::TK_EVENT_PATCH $::Slicer3_HOME/tkEventPatch.diff
262 pieper 376 set ::env(VTK_BUILD_SUBDIR) $::VTK_BUILD_SUBDIR
263 hliu 7835 set ::OPENIGTLINK_TEST_FILE $::OpenIGTLink_DIR/bin/libOpenIGTLink.$shared_lib_ext
264 pieper 8442 set ::BatchMake_TEST_FILE $::BatchMake_BUILD_DIR/bin/BatchMake
265 naucoin 6040 set ::SLICERLIBCURL_TEST_FILE $::SLICERLIBCURL_BUILD_DIR/bin/libslicerlibcurl.a
266 hliu 3004
267 pieper 376 }
268     "Linux" {
269 pieper 5261 set ::VTK_BUILD_SUBDIR ""
270 pieper 7799 set ::Teem_BIN_DIR $::Teem_BUILD_DIR/bin
271 pieper 376
272     set ::TCL_TEST_FILE $::TCL_BIN_DIR/tclsh8.4
273 pieper 6875 set ::INCR_TCL_LIB $::TCL_LIB_DIR/lib/libitcl3.2.so
274     set ::INCR_TK_LIB $::TCL_LIB_DIR/lib/libitk3.2.so
275 naucoin 7113 set ::IWIDGETS_TEST_FILE $::TCL_LIB_DIR/iwidgets4.0.1/iwidgets.tcl
276     set ::BLT_TEST_FILE $::TCL_BIN_DIR/bltwish24
277 pieper 7447 if { $::USE_SYSTEM_PYTHON } {
278     error "need to define system python path for $::tcl_platform(os)"
279     }
280 blezek 6869 set ::PYTHON_TEST_FILE $::PYTHON_BIN_DIR/bin/python
281 hjohnson 10422 set ::PYTHON_LIB $::PYTHON_BIN_DIR/lib/libpython2.6.so
282     set ::PYTHON_INCLUDE $::PYTHON_BIN_DIR/include/python2.6
283 pieper 7537 set ::NETLIB_TEST_FILE $::Slicer3_LIB/netlib-build/BLAS-build/libblas.a
284 hjohnson 10422 set ::NUMPY_TEST_FILE $::PYTHON_BIN_DIR/lib/python2.6/site-packages/numpy/core/numeric.pyc
285     set ::SCIPY_TEST_FILE $::PYTHON_BIN_DIR/lib/python2.6/site-packages/scipy/version.pyc
286 pieper 376 set ::TK_TEST_FILE $::TCL_BIN_DIR/wish8.4
287 pieper 6641 set ::ITCL_TEST_FILE $::TCL_LIB_DIR/libitcl3.2.so
288 pieper 7799 set ::Teem_TEST_FILE $::Teem_BIN_DIR/unu
289 pieper 376 set ::VTK_TEST_FILE $::VTK_DIR/bin/vtk
290 pieper 435 set ::KWWidgets_TEST_FILE $::KWWidgets_BUILD_DIR/bin/libKWWidgets.so
291 hliu 10000 set ::OpenCV_TEST_FILE $::OpenCV_DIR/lib/libcv.so
292 pieper 376 set ::VTK_TCL_LIB $::TCL_LIB_DIR/libtcl8.4.$shared_lib_ext
293     set ::VTK_TK_LIB $::TCL_LIB_DIR/libtk8.4.$shared_lib_ext
294     set ::VTK_TCLSH $::TCL_BIN_DIR/tclsh8.4
295     set ::ITK_TEST_FILE $::ITK_BINARY_PATH/bin/libITKCommon.$shared_lib_ext
296 barre 6777 set ::TK_EVENT_PATCH $::Slicer3_HOME/tkEventPatch.diff
297 pieper 376 set ::env(VTK_BUILD_SUBDIR) $::VTK_BUILD_SUBDIR
298 hliu 7835 set ::OPENIGTLINK_TEST_FILE $::OpenIGTLink_DIR/bin/libOpenIGTLink.$shared_lib_ext
299 pieper 8442 set ::BatchMake_TEST_FILE $::BatchMake_BUILD_DIR/bin/BatchMake
300 naucoin 6040 set ::SLICERLIBCURL_TEST_FILE $::SLICERLIBCURL_BUILD_DIR/bin/libslicerlibcurl.a
301 hliu 3004
302 pieper 376 }
303     "Windows NT" {
304     # Windows NT currently covers WinNT, Win2000, XP Home, XP Pro
305    
306     set ::VTK_BUILD_SUBDIR $::VTK_BUILD_TYPE
307 pieper 7799 set ::Teem_BIN_DIR $::Teem_BUILD_DIR/bin/$::VTK_BUILD_TYPE
308 pieper 376
309     set ::env(VTK_BUILD_SUBDIR) $::VTK_BUILD_SUBDIR
310     set ::TCL_TEST_FILE $::TCL_BIN_DIR/tclsh84.exe
311     set ::TK_TEST_FILE $::TCL_BIN_DIR/wish84.exe
312 pieper 6641 set ::ITCL_TEST_FILE $::TCL_LIB_DIR/itclConfig.sh
313 pieper 6875 set ::INCR_TCL_LIB $::TCL_LIB_DIR/lib/itcl3.2/itcl32.lib
314     set ::INCR_TK_LIB $::TCL_LIB_DIR/lib/itk3.2/itk32.lib
315 naucoin 7113 set ::IWIDGETS_TEST_FILE $::TCL_LIB_DIR/iwidgets4.0.2/iwidgets.tcl
316     set ::BLT_TEST_FILE $::TCL_BIN_DIR/BLT24.dll
317 pieper 7799 set ::Teem_TEST_FILE $::Teem_BIN_DIR/unu.exe
318 pieper 7447 if { $::USE_SYSTEM_PYTHON } {
319     error "need to define system python path for $::tcl_platform(os)"
320     }
321 pieper 8625 set ::PYTHON_TEST_FILE $::PYTHON_BIN_DIR/PCbuild/python.exe
322 pieper 10437 set ::PYTHON_LIB $::PYTHON_BIN_DIR/PCbuild/python26.lib
323 pieper 8625
324 blezek 6869 set ::PYTHON_INCLUDE $::PYTHON_BIN_DIR/include
325 pieper 8625
326 hjohnson 10422 set ::NETLIB_TEST_FILE $::PYTHON_BIN_DIR/lib/python2.6/site-packages/numpy/core/numeric.pyc
327 pieper 8625 set ::NUMPY_TEST_FILE $::PYTHON_BIN_DIR/lib/site-packages/numpy/core/numeric.pyc
328 hjohnson 10422 set ::SCIPY_TEST_FILE $::PYTHON_BIN_DIR/lib/python2.6/site-packages/scipy/version.pyc
329 pieper 376 set ::VTK_TEST_FILE $::VTK_DIR/bin/$::VTK_BUILD_TYPE/vtk.exe
330 pieper 435 set ::KWWidgets_TEST_FILE $::KWWidgets_BUILD_DIR/bin/$::env(VTK_BUILD_SUBDIR)/KWWidgets.lib
331 hliu 10000 set ::OpenCV_TEST_FILE $::OpenCV_DIR/lib/$::VTK_BUILD_TYPE/CV.lib
332 pieper 376 set ::VTK_TCL_LIB $::TCL_LIB_DIR/tcl84.lib
333     set ::VTK_TK_LIB $::TCL_LIB_DIR/tk84.lib
334     set ::VTK_TCLSH $::TCL_BIN_DIR/tclsh84.exe
335     set ::ITK_TEST_FILE $::ITK_BINARY_PATH/bin/$::VTK_BUILD_TYPE/ITKCommon.dll
336 hliu 7835 set ::OPENIGTLINK_TEST_FILE $::OpenIGTLink_DIR/bin/$::VTK_BUILD_TYPE/OpenIGTLink.lib
337 pieper 8442 set ::BatchMake_TEST_FILE $::BatchMake_BUILD_DIR/bin/$::VTK_BUILD_TYPE/BatchMake.lib
338 naucoin 6040 set ::SLICERLIBCURL_TEST_FILE $::SLICERLIBCURL_BUILD_DIR/bin/$::VTK_BUILD_TYPE/slicerlibcurl.lib
339 pieper 376 }
340     default {
341     puts stderr "Could not match platform \"$::tcl_platform(os)\"."
342     exit
343     }
344     }
345    
346     # System dependent variables
347    
348     switch $::tcl_platform(os) {
349 pieper 10163 "SunOS" {
350 barre 6777 set ::VTKSLICERBASE_BUILD_LIB $::Slicer3_HOME/Base/builds/$::env(BUILD)/bin/vtkSlicerBase.so
351     set ::VTKSLICERBASE_BUILD_TCL_LIB $::Slicer3_HOME/Base/builds/$::env(BUILD)/bin/vtkSlicerBaseTCL.so
352 pieper 376 set ::GENERATOR "Unix Makefiles"
353 pieper 9316 set have_compiler [info exists GETBUILDTEST(compiler)]
354     puts "have_compiler from GETBUILDTEST value: $have_compiler"
355     if {$have_compiler == 1} {
356     set GENLIB(compiler) $GETBUILDTEST(compiler)
357     } else {
358     set GETBUILDTEST(compiler) $GENLIB(compiler)
359     }
360     puts "slicer_variables.tcl: GENLIB(compiler): $::GENLIB(compiler) GETBUILDTEST(compiler): $::GETBUILDTEST(compiler)"
361     if {$GETBUILDTEST(compiler) == "suncc" || $GENLIB(compiler) == "suncc"} {
362     set ::COMPILER_PATH "/opt/SUNWspro/bin"
363     set ::COMPILER "CC"
364     set ::env(CC) cc
365     set ::env(CXX) CC
366     set ::FORTRAN_COMPILER "f90"
367 pieper 10443 set ::env(CXXFLAGS) "-library=stlport4"
368 pieper 9316 } else {
369     set ::env(CC) gcc
370     set ::env(CXX) g++
371     set ::COMPILER_PATH "/usr/sfw/bin"
372     set ::COMPILER "g++"
373     set ::FORTRAN_COMPILER "g77"
374 pieper 10443 set ::env(CXXFLAGS) ""
375 pieper 9316 }
376     # NOTE: the bellow flags will only work with gcc, and Studio 12 or newer.
377     # Earlier Studio versions do not accept the -m64 flag.
378     # If you're not using one of the two, you should check
379     # your compiler's manual for the existence of a similar flag.
380     set have_bitness [info exists GETBUILDTEST(bitness)]
381     if {$have_bitness == 1} {
382     set GENLIB(bitness) $GETBUILDTEST(bitness)
383     } else {
384     set GETBUILDTEST(bitness) $GENLIB(bitness)
385     }
386 pieper 10163 if {$::GETBUILDTEST(bitness) == "64" || $::GENLIB(bitness) == "64"} {
387    
388     # Due to bug 6223255 on Solaris 10 we need to explicitly set the runtime path
389     # for shared objects, because the linker will not find the 64 bit lib automatically.
390     # See the bellow link for more details:
391     # http://bugs.opensolaris.org/bugdatabase/view_bug.do?bug_id=6223255
392     if {$tcl_platform(osVersion) == "5.10" && ($::GETBUILDTEST(bitness) == "64" || $::GENLIB(bitness) == "64")} {
393     set ::env(CFLAGS) -m64
394 pieper 10443 set ::env(CXXFLAGS) "$::env(CXXFLAGS) -m64"
395 pieper 10163 set ::env(LDFLAGS) "-m64 -L/usr/sfw/lib/64 -R/usr/sfw/lib/64"
396    
397     } else {
398     set ::env(CFLAGS) -m64
399 pieper 10443 set ::env(CXXFLAGS) "$::env(CXXFLAGS) -m64"
400 pieper 10163 set ::env(LDFLAGS) -m64
401     }
402 pieper 9316 } else {
403     set ::env(CFLAGS) ""
404 pieper 10443 set ::env(CXXFLAGS) $::env(CXXFLAGS)
405 pieper 9316 set ::env(LDFLAGS) ""
406     }
407     puts "slicer_variables.tcl: GENLIB(bitness): $::GENLIB(bitness) GETBUILDTEST(bitness): $::GETBUILDTEST(bitness)"
408 pieper 376 set ::CMAKE $::CMAKE_PATH/bin/cmake
409 pieper 7336 set numCPUs [lindex [exec /usr/sbin/psrinfo | grep on-line | wc -l | tr -d ''] 0]
410     set ::MAKE "gmake -j[expr $numCPUs]"
411 pieper 376 set ::SERIAL_MAKE "gmake"
412     }
413     "Linux" {
414 barre 6777 set ::VTKSLICERBASE_BUILD_LIB $::Slicer3_HOME/Base/builds/$::env(BUILD)/bin/vtkSlicerBase.so
415     set ::VTKSLICERBASE_BUILD_TCL_LIB $::Slicer3_HOME/Base/builds/$::env(BUILD)/bin/vtkSlicerBaseTCL.so
416 pieper 376 set ::GENERATOR "Unix Makefiles"
417     set ::COMPILER_PATH "/usr/bin"
418     set ::COMPILER "g++"
419 pieper 7594 set ::FORTRAN_COMPILER "gfortran"
420 pieper 376 set ::CMAKE $::CMAKE_PATH/bin/cmake
421 pieper 885 set numCPUs [lindex [exec grep processor /proc/cpuinfo | wc] 0]
422 lorensen 8346 set ::MAKE "make -j [expr $numCPUs]"
423 pieper 376 set ::SERIAL_MAKE "make"
424     }
425     "Darwin" {
426 barre 6777 set ::VTKSLICERBASE_BUILD_LIB $::Slicer3_HOME/Base/builds/$::env(BUILD)/bin/vtkSlicerBase.dylib
427     set ::VTKSLICERBASE_BUILD_TCL_LIB $::Slicer3_HOME/Base/builds/$::env(BUILD)/bin/vtkSlicerBaseTCL.dylib
428 pieper 376 set ::GENERATOR "Unix Makefiles"
429     set ::COMPILER_PATH "/usr/bin"
430 hayes 933 set ::COMPILER "g++"
431 pieper 7560 set ::FORTRAN_COMPILER "gfortran"
432 pieper 376 set ::CMAKE $::CMAKE_PATH/bin/cmake
433 pieper 10127 set numCPUs 1
434     catch { set numCPUs [lindex [exec /usr/sbin/system_profiler | grep "Total Number Of Cores"] end] }
435 pieper 10100 set ::MAKE "make -j [expr (2 * $numCPUs) - 1]"
436 pieper 376 set ::SERIAL_MAKE make
437     }
438     default {
439     # different windows machines say different things, so assume
440     # that if it doesn't match above it must be windows
441     # (VC7 is Visual C++ 7.0, also known as the .NET version)
442    
443    
444 barre 6777 set ::VTKSLICERBASE_BUILD_LIB $::Slicer3_HOME/Base/builds/$::env(BUILD)/bin/$::VTK_BUILD_TYPE/vtkSlicerBase.lib
445     set ::VTKSLICERBASE_BUILD_TCL_LIB $::Slicer3_HOME/Base/builds/$::env(BUILD)/bin/$::VTK_BUILD_TYPE/vtkSlicerBaseTCL.lib
446 pieper 376
447     set ::CMAKE $::CMAKE_PATH/bin/cmake.exe
448    
449     set MSVC6 0
450     #
451     ## match this to the version of the compiler you have:
452     #
453    
454     ## for Visual Studio 6:
455     #set ::GENERATOR "Visual Studio 6"
456     #set ::MAKE "msdev"
457     #set ::COMPILER_PATH ""
458     #set MSVC6 1
459    
460     if {[info exists ::env(MSVC6)]} {
461     set ::MSVC6 $::env(MSVC6)
462     } else {
463     }
464    
465     ## for Visual Studio 7:
466     if {[info exists ::env(GENERATOR)]} {
467     set ::GENERATOR $::env(GENERATOR)
468     } else {
469     set ::GENERATOR "Visual Studio 7"
470     }
471    
472     if {[info exists ::env(MAKE)]} {
473     set ::MAKE $::env(MAKE)
474     } else {
475 barre 9722 # The following line set a default value, hoping that it will be
476     # overriden later on as the script tries for different flavors
477     # of visual studio. Let's try a little harder by checking
478     # some environment variable (ultimately we should try poking
479     # in the Win32 registry).
480     if {[info exists ::env(VSINSTALLDIR)]} {
481 barre 9724 set ::MAKE [file join $::env(VSINSTALLDIR) "Common7/IDE/devenv.exe"]
482 barre 9722 } else {
483     set ::MAKE "c:/Program\ Files/Microsoft\ Visual\ Studio\ .NET/Common7/IDE/devenv.exe"
484     }
485 pieper 376 }
486    
487     if {[info exists ::env(COMPILER_PATH)]} {
488     set ::COMPILER_PATH $::env(COMPILER_PATH)
489     } else {
490 barre 9724 if {[info exists ::env(VSINSTALLDIR)]} {
491     set ::COMPILER_PATH [file join $::env(VSINSTALLDIR) "Common7/Vc7/bin"]
492     } else {
493     set ::COMPILER_PATH "c:/Program\ Files/Microsoft\ Visual\ Studio\ .NET/Common7/Vc7/bin"
494     }
495 pieper 376 }
496    
497 barre 9727 if {[info exists ::env(MSSDK_PATH)]} {
498     set ::MSSDK_PATH $::env(MSSDK_PATH)
499     } else {
500     if {[info exists ::env(WindowsSdkDir)]} {
501     set ::MSSDK_PATH [file normalize $::env(WindowsSdkDir)]
502     } else {
503     set ::MSSDK_PATH "C:/Program\ Files/Microsoft\ SDKs/Windows/v6.0A"
504     }
505     }
506    
507 pieper 376 #
508     ## for Visual Studio 7.1:
509 pieper 917 # - automatically use newer if available
510 pieper 376 #
511     if { [file exists "c:/Program Files/Microsoft Visual Studio .NET 2003/Common7/IDE/devenv.exe"] } {
512     set ::GENERATOR "Visual Studio 7 .NET 2003"
513 pieper 9087 set ::MAKE "c:/Program\ Files/Microsoft\ Visual\ Studio\ .NET 2003/Common7/IDE/devenv.exe"
514 pieper 376 set ::COMPILER_PATH "c:/Program\ Files/Microsoft\ Visual\ Studio\ .NET 2003/Vc7/bin"
515 pieper 8625 set ::MSSDK_PATH "C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\PlatformSDK"
516 pieper 376 }
517    
518 pieper 917 #
519     ## for Visual Studio 8
520     # - automatically use newest if available
521 pieper 1456 # - use full if available, otherwise express
522 pieper 4760 # - use the 64 bit version if available
523 pieper 917 #
524     if { [file exists "c:/Program Files/Microsoft Visual Studio 8/Common7/IDE/VCExpress.exe"] } {
525     set ::GENERATOR "Visual Studio 8 2005"
526     set ::MAKE "c:/Program Files/Microsoft Visual Studio 8/Common7/IDE/VCExpress.exe"
527     set ::COMPILER_PATH "c:/Program Files/Microsoft Visual Studio 8/VC/bin"
528 pieper 8633 set ::MSSDK_PATH "C:\Program Files\Microsoft Platform SDK"
529 pieper 917 }
530    
531 pieper 1456
532     if { [file exists "c:/Program Files/Microsoft Visual Studio 8/Common7/IDE/devenv.exe"] } {
533     set ::GENERATOR "Visual Studio 8 2005"
534     set ::MAKE "c:/Program Files/Microsoft Visual Studio 8/Common7/IDE/devenv.exe"
535     set ::COMPILER_PATH "c:/Program Files/Microsoft Visual Studio 8/VC/bin"
536 pieper 8633 set ::MSSDK_PATH "C:\Program Files\Microsoft Platform SDK"
537 pieper 1456 }
538    
539 pieper 4690 if { [file exists "c:/Program Files (x86)/Microsoft Visual Studio 8/Common7/IDE/devenv.exe"] } {
540 pieper 4760 #set ::GENERATOR "Visual Studio 8 2005 Win64"
541     set ::GENERATOR "Visual Studio 8 2005" ;# do NOT use the 64 bit target
542 pieper 4690 set ::MAKE "c:/Program Files (x86)/Microsoft Visual Studio 8/Common7/IDE/devenv.exe"
543     set ::COMPILER_PATH "c:/Program Files (x86)/Microsoft Visual Studio 8/VC/bin"
544 pieper 11010 set ::MSSDK_PATH "c:/Program Files (x86)/Microsoft Visual Studio 8/SDK/v2.0"
545 pieper 4690 }
546 hayes 6440 #
547     ## for Visual Studio 9
548     if { [file exists "c:/Program Files/Microsoft Visual Studio 9.0/Common7/IDE/VCExpress.exe"] } {
549 hayes 6442 set ::GENERATOR "Visual Studio 9 2008"
550 hayes 6440 set ::MAKE "c:/Program Files/Microsoft Visual Studio 9.0/Common7/IDE/VCExpress.exe"
551     set ::COMPILER_PATH "c:/Program Files/Microsoft Visual Studio 9.0/VC/bin"
552 pieper 8625 set ::MSSDK_PATH "c:/Program Files/Microsoft SDKs/Windows/v6.0A"
553 hayes 6440 }
554 pieper 4690
555 pieper 7737 if { [file exists "c:/Program Files (x86)/Microsoft Visual Studio 9.0/Common7/IDE/devenv.exe"] } {
556     set ::GENERATOR "Visual Studio 9 2008"
557     set ::MAKE "c:/Program Files (x86)/Microsoft Visual Studio 9.0/Common7/IDE/devenv.exe"
558     set ::COMPILER_PATH "c:/Program Files (x86)/Microsoft Visual Studio 9.0/VC/bin"
559 pieper 8625 set ::MSSDK_PATH "c:/Program Files/Microsoft SDKs/Windows/v6.0A"
560 pieper 7737 }
561    
562 pieper 10861 if { [file exists "c:/Program Files (x86)/Microsoft Visual Studio 9.0/Common7/IDE/VCExpress.exe"] } {
563     set ::GENERATOR "Visual Studio 9 2008"
564     set ::MAKE "c:/Program Files (x86)/Microsoft Visual Studio 9.0/Common7/IDE/VCExpress.exe"
565     set ::COMPILER_PATH "c:/Program Files (x86)/Microsoft Visual Studio 9.0/VC/bin"
566     set ::MSSDK_PATH "c:/Program Files/Microsoft SDKs/Windows/v6.0A"
567     }
568 pieper 7737
569 pieper 10861
570 pieper 7379 if { [file exists "c:/Program Files/Microsoft Visual Studio 9.0/Common7/IDE/devenv.exe"] } {
571     set ::GENERATOR "Visual Studio 9 2008"
572     set ::MAKE "c:/Program Files/Microsoft Visual Studio 9.0/Common7/IDE/devenv.exe"
573     set ::COMPILER_PATH "c:/Program Files/Microsoft Visual Studio 9.0/VC/bin"
574 pieper 8625 set ::MSSDK_PATH "c:/Program Files/Microsoft SDKs/Windows/v6.0A"
575 pieper 7379 }
576    
577 pieper 376 set ::COMPILER "cl"
578     set ::SERIAL_MAKE $::MAKE
579     }
580     }
581    
582    
583 pieper 7556

  ViewVC Help
Powered by ViewVC 1.1.22