Skip to content

cmake: fix AR searching#76

Merged
ligurio merged 1 commit intomasterfrom
ligurio/fix-ar-found
Jan 20, 2026
Merged

cmake: fix AR searching#76
ligurio merged 1 commit intomasterfrom
ligurio/fix-ar-found

Conversation

@ligurio
Copy link
Owner

@ligurio ligurio commented Jan 19, 2026

The luzer library requires ar (archiver tool) for rebuilding libFuzzer archive. By default, CMAKE_C_COMPILER_AR is used. However, in OSS Fuzz environment (afl, address, x86_64) CMAKE_C_COMPILER_AR returns CMAKE_C_COMPILER_AR-NOTFOUND [1]. The patch adds a fallback to CMAKE_AR that successfully finds ar at the same environment.

Also, there is the following note regarding both CMake variables - CMAKE_AR vs. CMAKE_C_COMPILER_AR:

  • CMAKE_AR is a general variable for the default archiver tool.
  • CMAKE_C_COMPILER_AR is specific to the C language's toolchain. When certain features like Interprocedural Optimization (LTO) are enabled, CMake might favor the language-specific CMAKE_C_COMPILER_AR (or CMAKE_CXX_COMPILER_AR for C++) over the generic CMAKE_AR.
  1. tarantool: support luzer-based testing google/oss-fuzz#14656 (comment)

Needed for google/oss-fuzz#14656

ligurio added a commit to ligurio/lunapark that referenced this pull request Jan 19, 2026
The new version contains changes [1][2] required for OSS Fuzz
support.

1. ligurio/luzer#73
2. ligurio/luzer#76

Needed for tarantool/tarantool#12097
Needed for tarantool/tarantool#11250
Needed for google/oss-fuzz#14656
Related to google/oss-fuzz#13782
ligurio added a commit to ligurio/lunapark that referenced this pull request Jan 19, 2026
The new version contains changes [1][2] required for OSS Fuzz
support.

1. ligurio/luzer#73
2. ligurio/luzer#76

Needed for tarantool/tarantool#12097
Needed for tarantool/tarantool#11250
Needed for google/oss-fuzz#14656
Related to google/oss-fuzz#13782
ligurio added a commit to ligurio/nanodata that referenced this pull request Jan 19, 2026
The new version contains changes [1][2] required for OSS Fuzz
support.

1. ligurio/luzer#73
2. ligurio/luzer#76

Needed for tarantool#12097
Needed for tarantool#11250
Needed for google/oss-fuzz#14656
Related to google/oss-fuzz#13782

NO_CHANGELOG=build
NO_DOC=build
NO_TEST=build
@ligurio ligurio requested a review from Buristan January 19, 2026 12:17
Copy link
Collaborator

@Buristan Buristan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi, Sergey!
Thanks for the patch!
LGTM!

ligurio added a commit to ligurio/nanodata that referenced this pull request Jan 19, 2026
The new version contains changes [1][2] required for OSS Fuzz
support.

1. ligurio/luzer#73
2. ligurio/luzer#76

Needed for tarantool#12097
Needed for tarantool#11250
Needed for google/oss-fuzz#14656
Related to google/oss-fuzz#13782

NO_CHANGELOG=build
NO_DOC=build
NO_TEST=build
ligurio added a commit to ligurio/oss-fuzz that referenced this pull request Jan 19, 2026
sudo python infra/helper.py build_fuzzers tarantool
sudo python infra/helper.py check_build tarantool decimal_new_test
sudo python infra/helper.py run_fuzzer tarantool decimal_new_test

Depends on google#13929
Depends on ligurio/lunapark#163
Depends on ligurio/luzer#73
Depends on ligurio/luzer#76
Depends on tarantool/tarantool#12097
@ligurio ligurio force-pushed the ligurio/fix-ar-found branch from 704449c to 784c33f Compare January 19, 2026 19:30
The luzer library requires `ar` (archiver tool) for rebuilding
libFuzzer archive. By default, CMAKE_C_COMPILER_AR is used. However,
in OSS Fuzz environment (afl, address, x86_64) CMAKE_C_COMPILER_AR
returns CMAKE_C_COMPILER_AR-NOTFOUND [1]. The patch adds
a fallback to CMAKE_AR that successfully finds `ar` at the same
environment.

Also, there is the following note regarding both CMake variables -
CMAKE_AR vs. CMAKE_C_COMPILER_AR:

