summaryrefslogtreecommitdiffstats
path: root/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-07-24 09:54:23 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-07-24 09:54:44 +0000
commit836b47cb7e99a977c5a23b059ca1d0b5065d310e (patch)
tree1604da8f482d02effa033c94a84be42bc0c848c3 /fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain
parentReleasing debian version 1.44.3-2. (diff)
downloadnetdata-836b47cb7e99a977c5a23b059ca1d0b5065d310e.tar.xz
netdata-836b47cb7e99a977c5a23b059ca1d0b5065d310e.zip
Merging upstream version 1.46.3.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain')
-rw-r--r--fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/.dockerignore4
-rw-r--r--fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/Dockerfile71
-rw-r--r--fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/README.md18
-rw-r--r--fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/build_docker_image.bat9
-rwxr-xr-xfluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/build_docker_image.sh9
-rwxr-xr-xfluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/resource/build_wasm.sh25
-rwxr-xr-xfluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/resource/wamr_toolchain.cmake33
7 files changed, 0 insertions, 169 deletions
diff --git a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/.dockerignore b/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/.dockerignore
deleted file mode 100644
index 920e0990..00000000
--- a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/.dockerignore
+++ /dev/null
@@ -1,4 +0,0 @@
-# remove unnecessary files here to save build time cost and image size
-*.md
-*.sh
-*.bat \ No newline at end of file
diff --git a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/Dockerfile b/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/Dockerfile
deleted file mode 100644
index cd8da38d..00000000
--- a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/Dockerfile
+++ /dev/null
@@ -1,71 +0,0 @@
-# Copyright (C) 2019 Intel Corporation. All rights reserved.
-# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-
-## Build docker image that consists of gcc, cmake, wasi-sdk & zephyr sdk
-FROM gcc:12.2.0 AS BASE
-
-## set work directory
-WORKDIR /root/
-
-COPY resource /root/
-
-# - download cmake with wget and set up
-# hadolint ignore=DL3008
-RUN apt-get update \
- && apt-get -y install ccache ninja-build make cmake python3-pip --no-install-recommends
-
-# set compilation environment for wamrc
-# - wamr repo
-# - cmake
-# - wasi-sdk
-# - wamr-sdk
-
-# - download wasi-sdk with wget and set up to /opt/wasi-sdk
-RUN wget --progress=dot:giga https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-19/wasi-sdk-19.0-linux.tar.gz \
- && tar -zxf wasi-sdk-*-linux.tar.gz \
- && mv wasi-sdk-19.0 /opt/wasi-sdk/ \
- && rm -f wasi-sdk-*-linux.tar.gz
-
-## - clone wamr repo
-RUN git clone -b main --depth=1 https://github.com/bytecodealliance/wasm-micro-runtime.git
-
-WORKDIR /root/wasm-micro-runtime/build-scripts
-RUN pip3 install --no-cache-dir --user -r requirements.txt
-
-WORKDIR /root/wasm-micro-runtime/wamr-compiler
-RUN ./build_llvm.sh \
- && mkdir build
-
-WORKDIR /root/wasm-micro-runtime/wamr-compiler/build
-RUN cmake .. \
- && make \
- # - copy the wamrc to /root
- && cp /root/wasm-micro-runtime/wamr-compiler/build/wamrc /root/wamrc \
- && mkdir -p /opt/wamr-sdk \
- && cp -r /root/wasm-micro-runtime/wamr-sdk/app /opt/wamr-sdk/ \
- && mv /root/wamr_toolchain.cmake /opt/wamr-sdk/app \
- # - remove the wamr repo to save the size
- && rm -fr /root/wasm-micro-runtime
-
-# ## STAGE 2
-FROM ubuntu:22.04
-ENV HOME_DIR=/home/wasm-toolchain
-
-RUN mkdir -p /opt/wasi-sdk \
- && mkdir -p /opt/wamr-sdk/app \
- && mkdir -p /home/wasm-toolchain
-
-# COPY files from BASE image
-COPY --from=BASE /opt/wamr-sdk/app/ /opt/wamr-sdk/app/
-COPY --from=BASE /opt/wasi-sdk /opt/wasi-sdk/
-COPY --from=BASE /root/wamrc ${HOME_DIR}
-COPY --from=BASE /root/build_wasm.sh ${HOME_DIR}
-
-RUN ln -s ${HOME_DIR}/wamrc /usr/bin/wamrc
-
-# hadolint ignore=DL3008
-RUN apt-get update && apt-get install -y cmake make --no-install-recommends \
- && apt-get clean -y \
- && rm -rf /var/lib/apt/lists/*
-
-WORKDIR ${HOME_DIR}
diff --git a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/README.md b/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/README.md
deleted file mode 100644
index f5ecb957..00000000
--- a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/README.md
+++ /dev/null
@@ -1,18 +0,0 @@
-### Build Docker Image
-
-- Linux
-
- ```shell
- ./build_docker_image.sh
- ```
-
-- Windows
-
- ```shell
- ./build_docker_image.bat
- ```
-
-### Resource Details
-
-- `Dockerflie` is the source file to build `wasm-debug-server` docker image.
-- `resource/build_wasm.sh` is the script to compile the wasm app with `wasi-sdk`.
diff --git a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/build_docker_image.bat b/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/build_docker_image.bat
deleted file mode 100644
index 96fb0287..00000000
--- a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/build_docker_image.bat
+++ /dev/null
@@ -1,9 +0,0 @@
-@REM Copyright (C) 2019 Intel Corporation. All rights reserved.
-@REM SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-
-@echo off
-
-docker build -t wasm-toolchain:1.0 .
-
-@REM delete intermediate docker image
-docker image prune -f
diff --git a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/build_docker_image.sh b/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/build_docker_image.sh
deleted file mode 100755
index aa1e2f5e..00000000
--- a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/build_docker_image.sh
+++ /dev/null
@@ -1,9 +0,0 @@
-#!/bin/bash
-
-# Copyright (C) 2019 Intel Corporation. All rights reserved.
-# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-
-docker build -t wasm-toolchain:1.0 .
-
-# delete intermediate docker image
-docker image prune -f
diff --git a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/resource/build_wasm.sh b/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/resource/build_wasm.sh
deleted file mode 100755
index 3d8c06c4..00000000
--- a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/resource/build_wasm.sh
+++ /dev/null
@@ -1,25 +0,0 @@
-# Copyright (C) 2019 Intel Corporation. All rights reserved.
-# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-
-#!/bin/bash
-export CC=/opt/wasi-sdk/bin/clang
-export CXX=/opt/wasi-sdk/bin/clang++
-
-cd /mnt
-if [ -d build ];then
- rm -fr build
-fi
-
-mkdir -p build && cd build
-echo "========> compile wasm with wasi-sdk"
-cmake -DWASI_SDK_DIR=/opt/wasi-sdk -DCMAKE_TOOLCHAIN_FILE=/opt/wamr-sdk/app/wamr_toolchain.cmake ../.wamr && make
-
-if [ $? -eq 0 ]; then
- echo "========> compile wasm to AoT with wamrc"
- # target name will be provided:
- # - user input the target name in IDE
- # - generated wasm binary name will be set as user's input target name
- # - aot binary name should be the same as wasm binary name
- # - target name will be provided through 1st parameter
- wamrc -o $1.aot $1.wasm
-fi \ No newline at end of file
diff --git a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/resource/wamr_toolchain.cmake b/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/resource/wamr_toolchain.cmake
deleted file mode 100755
index 97b82cc9..00000000
--- a/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/test-tools/wamr-ide/WASM-Toolchain/Docker/resource/wamr_toolchain.cmake
+++ /dev/null
@@ -1,33 +0,0 @@
-# Copyright (C) 2019 Intel Corporation. All rights reserved.
-# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-
-SET (CMAKE_SYSTEM_NAME Linux)
-SET (CMAKE_SYSTEM_PROCESSOR wasm32)
-SET (CMAKE_SYSROOT ${CMAKE_CURRENT_LIST_DIR}/libc-builtin-sysroot)
-
-IF (NOT (DEFINED WASI_SDK_DIR OR DEFINED CACHE{WASI_SDK_DIR}))
- SET (WASI_SDK_DIR "/opt/wasi-sdk")
-ELSE ()
- MESSAGE (STATUS "WASI_SDK_DIR=${WASI_SDK_DIR}")
- LIST (APPEND CMAKE_TRY_COMPILE_PLATFORM_VARIABLES "WASI_SDK_DIR")
-ENDIF ()
-
-
-SET (CMAKE_C_FLAGS "-nostdlib" CACHE INTERNAL "")
-SET (CMAKE_C_COMPILER_TARGET "wasm32")
-SET (CMAKE_C_COMPILER "${WASI_SDK_DIR}/bin/clang")
-
-SET (CMAKE_CXX_FLAGS "-nostdlib" CACHE INTERNAL "")
-SET (CMAKE_CXX_COMPILER_TARGET "wasm32")
-SET (CMAKE_CXX_COMPILER "${WASI_SDK_DIR}/bin/clang++")
-
-SET (CMAKE_EXE_LINKER_FLAGS
- "-Wl,--no-entry,--fatal-warnings" CACHE INTERNAL "")
-
-SET (CMAKE_LINKER "${WASI_SDK_DIR}/bin/wasm-ld" CACHE INTERNAL "")
-SET (CMAKE_AR "${WASI_SDK_DIR}/bin/llvm-ar" CACHE INTERNAL "")
-SET (CMAKE_NM "${WASI_SDK_DIR}/bin/llvm-nm" CACHE INTERNAL "")
-SET (CMAKE_OBJDUMP "${WASI_SDK_DIR}/bin/llvm-dwarfdump" CACHE INTERNAL "")
-SET (CMAKE_RANLIB "${WASI_SDK_DIR}/bin/llvm-ranlib" CACHE INTERNAL "")
-SET (CMAKE_EXE_LINKER_FLAGS
- "${CMAKE_EXE_LINKER_FLAGS},--allow-undefined-file=${CMAKE_SYSROOT}/share/defined-symbols.txt" CACHE INTERNAL "") \ No newline at end of file