Skip to content

Conversation

@WonyoungChoi
Copy link

@WonyoungChoi WonyoungChoi commented Sep 8, 2021

  • Install EFL 1.25.1 and dependencies. (including xvfb)
  • Fix build-engine.sh for buliding host build.
  • Total uncompressed size of the docker will be 2.77GB including the tizen-tools image.
ghcr.io/flutter-tizen/build-engine   latest    a252ea0a8445   23 minutes ago   2.77GB
ghcr.io/flutter-tizen/tizen-tools    latest    12442f867f85   17 hours ago     1.86GB

The build workflows will be:

build.yml

      - name: gclient sync
        run: |
          gclient-prepare-sync.sh --reduce-deps --shallow-sync
          gclient sync -v --no-history --shallow

      - name: build
        run: |
          cache-checksum.sh restore $CACHE_PATH
          build-engine.sh \
            --target-os linux \
            --target-arch ${{ matrix.arch }} \
            --target-triple ${{ matrix.triple }} \
            --runtime-mode ${{ matrix.mode }}          
          cache-checksum.sh save $CACHE_PATH

test.yml

      - name: gclient sync
        run: |
          gclient-prepare-sync.sh --reduce-deps --shallow-sync
          gclient sync -v --no-history --shallow

      - name: check format
        run: |
          src/flutter/ci/format.sh

      - name: host build for test
        run: |
          cache-checksum.sh restore $CACHE_PATH
          build-engine.sh --build-target flutter_tizen_unittests
          cache-checksum.sh save $CACHE_PATH

      - name: run unit tests
        run: |
          $CACHE_PATH/flutter_tizen_unittests

ENV LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib/x86_64-linux-gnu/

# Start dbus service when running this container.
ENTRYPOINT /etc/init.d/dbus start && /bin/bash
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dbus service should be started to run flutter_tizen_unittests.

- Install EFL 1.51.1 and dependencies. (including xvfb)
- Fix build-engine.sh for buliding host build.
Comment on lines 8 to 16
apt-get install -y build-essential check meson ninja-build && \
apt-get install -y libssl-dev libsystemd-dev libjpeg-dev libglib2.0-dev libgstreamer1.0-dev \
liblua5.2-dev libfreetype6-dev libfontconfig1-dev libfribidi-dev libavahi-client-dev \
libharfbuzz-dev libibus-1.0-dev libx11-dev libxext-dev libxrender-dev libgl1-mesa-dev \
libgif-dev libtiff5-dev libpoppler-dev libpoppler-cpp-dev libspectre-dev libraw-dev \
librsvg2-dev libudev-dev libmount-dev libdbus-1-dev libpulse-dev libsndfile1-dev \
libxcursor-dev libxcomposite-dev libxinerama-dev libxrandr-dev libxtst-dev libxss-dev \
libgstreamer-plugins-base1.0-dev doxygen libopenjp2-7-dev libscim-dev libxdamage-dev \
libwebp-dev libunwind-dev libheif-dev libinput-dev libluajit-5.1-dev && \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How much image size would be increased by these additional dependencies? Is there no problem?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Compared to tizen-tools, the uncompressed size of the added layers is about 1 GB. It takes about 10 more seconds to download the docker image in the build workflows. I think it is acceptable.

ghcr.io/flutter-tizen/build-engine   latest    f1fb55b88802   3 hours ago     2.91GB
ghcr.io/flutter-tizen/tizen-tools    latest    12442f867f85   5 hours ago     1.86GB

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh. That's great.

libpulse-dev libsndfile1-dev libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev \
libibus-1.0-dev libscim-dev libfribidi-dev libinput-dev liblua5.2-dev libluajit-5.1-dev \
libx11-dev libxext-dev libxrender-dev libxcursor-dev libxcomposite-dev libxinerama-dev libxrandr-dev \
libxtst-dev libxss-dev libxdamage-dev libgl1-mesa-dev xvfb && \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow, now we can run test shell in docker?

Copy link
Author

@WonyoungChoi WonyoungChoi Sep 9, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, this docker image is for building the engine repository and *-unitests can be run after building the engine on this docker.

for example:

# docker run -it ghcr.io/flutter-tizen/build-engine /bin/bash
mkdir /workspace && cd /workspace
git clone --depth 1 https://github.com/flutter-tizen/engine src/flutter
gclient-prepare-sync.sh --reduce-deps --shallow-sync
gclient sync --no-history
build-engine.sh 
./src/out/host_debug/flutter-tizen-unittests 

But if the test shell you mentioned refers to the environment for testing the flutter widgets, we will need another docker environment.

@WonyoungChoi
Copy link
Author

I merge this PR early because of testing #182.

@WonyoungChoi WonyoungChoi merged commit e0dc8d8 into flutter-tizen:flutter-2.2.1-tizen Sep 9, 2021
@WonyoungChoi WonyoungChoi deleted the support-host-build branch September 9, 2021 05:45
swift-kim pushed a commit that referenced this pull request Sep 27, 2021
* [docker] Support host build

- Install EFL 1.51.1 and dependencies. (including xvfb)
- Fix build-engine.sh for buliding host build.

* [docker] Optimize Dockerfile for build-engine
swift-kim pushed a commit that referenced this pull request Nov 14, 2021
* [docker] Support host build

- Install EFL 1.51.1 and dependencies. (including xvfb)
- Fix build-engine.sh for buliding host build.

* [docker] Optimize Dockerfile for build-engine
swift-kim pushed a commit that referenced this pull request Dec 9, 2021
* [docker] Support host build

- Install EFL 1.51.1 and dependencies. (including xvfb)
- Fix build-engine.sh for buliding host build.

* [docker] Optimize Dockerfile for build-engine
swift-kim pushed a commit that referenced this pull request Dec 17, 2021
* [docker] Support host build

- Install EFL 1.51.1 and dependencies. (including xvfb)
- Fix build-engine.sh for buliding host build.

* [docker] Optimize Dockerfile for build-engine
swift-kim pushed a commit that referenced this pull request Feb 7, 2022
* [docker] Support host build

- Install EFL 1.51.1 and dependencies. (including xvfb)
- Fix build-engine.sh for buliding host build.

* [docker] Optimize Dockerfile for build-engine
swift-kim pushed a commit that referenced this pull request Feb 11, 2022
* [docker] Support host build

- Install EFL 1.51.1 and dependencies. (including xvfb)
- Fix build-engine.sh for buliding host build.

* [docker] Optimize Dockerfile for build-engine
swift-kim pushed a commit that referenced this pull request May 12, 2022
* [docker] Support host build

- Install EFL 1.51.1 and dependencies. (including xvfb)
- Fix build-engine.sh for buliding host build.

* [docker] Optimize Dockerfile for build-engine
swift-kim pushed a commit that referenced this pull request Aug 5, 2022
* [docker] Support host build

- Install EFL 1.51.1 and dependencies. (including xvfb)
- Fix build-engine.sh for buliding host build.

* [docker] Optimize Dockerfile for build-engine
swift-kim pushed a commit that referenced this pull request Sep 1, 2022
* [docker] Support host build

- Install EFL 1.51.1 and dependencies. (including xvfb)
- Fix build-engine.sh for buliding host build.

* [docker] Optimize Dockerfile for build-engine
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants