root/OpenSceneGraph/trunk/examples/CMakeLists.txt @ 10763

Revision 10763, 6.6 kB (checked in by robert, 4 years ago)

Added OSG_CPP_EXCEPTIONS_AVAILABLE cmake option to enable optional build of plugins and examples that required C++ exceptions

  • Property svn:eol-style set to native
Line 
1#######################################################
2# this are setting used in SETUP_EXAMPLE macro
3#######################################################
4SET(TARGET_DEFAULT_PREFIX "example_")
5SET(TARGET_DEFAULT_LABEL_PREFIX "Examples")
6
7SET(TARGET_COMMON_LIBRARIES
8    OpenThreads
9    osg
10    osgDB
11    osgUtil
12    osgGA
13    osgViewer
14    osgText
15)
16
17IF(DYNAMIC_OPENSCENEGRAPH)
18
19    ADD_SUBDIRECTORY(osg2cpp)
20    ADD_SUBDIRECTORY(osganimate)
21    ADD_SUBDIRECTORY(osgautocapture)
22    ADD_SUBDIRECTORY(osgautotransform)
23    ADD_SUBDIRECTORY(osgbillboard)
24    ADD_SUBDIRECTORY(osgblendequation)
25    ADD_SUBDIRECTORY(osgcallback)
26    ADD_SUBDIRECTORY(osgcamera)
27    ADD_SUBDIRECTORY(osgcatch)
28    ADD_SUBDIRECTORY(osgclip)
29    ADD_SUBDIRECTORY(osgcompositeviewer)
30    ADD_SUBDIRECTORY(osgcopy)
31    ADD_SUBDIRECTORY(osgcubemap)
32    ADD_SUBDIRECTORY(osgdelaunay)
33    ADD_SUBDIRECTORY(osgcluster)
34    ADD_SUBDIRECTORY(osgdatabaserevisions)
35    ADD_SUBDIRECTORY(osgdepthpartition)
36    ADD_SUBDIRECTORY(osgdepthpeeling)
37    ADD_SUBDIRECTORY(osgdrawinstanced)
38    ADD_SUBDIRECTORY(osgdistortion)
39    ADD_SUBDIRECTORY(osgfadetext)
40    ADD_SUBDIRECTORY(osgfont)
41    ADD_SUBDIRECTORY(osgforest)
42    ADD_SUBDIRECTORY(osgfxbrowser)
43    ADD_SUBDIRECTORY(osggameoflife)
44    ADD_SUBDIRECTORY(osggeodemo)
45    ADD_SUBDIRECTORY(osggeometry)
46    ADD_SUBDIRECTORY(osggeometryshaders)
47    ADD_SUBDIRECTORY(osghangglide)
48    ADD_SUBDIRECTORY(osghud)
49    ADD_SUBDIRECTORY(osgimagesequence)
50    ADD_SUBDIRECTORY(osgimpostor)
51    ADD_SUBDIRECTORY(osgintersection)
52    ADD_SUBDIRECTORY(osgkdtree)
53    ADD_SUBDIRECTORY(osgkeyboard)
54    ADD_SUBDIRECTORY(osgkeyboardmouse)
55    ADD_SUBDIRECTORY(osglauncher)
56    ADD_SUBDIRECTORY(osglight)
57    ADD_SUBDIRECTORY(osglightpoint)
58    ADD_SUBDIRECTORY(osglogicop)
59    ADD_SUBDIRECTORY(osglogo)
60    ADD_SUBDIRECTORY(osgmanipulator)
61    ADD_SUBDIRECTORY(osgmovie)
62    ADD_SUBDIRECTORY(osgmultiplerendertargets)
63    ADD_SUBDIRECTORY(osgmultitexture)
64    ADD_SUBDIRECTORY(osgmultitexturecontrol)
65    ADD_SUBDIRECTORY(osgoccluder)
66    ADD_SUBDIRECTORY(osgocclusionquery)
67    ADD_SUBDIRECTORY(osgpackeddepthstencil)
68    ADD_SUBDIRECTORY(osgpagedlod)
69    ADD_SUBDIRECTORY(osgparametric)
70    ADD_SUBDIRECTORY(osgparticle)
71    ADD_SUBDIRECTORY(osgparticleeffects)
72    ADD_SUBDIRECTORY(osgpick)
73    ADD_SUBDIRECTORY(osgplanets)
74    ADD_SUBDIRECTORY(osgpoints)
75    ADD_SUBDIRECTORY(osgpointsprite)
76    ADD_SUBDIRECTORY(osgprecipitation)
77    ADD_SUBDIRECTORY(osgprerender)
78    ADD_SUBDIRECTORY(osgprerendercubemap)
79    ADD_SUBDIRECTORY(osgreflect)
80    ADD_SUBDIRECTORY(osgrobot)
81    ADD_SUBDIRECTORY(osgscalarbar)
82    ADD_SUBDIRECTORY(osgscribe)
83    ADD_SUBDIRECTORY(osgsequence)
84    ADD_SUBDIRECTORY(osgshaders)
85    ADD_SUBDIRECTORY(osgshadergen)
86    ADD_SUBDIRECTORY(osgshaderterrain)
87    ADD_SUBDIRECTORY(osgshadercompositor)
88    ADD_SUBDIRECTORY(osgshadow)
89    ADD_SUBDIRECTORY(osgshape)
90    ADD_SUBDIRECTORY(osgsharedarray)
91    ADD_SUBDIRECTORY(osgsimplifier)
92    ADD_SUBDIRECTORY(osgsimulation)
93    ADD_SUBDIRECTORY(osgsidebyside)
94    ADD_SUBDIRECTORY(osgslice)
95    ADD_SUBDIRECTORY(osgspacewarp)
96    ADD_SUBDIRECTORY(osgspheresegment)
97    ADD_SUBDIRECTORY(osgspotlight)
98    ADD_SUBDIRECTORY(osgstereoimage)
99    ADD_SUBDIRECTORY(osgstereomatch)
100    ADD_SUBDIRECTORY(osgterrain)
101    ADD_SUBDIRECTORY(osgtext)
102    ADD_SUBDIRECTORY(osgtext3D)
103    ADD_SUBDIRECTORY(osgtexture1D)
104    ADD_SUBDIRECTORY(osgtexture2D)
105    ADD_SUBDIRECTORY(osgtexture3D)
106    ADD_SUBDIRECTORY(osgtexturerectangle)
107    ADD_SUBDIRECTORY(osgtexturecompression)
108    ADD_SUBDIRECTORY(osgthirdpersonview)
109    ADD_SUBDIRECTORY(osgvertexprogram)
110    ADD_SUBDIRECTORY(osgvertexattributes)
111    ADD_SUBDIRECTORY(osgvolume)
112    ADD_SUBDIRECTORY(osgwindows)
113    ADD_SUBDIRECTORY(osganimationhardware)
114    ADD_SUBDIRECTORY(osganimationtimeline)
115    ADD_SUBDIRECTORY(osganimationnode)
116    ADD_SUBDIRECTORY(osganimationmakepath)
117    ADD_SUBDIRECTORY(osganimationmorph)
118    ADD_SUBDIRECTORY(osganimationskinning)
119    ADD_SUBDIRECTORY(osganimationsolid)
120    ADD_SUBDIRECTORY(osganimationviewer)
121    ADD_SUBDIRECTORY(osgbrowser)
122    ADD_SUBDIRECTORY(osgwidgetaddremove)
123    ADD_SUBDIRECTORY(osgwidgetbox)
124    ADD_SUBDIRECTORY(osgwidgetcanvas)
125    ADD_SUBDIRECTORY(osgwidgetframe)
126    ADD_SUBDIRECTORY(osgwidgetinput)
127    ADD_SUBDIRECTORY(osgwidgetlabel)
128    ADD_SUBDIRECTORY(osgwidgetmessagebox)
129    ADD_SUBDIRECTORY(osgwidgetmenu)
130    ADD_SUBDIRECTORY(osgwidgetnotebook)
131    ADD_SUBDIRECTORY(osgwidgetperformance)
132    ADD_SUBDIRECTORY(osgwidgetscrolled)
133    ADD_SUBDIRECTORY(osgwidgetshader)
134    ADD_SUBDIRECTORY(osgwidgetstyled)
135    ADD_SUBDIRECTORY(osgwidgettable)
136    ADD_SUBDIRECTORY(osgwidgetwindow)
137
138    IF(OSG_CPP_EXCEPTIONS_AVAILABLE)
139        ADD_SUBDIRECTORY(osgunittests)
140        ADD_SUBDIRECTORY(osgmemorytest)
141    ENDIF()
142
143    IF(NOT OSG_GLES1_AVAILABLE AND NOT OSG_GLES2_AVAILABLE AND NOT OSG_GL3_AVAILABLE)
144        ADD_SUBDIRECTORY(osgscreencapture)
145        ADD_SUBDIRECTORY(osgmotionblur)
146        ADD_SUBDIRECTORY(osgteapot)
147    ENDIF()
148
149    IF(OSG_GLU_AVAILABLE)
150        ADD_SUBDIRECTORY(osgphotoalbum)
151        ADD_SUBDIRECTORY(osgtessellate)
152    ENDIF()
153
154    ADD_SUBDIRECTORY(osgpdf)
155   
156    IF   (BUILD_OSG_WRAPPERS)
157        ADD_SUBDIRECTORY(osgintrospection)
158    ENDIF(BUILD_OSG_WRAPPERS)
159
160    IF   (GLUT_FOUND)
161        ADD_SUBDIRECTORY(osgviewerGLUT)
162    ENDIF(GLUT_FOUND)
163
164    IF   (SDL_FOUND)
165        ADD_SUBDIRECTORY(osgviewerSDL)
166    ENDIF(SDL_FOUND)
167
168    IF   (GTKGL_FOUND)
169        ADD_SUBDIRECTORY(osgviewerGTK)
170    ENDIF(GTKGL_FOUND)
171
172    IF   (FOX_FOUND)
173        ADD_SUBDIRECTORY(osgviewerFOX)
174    ENDIF(FOX_FOUND)
175
176    IF   (wxWidgets_FOUND)
177        ADD_SUBDIRECTORY(osgviewerWX)
178    ENDIF(wxWidgets_FOUND)
179
180    IF   (QT_FOUND AND QT_QTOPENGL_LIBRARY)
181        ADD_SUBDIRECTORY(osgviewerQT)
182        IF (QT4_FOUND)
183            ADD_SUBDIRECTORY(osgviewerQtWidget)
184        ENDIF()
185    ENDIF()
186
187    IF (QT4_FOUND)
188        ADD_SUBDIRECTORY(osgQtBrowser)
189    ENDIF()
190
191    IF   (FLTK_FOUND)
192        ADD_SUBDIRECTORY(osgviewerFLTK)
193    ENDIF(FLTK_FOUND)
194
195    IF   (WIN32)
196
197        OPTION(BUILD_MFC_EXAMPLE "Enable the build of the MFC Example" OFF)
198
199        IF   (BUILD_MFC_EXAMPLE)       
200            ADD_SUBDIRECTORY(osgviewerMFC)
201        ENDIF(BUILD_MFC_EXAMPLE)
202
203    ENDIF(WIN32)
204
205    IF   (APPLE)
206        ADD_SUBDIRECTORY(osgviewerCocoa)
207    ENDIF(APPLE)
208
209
210
211    IF   (LIBVNCSERVER_FOUND)
212        ADD_SUBDIRECTORY(osgvnc)
213    ENDIF(LIBVNCSERVER_FOUND)
214
215
216    #ADD_SUBDIRECTORY(osgcegui)
217
218    #to add subject to find socket#ADD_SUBDIRECTORY(osgcluster)
219
220ELSE(DYNAMIC_OPENSCENEGRAPH)
221    #needed on win32 or the linker get confused by _declspec declarations
222    ADD_DEFINITIONS(-DOSG_LIBRARY_STATIC)
223
224    ADD_SUBDIRECTORY(osgstaticviewer)
225   
226ENDIF(DYNAMIC_OPENSCENEGRAPH)
227
Note: See TracBrowser for help on using the browser.