7 find_package(OpenGL REQUIRED)
9 find_package(SDL REQUIRED)
11 macro_optional_find_package(Nepomuk)
12 macro_optional_find_package(QJSON)
14 option(WITH_V4L "Build capture support with Video4Linux" ON)
15 option(WITH_JogShuttle "Build Jog/Shuttle support" ON)
16 option(WITH_BlackMagic "Build Blackmagic Decklinkl support" ON)
19 # This can be changed to support FreeBSD as soon as we move to a newer V4L2
21 check_include_files(linux/ioctl.h HAVE_LINUX_IOCTL_H)
22 if(HAVE_LINUX_IOCTL_H)
24 endif(HAVE_LINUX_IOCTL_H)
28 check_include_files(linux/input.h HAVE_LINUX_INPUT_H)
29 if(HAVE_LINUX_INPUT_H)
30 set(BUILD_JogShuttle TRUE)
31 endif(HAVE_LINUX_INPUT_H)
32 endif(WITH_JogShuttle)
35 set(BUILD_BlackMagic TRUE)
36 endif(WITH_BlackMagic)
38 macro_log_feature(QT_QTOPENGL_FOUND
40 "Qt bindings for the OpenGL library"
41 "http://qt.nokia.com/products/qt"
44 "QtOpenGL library and headers (most likely called libqt4-opengl and libqt4-opengl-dev)"
47 macro_log_feature(QT_QTSCRIPT_FOUND
49 "Qt module providing core scripting facilities"
50 "http://qt.nokia.com/products/qt"
53 "QtScript library (most likely called libqt4-script)"
57 macro_log_feature(SDL_FOUND
59 "Cross-platform multimedia library"
60 "http://www.libsdl.org"
65 macro_log_feature(Nepomuk_FOUND
67 "Support for the Nepomuk semantic desktop system"
68 "http://nepomuk.semanticdesktop.org"
71 macro_log_feature(QJSON_FOUND
73 "Qt-based library that maps JSON data to QVariant objects"
74 "http://qjson.sourceforge.net"
77 "Required to build the rotoscoping filter and for Freesound.org queries"
81 add_subdirectory(audioscopes)
82 add_subdirectory(beziercurve)
83 add_subdirectory(colorcorrection)
84 add_subdirectory(colorscopes)
85 add_subdirectory(commands)
86 add_subdirectory(projecttree)
87 add_subdirectory(utils)
88 add_subdirectory(databackup)
89 add_subdirectory(kiss_fft)
90 add_subdirectory(mimetypes)
91 add_subdirectory(onmonitoritems)
92 add_subdirectory(simplekeyframes)
93 add_subdirectory(stopmotion)
96 add_subdirectory(onmonitoritems/rotoscoping)
97 add_subdirectory(rotoscoping)
101 add_subdirectory(v4l)
105 add_subdirectory(blackmagic)
106 endif(BUILD_BlackMagic)
108 list(APPEND kdenlive_SRCS
114 abstractgroupitem.cpp
116 abstractscopewidget.cpp
119 choosecolorwidget.cpp
120 clipdurationdialog.cpp
126 colorpickerwidget.cpp
136 documentvalidator.cpp
137 doubleparameterwidget.cpp
140 dvdwizardchapters.cpp
145 effectslistwidget.cpp
148 encodingprofilesdialog.cpp
149 folderprojectitem.cpp
153 graphicsscenerectmove.cpp
158 kdenlivesettingsdialog.cpp
164 managecapturesdialog.cpp
168 monitoreditwidget.cpp
185 statusbarmessagelabel.cpp
192 tracksconfigdialog.cpp
195 transitionsettings.cpp
200 kde4_add_ui_files(kdenlive_UIS
201 widgets/addtrack_ui.ui
202 widgets/archivewidget_ui.ui
203 widgets/audiospectrum_ui.ui
204 widgets/backupdialog_ui.ui
205 widgets/bezierspline_ui.ui
206 widgets/boolval_ui.ui
207 widgets/clipdurationdialog_ui.ui
208 widgets/clipproperties_ui.ui
209 widgets/cliptranscode_ui.ui
210 widgets/clipstabilize_ui.ui
211 widgets/colorclip_ui.ui
212 widgets/colorplaneexport_ui.ui
213 widgets/configcapture_ui.ui
214 widgets/configenv_ui.ui
215 widgets/configjogshuttle_ui.ui
216 widgets/configmisc_ui.ui
217 widgets/configproject_ui.ui
218 widgets/configsdl_ui.ui
219 widgets/configtimeline_ui.ui
220 widgets/configtranscode_ui.ui
221 widgets/dvdwizardchapters_ui.ui
222 widgets/dvdwizardmenu_ui.ui
223 widgets/dvdwizardstatus_ui.ui
224 widgets/dvdwizardvob_ui.ui
225 widgets/effectlist_ui.ui
226 widgets/effectstack_ui.ui
227 widgets/freesound_ui.ui
228 widgets/geometryval_ui.ui
229 widgets/geometrywidget_ui.ui
230 widgets/histogram_ui.ui
231 widgets/keyframedialog_ui.ui
232 widgets/keyframeeditor_ui.ui
233 widgets/keyframewidget_ui.ui
234 widgets/listval_ui.ui
235 widgets/managecaptures_ui.ui
236 widgets/manageencodingprofile_ui.ui
237 widgets/markerdialog_ui.ui
238 widgets/missingclips_ui.ui
239 widgets/monitoreditwidget_ui.ui
240 widgets/profiledialog_ui.ui
241 widgets/projectsettings_ui.ui
242 widgets/recmonitor_ui.ui
243 widgets/renderwidget_ui.ui
244 widgets/rgbparade_ui.ui
245 widgets/saveprofile_ui.ui
246 widgets/slideshowclip_ui.ui
247 widgets/smconfig_ui.ui
248 widgets/spacerdialog_ui.ui
249 widgets/spectrogram_ui.ui
250 widgets/stopmotion_ui.ui
251 widgets/templateclip_ui.ui
252 widgets/timeline_ui.ui
253 widgets/timelinebuttons_ui.ui
254 widgets/titlewidget_ui.ui
255 widgets/trackheader_ui.ui
256 widgets/tracksconfigdialog_ui.ui
257 widgets/transitionsettings_ui.ui
258 widgets/unicodedialog_ui.ui
260 widgets/vectorscope_ui.ui
261 widgets/waveform_ui.ui
262 widgets/wipeval_ui.ui
263 widgets/wizardcapture_ui.ui
264 widgets/wizardcheck_ui.ui
265 widgets/wizardextra_ui.ui
266 widgets/wizardmltcheck_ui.ui
267 widgets/wizardstandard_ui.ui
268 widgets/keywordval_ui.ui
269 widgets/fontval_ui.ui
270 widgets/cutjobdialog_ui.ui
274 list(APPEND kdenlive_SRCS videoglwidget.cpp)
278 list(APPEND kdenlive_SRCS
283 endif(BUILD_JogShuttle)
285 kde4_add_kcfg_files(kdenlive_SRCS kdenlivesettings.kcfgc)
286 qt4_add_dbus_adaptor(kdenlive_SRCS
287 org.kdenlive.MainWindow.xml
291 qt4_add_resources(kdenlive_SRCS widgets/resources.qrc)
292 kde4_add_executable(kdenlive
297 # To compile kiss_fft.
298 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} --std=c99")
300 # KDE definitions and include directories *must* always come first, Qt follows
301 # (to avoid breaking builds when KDE and/or Qt are installed to different
303 add_definitions(${KDE4_DEFINITIONS})
307 ${KDE4_INCLUDES} # Adds Qt include directories too.
308 ${LIBMLT_INCLUDE_DIR}
309 ${LIBMLTPLUS_INCLUDE_DIR}
312 # Adds Qt definitions and include directories, and sets QT_LIBRARIES according
313 # to the components requested in find_package().
314 include(${QT_USE_FILE})
316 if(${KDE_VERSION} VERSION_LESS 4.3.80)
317 set(KDE4_KNEWSTUFF_LIBS ${KDE4_KNEWSTUFF2_LIBS})
318 else(${KDE_VERSION} VERSION_LESS 4.3.80)
319 set(KDE4_KNEWSTUFF_LIBS ${KDE4_KNEWSTUFF3_LIBS})
320 endif(${KDE_VERSION} VERSION_LESS 4.3.80)
322 target_link_libraries(kdenlive
325 ${KDE4_KNEWSTUFF_LIBS}
326 ${KDE4_KNOTIFYCONFIG_LIBRARY}
331 ${LIBMLTPLUS_LIBRARY}
333 ${CMAKE_THREAD_LIBS_INIT}
337 include_directories(${X11_Xlib_INCLUDE_PATH})
338 target_link_libraries(kdenlive ${X11_LIBRARIES})
341 if(OPENGL_FOUND AND QT_QTOPENGL_FOUND)
342 add_definitions(-DUSE_OPENGL)
343 target_link_libraries(kdenlive ${OPENGL_LIBRARIES})
344 endif(OPENGL_FOUND AND QT_QTOPENGL_FOUND)
347 target_link_libraries(kdenlive ${SDL_LIBRARY})
351 add_definitions(-DUSE_NEPOMUK)
352 include_directories(${NEPOMUK_INCLUDES})
353 target_link_libraries(kdenlive ${NEPOMUK_LIBRARIES})
357 add_definitions(-DUSE_QJSON)
358 include_directories(${QJSON_INCLUDE_DIR})
359 target_link_libraries(kdenlive ${QJSON_LIBRARIES})
363 add_definitions(-DUSE_V4L)
367 add_definitions(-DUSE_BLACKMAGIC)
368 endif(BUILD_BlackMagic)
371 add_definitions(-DUSE_JOGSHUTTLE)
372 endif(BUILD_JogShuttle)
374 install(TARGETS kdenlive DESTINATION ${BIN_INSTALL_DIR})
378 DESTINATION ${DATA_INSTALL_DIR}/kdenlive
380 install(FILES kdenlivesettings.kcfg DESTINATION ${KCFG_INSTALL_DIR})
382 kdenlive_projectprofiles.knsrc
383 kdenlive_renderprofiles.knsrc
384 kdenlive_titles.knsrc
386 kdenlivetranscodingrc
387 DESTINATION ${CONFIG_INSTALL_DIR}
389 kde4_install_icons(${ICON_INSTALL_DIR})
390 install(FILES kdenlive.desktop DESTINATION ${XDG_APPS_INSTALL_DIR})