oneplus3tlineage14android7_1">oneplus3t-lineage-14编译-android7
1
清华linageos镜像
x
lineage-14.1-20180223-nightly-oneplus3-signed.zip
ntfs分区挂载为普通用户目录 , ext4分区挂载为普通用户目录
bfsu/lineageOS镜像
ts/lingeageOS镜像
oneplus3/lineage-build-simple-manual.md, manifest-parser/git-repo#6_build, LineageOS16_oneplus3t_gitRepoLs_clone_desc.pdf
LineageOS/android.git/cm-14.1 : 改为bfsu镜像
高通私有驱动 TheMuppets/proprietary_vendor_oneplus.git/cm-14.1/oneplus3 == TheMuppets/proprietary_vendor_oneplus/.git/8b8001
1. 仓库群下载工具准备
D=/OP3Los14Build
cd $Dgit clone -b v2.50.1 https://mirrors.tuna.tsinghua.edu.cn/git/git-repo
#file /OP3Los14Build/git-repo/.git/config
#file /OP3Los14Build/git-repo/repoexport GitRepoD=/OP3Los14Build/git-repo
export PATH_BASE=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
export PATH=$PATH_BASE:$GitRepoDwhich repo # == /OP3Los14Build/git-repo/repo
2. 仓库群下载
LosVer=cm-14.1#repo init -u https://mirrors.tuna.tsinghua.edu.cn/git/lineageOS/LineageOS/android.git -b cm-14.1 --git-lfsexport REPO_URL='https://mirrors.tuna.tsinghua.edu.cn/git/git-repo'
#manifest_repo=https://mirrors.tuna.tsinghua.edu.cn/git/lineageOS/LineageOS/android.git
#manifest_repo=https://mirrors.bfsu.edu.cn/git/lineageOS/LineageOS/android.git
manifest_repo=https://gitlab.com/cm-14/android.git #已修改AOSP为国内镜像
repo init --manifest-url $manifest_repo --manifest-branch $LosVer --git-lfsrepo sync
3. 下载oneplus3相关仓库
packages/resources/devicesettings
git clone -b $LosVer https://githubfast.com/LineageOS/android_packages_resources_devicesettings.git $D/packages/resources/devicesettings
oneplus3高通私有驱动(vendor)下载 方法1: 不用此法
下载 git仓库,但仓库有将近10个GB,因此不用此方法
注意: 目录TheMuppets-proprietary_vendor_oneplus
不要放在 /OP3Los14Build
下, 否则 会被 mka showcommands bacon
认为和 软链接/OP3Los14Build/vendor/oneplus/oneplus3
重复了。 这可能是cm-14.1的问题, 貌似 LinageOS-16无此问题.
#命令目标: 构造软链接: $D/vendor/oneplus/oneplus3 --> /app/TheMuppets-proprietary_vendor_oneplus/oneplus3#D=/OP3Los14Build
#LosVer=cm-14.1
proprD=/app
proprietary_vendor_oneplus=$proprD/TheMuppets-proprietary_vendor_oneplus
git clone https://githubfast.com/TheMuppets/proprietary_vendor_oneplus.git -b $LosVer $proprietary_vendor_oneplus
#命令展开: git clone https://githubfast.com/TheMuppets/proprietary_vendor_oneplus.git -b cm-14.1 /app/TheMuppets-proprietary_vendor_oneplus
ln -s $proprietary_vendor_oneplus/oneplus3 $D/vendor/oneplus/oneplus3
#命令展开:ln -s /app/TheMuppets-proprietary_vendor_oneplus/oneplus3 /OP3Los14Build/vendor/oneplus/oneplus3
oneplus3高通私有驱动(vendor)下载: 方法2: git仓库给定版本包
注意: 目录proprietary_vendor_oneplus-cm-14.1
不要放在 /OP3Los14Build
下, 否则 会被 mka showcommands bacon
认为和 软链接/OP3Los14Build/vendor/oneplus/oneplus3
重复了。 这可能是cm-14.1的问题, 貌似 LinageOS-16无此问题.
#命令目标: 构造软链接: $D/vendor/oneplus/oneplus3 --> /app/proprietary_vendor_oneplus-cm-14.1/oneplus3#D=/OP3Los14Build
#LosVer=cm-14.1
proprD=/app
wget --output-document=$D/cm-14.1.zip https://github.com/TheMuppets/proprietary_vendor_oneplus/archive/refs/heads/$LosVer.zip
#命令展开: wget https://github.com/TheMuppets/proprietary_vendor_oneplus/archive/refs/heads/cm-14.1.zip
sha256sum $D/cm-14.1.zip #==f008b553dceac26b0feb26fdbda15c7c620ec4e3103c67b749a32900c83a55ec
unzip $D/$LosVer.zip -d $proprD
#命令展开: unzip /OP3Los14Build/cm-14.1.zip -d /app/
#解压产物目录为 /app/proprietary_vendor_oneplus-cm-14.1
file /app/proprietary_vendor_oneplus-cm-14.1/oneplus3/Android.mk #解压产物列举
mkdir -p $D/vendor/oneplus
ln -s $proprD/proprietary_vendor_oneplus-cm-14.1/oneplus3 $D/vendor/oneplus/oneplus3
#命令展开: ln -s /app/proprietary_vendor_oneplus-cm-14.1/oneplus3 /OP3Los14Build/vendor/oneplus/oneplus3
device/oneplus/oneplus3, device/oppo/common, kernel/oneplus/msm8996, packages/resources
git clone -b $LosVer https://github.com/LineageOS/android_device_oneplus_oneplus3.git $D/device/oneplus/oneplus3
git clone -b $LosVer https://github.com/LineageOS/android_device_oppo_common.git $D/device/oppo/common
git clone -b $LosVer https://github.com/LineageOS/android_kernel_oneplus_msm8996.git $D/kernel/oneplus/msm8996
git clone -b $LosVer https://github.com/LineageOS/android_packages_resources_devicesettings.git $D/packages/resources
4. 编译错误解决
1.multiple definition of ‘yylloc’
解决编译错误, /usr/bin/ld: scripts/dtc/dtc-parser.tab.o:(.bss+0x50): multiple definition of 'yylloc'; scripts/dtc/dtc-lexer.lex.o:(.bss+0x0): first defined here
#D=/OP3Los14Build
grep url $D/kernel/oneplus/msm8996/.git/config
# url = https://github.com/LineageOS/android_kernel_oneplus_msm8996.git
echo 'HOSTCFLAGS += -fcommon' >> $D/kernel/oneplus/msm8996/Makefile
2. Jack server
解决报错 Communication error with Jack server (56). Try 'jack-diagnose'
export ANDROID_JACK_VM_ARGS="-Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx4G"
5A. 编译依赖工具安装
#所用linux发行版
cat /etc/issue #Ubuntu 22.04.4 LTS \n \l#查找deb包
sudo apt install -y apt-file
sudo apt-file update
lunch lineage_oneplus3-userdebug
需要的
sudo apt install -y build-essential
sudo apt install -y python2.7
sudo ln -s /usr/bin/python2.7 /usr/bin/python
mka bacon
需要的
1
apt-file search "/schedtool"
#schedtool: /usr/bin/schedtool
sudo apt install -y schedtool
2
apt-file search "/libncurses.so.5"
#libncurses5: /lib/x86_64-linux-gnu/libncurses.so.5
sudo apt install -y libncurses5
3
下载 https://static.azul.com/zulu/bin?C=S/zulu8.82.0.21-ca-jdk8.0.432-linux_x64.tar.gz
#查找jdk8的最新版本为 zulu8.82.0.21-ca-jdk8.0.432-linux_x64.tar.gz
pageUrl_azul_jdkLs="https://static.azul.com/zulu/bin?C=S"
alias alias_grep_jdk8_linux_x64_tar_gz_sort_head_n='grep jdk8 | grep linux_x64.tar.gz | sort --reverse | head -n'
w3m -T text/html $pageUrl_azul_jdkLs -dump | alias_grep_jdk8_linux_x64_tar_gz_sort_head_n 2
#[ ] zulu8.82.0.21-ca-jdk8.0.432-linux_x64.tar.gz 2024-10-10 102M
#[ ] zulu8.82.0.21-ca-fx-jdk8.0.432-linux_x64.tar.gz 2024-10-23 173M#下载zulu8.82.0.21-ca-jdk8.0.432-linux_x64.tar.gz
( cd /app/pack/ && wget https://static.azul.com/zulu/bin/zulu8.82.0.21-ca-jdk8.0.432-linux_x64.tar.gz )#解压
tar -xf zulu8.82.0.21-ca-jdk8.0.432-linux_x64.tar.gz -C /app/#测试
/app/zulu8.82.0.21-ca-jdk8.0.432-linux_x64/bin/javac -version
#javac 1.8.0_432
4
apt-file search "/ImageMagick"
sudo apt install -y imagemagick
#不是 libmagickcore-dev libmagick++-dev
5
prebuilts/misc/linux-x86/bison/bison
是32位ELF,
而ubuntu22 默认只支持64位ELF, 因此 要安装32位兼容库
prebuilts/misc/linux-x86/bison/bison --help #报错 说`No such file or directory` , 实际是因为没有32位ELF加载器ldsudo dpkg --add-architecture i386
sudo apt updatesudo apt install -y libc6:i386 libstdc++6:i386
prebuilts/misc/linux-x86/bison/bison --help #正常运行
6.
报错命令:
prebuilts/misc/linux-x86/bison/bison -d --defines=/OP3Los14Build/out/host/linux-x86/obj/STATIC_LIBRARIES/libaidl-common_intermediates/aidl_language_y.h -o /OP3Los14Build/out/host/linux-x86/obj/STATIC_LIBRARIES/libaidl-common_intermediates/aidl_language_y.cpp system/tools/aidl/aidl_language_y.yy
#prebuilts/misc/linux-x86/bison/bison: m4 subprocess failed: No such file or directory
解决
sudo apt install -y m4
5B. github加速
加速githubusercontent(可选)
githubusercontent
后加s
#D=/OP3Los14Build
sed -i 's/raw.githubusercontent.com/raw.githubusercontents.com/g' $D/vendor/cm/vendorsetup.sh
提高 source build/envsetup.sh
速度
5. 编译
screen -L -Logfile ~/OP3-cm14_1-screen-$(date +%Y-%m-%d-%H-%M-%S).log -S OP3#编译步骤正文 开始
D=/OP3Los14Build
cd $Djdk8_d=/app/zulu8.82.0.21-ca-jdk8.0.432-linux_x64
export PATH_BASE=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
export PATH=$PATH_BASE:$jdk8_d/bin#单行编译命令 开始
source build/envsetup.shexport ANDROID_JACK_VM_ARGS="-Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx4G"
#export V=1
export LC_ALL=C
export ALLOW_MISSING_DEPENDENCIES=true
#export DEBUG_MODULE_android_runtime=true
#export TARGET_CUSTOM_DEBUG_CFLAGS="-O0 -g"
#export MAKE_OPTS="-j8"
#export TARGET_ARCH=arm
lunch lineage_oneplus3-userdebug && mka showcommands bacon # lineage_oneplus3-eng
#单行编译命令 结束#编译步骤正文 结束#离开screen但不退出快捷键: ctrl+ad#进入screen : screen -r OP3
编译步骤 中 不同用途 的 单行编译命令
完整编译
source build/envsetup.sh && export LC_ALL=C && export ALLOW_MISSING_DEPENDENCIES=true && lunch lineage_oneplus3-userdebug && export MAKE_OPTS="-j8" && export TARGET_ARCH=arm && mka showcommands bacon
备注
一般备注
grep url $D/.repo/manifests/.git/config
# url = https://gitlab.com/cm-14/android.git#查看screen日志
tail -f ~/OP3-screen-*.log#关机命令
sleep 60 ; cd /tmp; echo z |sudo -S umount /OP3Los14Build ; echo z |sudo -S umount /mnt/OP3Los14Build ; echo z |sudo -S poweroff
确认版本号 为 cm-14.1
cd /tmp/
git clone https://mirrors.bfsu.edu.cn/git/lineageOS/LineageOS/android.git
cd /tmp/android/git --no-pager branch --all | grep cm-14.1 # == remotes/origin/cm-14.1
git --no-pager tag --list | grep cm-14.1 #无
oneplus3tlineageos161android9_331">oneplus3t-lineageos-16.1编译-android9
oneplus3t__332">oneplus3t 前提
-
救砖线刷 OnePlus3t android9
-
OTA卡刷 OnePlus3t android9
-
APatch root
-
debian11(标准GNU工具集) arm 工具盘(chroot 风格rootfs, 含有 比如sshd 、gdb) : tinan/eadb.git
本仓库开发已经完毕,使用请直接从4.2开始
** LineageOS16_oneplus3t仓库群克隆 、 编译 、 刷机**
- 编译过程若
ctrl+c
强制终止,请重新从头编译
oneplus3t_353">LineageOS16_oneplus3t仓库群克隆过程
LineageOS16_oneplus3t仓库群克隆过程描述: LineageOS16_oneplus3t_gitRepoLs_clone_desc.pdf
0_clone_me
git clone --branch zzz-stable https://gitlab.com/lineage16_oneplus3t/manifest-parser/git-repo.git /app4/git-repo
#/app4/git-repo/.git/config
1_lineageOS16_android9_repo_pull
仅开发时执行,产物已在本仓库,用户无需执行
此步骤执行了修改的repo命令,从而获得LineageOS-16.0–oneplus3t仓库群
执行内容
bash -x <(curl https://gitlab.com/lineage16_oneplus3t/manifest-parser/git-repo/-/raw/zzz-stable/projGit_ls/lineageOS16_android9_repo_pull.sh)
lineageOS16(android9)代码仓库拉取 ( 执行展开 ),
输入
manifest/lineageos-android–oneplus3t/lineage-16.0/default.xml
产物
-
仓库群描述 : projGit_ls/gen
/[projGit_ls.*.json|projGit_ls.*.md]
-
本地目录下仓库群 中 的 软链接命令、复制文件命令 : projGit_ls/gen
/[projCopyAndSoftLinkLs_ls.*.sh]
2_gitlabWebBatchImportReqXmlFile_gen
仅开发时执行,产物已在本仓库,用户无需执行
gitlab网页端批量导入请求生成
执行内容
bash /app4/git-repo/projGit_ls/json__to__gitlabWebBatchImportReqXmlFile/main.sh
( main.sh )
输入
即上一步产物: projGit_ls/gen/[projGit_ls.*.json|projGit_ls.*.md]
产物
gitlabWebBatchImportReq/*.xml
3_gitlabWebBatchImport
仅开发时执行, 产物已在本仓库,用户无需执行
gitlab网页批量导入LineageOS-16.0–oneplus3t仓库群**
执行内容
浏览器人工打开此网页批量导入仓库: gitlab网页批量导入
文档和例子manifest.xml
输入
即上一步产物: gitlabWebBatchImportReq/*.xml
产物
https://gitlab.com/lineage16_mirror
4_lineage16_clone
4.1
准备
仓库群描述 转换为 仓库群克隆文件
仅开发时执行, 产物已在本仓库,用户无需执行
产物 projGit_ls/gen/gitCloneCmd.sh
已在本仓库 。
bash /app4/git-repo/projGit_ls/json__to__cloneCmd/main.sh
4.2
执行内容
克隆LineageOS-16.0–oneplus3t仓库群
#克隆LineageOS-16.0--oneplus3t仓库群 , gitCloneCmd.sh 中 已写明 --depth=1 (只要以指定分支为起点的1个提交,以减小仓库尺寸)
root_dir=/app4/lineage16_oneplus3t_newdir bash /app4/git-repo/projGit_ls/gen/gitCloneCmd.sh
projGit_ls/json__to__cloneCmd/main.sh
projGit_ls/gen/gitCloneCmd.sh
输入
即 步骤2_gitlabWebBatchImportReqXmlFile_gen
的产物: gitlabWebBatchImportReq/*.xml
产物
projGit_ls/gen/gitCloneCmd.sh
5_projCopyAndSoftLinkLs
本地目录下仓库群 中 的 软链接命令、复制文件命令 执行
root_dir=/app4/lineage16_oneplus3t_new bash -x /app4/git-repo/projGit_ls/gen/projCopyAndSoftLinkLs_ls.*.sh
#比如 projCopyAndSoftLinkLs_ls.1730372866.43542.sh
projGit_ls/gen//projCopyAndSoftLinkLs_ls.*.sh
oneplus3t__479">LineageOS16_oneplus3t仓库群 编译
6_build
已在前几步完成 保留注释作为警醒
本文中注释掉的部分 都已在前几步完成了,保留注释只是为了保持警醒
主要由以下几处 完成了注释中的内容
- https://gitlab.com/lineage16_oneplus3t/manifest/lineageos-android/-/blob/lineage-16.0/default.xml
- https://gitlab.com/lineage16_oneplus3t/resource
### '已在前几步完成 保留注释作为警醒' 开始
#curl https://mirrors.tuna.tsinghua.edu.cn/git/git-repo -o /app/bin/repo#export REPO_URL='https://mirrors.tuna.tsinghua.edu.cn/git/git-repo'
#repo init --manifest-url https://mirrors.tuna.tsinghua.edu.cn/git/lineageOS/LineageOS/android.git --manifest-branch $GitBranch # GitBranch=lineage-16.0#解决报错, resource layout/preference_category_material_settings (aka org.lineageos.settings.device:layout/preference_category_material_settings) not found
#git clone -b lineage-16.0 https://githubfast.com/LineageOS/android_packages_resources_devicesettings.git $D/packages/resources/devicesettings#git clone https://github.com/TheMuppets/proprietary_vendor_oneplus.git/oneplus3 -b lineage-16.0 $D/vendor/oneplus/oneplus3#$D/repo/manifests/default.xml
#<remote name="aosp" fetch="https://android.googlesource.com" fetch替换为 "https://mirrors.tuna.tsinghua.edu.cn/git/AOSP"#repo sync --current-branch --no-tags --prune#oneplus3t linux内核、第三方厂商vendor
#git clone -b $GitBranch https://github.com/LineageOS/android_device_oneplus_oneplus3.git $D/device/oneplus/oneplus3
#git clone -b $GitBranch https://github.com/LineageOS/android_device_oppo_common.git $D/device/oppo/common
#git clone -b $GitBranch https://github.com/LineageOS/android_kernel_oneplus_msm8996.git $D/kernel/oneplus/msm8996
#git clone -b $GitBranch https://github.com/LineageOS/android_packages_resources_devicesettings.git $D/packages/resources#解决编译错误, /usr/bin/ld: scripts/dtc/dtc-parser.tab.o:(.bss+0x50): multiple definition of `yylloc'; scripts/dtc/dtc-lexer.lex.o:(.bss+0x0): first defined here### '已在前几步完成 保留注释作为警醒' 结束
编译步骤正文
#编译步骤正文开始export PATH_BASE=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/app/bin/
export PATH=$PATH_BASED=/app4/lineage16_oneplus3t_new
cd $D
#GitBranch=lineage-16.0source build/envsetup.sh#export V=1
export LC_ALL=C
export ALLOW_MISSING_DEPENDENCIES=true
lunch lineage_oneplus3-userdebug && mka showcommands bacon # lineage_oneplus3-eng
#编译步骤正文结束
参考: gitee/android_framework/oneplus3/lineage-build-simple-manual.md
某次编译产物举例
-
编译完成消耗时长为 53分钟(电脑配置: intel-12代i7+16GB内存),
-
获得的OTA全量卡刷包
lineage-16.0-20241101-UNOFFICIAL-oneplus3.zip
尺寸为630MB
-
/app4
占据空间128GB
,out
目录大小为77GB, 源码目录大小为50GB
cat /proc/cpuinfo | grep 'model name' | uniq
#model name : 12th Gen Intel(R) Core(TM) i7-12650Hsudo dmidecode -t memory #16GB内存#Package Complete: /app4/lineage16_oneplus3t/out/target/product/oneplus3/lineage-16.0-20241101-UNOFFICIAL-oneplus3.zip# build completed successfully (53:32 (mm:ss)) ####ls -lh /app4/lineage16_oneplus3t/out/target/product/oneplus3/lineage-16.0-20241101-UNOFFICIAL-oneplus3.zip
#-rwxrwxrwx 630M 2024年11月1日 22点18分 /app4/lineage16_oneplus3t/out/target/product/oneplus3/lineage-16.0-20241101-UNOFFICIAL-oneplus3.zipdf -h /app4
#Filesystem Size Used Avail Use% Mounted on
#/dev/nvme0n1p1 239G 128G 111G 54% /app4###编译产物中的调试符号 比如 libandroid_runtime.so.debug
find out/ -type f -path "*/oneplus3*/*/libandroid_runtime.so*"
#out/target/product/oneplus3/obj/SHARED_LIBRARIES/libandroid_runtime_intermediates/libandroid_runtime.so.debug
#out/target/product/oneplus3/obj/SHARED_LIBRARIES/libandroid_runtime_intermediates/libandroid_runtime.so#pwd==/app4/lineage16_oneplus3t/
#out目录大小为77GB
du --threshold=1G --max-depth=1 --human-readable out/
#4.9G out/host
#30G out/soong
#42G out/target
#77G out/#源码目录大小为50GB
du --exclude=out --threshold=1G --max-depth=1 --human-readable .
#1.4G ./cts
#8.3G ./external
#2.5G ./frameworks
#31G ./prebuilts
#2.3G ./tools
#50G .
oneplus3t__606">LineageOS16_oneplus3t仓库群 刷机
7_OTA_package_flush
刷机(OTA全量卡刷包)
前提: 已获得root 、 已解锁OEM
adb reboot bootloader
fastboot boot /app4/twrp-3.5.2_9-0-oneplus3.img #twrp界面 进入 sideload等待: Advance -> 'adb sideload' -> 清除 'davld cache' 、 `user cache' (双请) -> 底部进度条拉到右端
adb sideload /app4/lineage16_oneplus3t/out/target/product/oneplus3/lineage-16.0-20241101-UNOFFICIAL-oneplus3.zip
缺少依赖的报错解决记录
libncurses.so.5: cannot open shared object file
报错现象
m V=1 -j 1 bacon # 或mka showcommands bacon
报错如下
prebuilts/clang/host/linux-x86/clang-3289846/bin/clang.real: error while loading shared libraries: libncurses.so.5: cannot open shared object file: No such file or directory
报错解决
apt-file search libncurses.so.5
#libncurses5: /lib/x86_64-linux-gnu/libncurses.so.5sudo apt install libncurses5
m4: command not found
sudo apt install -y build-essential m4
libtinfo.so.5: cannot open shared object file
报错现象
m V=1 -j 1 bacon # 或mka showcommands bacon
报错如下
prebuilts/clang/host/linux-x86/clang-4691093/bin/clang++.real: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
报错解决
apt-file search libtinfo.so.5
#libtinfo5: /lib/x86_64-linux-gnu/libtinfo.so.5
sudo apt install -y libtinfo5
The boot animation could not be generated, as ImageMagick is not installed in your system.
报错现象
m V=1 -j 1 bacon # 或mka showcommands bacon
报错如下
The boot animation could not be generated
as ImageMagick is not installed in your system.
报错解决
apt-file search ImageMagick
sudo apt install -y imagemagick
其他报错解决记录
aarch64-linux-android-gcc: No such file or directory
报错现象
m V=1 -j 1 bacon # 或mka showcommands bacon
报错如下
/OP3TLos16Build/kernel/oneplus/msm8996/Makefile:671: Cannot use CONFIG_CC_STACKPROTECTOR_STRONG: -fstack-protector-strong not supported by compiler
make[1]: aarch64-linux-android-gcc: No such file or directory
报错分析
aarch64-linux-android-gcc是个python2.7脚本,且指定了需要解释器路径为#!/usr/bin/python
head -n 1 /OP3TLos16Build/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9/bin/aarch64-linux-android-gcc
##!/usr/bin/python/OP3TLos16Build/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9/bin/aarch64-linux-android-gcc
#-bash: /OP3TLos16Build/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9/bin/aarch64-linux-android-gcc: /usr/bin/python: bad interpreter: No such file or directory
报错解决
sudo apt install -y python2.7
sudo ln -s /usr/bin/python2.7 /usr/bin/python
which python #/usr/bin/python
cp: preserving permissions for
报错现象
m V=1 -j 1 bacon # 或mka showcommands bacon
报错如下
/bin/bash -c "(rm -f /app4/lineage16_oneplus3t/out/target/common/obj/JAVA_LIBRARIES/apache-xml_intermediates//classes*.dex ) && (cp -fp /app4/lineage16_oneplus3t/out/target/common/obj/JAVA_LIBRARIES/apache-xml_intermediates/dex-hiddenapi//classes*.dex /app4/lineage16_oneplus3t/out/target/common/obj/JAVA_LIBRARIES/apache-xml_intermediates/ )"
cp: preserving permissions for '/app4/lineage16_oneplus3t/out/target/common/obj/JAVA_LIBRARIES/apache-xml_intermediates/classes.dex': Operation not permitted
报错解决
/app4
所在分区挂载选项中增加 uid=1000,gid=1000,
,其中的数值是举例(表示ubuntu22当前登陆的用户的)