Updated GDB build script
This commit is contained in:
parent
7facf8d89e
commit
885534ec82
2 changed files with 15 additions and 54 deletions
57
.github/workflows/build-gdb.yml
vendored
57
.github/workflows/build-gdb.yml
vendored
|
@ -15,20 +15,10 @@ jobs:
|
||||||
run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh
|
run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh
|
||||||
|
|
||||||
- name: Install build compiler
|
- name: Install build compiler
|
||||||
run: /bin/sh -c "cd / && curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz && tar -xf ${ARCH}-cross.tgz && rm ${ARCH}-cross.tgz && cd ${ARCH}-cross"
|
run: $GITHUB_WORKSPACE/02_install_build_compiler.sh x86_64
|
||||||
env:
|
|
||||||
ARCH: x86_64-linux-musl
|
|
||||||
HOST: http://musl.cc/
|
|
||||||
TEMP: /tmp
|
|
||||||
USER: 0
|
|
||||||
|
|
||||||
- name: Install dependencies workaround
|
- name: Install dependencies workaround
|
||||||
run: /bin/sh -c "cd / && curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz && tar -xf ${ARCH}-cross.tgz && rm ${ARCH}-cross.tgz && cd ${ARCH}-cross"
|
run: $GITHUB_WORKSPACE/02_install_build_compiler.sh i686
|
||||||
env:
|
|
||||||
ARCH: i686-linux-musl
|
|
||||||
HOST: http://musl.cc/
|
|
||||||
TEMP: /tmp
|
|
||||||
USER: 0
|
|
||||||
|
|
||||||
- name: Build GDB
|
- name: Build GDB
|
||||||
id: build_gdb
|
id: build_gdb
|
||||||
|
@ -54,20 +44,7 @@ jobs:
|
||||||
run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh
|
run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh
|
||||||
|
|
||||||
- name: Install build compiler
|
- name: Install build compiler
|
||||||
run: /bin/sh -c "cd / && curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz && tar -xf ${ARCH}-cross.tgz && rm ${ARCH}-cross.tgz && cd ${ARCH}-cross"
|
run: $GITHUB_WORKSPACE/02_install_build_compiler.sh x86_64
|
||||||
env:
|
|
||||||
ARCH: x86_64-linux-musl
|
|
||||||
HOST: http://musl.cc/
|
|
||||||
TEMP: /tmp
|
|
||||||
USER: 0
|
|
||||||
|
|
||||||
- name: Install dependencies workaround
|
|
||||||
run: /bin/sh -c "cd / && curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz && tar -xf ${ARCH}-cross.tgz && rm ${ARCH}-cross.tgz && cd ${ARCH}-cross"
|
|
||||||
env:
|
|
||||||
ARCH: x86_64-linux-musl
|
|
||||||
HOST: http://musl.cc/
|
|
||||||
TEMP: /tmp
|
|
||||||
USER: 0
|
|
||||||
|
|
||||||
- name: Build GDB
|
- name: Build GDB
|
||||||
id: build_gdb
|
id: build_gdb
|
||||||
|
@ -94,20 +71,10 @@ jobs:
|
||||||
run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh
|
run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh
|
||||||
|
|
||||||
- name: Install build compiler
|
- name: Install build compiler
|
||||||
run: /bin/sh -c "cd / && curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz && tar -xf ${ARCH}-cross.tgz && rm ${ARCH}-cross.tgz && cd ${ARCH}-cross"
|
run: $GITHUB_WORKSPACE/02_install_build_compiler.sh x86_64
|
||||||
env:
|
|
||||||
ARCH: x86_64-linux-musl
|
|
||||||
HOST: http://musl.cc/
|
|
||||||
TEMP: /tmp
|
|
||||||
USER: 0
|
|
||||||
|
|
||||||
- name: Install dependencies workaround
|
- name: Install dependencies workaround
|
||||||
run: /bin/sh -c "cd / && curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz && tar -xf ${ARCH}-cross.tgz && rm ${ARCH}-cross.tgz && cd ${ARCH}-cross"
|
run: $GITHUB_WORKSPACE/02_install_build_compiler.sh arm
|
||||||
env:
|
|
||||||
ARCH: arm-linux-musleabihf
|
|
||||||
HOST: http://musl.cc/
|
|
||||||
TEMP: /tmp
|
|
||||||
USER: 0
|
|
||||||
|
|
||||||
- name: Build gdb
|
- name: Build gdb
|
||||||
id: build_gdb
|
id: build_gdb
|
||||||
|
@ -134,20 +101,10 @@ jobs:
|
||||||
run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh
|
run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh
|
||||||
|
|
||||||
- name: Install build compiler
|
- name: Install build compiler
|
||||||
run: /bin/sh -c "cd / && curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz && tar -xf ${ARCH}-cross.tgz && rm ${ARCH}-cross.tgz && cd ${ARCH}-cross"
|
run: $GITHUB_WORKSPACE/02_install_build_compiler.sh x86_64
|
||||||
env:
|
|
||||||
ARCH: x86_64-linux-musl
|
|
||||||
HOST: http://musl.cc/
|
|
||||||
TEMP: /tmp
|
|
||||||
USER: 0
|
|
||||||
|
|
||||||
- name: Install dependencies workaround
|
- name: Install dependencies workaround
|
||||||
run: /bin/sh -c "cd / && curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz && tar -xf ${ARCH}-cross.tgz && rm ${ARCH}-cross.tgz && cd ${ARCH}-cross"
|
run: $GITHUB_WORKSPACE/02_install_build_compiler.sh aarch64
|
||||||
env:
|
|
||||||
ARCH: aarch64-linux-musl
|
|
||||||
HOST: http://musl.cc/
|
|
||||||
TEMP: /tmp
|
|
||||||
USER: 0
|
|
||||||
|
|
||||||
- name: Patch headers
|
- name: Patch headers
|
||||||
run: |
|
run: |
|
||||||
|
|
|
@ -1,12 +1,16 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -e
|
if [ -z "$GITHUB_WORKSPACE" ];then
|
||||||
set -o pipefail
|
echo "GITHUB_WORKSPACE environemnt variable not set!"
|
||||||
set -x
|
exit 1
|
||||||
|
fi
|
||||||
if [ "$#" -ne 1 ];then
|
if [ "$#" -ne 1 ];then
|
||||||
echo "Usage: ${0} [x86|x86_64|armhf|aarch64]"
|
echo "Usage: ${0} [x86|x86_64|armhf|aarch64]"
|
||||||
echo "Example: ${0} x86_64"
|
echo "Example: ${0} x86_64"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
set -e
|
||||||
|
set -o pipefail
|
||||||
|
set -x
|
||||||
source $GITHUB_WORKSPACE/build/lib.sh
|
source $GITHUB_WORKSPACE/build/lib.sh
|
||||||
init_lib $1
|
init_lib $1
|
||||||
|
|
||||||
|
@ -24,7 +28,7 @@ build_gdb() {
|
||||||
CMD+="CPP_FOR_BUILD=\"/x86_64-linux-musl-cross/bin/x86_64-linux-musl-g++\" "
|
CMD+="CPP_FOR_BUILD=\"/x86_64-linux-musl-cross/bin/x86_64-linux-musl-g++\" "
|
||||||
fi
|
fi
|
||||||
CMD+="${BUILD_DIRECTORY}/binutils-gdb/configure --build=x86_64-linux-musl --host=$(get_host_triple) "
|
CMD+="${BUILD_DIRECTORY}/binutils-gdb/configure --build=x86_64-linux-musl --host=$(get_host_triple) "
|
||||||
CMD+="--disable-shared --enable-static --enable-gdbserver --disable-nls"
|
CMD+="--disable-shared --enable-static --enable-gdbserver --disable-nls --disable-inprocess-agent"
|
||||||
|
|
||||||
mkdir -p "${BUILD_DIRECTORY}/gdb_build"
|
mkdir -p "${BUILD_DIRECTORY}/gdb_build"
|
||||||
cd "${BUILD_DIRECTORY}/gdb_build/"
|
cd "${BUILD_DIRECTORY}/gdb_build/"
|
||||||
|
|
Loading…
Reference in a new issue