Skip to content

Commit

Permalink
Add CFLAGS=-static on macOS
Browse files Browse the repository at this point in the history
  • Loading branch information
will-v-pi committed Sep 7, 2024
1 parent d3c64dd commit df87c58
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/macos/openocd/build-openocd.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ sed -i -e 's/uint /unsigned int /g' ./src/flash/nor/rp2040.c
./bootstrap
# See https://github.com/raspberrypi/openocd/issues/30
# ./configure --disable-werror CAPSTONE_CFLAGS="$(pkg-config capstone --cflags | sed s/.capstone\$//)"
./configure LDFLAGS=-static --disable-werror
./configure CFLAGS=-static LDFLAGS=-static --disable-werror
make clean
make -j$(nproc)
INSTALLDIR="$PWD/../openocd-install/usr/local/bin"
Expand Down
2 changes: 1 addition & 1 deletion packages/macos/riscv/build-riscv-gcc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ GDB_TARGET_FLAGS_EXTRA="--with-gmp=/opt/homebrew --with-mpfr=/opt/homebrew"
export GDB_TARGET_FLAGS_EXTRA

cd riscv-gnu-toolchain
./configure LDFLAGS=-static --prefix=$BUILDDIR/$INSTALLDIR --with-arch=rv32ima_zicsr_zifencei_zba_zbb_zbs_zbkb_zca_zcb --with-abi=ilp32 --with-multilib-generator="rv32ima_zicsr_zifencei_zba_zbb_zbs_zbkb_zca_zcb-ilp32--;rv32imac_zicsr_zifencei_zba_zbb_zbs_zbkb-ilp32--" --with-gcc-src=$BUILDDIR/gcc
./configure CFLAGS=-static LDFLAGS=-static --prefix=$BUILDDIR/$INSTALLDIR --with-arch=rv32ima_zicsr_zifencei_zba_zbb_zbs_zbkb_zca_zcb --with-abi=ilp32 --with-multilib-generator="rv32ima_zicsr_zifencei_zba_zbb_zbs_zbkb_zca_zcb-ilp32--;rv32imac_zicsr_zifencei_zba_zbb_zbs_zbkb-ilp32--" --with-gcc-src=$BUILDDIR/gcc
# 4 threads, as 8 threads runs out of memory
make -j4

Expand Down

0 comments on commit df87c58

Please sign in to comment.