Skip to content

Commit

Permalink
[core] Removed deprecated ANDROID macro (#1684).
Browse files Browse the repository at this point in the history
Removed unused ANDROID define from CMake config
  • Loading branch information
sergeiignatov authored Dec 1, 2020
1 parent 03dafd8 commit d3ad2a4
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
3 changes: 1 addition & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -564,8 +564,7 @@ elseif(LINUX)
message(STATUS "DETECTED SYSTEM: LINUX; LINUX=1" )
elseif(ANDROID)
add_definitions(-DLINUX=1)
add_definitions(-DANDROID=1)
message(STATUS "DETECTED SYSTEM: ANDROID; LINUX=1 ANDROID=1" )
message(STATUS "DETECTED SYSTEM: ANDROID; LINUX=1" )
elseif(CYGWIN)
add_definitions(-DCYGWIN=1)
message(STATUS "DETECTED SYSTEM: CYGWIN (posix mode); CYGWIN=1")
Expand Down
2 changes: 1 addition & 1 deletion srtcore/platform_sys.h
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@

#endif

#if defined(__ANDROID__) || defined(ANDROID)
#ifdef __ANDROID__

#ifdef SRT_IMPORT_EVENT
#include <sys/select.h>
Expand Down
4 changes: 2 additions & 2 deletions srtcore/sync_posix.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -370,13 +370,13 @@ srt::sync::CThread& srt::sync::CThread::operator=(CThread& other)
LOGC(inlog.Error, log << "IPE: Assigning to a thread that is not terminated!");

#ifndef DEBUG
#ifndef ANDROID
#ifndef __ANDROID__
// In case of production build the hanging thread should be terminated
// to avoid hang ups and align with C++11 implementation.
// There is no pthread_cancel on Android. See #1476. This error should not normally
// happen, but if it happen, then detaching the thread.
pthread_cancel(m_thread);
#endif // ANDROID
#endif // __ANDROID__
#else
join();
#endif
Expand Down

0 comments on commit d3ad2a4

Please sign in to comment.