- CMAKE_AR is a general variable for the default archiver tool.
- CMAKE_C_COMPILER_AR is specific to the C language's toolchain.
  When certain features like Interprocedural Optimization (LTO)
  are enabled, CMake might favor the language-specific
  CMAKE_C_COMPILER_AR (or CMAKE_CXX_COMPILER_AR for C++) over the
  generic CMAKE_AR.

1. google/oss-fuzz#14656 (comment)

Needed for google/oss-fuzz#14656
Follows up #73
@ligurio ligurio force-pushed the ligurio/fix-ar-found branch from 784c33f to e2e6735 Compare January 20, 2026 11:11
@ligurio ligurio merged commit 872ef18 into master Jan 20, 2026
16 checks passed
@ligurio ligurio deleted the ligurio/fix-ar-found branch January 20, 2026 11:13
ligurio added a commit to ligurio/lunapark that referenced this pull request Jan 20, 2026
The new version contains changes [1][2] required for OSS Fuzz
support and other changes:

- cmake: fix AR searching
- luzer: fix handling two dashes in console arguments
- cmake: disable LLVM version check
- cmake: fix search of libraries on OSS Fuzz
- cmake: install sanitizers libraries

1. ligurio/luzer#73
2. ligurio/luzer#76

Needed for tarantool/tarantool#12097
Needed for tarantool/tarantool#11250
Needed for google/oss-fuzz#14656
Related to google/oss-fuzz#13782
ligurio added a commit to ligurio/oss-fuzz that referenced this pull request Jan 20, 2026
sudo python infra/helper.py build_fuzzers tarantool
sudo python infra/helper.py check_build tarantool decimal_new_test
sudo python infra/helper.py run_fuzzer tarantool decimal_new_test

Depends on google#13929
Depends on ligurio/lunapark#163
Depends on ligurio/luzer#73
Depends on ligurio/luzer#76
Depends on tarantool/tarantool#12097
ligurio added a commit to ligurio/nanodata that referenced this pull request Jan 20, 2026
The new version contains changes [1][2] required for OSS Fuzz
support and other changes:

- cmake: fix AR searching
- luzer: fix handling two dashes in console arguments
- cmake: disable LLVM version check
- cmake: fix search of libraries on OSS Fuzz
- cmake: install sanitizers libraries
- readme: fix links to tests
- doc: update contribution guide

1. ligurio/luzer#73
2. ligurio/luzer#76

Needed for tarantool#12097
Needed for tarantool#11250
Needed for google/oss-fuzz#14656
Related to google/oss-fuzz#13782

NO_CHANGELOG=build
NO_DOC=build
NO_TEST=build
ligurio added a commit to ligurio/lunapark that referenced this pull request Jan 20, 2026
The new version contains changes [1][2] required for OSS Fuzz
support and other changes:

- cmake: fix AR searching
- luzer: fix handling two dashes in console arguments
- cmake: disable LLVM version check
- cmake: fix search of libraries on OSS Fuzz
- cmake: install sanitizers libraries

1. ligurio/luzer#73
2. ligurio/luzer#76

Needed for tarantool/tarantool#12097
Needed for tarantool/tarantool#11250
Needed for google/oss-fuzz#14656
Related to google/oss-fuzz#13782
ligurio added a commit to ligurio/oss-fuzz that referenced this pull request Jan 20, 2026
sudo python infra/helper.py build_fuzzers tarantool
sudo python infra/helper.py check_build tarantool decimal_new_test
sudo python infra/helper.py run_fuzzer tarantool decimal_new_test

Depends on google#13929
Depends on ligurio/lunapark#163
Depends on ligurio/luzer#73
Depends on ligurio/luzer#76
Depends on tarantool/tarantool#12097
ligurio added a commit to ligurio/oss-fuzz that referenced this pull request Jan 20, 2026
sudo python infra/helper.py build_fuzzers tarantool
sudo python infra/helper.py check_build tarantool decimal_new_test
sudo python infra/helper.py run_fuzzer tarantool decimal_new_test

Depends on google#13929
Depends on ligurio/lunapark#163
Depends on ligurio/luzer#73
Depends on ligurio/luzer#76
Depends on tarantool/tarantool#12097
ligurio added a commit to ligurio/nanodata that referenced this pull request Jan 21, 2026
The new version contains changes [1][2] required for OSS Fuzz
support and other changes:

