forked from bilibili/ijkplayer
-
Notifications
You must be signed in to change notification settings - Fork 92
/
CMakeLists.txt
63 lines (55 loc) · 2.11 KB
/
CMakeLists.txt
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
62
63
#
# Copyright (c) 2019 Befovy <befovy@gmail.com>
#
# This file is part of fijkPlayer.
#
# fijkPlayer is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 2.1 of the License, or (at your option) any later version.
#
# fijkPlayer is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with ijkPlayer; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
#
cmake_minimum_required(VERSION 3.5)
if (NOT DEFINED FIJKROOT_PATH)
set(FIJKROOT_PATH ${CMAKE_CURRENT_LIST_DIR}/../)
endif ()
if (IJK_DESKTOP_UNI)
add_subdirectory(portaudio)
add_subdirectory(ijkyuv)
target_compile_options(portaudio_static PRIVATE "-Wno-deprecated-declarations")
target_compile_options(portaudio PRIVATE "-Wno-deprecated-declarations")
endif ()
add_subdirectory(ijksdl)
add_subdirectory(ijkplayer)
set(GIT_DESCRIBE "unknown, dose not found git")
execute_process(
COMMAND git describe --dirty
OUTPUT_VARIABLE GIT_DESCRIBE
OUTPUT_STRIP_TRAILING_WHITESPACE
# ERROR_QUIET
WORKING_DIRECTORY ${CMAKE_CURRENT_LIST_DIR}
)
configure_file(ijkplayer/ijkversion.h.in ${CMAKE_CURRENT_LIST_DIR}/ijkplayer/ijkversion.h @ONLY)
if (ANDROID)
add_subdirectory(ijksoundtouch)
add_subdirectory(ijkyuv)
add_subdirectory(ijkj4a)
# just a dummy android ndk prifiler
option(ANDROID_NDK_PROFILER OFF)
if (NDK_PROFILER)
# not implemented yet
message(FATAL_ERROR "not implemented yet, android-ndk-profiler")
add_subdirectory(../ijkprof/android-ndk-profiler/jni ijkprof)
else ()
add_subdirectory(../ijkprof/android-ndk-profiler-dummy/jni ijkprof)
endif (NDK_PROFILER)
# add_dependencies(ijkplayer android-ndk-profiler)
endif ()