Lines Matching +full:xtensa +full:- +full:build +full:- +full:all
1 # Copyright 2018 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
5 # Defines a docker image that can build sound open firmware
9 # build docker image:
10 # docker build --build-arg UID=$(id -u) -t sof .
11 # docker run -it -v <insert sof dir here>:/home/sof/workdir --user `id -u` sof
14 # docker run -it -v <insert sof dir here>:/home/sof/work/sof.git --user `id -u` sof ./incremental.…
25 # for non-interactive package install
28 RUN apt-get -y update && \
29 apt-get install -y \
31 apt-utils \
36 build-essential \
37 python3-pyelftools \
44 libncurses5-dev \
45 libssl-dev \
47 libtool-bin \
48 pkg-config \
49 software-properties-common \
58 libglib2.0-dev
60 ARG CLONE_DEFAULTS="--depth 5"
63 RUN useradd --create-home -d /home/sof -u $UID -G sudo sof && \
68 # Note: For alsa-lib, set default library directory to /usr/lib/x86_64-linux-gnu.
70 # path does not have this. Typical build error is like,
72 RUN mkdir -p /home/sof/work/alsa && cd /home/sof/work/alsa && \
73 git clone $CLONE_DEFAULTS https://github.com/thesofproject/alsa-lib.git && \
74 git clone $CLONE_DEFAULTS https://github.com/thesofproject/alsa-utils.git && \
75 cd /home/sof/work/alsa/alsa-lib && ./gitcompile --prefix=/usr --libdir=/usr/lib/x86_64-linux-gnu/ &…
76 cd /home/sof/work/alsa/alsa-utils && ./gitcompile && make install &&\
77 chown -R sof:sof /home/sof
80 ARG XT_OVERLAY_REPO=$GITHUB_SOF/xtensa-overlay.git
81 ARG CT_NG_REPO=$GITHUB_SOF/crosstool-ng.git
82 # build cross compiler
85 git clone $CLONE_DEFAULTS --branch sof-gcc10.2 $XT_OVERLAY_REPO && \
86 cd xtensa-overlay && cd ../ && \
87 git clone $CLONE_DEFAULTS --branch sof-gcc10x $CT_NG_REPO && \
88 mkdir -p /home/sof/work/ && \
89 cd crosstool-ng && \
90 ./bootstrap && ./configure --prefix=`pwd` && make && make install && \
92 cp config-${arch}-gcc10.2-gdb9 .config && \
93 # replace the build dist to save space
94 sed -i 's#${CT_TOP_DIR}\/builds#\/home\/sof\/work#g' .config && \
95 # gl_cv_func_getcwd_path_max=yes is used to avoid too-long confdir3/confdir3/...
96 gl_cv_func_getcwd_path_max=yes ./ct-ng build && \
97 ./ct-ng distclean ; \
99 cd /home/sof/ && rm -rf xtensa-overlay && rm -rf crosstool-ng
101 ENV PATH="/home/sof/work/xtensa-byt-elf/bin:${PATH}"
102 ENV PATH="/home/sof/work/xtensa-hsw-elf/bin:${PATH}"
103 ENV PATH="/home/sof/work/xtensa-apl-elf/bin:${PATH}"
104 ENV PATH="/home/sof/work/xtensa-cnl-elf/bin:${PATH}"
105 ENV PATH="/home/sof/work/xtensa-imx-elf/bin:${PATH}"
106 ENV PATH="/home/sof/work/xtensa-imx8m-elf/bin:${PATH}"
107 ENV PATH="/home/sof/work/xtensa-imx8ulp-elf/bin:${PATH}"
109 ARG NEWLIB_REPO=https://github.com/jcmvbkbc/newlib-xtensa.git
111 git clone $CLONE_DEFAULTS --branch xtensa $NEWLIB_REPO && \
112 cd newlib-xtensa && \
114 ./configure --target=xtensa-${arch}-elf \
115 --prefix=/home/sof/work/xtensa-root && \
118 rm -rf etc/config.cache; \
120 cd /home/sof/ && rm -rf newlib-xtensa.git
124 RUN mkdir -p /home/sof/work/sof.git