blob: 6aea0e3c1635f945587207f8b34801559f864c8a (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
|
project(libvorbis)
# qt plugin
ADD_DEFINITIONS( -Wall )
ADD_DEFINITIONS(${QT_DEFINITIONS})
ADD_DEFINITIONS(-DQT_PLUGIN)
ADD_DEFINITIONS(-DQT_NO_DEBUG)
ADD_DEFINITIONS(-DQT_SHARED)
ADD_DEFINITIONS(-DQT_THREAD)
include_directories(${CMAKE_CURRENT_BINARY_DIR})
SET(QT_INCLUDES
${QT_INCLUDES}
${CMAKE_CURRENT_SOURCE_DIR}/../../../
)
# libqmmp
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/../../../)
link_directories(${CMAKE_CURRENT_BINARY_DIR}/../../../qmmp)
# libvorbis and taglib
pkg_check_modules(VORBIS ogg vorbis vorbisfile)
include_directories(${VORBIS_INCLUDE_DIRS} ${TAGLIB_INCLUDE_DIRS})
link_directories(${VORBIS_LIBRARY_DIRS} ${TAGLIB_LIBRARY_DIRS})
ADD_DEFINITIONS(${VORBIS_CFLAGS} ${TAGLIB_CFLAGS})
SET(libvorbis_SRCS
decoder_vorbis.cpp
decodervorbisfactory.cpp
vorbismetadatamodel.cpp
replaygainreader.cpp
)
SET(libvorbis_HDRS
decoder_vorbis.h
replaygainreader.h
)
SET(libvorbis_RCCS translations/translations.qrc)
QT4_ADD_RESOURCES(libvorbis_RCC_SRCS ${libvorbis_RCCS})
# user interface
QT4_WRAP_UI(libvorbis_UIS_H ${libvorbis_UIS})
# Don't forget to include output directory, otherwise
# the UI file won't be wrapped!
include_directories(${CMAKE_CURRENT_BINARY_DIR})
IF(VORBIS_FOUND)
ADD_LIBRARY(vorbis MODULE ${libvorbis_SRCS} ${libvorbis_RCC_SRCS} ${libvorbis_HDRS})
add_dependencies(vorbis qmmp)
target_link_libraries(vorbis ${QT_LIBRARIES} libqmmp ${VORBIS_LDFLAGS} ${TAGLIB_LDFLAGS})
install(TARGETS vorbis DESTINATION ${LIB_DIR}/qmmp/Input)
ENDIF(VORBIS_FOUND)
|