ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/meta/CMakeLists.txt
Revision: 1.3
Committed: Mon Jan 8 16:51:32 2018 UTC (6 years, 4 months ago) by greg
Content type: text/plain
Branch: MAIN
CVS Tags: rad5R4, rad5R2, rad5R3, HEAD
Changes since 1.2: +39 -15 lines
Log Message:
Update to CMake build system from Rob G. and Alex S., adding test cases

File Contents

# User Rev Content
1 greg 1.3 set(common_src mfio.c misc.c syscalls.c)
2 greg 1.1
3     add_executable(bgraph bgraph.c mgvars.c mgraph.c)
4     target_link_libraries(bgraph meta rtrad)
5    
6     add_executable(cv cv.c mfio.c cvhfio.c syscalls.c misc.c)
7     target_link_libraries(cv rtrad)
8    
9     add_executable(dgraph dgraph.c cgraph.c mgvars.c)
10     target_link_libraries(dgraph rtrad)
11    
12     add_executable(gcomp gcomp.c gcalc.c mgvars.c)
13     target_link_libraries(gcomp rtrad)
14    
15     add_executable(igraph igraph.c mgvars.c mgraph.c gcalc.c cgraph.c)
16     target_link_libraries(igraph meta rtrad)
17    
18     add_library(meta metacalls.c primout.c progname.c ${common_src})
19    
20     add_executable(meta2bmp meta2bmp.c rplot.c plot.c palloc.c ${common_src})
21     target_link_libraries(meta2bmp rtrad)
22    
23     add_executable(meta2tga meta2tga.c rplot.c plot.c palloc.c ${common_src})
24     target_link_libraries(meta2tga rtrad)
25    
26     add_executable(mtext mtext.c primout.c ${common_src})
27     target_link_libraries(mtext rtrad)
28    
29     add_executable(pexpand pexpand.c expand.c segment.c palloc.c ${common_src})
30     target_link_libraries(pexpand rtrad)
31    
32     add_executable(plot4 plot4.c primout.c ${common_src})
33     target_link_libraries(plot4 rtrad)
34    
35     add_executable(plotin plotin.c primout.c ${common_src})
36     target_link_libraries(plotin rtrad)
37    
38     add_executable(psmeta psmeta.c psplot.c ${common_src})
39     target_link_libraries(psmeta rtrad)
40    
41     add_executable(psort psort.c sort.c palloc.c ${common_src})
42     target_link_libraries(psort rtrad)
43    
44     #add_executable(tbar tbar.c tgraph.c primout.c)
45     #target_link_libraries(tbar rtrad)
46    
47     #add_executable(tcurve tcurve.c tgraph.c primout.c)
48     #target_link_libraries(tcurve ${LIB_M})
49    
50     #add_executable(tscat tscat.c tgraph.c primout.c)
51     #target_link_libraries(tscat rtrad)
52    
53     if(X11_FOUND)
54 greg 1.3 add_executable(x11meta
55     palloc.c
56     plot.c
57     x11plot.c
58     xmeta.c
59     ${common_src}
60     )
61 greg 1.1 target_link_libraries(x11meta rtrad ${X11_LIBRARIES})
62 greg 1.3 install(TARGETS x11meta
63     RUNTIME DESTINATION "bin"
64     )
65 greg 1.1 endif()
66    
67 greg 1.2 add_custom_target(mta ALL
68     COMMAND cv "${CMAKE_CURRENT_SOURCE_DIR}/symbols.met" > "${CMAKE_CURRENT_BINARY_DIR}/symbols.mta"
69     COMMAND cv "${CMAKE_CURRENT_SOURCE_DIR}/vchars.met" > "${CMAKE_CURRENT_BINARY_DIR}/vchars.mta"
70 greg 1.3 COMMAND "${CMAKE_COMMAND}" -E copy "${CMAKE_CURRENT_BINARY_DIR}/symbols.mta" "${CMAKE_CURRENT_BINARY_DIR}/vchars.mta" "${CMAKE_BINARY_DIR}/lib"
71 greg 1.2 SOURCES symbols.met vchars.met
72     )
73    
74 greg 1.3 file(COPY
75     boxw.plt
76     cartesian.plt
77     curve.plt
78     function.plt
79     line.plt
80     polar.plt
81     scatter.plt
82     standard.plt
83     symbols.met
84     vchars.met
85     DESTINATION "${CMAKE_BINARY_DIR}/lib"
86 greg 1.2 )
87    
88 greg 1.3 install(TARGETS
89     bgraph
90     cv
91     dgraph
92     gcomp
93     igraph
94     meta2bmp
95     meta2tga
96     pexpand
97     plot4
98     plotin
99     psmeta
100     psort
101     RUNTIME DESTINATION "bin"
102     )