ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/util/CMakeLists.txt
(Generate patch)

Comparing ray/src/util/CMakeLists.txt (file contents):
Revision 1.1 by greg, Sat Oct 22 22:38:10 2011 UTC vs.
Revision 1.30 by greg, Thu Jul 18 18:51:56 2019 UTC

# Line 1 | Line 1
1   set(VERSION_FILE "${radiance_BINARY_DIR}/src/util/Version.c")
2 < add_custom_command(
3 <  OUTPUT "${VERSION_FILE}"
4 <  DEPENDS "${radiance_SOURCE_DIR}/src/util/VERSION"
5 <  COMMAND "${CMAKE_COMMAND}"
6 <  -DVERSION_OUT_FILE="${VERSION_FILE}"
7 <  -DVERSION_IN_FILE="${radiance_SOURCE_DIR}/src/util/VERSION"
8 <  -P "${radiance_SOURCE_DIR}/src/common/create_version.cmake"
9 < )
2 > create_version_file("${VERSION_FILE}")
3  
4 < add_executable(dctimestep dctimestep.c)
4 > add_executable(dctimestep dctimestep.c cmbsdf.c cmatrix.c)
5   target_link_libraries(dctimestep rtrad)
6  
7   add_executable(findglare findglare.c glareval.c glaresrc.c setscan.c)
# Line 22 | Line 15 | target_link_libraries(glarendx rtrad)
15  
16   add_executable(rad rad.c)
17   target_link_libraries(rad rtrad)
18 +
19   if(WIN32)
20    set(netproc_SOURCES win_netproc.c)
21   else()
22    set(netproc_SOURCES netproc.c)
23   endif()
24 +
25   add_executable(ranimate ranimate.c ${netproc_SOURCES})
26   target_link_libraries(ranimate rtrad)
27  
28   add_executable(rpiece rpiece.c "${VERSION_FILE}")
29   target_link_libraries(rpiece rtrad)
30  
36 add_executable(rtcontrib
37  rtcontrib.c "${VERSION_FILE}")
38 target_link_libraries(rtcontrib rtrad)
39
31   add_executable(vwrays vwrays.c)
32   target_link_libraries(vwrays rtrad)
33  
# Line 44 | Line 35 | add_executable(vwright vwright.c)
35   target_link_libraries(vwright rtrad)
36  
37   #the next few libraries all need to include header files from the rt directory
38 < include_directories(${CMAKE_CURRENT_SOURCE_DIR}/../rt)
38 > include_directories("${CMAKE_CURRENT_SOURCE_DIR}/../rt")
39  
40   add_executable(ranimove ranimove.c ranimove1.c ranimove2.c)
41   target_link_libraries(ranimove raycalls radiance rtrad)
# Line 52 | Line 43 | target_link_libraries(ranimove raycalls radiance rtrad
43   add_executable(rsensor rsensor.c)
44   target_link_libraries(rsensor raycalls radiance rtrad)
45  
46 + add_executable(rttree_reduce rttree_reduce.c)
47 + target_link_libraries(rttree_reduce rtrad)
48 +
49 + add_executable(rcollate rcollate.c)
50 + target_link_libraries(rcollate rtrad)
51 +
52 + add_executable(rmtxop rmtxop.c rmatrix.c cmbsdf.c cmatrix.c)
53 + target_link_libraries(rmtxop rtrad)
54 +
55 + add_executable(wrapBSDF wrapBSDF.c)
56 + target_link_libraries(wrapBSDF rtrad)
57 +
58 + add_executable(eplus_adduvf eplus_adduvf.c eplus_idf.c)
59 + target_link_libraries(eplus_adduvf rtrad)
60 +
61 + add_executable(rfluxmtx rfluxmtx.c)
62 + target_link_libraries(rfluxmtx rtrad)
63 +
64 + add_executable(evalglare evalglare.c pictool.c)
65 + target_link_libraries(evalglare rtrad libreetz)
66 +
67 + add_executable(radcompare radcompare.c)
68 + target_link_libraries(radcompare rtrad)
69 +
70 + add_executable(rcode_depth rcode_depth.c depthcodec.c)
71 + target_link_libraries(rcode_depth rtrad)
72 +
73   if(X11_FOUND)
74    add_executable(xglaresrc
75 <    xglaresrc.c ${CMAKE_CURRENT_SOURCE_DIR}/../common/x11findwind.c)
75 >    xglaresrc.c
76 >    "${CMAKE_CURRENT_SOURCE_DIR}/../common/x11findwind.c"
77 >  )
78    target_link_libraries(xglaresrc rtrad ${X11_LIBRARIES})
79 <  install(TARGETS xglaresrc RUNTIME DESTINATION bin)
79 >  install(TARGETS xglaresrc
80 >    RUNTIME DESTINATION "bin"
81 >  )
82   endif()
83  
84 < find_library(LIB_RGL "rgl" DOC "Path to librgl")
85 < if(LIB_RGL)
86 <  #glrad needs to be able to include OpenGL headers
84 > #glrad needs to link against OpenGL libraries
85 > if(APPLE)
86 >  find_library(OPENGL_gl_LIBRARY
87 >    NAMES GL MesaGL
88 >    PATHS ${X11_LIB_SEARCH_PATH}
89 >  )
90 >  find_library(OPENGL_glu_LIBRARY
91 >    NAMES GLU MesaGLU
92 >    PATHS ${X11_LIB_SEARCH_PATH}
93 >  )
94 >  set(OPENGL_LIBRARIES ${OPENGL_gl_LIBRARY} ${OPENGL_glu_LIBRARY})
95 > else()
96 >  find_package(OpenGL REQUIRED)
97    include_directories(${OPENGL_INCLUDE_DIR})
98 + endif()
99  
100 <  #check if we have SGIStereo.h
101 <  find_file(HAVE_SGISTEREO_H "SGIStereo.h" ${OPENGL_INCLUDE_DIR})
102 <  if(NOT HAVE_SGISTEREO_H)
103 <    add_definitions(-DNOSTEREO)
100 > #check if we have SGIStereo.h
101 > find_file(HAVE_SGISTEREO_H "SGIStereo.h" ${OPENGL_INCLUDE_DIR})
102 > if(NOT HAVE_SGISTEREO_H)
103 >  add_definitions(-DNOSTEREO)
104 > endif()
105 > if(UNIX AND X11_FOUND)
106 >  add_executable(glrad glrad.c)
107 >  target_link_libraries(glrad rgl rtrad ${OPENGL_LIBRARIES} ${X11_LIBRARIES})
108 >  install(TARGETS glrad
109 >    RUNTIME DESTINATION "bin"
110 >  )
111 >  if(CMAKE_SYSTEM_NAME STREQUAL "SunOS")
112 >    target_link_libraries(glrad rt)
113    endif()
114 + endif()
115  
116 <  add_executable(glrad glrad.c)
117 <  target_link_libraries(glrad
118 <    rtrad ${LIB_RGL} ${OPENGL_LIBRARIES} ${X11_LIBRARIES})
119 <  install(TARGETS glrad RUNTIME DESTINATION bin)
116 > if(UNIX)
117 >  install(TARGETS rpiece
118 >    RUNTIME DESTINATION "bin"
119 >  )
120   endif()
121  
122 < install(TARGETS dctimestep findglare getinfo glarendx rad ranimate rpiece
123 <                rtcontrib vwrays vwright ranimove rsensor
124 <        RUNTIME DESTINATION bin)
125 < install(FILES objview.csh objpict.csh glare.csh dayfact.csh rlux.csh
126 <              raddepend.csh trad.wsh objline.csh compamb.csh vinfo.csh
127 <              genambpos.csh fieldcomb.csh genklemsamp.pl genskyvec.pl
128 <              genBSDF.pl tregsamp.dat
129 <        DESTINATION bin)
122 > install(TARGETS
123 >  dctimestep
124 >  eplus_adduvf
125 >  evalglare
126 >  findglare
127 >  getinfo
128 >  glarendx
129 >  rad
130 >  radcompare
131 >  ranimate
132 >  ranimove
133 >  rcollate
134 >  rfluxmtx
135 >  rmtxop
136 >  rsensor
137 >  rttree_reduce
138 >  vwrays
139 >  vwright
140 >  wrapBSDF
141 >  RUNTIME DESTINATION "bin"
142 > )
143 >
144 > file(COPY
145 >  ambpos.cal
146 >  disk2square.cal
147 >  klems_full.cal
148 >  klems_half.cal
149 >  klems_quarter.cal
150 >  minimalBSDFt.xml
151 >  rambpos.cal
152 >  reinhartb.cal
153 >  tregsamp.dat
154 >  WINDOW6BSDFt.xml
155 >  DESTINATION "${CMAKE_BINARY_DIR}/lib"
156 > )
157 >
158 > if(WIN32)
159 >  install(PROGRAMS
160 >    bsdfview.pl
161 >    genBSDF.pl
162 >    genklemsamp.pl
163 >    genskyvec.pl
164 >    ltpict.pl
165 >    ltview.pl
166 >    objpict.pl
167 >    objview.pl
168 >    DESTINATION "bin"
169 >  )
170 > else()
171 >  install_without_extension(
172 >    bsdfview.pl
173 >    compamb.csh
174 >    dayfact.csh
175 >    fieldcomb.csh
176 >    genBSDF.pl
177 >    genambpos.csh
178 >    genklemsamp.pl
179 >    genskyvec.pl
180 >    glare.csh
181 >    ltpict.pl
182 >    ltview.pl
183 >    objline.csh
184 >    objpict.pl
185 >    objview.pl
186 >    raddepend.csh
187 >    rlux.csh
188 >    rtpict.pl
189 >    trad.wsh
190 >    vinfo.csh
191 >  )
192 > endif()

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines