From 4b515d725cfd6e308178fc0657dba55b711ca4f4 Mon Sep 17 00:00:00 2001 From: NEU-lab <2942375747@qq.com> Date: Tue, 17 Dec 2024 16:41:50 +0800 Subject: [PATCH 1/2] =?UTF-8?q?bullet3=E5=BA=93=E4=BF=AE=E6=94=B9=E5=90=84?= =?UTF-8?q?=E6=96=87=E4=BB=B6=E4=B8=AD=E7=89=88=E6=9C=AC=E5=8F=B7=E7=AD=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: NEU-lab <2942375747@qq.com> --- community/{bullet3-3.22 => bullet3}/HPKBUILD | 6 +++--- community/{bullet3-3.22 => bullet3}/HPKCHECK | 13 ++++++++----- community/{bullet3-3.22 => bullet3}/OAT.xml | 0 .../{bullet3-3.22 => bullet3}/README.OpenSource | 2 +- community/{bullet3-3.22 => bullet3}/README_zh.md | 4 ++-- community/{bullet3-3.22 => bullet3}/SHA512SUM | 0 .../bullet3-3.22_oh_pkg.patch | 0 .../docs/hap_integrate.md | 13 +++++++------ .../docs/pic/bullet3_install_dir.png | Bin .../docs/pic/bullet3_test.png | Bin 10 files changed, 21 insertions(+), 17 deletions(-) rename community/{bullet3-3.22 => bullet3}/HPKBUILD (96%) rename community/{bullet3-3.22 => bullet3}/HPKCHECK (82%) rename community/{bullet3-3.22 => bullet3}/OAT.xml (100%) rename community/{bullet3-3.22 => bullet3}/README.OpenSource (93%) rename community/{bullet3-3.22 => bullet3}/README_zh.md (51%) rename community/{bullet3-3.22 => bullet3}/SHA512SUM (100%) rename community/{bullet3-3.22 => bullet3}/bullet3-3.22_oh_pkg.patch (100%) rename community/{bullet3-3.22 => bullet3}/docs/hap_integrate.md (83%) rename community/{bullet3-3.22 => bullet3}/docs/pic/bullet3_install_dir.png (100%) rename community/{bullet3-3.22 => bullet3}/docs/pic/bullet3_test.png (100%) diff --git a/community/bullet3-3.22/HPKBUILD b/community/bullet3/HPKBUILD similarity index 96% rename from community/bullet3-3.22/HPKBUILD rename to community/bullet3/HPKBUILD index 94a06aad..811c0edc 100644 --- a/community/bullet3-3.22/HPKBUILD +++ b/community/bullet3/HPKBUILD @@ -14,7 +14,7 @@ # Contributor: wangjialun<2271411@stu.neu.edu.cn>, zhangqian<2371418@stu.neu.edu.cn>, wangyihao<2471389@stu.neu.edu.cn>, wangying # Maintainer: wangyihao<2471389@stu.neu.edu.cn>, wangjialun<2271411@stu.neu.edu.cn>, zhangqian<2371418@stu.neu.edu.cn>, wangying -pkgname=bullet3-3.22 +pkgname=bullet3 pkgver=3.22 pkgrel=0 pkgdesc="It is a real-time collision detection and multi-physics simulation for VR, games, visual effects, robotics, machine learning etc." @@ -29,8 +29,8 @@ downloadpackage=true autounpack=true buildtools=cmake patchflag=true -builddir=bullet3-refs-tags-$pkgver -packagename=$pkgname.zip +builddir=$pkgname-${pkgver} +packagename=$builddir.zip # 为编译设置环境,如设置环境变量,创建编译目录等 prepare() { diff --git a/community/bullet3-3.22/HPKCHECK b/community/bullet3/HPKCHECK similarity index 82% rename from community/bullet3-3.22/HPKCHECK rename to community/bullet3/HPKCHECK index 9ceab104..45087f23 100644 --- a/community/bullet3-3.22/HPKCHECK +++ b/community/bullet3/HPKCHECK @@ -22,9 +22,12 @@ logfile=${LYCIUM_THIRDPARTY_ROOT}/${pkgname}/${pkgname}_${OHOS_SDK_VER}_test.log openharmonycheck() { res=0 cd ${builddir}/${ARCH}-build # 进入到测试目录 - ctest > ${logfile} 2>&1 # 执行测试命令并将测试结果导出到${logfile} - res=$? - cd $OLDPWD - - return $res + ctest > $logfile 2>&1 + res=$? + if [ $res -ne 0 ];then + mkdir ${LYCIUM_FAULT_PATH}/${pkgname} + cp Testing/Temporary/LastTest.log ${LYCIUM_FAULT_PATH}/${pkgname}/ + fi + cd $OLDPWD + return $res } \ No newline at end of file diff --git a/community/bullet3-3.22/OAT.xml b/community/bullet3/OAT.xml similarity index 100% rename from community/bullet3-3.22/OAT.xml rename to community/bullet3/OAT.xml diff --git a/community/bullet3-3.22/README.OpenSource b/community/bullet3/README.OpenSource similarity index 93% rename from community/bullet3-3.22/README.OpenSource rename to community/bullet3/README.OpenSource index 71d24c96..406a3ec7 100644 --- a/community/bullet3-3.22/README.OpenSource +++ b/community/bullet3/README.OpenSource @@ -1,6 +1,6 @@ [ { - "Name": "bullet3-3.22", + "Name": "bullet3", "License": "Zlib License", "License File": "https://github.com/bulletphysics/bullet3/blob/master/LICENSE.txt", "Version Number": "3.22", diff --git a/community/bullet3-3.22/README_zh.md b/community/bullet3/README_zh.md similarity index 51% rename from community/bullet3-3.22/README_zh.md rename to community/bullet3/README_zh.md index 7393f0b7..093d9aed 100644 --- a/community/bullet3-3.22/README_zh.md +++ b/community/bullet3/README_zh.md @@ -1,6 +1,6 @@ -# bullet3-3.22三方库说明 +# bullet3三方库说明 ## 功能简介 -bullet3-3.22可以实现实时碰撞检测和多物理场仿真,适用于VR、游戏、视觉效果、机器人、机器学习等。 +bullet3可以实现实时碰撞检测和多物理场仿真,适用于VR、游戏、视觉效果、机器人、机器学习等。 ## 三方库版本: - 3.22 ## 使用约束: diff --git a/community/bullet3-3.22/SHA512SUM b/community/bullet3/SHA512SUM similarity index 100% rename from community/bullet3-3.22/SHA512SUM rename to community/bullet3/SHA512SUM diff --git a/community/bullet3-3.22/bullet3-3.22_oh_pkg.patch b/community/bullet3/bullet3-3.22_oh_pkg.patch similarity index 100% rename from community/bullet3-3.22/bullet3-3.22_oh_pkg.patch rename to community/bullet3/bullet3-3.22_oh_pkg.patch diff --git a/community/bullet3-3.22/docs/hap_integrate.md b/community/bullet3/docs/hap_integrate.md similarity index 83% rename from community/bullet3-3.22/docs/hap_integrate.md rename to community/bullet3/docs/hap_integrate.md index 781f4da5..953e64c1 100644 --- a/community/bullet3-3.22/docs/hap_integrate.md +++ b/community/bullet3/docs/hap_integrate.md @@ -17,13 +17,14 @@ - 三方库目录结构 ```shell - tpc_c_cplusplus/thirdparty/bullet3-3.22 #三方库bullet3-3.22的目录结构如下 + tpc_c_cplusplus/thirdparty/bullet3 #三方库bullet3的目录结构如下 ├── docs #三方库相关文档的文件夹 ├── HPKBUILD #构建脚本 ├── HPKCHECK #测试脚本 ├── SHA512SUM #三方库校验文件 ├── README.OpenSource #说明三方库源码的下载地址,版本,license等信息 ├── README_zh.md #三方库简介 + ├── bullet3-3.22_oh_pkg.patch #用于bullet3库编译的补丁 ``` - 在lycium目录下编译三方库 @@ -32,7 +33,7 @@ ```shell cd lycium - ./build.sh bullet3-3.22 + ./build.sh bullet3 ``` - 三方库头文件及生成的库 @@ -40,15 +41,14 @@ 在lycium目录下会生成usr目录,该目录下存在已编译完成的32位和64位三方库 ```shell - bullet3-3.22/arm64-v8a bullet3-3.22/armeabi-v7a + bullet3/arm64-v8a bullet3/armeabi-v7a ``` - [测试三方库](#测试三方库) -- 编译出可执行的文件进行测试,[准备三方库测试环境](../../../lycium/README.md#3ci环境准备) ## 应用中使用三方库 -- 在IDE的cpp目录下新增thirdparty目录,将编译生成的头文件拷贝到该目录下,将编译生成的三方库以及依赖库全部(动态库名字带版本号和不带版本号的都需要)拷贝到工程的libs目录下,如下图所示: +- 在IDE的cpp目录下新增thirdparty目录,将编译生成的头文件和静态库文件拷贝到该目录下,如下图所示:    ![thirdparty_install_dir](pic/bullet3_install_dir.png) @@ -66,7 +66,8 @@ ``` ## 测试三方库 -进入到构建目录运行测试用例(注意arm64-v8a为构建64位的目录,armeabi-v7a为构建32位的目录),执行结果如图所示 +- 编译出可执行的文件,使用原库自带的测试用例来做测试 [准备三方库测试环境](../../../lycium/README.md#3ci环境准备) +进入到构建目录运行测试用例(注意arm64-v8a为构建64位的目录,armeabi-v7a为构建32位的目录)。执行结果如图所示 ```shell cd /data/tpc_c_cplusplus/thirdparty/bullet3-3.22/arm64-v8a-build/ diff --git a/community/bullet3-3.22/docs/pic/bullet3_install_dir.png b/community/bullet3/docs/pic/bullet3_install_dir.png similarity index 100% rename from community/bullet3-3.22/docs/pic/bullet3_install_dir.png rename to community/bullet3/docs/pic/bullet3_install_dir.png diff --git a/community/bullet3-3.22/docs/pic/bullet3_test.png b/community/bullet3/docs/pic/bullet3_test.png similarity index 100% rename from community/bullet3-3.22/docs/pic/bullet3_test.png rename to community/bullet3/docs/pic/bullet3_test.png -- Gitee From fed45cf54ef5a488caecc413ec2854b521a3544d Mon Sep 17 00:00:00 2001 From: NEU-lab <2942375747@qq.com> Date: Tue, 17 Dec 2024 17:51:00 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E5=88=A0=E9=99=A4OAT.xml?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: NEU-lab <2942375747@qq.com> --- community/bullet3/OAT.xml | 16 ---------------- 1 file changed, 16 deletions(-) delete mode 100644 community/bullet3/OAT.xml diff --git a/community/bullet3/OAT.xml b/community/bullet3/OAT.xml deleted file mode 100644 index eeb1f946..00000000 --- a/community/bullet3/OAT.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - - - - - - - - - - - - - - \ No newline at end of file -- Gitee