Skip to content

Commit

Permalink
OSS-Fuzz: limit link jobs to 4
Browse files Browse the repository at this point in the history
For introspector builds using LTO, memory usage can become quite
heavy. To prevent potential OOM errors, limit Ninja to using no
more than 4 processes for linking.

Might fix the introspector build after PR libvips#4092.
  • Loading branch information
kleisauke committed Aug 23, 2024
1 parent d08f555 commit 7abb23c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fuzz/oss_fuzz_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ popd
# Disable building man pages, gettext po files, tools, and tests
sed -i "/subdir('man')/{N;N;N;d;}" meson.build
meson setup build --prefix=$WORK --libdir=lib --prefer-static --default-library=static --buildtype=debugoptimized \
-Ddeprecated=false -Dexamples=false -Dcplusplus=false -Dmodules=disabled \
-Dbackend_max_links=4 -Ddeprecated=false -Dexamples=false -Dcplusplus=false -Dmodules=disabled \
-Dfuzzing_engine=oss-fuzz -Dfuzzer_ldflags="$LIB_FUZZING_ENGINE" \
-Dcpp_link_args="$LDFLAGS -Wl,-rpath=\$ORIGIN/lib"
meson install -C build --tag devel
Expand Down

0 comments on commit 7abb23c

Please sign in to comment.