|
| 1 | +project('openFrameworks', 'cpp', |
| 2 | +version : '0.12.0', |
| 3 | +default_options : [ |
| 4 | + 'cpp_std=c++20', |
| 5 | + 'buildtype=release', |
| 6 | + 'optimization=3', |
| 7 | + 'default_library=shared', |
| 8 | + # 'prefer_static=true', |
| 9 | + 'b_ndebug=if-release', |
| 10 | + 'c_args=-pipe', |
| 11 | + 'cpp_args=-pipe', |
| 12 | + # 'warning_level=3' |
| 13 | +] |
| 14 | +) |
| 15 | + |
| 16 | +inc = include_directories( |
| 17 | + 'libs/openFrameworks/3d', |
| 18 | + 'libs/openFrameworks/app', |
| 19 | + 'libs/openFrameworks/communication', |
| 20 | + 'libs/openFrameworks/events', |
| 21 | + 'libs/openFrameworks/gl', |
| 22 | + 'libs/openFrameworks/graphics', |
| 23 | + 'libs/openFrameworks/math', |
| 24 | + 'libs/openFrameworks/sound', |
| 25 | + 'libs/openFrameworks/types', |
| 26 | + 'libs/openFrameworks/utils', |
| 27 | + 'libs/openFrameworks/video', |
| 28 | + 'libs/openFrameworks', |
| 29 | +) |
| 30 | + |
| 31 | +sources = files( |
| 32 | + 'libs/openFrameworks/3d/of3dPrimitives.cpp', |
| 33 | + 'libs/openFrameworks/3d/of3dUtils.cpp', |
| 34 | + 'libs/openFrameworks/3d/ofCamera.cpp', |
| 35 | + 'libs/openFrameworks/3d/ofEasyCam.cpp', |
| 36 | + 'libs/openFrameworks/3d/ofNode.cpp', |
| 37 | + 'libs/openFrameworks/app/ofAppEGLWindow.cpp', |
| 38 | + 'libs/openFrameworks/app/ofAppGLFWWindow.cpp', |
| 39 | + 'libs/openFrameworks/app/ofAppGlutWindow.cpp', |
| 40 | + 'libs/openFrameworks/app/ofAppNoWindow.cpp', |
| 41 | + 'libs/openFrameworks/app/ofAppRunner.cpp', |
| 42 | + 'libs/openFrameworks/app/ofBaseApp.cpp', |
| 43 | + 'libs/openFrameworks/app/ofMainLoop.cpp', |
| 44 | + 'libs/openFrameworks/communication/ofArduino.cpp', |
| 45 | + 'libs/openFrameworks/communication/ofSerial.cpp', |
| 46 | + 'libs/openFrameworks/events/ofEvents.cpp', |
| 47 | + 'libs/openFrameworks/gl/ofBufferObject.cpp', |
| 48 | + 'libs/openFrameworks/gl/ofCubeMap.cpp', |
| 49 | + 'libs/openFrameworks/gl/ofFbo.cpp', |
| 50 | + 'libs/openFrameworks/gl/ofGLProgrammableRenderer.cpp', |
| 51 | + 'libs/openFrameworks/gl/ofGLRenderer.cpp', |
| 52 | + 'libs/openFrameworks/gl/ofGLUtils.cpp', |
| 53 | + 'libs/openFrameworks/gl/ofLight.cpp', |
| 54 | + 'libs/openFrameworks/gl/ofMaterial.cpp', |
| 55 | + 'libs/openFrameworks/gl/ofShader.cpp', |
| 56 | + 'libs/openFrameworks/gl/ofShadow.cpp', |
| 57 | + 'libs/openFrameworks/gl/ofTexture.cpp', |
| 58 | + 'libs/openFrameworks/gl/ofVbo.cpp', |
| 59 | + 'libs/openFrameworks/gl/ofVboMesh.cpp', |
| 60 | + 'libs/openFrameworks/graphics/of3dGraphics.cpp', |
| 61 | + 'libs/openFrameworks/graphics/ofBitmapFont.cpp', |
| 62 | + 'libs/openFrameworks/graphics/ofCairoRenderer.cpp', |
| 63 | + 'libs/openFrameworks/graphics/ofGraphicsBaseTypes.cpp', |
| 64 | + 'libs/openFrameworks/graphics/ofGraphicsCairo.cpp', |
| 65 | + 'libs/openFrameworks/graphics/ofGraphics.cpp', |
| 66 | + 'libs/openFrameworks/graphics/ofImage.cpp', |
| 67 | + 'libs/openFrameworks/graphics/ofPath.cpp', |
| 68 | + 'libs/openFrameworks/graphics/ofPixels.cpp', |
| 69 | + 'libs/openFrameworks/graphics/ofRendererCollection.cpp', |
| 70 | + 'libs/openFrameworks/graphics/ofTessellator.cpp', |
| 71 | + 'libs/openFrameworks/graphics/ofTrueTypeFont.cpp', |
| 72 | + 'libs/openFrameworks/math/ofMath.cpp', |
| 73 | + 'libs/openFrameworks/math/ofMatrix3x3.cpp', |
| 74 | + 'libs/openFrameworks/math/ofMatrix4x4.cpp', |
| 75 | + 'libs/openFrameworks/math/ofQuaternion.cpp', |
| 76 | + 'libs/openFrameworks/math/ofVec2f.cpp', |
| 77 | + 'libs/openFrameworks/math/ofVec4f.cpp', |
| 78 | + 'libs/openFrameworks/sound/ofFmodSoundPlayer.cpp', |
| 79 | + 'libs/openFrameworks/sound/ofMediaFoundationSoundPlayer.cpp', |
| 80 | + 'libs/openFrameworks/sound/ofOpenALSoundPlayer.cpp', |
| 81 | + 'libs/openFrameworks/sound/ofRtAudioSoundStream.cpp', |
| 82 | + 'libs/openFrameworks/sound/ofSoundBaseTypes.cpp', |
| 83 | + 'libs/openFrameworks/sound/ofSoundBuffer.cpp', |
| 84 | + 'libs/openFrameworks/sound/ofSoundPlayer.cpp', |
| 85 | + 'libs/openFrameworks/sound/ofSoundStream.cpp', |
| 86 | + 'libs/openFrameworks/types/ofBaseTypes.cpp', |
| 87 | + 'libs/openFrameworks/types/ofColor.cpp', |
| 88 | + 'libs/openFrameworks/types/ofParameter.cpp', |
| 89 | + 'libs/openFrameworks/types/ofParameterGroup.cpp', |
| 90 | + 'libs/openFrameworks/types/ofRectangle.cpp', |
| 91 | + 'libs/openFrameworks/utils/ofFileUtils.cpp', |
| 92 | + 'libs/openFrameworks/utils/ofFpsCounter.cpp', |
| 93 | + 'libs/openFrameworks/utils/ofLog.cpp', |
| 94 | + 'libs/openFrameworks/utils/ofMatrixStack.cpp', |
| 95 | + 'libs/openFrameworks/utils/ofSystemUtils.cpp', |
| 96 | + 'libs/openFrameworks/utils/ofThread.cpp', |
| 97 | + 'libs/openFrameworks/utils/ofTimer.cpp', |
| 98 | + 'libs/openFrameworks/utils/ofURLFileLoader.cpp', |
| 99 | + 'libs/openFrameworks/utils/ofUtils.cpp', |
| 100 | + 'libs/openFrameworks/utils/ofXml.cpp', |
| 101 | + 'libs/openFrameworks/video/ofDirectShowGrabber.cpp', |
| 102 | + 'libs/openFrameworks/video/ofDirectShowPlayer.cpp', |
| 103 | + 'libs/openFrameworks/video/ofGstUtils.cpp', |
| 104 | + 'libs/openFrameworks/video/ofGstVideoGrabber.cpp', |
| 105 | + 'libs/openFrameworks/video/ofGstVideoPlayer.cpp', |
| 106 | + 'libs/openFrameworks/video/ofMediaFoundationPlayer.cpp', |
| 107 | + 'libs/openFrameworks/video/ofVideoGrabber.cpp', |
| 108 | + 'libs/openFrameworks/video/ofVideoPlayer.cpp', |
| 109 | +) |
| 110 | + |
| 111 | +install_headers( |
| 112 | + 'libs/openFrameworks/3d/of3dPrimitives.h', |
| 113 | + 'libs/openFrameworks/3d/of3dUtils.h', |
| 114 | + 'libs/openFrameworks/3d/ofCamera.h', |
| 115 | + 'libs/openFrameworks/3d/ofEasyCam.h', |
| 116 | + 'libs/openFrameworks/3d/ofMesh.h', |
| 117 | + 'libs/openFrameworks/3d/ofNode.h', |
| 118 | + 'libs/openFrameworks/app/ofAppBaseWindow.h', |
| 119 | + 'libs/openFrameworks/app/ofAppEGLWindow.h', |
| 120 | + 'libs/openFrameworks/app/ofAppGLFWWindow.h', |
| 121 | + 'libs/openFrameworks/app/ofAppGlutWindow.h', |
| 122 | + 'libs/openFrameworks/app/ofAppNoWindow.h', |
| 123 | + 'libs/openFrameworks/app/ofAppRunner.h', |
| 124 | + 'libs/openFrameworks/app/ofBaseApp.h', |
| 125 | + 'libs/openFrameworks/app/ofIcon.h', |
| 126 | + 'libs/openFrameworks/app/ofMainLoop.h', |
| 127 | + 'libs/openFrameworks/app/ofWindowSettings.h', |
| 128 | + 'libs/openFrameworks/communication/ofArduino.h', |
| 129 | + 'libs/openFrameworks/communication/ofSerial.h', |
| 130 | + 'libs/openFrameworks/events/ofEvent.h', |
| 131 | + 'libs/openFrameworks/events/ofEvents.h', |
| 132 | + 'libs/openFrameworks/events/ofEventUtils.h', |
| 133 | + 'libs/openFrameworks/gl/ofBufferObject.h', |
| 134 | + 'libs/openFrameworks/gl/ofCubeMap.h', |
| 135 | + 'libs/openFrameworks/gl/ofCubeMapShaders.h', |
| 136 | + 'libs/openFrameworks/gl/ofFbo.h', |
| 137 | + 'libs/openFrameworks/gl/ofGLBaseTypes.h', |
| 138 | + 'libs/openFrameworks/gl/ofGLProgrammableRenderer.h', |
| 139 | + 'libs/openFrameworks/gl/ofGLRenderer.h', |
| 140 | + 'libs/openFrameworks/gl/ofGLUtils.h', |
| 141 | + 'libs/openFrameworks/gl/ofLight.h', |
| 142 | + 'libs/openFrameworks/gl/ofMaterialBaseTypes.h', |
| 143 | + 'libs/openFrameworks/gl/ofMaterial.h', |
| 144 | + 'libs/openFrameworks/gl/ofShader.h', |
| 145 | + 'libs/openFrameworks/gl/ofShadow.h', |
| 146 | + 'libs/openFrameworks/gl/ofTexture.h', |
| 147 | + 'libs/openFrameworks/gl/ofVbo.h', |
| 148 | + 'libs/openFrameworks/gl/ofVboMesh.h', |
| 149 | + 'libs/openFrameworks/graphics/of3dGraphics.h', |
| 150 | + 'libs/openFrameworks/graphics/ofBitmapFont.h', |
| 151 | + 'libs/openFrameworks/graphics/ofCairoRenderer.h', |
| 152 | + 'libs/openFrameworks/graphics/ofGraphicsBaseTypes.h', |
| 153 | + 'libs/openFrameworks/graphics/ofGraphicsCairo.h', |
| 154 | + 'libs/openFrameworks/graphics/ofGraphicsConstants.h', |
| 155 | + 'libs/openFrameworks/graphics/ofGraphics.h', |
| 156 | + 'libs/openFrameworks/graphics/ofImage.h', |
| 157 | + 'libs/openFrameworks/graphics/ofPath.h', |
| 158 | + 'libs/openFrameworks/graphics/ofPixels.h', |
| 159 | + 'libs/openFrameworks/graphics/ofPolyline.h', |
| 160 | + 'libs/openFrameworks/graphics/ofRendererCollection.h', |
| 161 | + 'libs/openFrameworks/graphics/ofTessellator.h', |
| 162 | + 'libs/openFrameworks/graphics/ofTrueTypeFont.h', |
| 163 | + 'libs/openFrameworks/math/ofMathConstants.h', |
| 164 | + 'libs/openFrameworks/math/ofMath.h', |
| 165 | + 'libs/openFrameworks/math/ofMatrix3x3.h', |
| 166 | + 'libs/openFrameworks/math/ofMatrix4x4.h', |
| 167 | + 'libs/openFrameworks/math/ofQuaternion.h', |
| 168 | + 'libs/openFrameworks/math/ofVec2f.h', |
| 169 | + 'libs/openFrameworks/math/ofVec3f.h', |
| 170 | + 'libs/openFrameworks/math/ofVec4f.h', |
| 171 | + 'libs/openFrameworks/math/ofVectorMath.h', |
| 172 | + 'libs/openFrameworks/ofMain.h', |
| 173 | + 'libs/openFrameworks/sound/ofAVEngineSoundPlayer.h', |
| 174 | + 'libs/openFrameworks/sound/ofFmodSoundPlayer.h', |
| 175 | + 'libs/openFrameworks/sound/ofMediaFoundationSoundPlayer.h', |
| 176 | + 'libs/openFrameworks/sound/ofOpenALSoundPlayer.h', |
| 177 | + 'libs/openFrameworks/sound/ofRtAudioSoundStream.h', |
| 178 | + 'libs/openFrameworks/sound/ofSoundBaseTypes.h', |
| 179 | + 'libs/openFrameworks/sound/ofSoundBuffer.h', |
| 180 | + 'libs/openFrameworks/sound/ofSoundPlayer.h', |
| 181 | + 'libs/openFrameworks/sound/ofSoundStream.h', |
| 182 | + 'libs/openFrameworks/sound/ofSoundUtils.h', |
| 183 | + 'libs/openFrameworks/types/ofBaseTypes.h', |
| 184 | + 'libs/openFrameworks/types/ofColor.h', |
| 185 | + 'libs/openFrameworks/types/ofParameterGroup.h', |
| 186 | + 'libs/openFrameworks/types/ofParameter.h', |
| 187 | + 'libs/openFrameworks/types/ofPoint.h', |
| 188 | + 'libs/openFrameworks/types/ofRectangle.h', |
| 189 | + 'libs/openFrameworks/types/ofTypes.h', |
| 190 | + 'libs/openFrameworks/utils/ofConstants.h', |
| 191 | + 'libs/openFrameworks/utils/ofFileUtils.h', |
| 192 | + 'libs/openFrameworks/utils/ofFpsCounter.h', |
| 193 | + 'libs/openFrameworks/utils/ofJson.h', |
| 194 | + 'libs/openFrameworks/utils/ofLog.h', |
| 195 | + 'libs/openFrameworks/utils/ofMatrixStack.h', |
| 196 | + 'libs/openFrameworks/utils/ofNoise.h', |
| 197 | + 'libs/openFrameworks/utils/ofRandomDistributions.h', |
| 198 | + 'libs/openFrameworks/utils/ofRandomEngine.h', |
| 199 | + 'libs/openFrameworks/utils/ofSystemUtils.h', |
| 200 | + 'libs/openFrameworks/utils/ofThreadChannel.h', |
| 201 | + 'libs/openFrameworks/utils/ofThread.h', |
| 202 | + 'libs/openFrameworks/utils/ofTimer.h', |
| 203 | + 'libs/openFrameworks/utils/ofURLFileLoader.h', |
| 204 | + 'libs/openFrameworks/utils/ofUtils.h', |
| 205 | + 'libs/openFrameworks/utils/ofXml.h', |
| 206 | + 'libs/openFrameworks/video/ofAVFoundationGrabber.h', |
| 207 | + 'libs/openFrameworks/video/ofAVFoundationPlayer.h', |
| 208 | + 'libs/openFrameworks/video/ofAVFoundationVideoPlayer.h', |
| 209 | + 'libs/openFrameworks/video/ofDirectShowGrabber.h', |
| 210 | + 'libs/openFrameworks/video/ofDirectShowPlayer.h', |
| 211 | + 'libs/openFrameworks/video/ofGstUtils.h', |
| 212 | + 'libs/openFrameworks/video/ofGstVideoGrabber.h', |
| 213 | + 'libs/openFrameworks/video/ofGstVideoPlayer.h', |
| 214 | + 'libs/openFrameworks/video/ofMediaFoundationPlayer.h', |
| 215 | + 'libs/openFrameworks/video/ofVideoBaseTypes.h', |
| 216 | + 'libs/openFrameworks/video/ofVideoGrabber.h', |
| 217 | + 'libs/openFrameworks/video/ofVideoPlayer.h', |
| 218 | + subdir: 'openframeworks' |
| 219 | +) |
| 220 | + |
| 221 | +add_project_arguments('-D GLM_ENABLE_EXPERIMENTAL', language: 'cpp') |
| 222 | + |
| 223 | +compiler = meson.get_compiler('cpp') |
| 224 | + |
| 225 | +deps = [ |
| 226 | + dependency('assimp'), |
| 227 | + dependency('boost'), |
| 228 | + dependency('cairo'), |
| 229 | + dependency('egl'), |
| 230 | + dependency('fontconfig'), |
| 231 | + dependency('freeglut'), |
| 232 | + dependency('freetype2'), |
| 233 | + dependency('glew'), |
| 234 | + dependency('glfw3'), |
| 235 | + dependency('glm'), |
| 236 | + dependency('gstreamer-1.0'), |
| 237 | + dependency('gstreamer-app-1.0'), |
| 238 | + dependency('gstreamer-plugins-bad-1.0'), |
| 239 | + dependency('gstreamer-plugins-base-1.0'), |
| 240 | + dependency('gstreamer-video-1.0'), |
| 241 | + dependency('kissfft-float'), |
| 242 | + dependency('libcurl'), |
| 243 | + dependency('libmpg123'), |
| 244 | + dependency('libtess2'), |
| 245 | + dependency('libudev'), |
| 246 | + dependency('nlohmann_json'), |
| 247 | + dependency('openal'), |
| 248 | + dependency('pugixml'), |
| 249 | + dependency('rtaudio'), |
| 250 | + dependency('sndfile'), |
| 251 | + dependency('uriparser'), |
| 252 | + dependency('utf8cpp'), |
| 253 | + dependency('x11-xcb'), |
| 254 | + dependency('xcursor'), |
| 255 | + compiler.find_library('freeimage', has_headers: ['FreeImage.h']), |
| 256 | +] |
| 257 | + |
| 258 | +lib = library('openFrameworks', |
| 259 | + sources, |
| 260 | + include_directories: inc, |
| 261 | + dependencies: deps, |
| 262 | + install: true) |
| 263 | + |
| 264 | +openframeworks_dep = declare_dependency(link_with: lib, include_directories: inc, dependencies: deps) |
| 265 | + |
| 266 | +meson.override_dependency('openFrameworks', openframeworks_dep) |
| 267 | + |
| 268 | +pkg = import('pkgconfig') |
| 269 | +pkg.generate(lib) |
0 commit comments