Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add meson option for a static build #46

Merged
merged 1 commit into from
Nov 30, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .github/workflows/github-actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,10 @@ jobs:
run: sudo apt-get install -qq
gcc
gcc-arm-linux-gnueabi libc-dev-armel-cross
git meson device-tree-compiler qemu-user
git device-tree-compiler qemu-user
python3-pip ninja-build
- name: Install minimum meson
run: pip3 install --user meson~=0.63
- uses: actions/checkout@v2
- name: arm32
# meson compile requires 0.54, but Ubuntu 20.04 ships 0.53, so run ninja directly
Expand Down
2 changes: 1 addition & 1 deletion meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ project('culvert', 'c',
'b_lto=true',
'b_ndebug=true',
],
meson_version: '>=0.53.0',
meson_version: '>=0.63.0',
version: 'v0.4.0')
amboar marked this conversation as resolved.
Show resolved Hide resolved

add_global_link_arguments('-z', 'noexecstack', language: 'c')
Expand Down
4 changes: 4 additions & 0 deletions src/meson.build
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
fs = import('fs')

if get_option('prefer_static')
add_project_link_arguments('-static', language: 'c')
amboar marked this conversation as resolved.
Show resolved Hide resolved
endif

incdirs = [ '.' ]

src = files(
Expand Down
Loading