ubuntu20.04源码安装scrcpy
时间: 2023-10-17 19:28:49 浏览: 144
详解ubuntu 20.04 LTS安装记录
对于Ubuntu 20.04,您可以按照以下步骤从源码安装scrcpy:
1. 首先,请确保您的系统已经安装了所需的依赖关系。在终端中运行以下命令来安装这些依赖项:
```bash
sudo apt install git pkg-config meson ninja-build libsdl2-dev ffmpeg libavcodec-dev libavformat-dev libavutil-dev libswscale-dev adb
```
2. 下载scrcpy的源代码。您可以通过以下命令将源代码克隆到本地:
```bash
git clone https://github.com/Genymobile/scrcpy.git
```
3. 进入源代码目录:
```bash
cd scrcpy
```
4. 编译源代码并生成可执行文件:
```bash
meson x --buildtype release --strip -Db_lto=true
ninja -Cx
```
5. 安装scrcpy:
```bash
sudo ninja -Cx install
#### 引用[.reference_title]
- *1* *2* *3* [ubuntu18.04 安装 scrcpy 遇到的坑](https://blog.csdn.net/ameyume/article/details/107239215)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 100%"]
[ .reference_list ]
阅读全文