From 91428e3044d996ce63f1f2a02bb0c93e483ee1ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=B8=A5=E5=BC=80=E5=AE=89?= Date: Sat, 30 Mar 2024 17:51:00 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0DevKit=E5=91=BD=E4=BB=A4?= =?UTF-8?q?=E8=A1=8C=E3=80=81clamAV=E5=AE=89=E8=A3=85=E8=84=9A=E6=9C=AC=20?= =?UTF-8?q?=E4=BF=AE=E6=94=B9BishengJDK=E5=AE=89=E8=A3=85=E8=84=9A?= =?UTF-8?q?=E6=9C=AC=EF=BC=8C=E5=88=A0=E9=99=A4alternative=E9=85=8D?= =?UTF-8?q?=E7=BD=AEJava=20=E4=BF=AE=E6=94=B9=E6=89=B9=E9=87=8F=E9=83=A8?= =?UTF-8?q?=E7=BD=B2=E6=96=87=E6=A1=A3=E5=AF=B9BishengJDK=E7=9A=84?= =?UTF-8?q?=E9=83=A8=E7=BD=B2=E8=AF=B4=E6=98=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- component/BiShengJDK17/install.sh | 15 --------------- component/BiShengJDK8/install.sh | 15 --------------- component/DevKitCLI/install.sh | 7 +++++++ component/build_component.sh | 1 + component/clamAV/build.sh | 2 ++ ...57\264\346\230\216\346\226\207\346\241\243.md" | 14 +++----------- 6 files changed, 13 insertions(+), 41 deletions(-) create mode 100644 component/DevKitCLI/install.sh create mode 100644 component/clamAV/build.sh diff --git a/component/BiShengJDK17/install.sh b/component/BiShengJDK17/install.sh index 4ce4813..edd12eb 100644 --- a/component/BiShengJDK17/install.sh +++ b/component/BiShengJDK17/install.sh @@ -10,21 +10,6 @@ if [[ ${verify_signature} -eq "0" ]]; then tar -zxf /tmp/devkitdependencies/bisheng-jdk-17.0.10-linux-aarch64.tar.gz -C ${HOME}/.local echo "Decompress bisheng-jdk-17.0.10-linux-aarch64.tar.gz to ${HOME}/.local finished." fi - - java_path=$(which java) - if [[ ${java_path} != ${HOME}/.local/bisheng-jdk-17.0.10/bin/java ]]; then - # 配置alternatives - echo "do update-alternatives install something to /usr/bin/" - for BinFilePath in ${HOME}/.local/bisheng-jdk-17.0.10/bin/*; do - if [[ -x ${BinFilePath} ]]; then - BinFileName=$(basename ${BinFilePath}) - sudo update-alternatives --install /usr/bin/${BinFileName} ${BinFileName} ${BinFilePath} 50 - fi - done - else - echo "install bisheng-jdk-17.0.10 success." - fi - else echo "Failed to verify the signature of the bisheng-jdk-17.0.10-linux-aarch64.tar.gz installation package." fi diff --git a/component/BiShengJDK8/install.sh b/component/BiShengJDK8/install.sh index e17caf6..d8710d4 100644 --- a/component/BiShengJDK8/install.sh +++ b/component/BiShengJDK8/install.sh @@ -10,21 +10,6 @@ if [[ ${verify_signature} -eq "0" ]]; then tar -zxf /tmp/devkitdependencies/bisheng-jdk-8u402-linux-aarch64.tar.gz -C ${HOME}/.local echo "Decompress bisheng-jdk-8u402-linux-aarch64.tar.gz to ${HOME}/.local finished." fi - - java_path=$(which java) - if [[ ${java_path} != ${HOME}/.local/bisheng-jdk1.8.0_402/bin/java ]]; then - # 配置alternatives - echo "do update-alternatives install something to /usr/bin/" - for BinFilePath in ${HOME}/.local/bisheng-jdk1.8.0_402/bin/*; do - if [[ -x ${BinFilePath} ]]; then - BinFileName=$(basename ${BinFilePath}) - sudo update-alternatives --install /usr/bin/${BinFileName} ${BinFileName} ${BinFilePath} 100 - fi - done - else - echo "install bisheng-jdk-8u402 success." - fi - else echo "Failed to verify the signature of the bisheng-jdk-8u402-linux-aarch64.tar.gz installation package." fi diff --git a/component/DevKitCLI/install.sh b/component/DevKitCLI/install.sh new file mode 100644 index 0000000..39398b6 --- /dev/null +++ b/component/DevKitCLI/install.sh @@ -0,0 +1,7 @@ +#!/bin/bash +cd /tmp/devkitdependencies/ +echo "Decompress DevKit-CLI-24.0.RC1-Linux-Kunpeng.tar.gz to ${HOME}/.local" +tar -zxf /tmp/devkitdependencies/DevKit-CLI-24.0.RC1-Linux-Kunpeng.tar.gz -C ${HOME}/.local +echo "Decompress DevKit-CLI-24.0.RC1-Linux-Kunpeng.tar.gz to ${HOME}/.local finished." +ln -s ${HOME}/.local/DevKit-CLI-24.0.RC1-Linux-Kunpeng/devkit /usr/local/bin +echo "install DevkitCLI success." diff --git a/component/build_component.sh b/component/build_component.sh index 2be9d33..3b40bf5 100644 --- a/component/build_component.sh +++ b/component/build_component.sh @@ -35,6 +35,7 @@ function main() { component_arrays=( "BiShengCompiler" "BiShengJDK8" "BiShengJDK17" "GCCforOpenEuler" "OpenEulerMirrorISO" "CompatibilityTesting" "NonInvasiveSwitching" "A-FOT" + "DevKitCLI" "clamAV" ) for element in "${component_arrays[@]}"; do cp -rf "${current_dir}/${element}" "${final_component_dir}" diff --git a/component/clamAV/build.sh b/component/clamAV/build.sh new file mode 100644 index 0000000..48553f7 --- /dev/null +++ b/component/clamAV/build.sh @@ -0,0 +1,2 @@ +#!/bin/bash +yum install -y clamav \ No newline at end of file diff --git "a/document/\346\211\271\351\207\217\351\203\250\347\275\262\345\267\245\345\205\267/\346\211\271\351\207\217\351\203\250\347\275\262\345\267\245\345\205\267\345\222\214\344\270\200\351\224\256\344\270\213\350\275\275\345\267\245\345\205\267\350\257\264\346\230\216\346\226\207\346\241\243.md" "b/document/\346\211\271\351\207\217\351\203\250\347\275\262\345\267\245\345\205\267/\346\211\271\351\207\217\351\203\250\347\275\262\345\267\245\345\205\267\345\222\214\344\270\200\351\224\256\344\270\213\350\275\275\345\267\245\345\205\267\350\257\264\346\230\216\346\226\207\346\241\243.md" index ddddc28..3e765f6 100644 --- "a/document/\346\211\271\351\207\217\351\203\250\347\275\262\345\267\245\345\205\267/\346\211\271\351\207\217\351\203\250\347\275\262\345\267\245\345\205\267\345\222\214\344\270\200\351\224\256\344\270\213\350\275\275\345\267\245\345\205\267\350\257\264\346\230\216\346\226\207\346\241\243.md" +++ "b/document/\346\211\271\351\207\217\351\203\250\347\275\262\345\267\245\345\205\267/\346\211\271\351\207\217\351\203\250\347\275\262\345\267\245\345\205\267\345\222\214\344\270\200\351\224\256\344\270\213\350\275\275\345\267\245\345\205\267\350\257\264\346\230\216\346\226\207\346\241\243.md" @@ -96,7 +96,7 @@ devkit: 各工具下载版本为2024年2月各工具官网提供的最新版,可查看本项目源代码`tools/download_dependency/src/download_config.py` 文件查看具体下载链接。 -说明:部署工具部署BiShengJDK8 和 BiShengJDK17时,均使用服务器内部自带的 `update-alternatives` 命令进行配置。默认BiShengJDK8版本优先。 +说明:**部署工具部署BiShengJDK8 和 BiShengJDK17时,两个版本的安装包解压在${HOME}/.local/目录下,用户需要按自己需要使用的版本进行手动配置环境变量**。 部署安装过程中会使用目标结点机器的 **`/tmp`** 目录作为临时文件所在目录,部署完成后将会删除 **`/tmp`** 目录下的临时文件。若目标结点机器 **`/tmp`** 目录磁盘空间不足,则会导致安装失败。若使用挂载本地镜像方式安装,则安装完依赖后,本地镜像源将被取消挂载并恢复原来的镜像源配置。 @@ -195,11 +195,7 @@ export PATH=${BISHENG_COMPILER_HOME}:${PATH} #### BiShengJDK8安装结果 -批量部署工具将`BiShengJDK8`安装包解压至用户家目录下的.local文件夹下,并使用`alternatives`中`install`命令配置java版本。用户重新登录服务器后即可使用如下命令查询或更改当前环境所用`java`版本。 - -```shell -update-alternatives --config java -``` +批量部署工具将`BiShengJDK8`安装包解压至用户家目录下的.local文件夹下,用户手动配置环境变量后,可使用如下命令查询当前环境所用`java`版本。 ```shell java -version @@ -207,11 +203,7 @@ java -version #### BiShengJDK17安装结果 -批量部署工具将`BiShengJDK17`安装包解压至用户家目录下的.local文件夹下,并使用`alternatives`中`install`命令配置java版本。用户重新登录服务器后即可使用如下命令查询或更改当前环境所用`java`版本。 - -```shell -update-alternatives --config java -``` +批量部署工具将`BiShengJDK17`安装包解压至用户家目录下的.local文件夹下,用户手动配置环境变量后,可使用如下命令查询当前环境所用`java`版本。 ```shell java -version -- Gitee