File: CMakeLists.txt

package info (click to toggle)
amarok 3.3.1-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 112,168 kB
  • sloc: cpp: 195,056; xml: 4,322; ansic: 2,634; javascript: 673; ruby: 528; python: 507; sh: 252; makefile: 12
file content (61 lines) | stat: -rw-r--r-- 1,567 bytes parent folder | download
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
58
59
60
61
macro(link_database_test test_target)
    if(APPLE)
        set_target_properties(${test_target} PROPERTIES LINK_FLAGS "-undefined dynamic_lookup")
    endif()

    add_dependencies( ${test_target} amarokconfig_h )
    add_dependencies( ${test_target} amarokcore )
    add_dependencies( ${test_target} amaroklib)

    target_link_libraries(${test_target}
        amarokcore
        amaroklib
        KF${KF_MAJOR_VERSION}::KIOCore
        KF${KF_MAJOR_VERSION}::ThreadWeaver
        Qt::Test
        Qt::Core
        ${MYSQL_LIBRARIES}
        ${CMAKE_DL_LIBS}
#        ${TAGLIB_LIBRARIES}
    )

endmacro(link_database_test)


include_directories(
  ${AMAROK_TEST_TREE}
  ${AMAROK_SOURCE_TREE}
  # ${AMAROK_SOURCE_TREE}/core-impl/logger
  ${AMAROK_UTILITY_TREE}
  ${CMAKE_BINARY_DIR}/src
  ${CMAKE_BINARY_DIR}/tests
  ${AMAROK_COLLECTION_SUPPORT_DIR}
)

include_directories(SYSTEM
  ${MYSQL_INCLUDE_DIR}
  )

#------------------------------- DynamicModel Test -------------------------------

set( dynamicmodel_SRCS
        TestDynamicModel.cpp
    )

add_executable( testdynamicmodel ${dynamicmodel_SRCS} )
add_test(NAME testdynamicmodel COMMAND $<TARGET_FILE:testdynamicmodel>)
ecm_mark_as_test(testdynamicmodel)
link_database_test( testdynamicmodel )

#------------------------------- TrackSet Test -------------------------------

set( trackset_SRCS
        TestTrackSet.cpp
    )

add_executable( testtrackset ${trackset_SRCS} )
add_test(NAME testtrackset COMMAND $<TARGET_FILE:testtrackset>)
ecm_mark_as_test(testtrackset)
link_database_test( testtrackset )