Skip to content

Commit

Permalink
build: Add liburing on Linux
Browse files Browse the repository at this point in the history
  • Loading branch information
tavianator committed Oct 2, 2023
1 parent 52de184 commit 90840f7
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 5 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,10 @@ jobs:
libcap-dev \
libcap2:i386 \
libonig-dev \
libonig5:i386
libonig5:i386 \
liburing-dev
# Ubuntu doesn't let you install the -dev packages for both amd64 and
# i386 at once, so we make our own symlinks to fix -m32 -lacl -lattr -lcap
# i386 at once, so we make our own symlinks to fix -m32 -lacl -l...
sudo ln -s libacl.so.1 /lib/i386-linux-gnu/libacl.so
sudo ln -s libattr.so.1 /lib/i386-linux-gnu/libattr.so
sudo ln -s libcap.so.2 /lib/i386-linux-gnu/libcap.so
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/codecov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@ jobs:
libattr1-dev \
libcap2-bin \
libcap-dev \
libonig-dev
libonig-dev \
liburing-dev
- name: Generate coverage
run: |
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ jobs:
libattr1-dev \
libcap2-bin \
libcap-dev \
libonig-dev
libonig-dev \
liburing-dev
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
Expand Down
8 changes: 7 additions & 1 deletion GNUmakefile
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ ifndef NOLIBS
USE_ACL := y
USE_ATTR := y
USE_LIBCAP := y
USE_LIBURING := y
endif

ifdef USE_ACL
Expand All @@ -146,6 +147,11 @@ else
LOCAL_CPPFLAGS += -DBFS_USE_SYS_CAPABILITY_H=0
endif

ifdef USE_LIBURING
LOCAL_CPPFLAGS += -DBFS_USE_LIBURING=1
LOCAL_LDLIBS += -luring
endif

LOCAL_LDFLAGS += -Wl,--as-needed
LOCAL_LDLIBS += -lrt
endif # Linux
Expand Down Expand Up @@ -287,7 +293,7 @@ ifneq ($(OS),Darwin)
endif
+$(MAKE) -B tsan ubsan check CC=clang $(DISTCHECK_FLAGS)
ifeq ($(OS) $(ARCH),Linux x86_64)
+$(MAKE) -B check EXTRA_CFLAGS="-m32" ONIG_CONFIG= $(DISTCHECK_FLAGS)
+$(MAKE) -B check EXTRA_CFLAGS="-m32" ONIG_CONFIG= USE_LIBURING= $(DISTCHECK_FLAGS)
endif
+$(MAKE) -B release check $(DISTCHECK_FLAGS)
+$(MAKE) -B check $(DISTCHECK_FLAGS)
Expand Down
2 changes: 2 additions & 0 deletions docs/BUILDING.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,11 +75,13 @@ These dependencies are optional, and can be turned off at build time if necessar
| [acl] | Linux only | `USE_ACL` |
| [attr] | Linux only | `USE_ATTR` |
| [libcap] | Linux only | `USE_LIBCAP` |
| [liburing] | Linux only | `USE_LIBURING` |
| [Oniguruma] | All | `USE_ONIGURUMA` |

[acl]: https://savannah.nongnu.org/projects/acl
[attr]: https://savannah.nongnu.org/projects/attr
[libcap]: https://sites.google.com/site/fullycapable/
[liburing]: https://github.com/axboe/liburing
[Oniguruma]: https://github.com/kkos/oniguruma

### Dependency tracking
Expand Down

0 comments on commit 90840f7

Please sign in to comment.