2 |
|
|
3 |
|
from SCons.SConf import SConf # aka Configure |
4 |
|
|
5 |
+ |
def find_radlib(env): |
6 |
+ |
v = env.FindFile('helvet.fnt', './lib') |
7 |
+ |
if not v: |
8 |
+ |
print ''' |
9 |
+ |
Radiance auxiliary support files not found. |
10 |
+ |
-> Download from radiance-online.org and extract. |
11 |
+ |
''' |
12 |
+ |
env.Exit() |
13 |
+ |
|
14 |
|
def find_x11(env): |
15 |
|
# Search for libX11, remember the X11 library and include dirs |
16 |
|
for d in ('/usr/X11R6', '/usr/X11', '/usr/openwin'): |
61 |
|
dl = [ (None,None), ] # standard search path |
62 |
|
cfgi = env.get('TIFFINCLUDE') |
63 |
|
cfgl = env.get('TIFFLIB') |
64 |
+ |
#print('TIFFLIB:', cfgl) |
65 |
|
if cfgi or cfgl: |
66 |
|
dl.insert(0,(cfgi, cfgl)) |
67 |
|
for incdir, libdir in dl: |
68 |
|
if incdir: env.Prepend(CPPPATH=[incdir]) # add temporarily |
69 |
|
if libdir: env.Prepend(LIBPATH=[libdir]) |
70 |
|
conf = SConf(env) |
71 |
< |
if conf.CheckLib('tiff', 'TIFFInitSGILog', |
72 |
< |
header='void TIFFInitSGILog(void);', autoadd=0): |
71 |
> |
libname = 'tiff' |
72 |
> |
header = 'void TIFFInitSGILog(void);' |
73 |
> |
if os.name == 'nt': |
74 |
> |
libname = 'libtiff' |
75 |
> |
if conf.CheckLib(libname, 'TIFFInitSGILog', |
76 |
> |
header=header, autoadd=0): |
77 |
|
env['TIFFLIB_INSTALLED'] = 1 |
78 |
|
if incdir: env['CPPPATH'].remove(incdir) # not needed for now |
79 |
|
if libdir: env['LIBPATH'].remove(libdir) |