diff options
author | Slávek Banko <[email protected]> | 2013-05-12 12:26:39 +0200 |
---|---|---|
committer | Slávek Banko <[email protected]> | 2013-05-12 12:29:14 +0200 |
commit | 5fc2ad73cc00132503b3cf958327be19ca3a695a (patch) | |
tree | 64998c1af72c19a2ffee419cccdd13e43a8af382 | |
parent | 8bad2664cb6f8ab191d44647937acfd45b977920 (diff) | |
download | amarok-5fc2ad73cc00132503b3cf958327be19ca3a695a.tar.gz amarok-5fc2ad73cc00132503b3cf958327be19ca3a695a.zip |
Add cmake support for mp4v2
-rw-r--r-- | CMakeLists.txt | 1 | ||||
-rw-r--r-- | ConfigureChecks.cmake | 20 | ||||
-rw-r--r-- | amarok/src/metadata/m4a/CMakeLists.txt | 5 | ||||
-rw-r--r-- | amarok/src/metadata/mp4/CMakeLists.txt | 33 | ||||
-rw-r--r-- | config.h.cmake | 4 |
5 files changed, 60 insertions, 3 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 0a095c86..6080c379 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -54,6 +54,7 @@ option( WITH_NJB "Enable njb support" OFF ) option( WITH_MTP "Enable mtp support" OFF ) option( WITH_RIOKARMA "Enable riokarma support" OFF ) option( WITH_DAAP "Enable daap support" OFF ) +option( WITH_MP4V2 "Enable mp4v2 support" OFF ) option( WITH_INOTIFY "Enable inotify support" OFF ) diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake index 377fa4d3..d6891aa7 100644 --- a/ConfigureChecks.cmake +++ b/ConfigureChecks.cmake @@ -222,3 +222,23 @@ if( WITH_KONQSIDEBAR ) tde_message_fatal( "konqsidebarplugin.h are requested, but not found on your system" ) endif( ) endif( ) + +##### check for mp4v2 ########################### + +if( WITH_MP4V2 ) + check_include_file( "mp4v2/mp4v2.h" MP4V2_H_FOUND ) + if( MP4V2_H_FOUND ) + set( HAVE_MP4V2_H 1) + else( MP4V2_H_FOUND ) + check_include_file( "mp4.h" MP4_H_FOUND ) + if( MP4_H_FOUND ) + set( HAVE_MP4_H 1) + endif( MP4_H_FOUND ) + endif( MP4V2_H_FOUND ) + + if( HAVE_MP4V2_H OR HAVE_MP4_H ) + set( HAVE_MP4V2 1 ) + else( ) + tde_message_fatal( "MP4V2 support was requested, but not found on your system" ) + endif( ) +endif( ) diff --git a/amarok/src/metadata/m4a/CMakeLists.txt b/amarok/src/metadata/m4a/CMakeLists.txt index ea1f4046..0043d271 100644 --- a/amarok/src/metadata/m4a/CMakeLists.txt +++ b/amarok/src/metadata/m4a/CMakeLists.txt @@ -10,15 +10,16 @@ ################################################# include_directories( + ${CMAKE_BINARY_DIR} ${TDE_INCLUDE_DIR} ${TQT_INCLUDE_DIRS} ${TAGLIB_INCLUDE_DIRS} ) -##### tagmp4 (static) ########################### +##### tagm4a (static) ########################### -tde_add_library( tagmp4 STATIC_PIC +tde_add_library( tagm4a STATIC_PIC SOURCES taglib_mp4filetyperesolver.cpp mp4file.cpp mp4itunestag.cpp mp4isobox.cpp mp4isofullbox.cpp mp4skipbox.cpp mp4moovbox.cpp mp4mvhdbox.cpp diff --git a/amarok/src/metadata/mp4/CMakeLists.txt b/amarok/src/metadata/mp4/CMakeLists.txt new file mode 100644 index 00000000..a3149dd2 --- /dev/null +++ b/amarok/src/metadata/mp4/CMakeLists.txt @@ -0,0 +1,33 @@ +################################################# +# +# (C) 2010-2013 Darrell Anderson +# humanreadable (AT) yahoo.com +# +# Improvements and feedback are welcome +# +# This file is released under GPL >= 2 +# +################################################# + +include_directories( + ${CMAKE_BINARY_DIR} + ${TDE_INCLUDE_DIR} + ${TQT_INCLUDE_DIRS} + ${TAGLIB_INCLUDE_DIRS} + ${MP4V2_INCLUDE_DIRS} +) + +link_directories( + ${MP4V2_LIBRARY_DIRS} +) + + +##### tagmp4 (static) ########################### + +tde_add_library( tagmp4 STATIC_PIC + SOURCES + mp4file.cpp mp4file.h mp4properties.cpp mp4properties.h mp4tag.cpp mp4tag.h + taglib_mp4filetyperesolver.cpp taglib_mp4filetyperesolver.h + LINK + mp4v2 +) diff --git a/config.h.cmake b/config.h.cmake index b895f46f..caddad59 100644 --- a/config.h.cmake +++ b/config.h.cmake @@ -12,8 +12,10 @@ #cmakedefine HAVE_ITDB_MEDIATYPE 1 #cmakedefine HAVE_LIBGPOD_060 1 #cmakedefine HAVE_MP4V2 1 +#cmakedefine HAVE_MP4V2_H 1 +#cmakedefine HAVE_MP4_H 1 #cmakedefine HAVE_TUNEPIMP 1 #cmakedefine TAGLIB_15 1 #cmakedefine HAVE_QGLWIDGET 1 -#cmakedefine HAVE_OLD_RUBY @HAVE_OLD_RUBY@
\ No newline at end of file +#cmakedefine HAVE_OLD_RUBY @HAVE_OLD_RUBY@ |