Skip to content

Commit 4247a4e

Browse files
authored
Add a build support for mac/aarch64 (#109)
* macos aarch64 build support
1 parent 1329839 commit 4247a4e

File tree

2 files changed

+19
-1
lines changed

2 files changed

+19
-1
lines changed

pom.xml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -306,6 +306,19 @@
306306
<platform.module>webrtc.macos.x86_64</platform.module>
307307
</properties>
308308
</profile>
309+
<profile>
310+
<id>mac-aarch64</id>
311+
<activation>
312+
<os>
313+
<family>mac</family>
314+
<arch>aarch64</arch>
315+
</os>
316+
</activation>
317+
<properties>
318+
<platform.classifier>macos-aarch64</platform.classifier>
319+
<platform.module>webrtc.macos.aarch64</platform.module>
320+
</properties>
321+
</profile>
309322
</profiles>
310323

311324
<reporting>

webrtc-jni/src/main/cpp/dependencies/webrtc/CMakeLists.txt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
cmake_minimum_required(VERSION 3.13)
1+
cmake_minimum_required(VERSION 3.13)
22
project(webrtc)
33

44
FILE(WRITE ${CMAKE_CURRENT_BINARY_DIR}/pseudo.hxx
@@ -14,6 +14,10 @@ if(NOT DEFINED TARGET_CPU)
1414
elseif(CMAKE_SIZEOF_VOID_P EQUAL 8)
1515
set(TARGET_CPU "x64")
1616
endif()
17+
18+
if(${CMAKE_SYSTEM_PROCESSOR} MATCHES "aarch64")
19+
set(TARGET_CPU "${CMAKE_SYSTEM_PROCESSOR}")
20+
endif()
1721
endif()
1822

1923
if(NOT DEFINED WEBRTC_BRANCH)
@@ -254,3 +258,4 @@ install(CODE "
254258
endif()
255259
endforeach()
256260
")
261+

0 commit comments

Comments
 (0)