- cmake: introduce CMake option OSS_FUZZ
- cmake: fix AR searching
- luzer: fix handling two dashes in console arguments
- cmake: disable LLVM version check
- cmake: fix search of libraries on OSS Fuzz
- cmake: install sanitizers libraries
- readme: fix links to tests
- doc: update contribution guide

1. ligurio/luzer#73
2. ligurio/luzer#76

Needed for tarantool#12097
Needed for tarantool#11250
Needed for google/oss-fuzz#14656
Related to google/oss-fuzz#13782

NO_CHANGELOG=build
NO_DOC=build
NO_TEST=build
ligurio added a commit to ligurio/nanodata that referenced this pull request Jan 21, 2026
The new version contains changes [1][2] required for OSS Fuzz
support and other changes:

- cmake: introduce CMake option OSS_FUZZ
- cmake: fix AR searching
- luzer: fix handling two dashes in console arguments
- cmake: disable LLVM version check
- cmake: fix search of libraries on OSS Fuzz
- cmake: install sanitizers libraries
- readme: fix links to tests
- doc: update contribution guide

1. ligurio/luzer#73
2. ligurio/luzer#76

Needed for tarantool#12097
Needed for tarantool#11250
Needed for google/oss-fuzz#14656
Related to google/oss-fuzz#13782

NO_CHANGELOG=build
NO_DOC=build
NO_TEST=build
ligurio added a commit to ligurio/oss-fuzz that referenced this pull request Jan 21, 2026
sudo python infra/helper.py build_fuzzers tarantool
sudo python infra/helper.py check_build tarantool decimal_new_test
sudo python infra/helper.py run_fuzzer tarantool decimal_new_test

Depends on google#13929
Depends on ligurio/lunapark#163
Depends on ligurio/luzer#73
Depends on ligurio/luzer#76
Depends on tarantool/tarantool#12097
ligurio added a commit to ligurio/oss-fuzz that referenced this pull request Jan 21, 2026
sudo python infra/helper.py build_fuzzers tarantool
sudo python infra/helper.py check_build tarantool decimal_new_test
sudo python infra/helper.py run_fuzzer tarantool decimal_new_test

Depends on google#13929
Depends on ligurio/lunapark#163
Depends on ligurio/luzer#73
Depends on ligurio/luzer#76
Depends on tarantool/tarantool#12097
Buristan pushed a commit to tarantool/tarantool that referenced this pull request Jan 21, 2026
The new version contains changes [1][2] required for OSS Fuzz
support and other changes:

- cmake: introduce CMake option OSS_FUZZ
- cmake: fix AR searching
- luzer: fix handling two dashes in console arguments
- cmake: disable LLVM version check
- cmake: fix search of libraries on OSS Fuzz
- cmake: install sanitizers libraries
- readme: fix links to tests
- doc: update contribution guide

1. ligurio/luzer#73
2. ligurio/luzer#76

Needed for #12097
Needed for #11250
Needed for google/oss-fuzz#14656
Related to google/oss-fuzz#13782

NO_CHANGELOG=build
NO_DOC=build
NO_TEST=build
ligurio added a commit to ligurio/oss-fuzz that referenced this pull request Jan 21, 2026
sudo python infra/helper.py build_fuzzers tarantool
sudo python infra/helper.py check_build tarantool decimal_new_test
sudo python infra/helper.py run_fuzzer tarantool decimal_new_test

Depends on google#13929
Depends on ligurio/luzer#73
Depends on ligurio/luzer#74
Depends on ligurio/luzer#76
Depends on ligurio/luzer#78
Depends on ligurio/lunapark#163
Depends on tarantool/tarantool#12097
ligurio added a commit to ligurio/oss-fuzz that referenced this pull request Jan 21, 2026
jonathanmetzman pushed a commit to google/oss-fuzz that referenced this pull request Jan 22, 2026
- [x] ~~Depends on #13929~~
- [x] ~~Depends on ligurio/luzer#74
- [x] ~~Depends on ligurio/luzer#76
- [x] ~~Depends on ligurio/luzer#78
- [x] ~~Depends on ligurio/lunapark#163
- [x] Depends on tarantool/tarantool#12097
ranok pushed a commit to ranok/oss-fuzz that referenced this pull request Jan 22, 2026
- [x] ~~Depends on google#13929~~
- [x] ~~Depends on ligurio/luzer#74
- [x] ~~Depends on ligurio/luzer#76
- [x] ~~Depends on ligurio/luzer#78
- [x] ~~Depends on ligurio/lunapark#163
- [x] Depends on tarantool/tarantool#12097
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants