• 切换GCC编译器版本


    当前版本信息
    root@ubuntu:runninglinuxkernel_4.0# aarch64-linux-gnu-gcc -v
    Using built-in specs.
    COLLECT_GCC=aarch64-linux-gnu-gcc
    COLLECT_LTO_WRAPPER=/usr/lib/gcc-cross/aarch64-linux-gnu/7/lto-wrapper
    Target: aarch64-linux-gnu
    Configured with: ../src/configure -v
    .............................
    gcc version 7.4.0 (Ubuntu/Linaro 7.4.0-1ubuntu1~18.04.1)


    切换GCC版本为5.5
    查看gcc信息
    root@ubuntu:runninglinuxkernel_4.0# update-alternatives --query  aarch64-linux-gnu-gcc
    Name: aarch64-linux-gnu-gcc
    Link: /usr/bin/aarch64-linux-gnu-gcc
    Status: auto
    Best: /usr/bin/aarch64-linux-gnu-gcc-5
    Value: /usr/bin/aarch64-linux-gnu-gcc-5

    Alternative: /usr/bin/aarch64-linux-gnu-gcc-5
    Priority: 5



    切换版本
    root@ubuntu:runninglinuxkernel_4.0# update-alternatives --install /usr/bin/aarch64-linux-gnu-gcc  aarch64-linux-gnu-gcc /usr/bin/aarch64-linux-gnu-gcc-5 100


    验证版本是否切换成功
    root@ubuntu:runninglinuxkernel_4.0# aarch64-linux-gnu-gcc -v
    Using built-in specs.
    COLLECT_GCC=aarch64-linux-gnu-gcc
    COLLECT_LTO_WRAPPER=/usr/lib/gcc-cross/aarch64-linux-gnu/5/lto-wrapper
    Target: aarch64-linux-gnu
    ..................................
    gcc version 5.5.0 20171010 (Ubuntu/Linaro 5.5.0-12ubuntu1)

  • 相关阅读:
    ELASTIC 动态修改配置API
    ELASTIC API
    ELASTIC索引监控脚本
    java并发多线程纪要
    Git 基础
    Linux 权限规划ACL
    Linux账号管理(二)
    Linux账号管理(一)
    Linux 备份工具dump
    Linux 文件压缩、打包
  • 原文地址:https://www.cnblogs.com/menkeyi/p/11430455.html
Copyright © 2020-2023  润新知