Implemente la cadena de herramientas cruzadas del brazo en la imagen de la ventana acoplable WSL2.0 real (4)

Implemente la cadena de herramientas cruzadas del brazo en la imagen de la ventana acoplable WSL2.0 real (4)

7. Descargue y ejecute la imagen i386 / ubuntu

  • descargar

    [root@localhost docker]# docker pull i386/ubuntu
    Using default tag: latest
    latest: Pulling from i386/ubuntu
    e777d477ce90: Pull complete 
    e0aa7d8210ab: Pull complete 
    05340dfc06a9: Pull complete 
    f2f193f23089: Pull complete 
    Digest: sha256:8fc36de4b957529f5a274da741739aa47b899368318c88bb6bebf9d9e6b0ccd0
    Status: Downloaded newer image for i386/ubuntu:latest
    docker.io/i386/ubuntu:latest
    
  • Ejecute este ubuntu:

    sudo docker run -v /dev:/dev -v /lib/modules/:/lib/modules/ -v /run:/run -v /mnt/e/rumba:/rumba --add-host='osc:127.0.0.1' -it i386/ubuntu /bin/bash
    [root@localhost nb]# docker run -it --name ubuntu386 i386/ubuntu /bin/bash
    root@099ac84db527:/# 
    root@099ac84db527:/# getconf LONG_BIT
    32
    

8. cc1plus: valor demasiado grande para el tipo definido

Referencia: https://blog.csdn.net/qq_43189737/article/details/83000619

Lanzamiento: Sr.Jia Xiao2018-10-10 17:33:56

  • problema
    ## 1) 部分存量项目使用 arm 2009 编译器;
    ## 2) 项目代码在windows目录下, 在wsl2.0中通过如下命令挂载到容器中
    sudo docker run -v /home/work:/work -v /dev:/dev -v /lib/modules/:/lib/modules/ -v /run:/run --add-host='osc:127.0.0.1'-i -t ubuntu
    ## 3) 执行 make,执行如下错误
    cc1plus: error: /work/prj/3.xxx/yyy/zzz/include: Value too large for defined data type
    
  • Solución
    ## 1) 在 windows 中共享该源代码目录,例如本例中共享了 work 目录
    ## 2) 通过 cifs 挂载到容器中,在-o参数添加nounix,noserverino指令
    mount -t cifs //192.168.1.2/work /work -o username="xxx",password="yyy",nounix,noserverino
    
    Disfrútala !

Supongo que te gusta

Origin blog.csdn.net/hylaking/article/details/109157455
Recomendado
Clasificación