在deepin上安装scrcpy--安卓投屏软件

1.效果

  • 1.游戏界面
    在这里插入图片描述

2.安装

  • 1.大佬可以尝试从源码安装,源码地址:https://github.com/Genymobile/scrcpy
  • 2.使用snap安装需要先装snap(安装之前可先换一下源,见文末)

    sudo apt-get install snapd

  • 3.使用snap安装scrcpy

    sudo snap install scrcpy

  • 4.有时会提示缺少core18库,或者提示
    error: could not install *smartsocket* listener: Operation not permitted
    
    • 别慌,安装一下core就行

    sudo snap install core

  • 5.有时运行还是会提示找不到[adb]和其他一些jar文件以及一些依赖的库,这些都可以在/snap中进行查找,然后添加到系统环境变量

    在这里插入图片描述

    • 添加到系统目录或修改环境变量

    sudo cp /snap/scrcpy/136/usr/local/share/scrcpy/scrcpy-server.jar /usr/local/bin/
    sudo vim /etc/profile

    • 在文件尾加上:
        export PATH=$PATH:/snap/scrcpy/136/usr/bin/
        export LD_LIBRARY_PATH=/snap/scrcpy/136/usr/lib/x86_64-linux-gnu/android/:$LD_LIBRARY_PATH
      
    • 保存退出,重启或注销重新登录
  • 6.用数据线连接手机和电脑(手机需要打开USB调试开关),在终端输入(其中一个命令)

    snap run scrcpy
    scrcpy


3.其他问题

  • 刚安装好系统安装前记得换一下源,不然下载很慢,比如下面这个(替换 /etc/apt/sources.list)
# deb cdrom:[Ubuntu 16.04 LTS _Xenial Xerus_ - Release amd64 (20160420.1)]/ xenial main restricted
deb-src http://archive.ubuntu.com/ubuntu xenial main restricted #Added by software-properties
deb http://mirrors.aliyun.com/ubuntu/ xenial main restricted
deb-src http://mirrors.aliyun.com/ubuntu/ xenial main restricted multiverse universe #Added by software-properties
deb http://mirrors.aliyun.com/ubuntu/ xenial-updates main restricted
deb-src http://mirrors.aliyun.com/ubuntu/ xenial-updates main restricted multiverse universe #Added by software-properties
deb http://mirrors.aliyun.com/ubuntu/ xenial universe
deb http://mirrors.aliyun.com/ubuntu/ xenial-updates universe
deb http://mirrors.aliyun.com/ubuntu/ xenial multiverse
deb http://mirrors.aliyun.com/ubuntu/ xenial-updates multiverse
deb http://mirrors.aliyun.com/ubuntu/ xenial-backports main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ xenial-backports main restricted universe multiverse #Added by software-properties
deb http://archive.canonical.com/ubuntu xenial partner
deb-src http://archive.canonical.com/ubuntu xenial partner
deb http://mirrors.aliyun.com/ubuntu/ xenial-security main restricted
deb-src http://mirrors.aliyun.com/ubuntu/ xenial-security main restricted multiverse universe #Added by software-properties
deb http://mirrors.aliyun.com/ubuntu/ xenial-security universe
deb http://mirrors.aliyun.com/ubuntu/ xenial-security multiverse
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值