Skip to content

Commit 966ac9d

Browse files
committed
ci: test pkg-config file
As mentioned in #3252 (comment) , this patch adds a CI job that builds and installs libzstd on the job runner, and then compiles a sample binary linking against the installed library; the needed build flags are passed by invoking pkg-config.
1 parent 1c04514 commit 966ac9d

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

.github/workflows/dev-short-tests.yml

+16
Original file line numberDiff line numberDiff line change
@@ -410,6 +410,22 @@ jobs:
410410
run: |
411411
sde-external-9.0.0-2021-11-07-lin/sde -cet -cet-raise 0 -cet-endbr-exe -cet-stderr -cet-abort -- ./zstd -b3
412412
413+
pkg-config:
414+
runs-on: ubuntu-latest
415+
container:
416+
image: debian:testing
417+
steps:
418+
- uses: actions/checkout@v3
419+
- name: Install dependencies
420+
run: |
421+
apt -y update
422+
apt -y install --no-install-recommends gcc libc6-dev make pkg-config
423+
- name: Build and install
424+
run: make -C lib install
425+
- name: Test pkg-config
426+
run: |
427+
cc -Wall -Wextra -Wpedantic -Werror -o simple examples/simple_compression.c $(pkg-config --cflags --libs libzstd)
428+
./simple LICENSE
413429
414430
415431
# This test currently fails on Github Actions specifically.

0 commit comments

Comments
 (0)