~ubuntu-branches/ubuntu/utopic/mir/utopic-proposed

« back to all changes in this revision

Viewing changes to src/platform/graphics/android/CMakeLists.txt

  • Committer: Package Import Robot
  • Author(s): Ubuntu daily release
  • Date: 2014-03-10 19:28:46 UTC
  • mto: This revision was merged to the branch mainline in revision 63.
  • Revision ID: package-import@ubuntu.com-20140310192846-rq9qm3ec26yrelo2
Tags: upstream-0.1.6+14.04.20140310
ImportĀ upstreamĀ versionĀ 0.1.6+14.04.20140310

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
    ${GLESv2_INCLUDE_DIRS}
5
5
)
6
6
 
 
7
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fpermissive")
 
8
add_definitions( -DANDROID )
 
9
 
7
10
add_library(
8
 
  mirplatformgraphics SHARED
 
11
  mirplatformgraphicsandroid SHARED
9
12
 
10
13
  android_platform.cpp
11
14
  android_buffer_allocator.cpp
31
34
  gl_context.cpp
32
35
)
33
36
 
 
37
set_target_properties(
 
38
  mirplatformgraphicsandroid PROPERTIES
 
39
  OUTPUT_NAME mirplatformgraphics
 
40
  LIBRARY_OUTPUT_DIRECTORY ${LIBRARY_OUTPUT_PATH}/android
 
41
)
 
42
 
34
43
target_link_libraries(
35
 
  mirplatformgraphics
 
44
  mirplatformgraphicsandroid
36
45
 
37
46
  mirplatform
38
47
  mirsharedandroid
42
51
  ${GLESv2_LDFLAGS} ${GLESv2_LIBRARIES}
43
52
)
44
53
 
45
 
install(TARGETS mirplatformgraphics LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})
 
54
if (MIR_TEST_PLATFORM STREQUAL "android")
 
55
  add_custom_command(TARGET mirplatformgraphicsandroid
 
56
    POST_BUILD
 
57
    COMMAND ${CMAKE_COMMAND} -E remove libmirplatformgraphics.so
 
58
    COMMAND ${CMAKE_COMMAND} -E create_symlink android/$<TARGET_FILE_NAME:mirplatformgraphicsandroid> libmirplatformgraphics.so
 
59
    WORKING_DIRECTORY ${LIBRARY_OUTPUT_PATH}
 
60
  )
 
61
endif()
 
62
 
 
63
install(TARGETS mirplatformgraphicsandroid LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/mir/platformgraphics/android)