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

Build issue with SYCLomatic with GNU 14.1.0 #2640

Open
abagusetty opened this issue Jan 23, 2025 · 1 comment
Open

Build issue with SYCLomatic with GNU 14.1.0 #2640

abagusetty opened this issue Jan 23, 2025 · 1 comment
Labels
bug Something isn't working

Comments

@abagusetty
Copy link
Contributor

Describe the bug

Came across a build error when trying to build c2s with GNU 14.1.0 compilers.
CMake config is pretty standard one:

cmake -G Ninja -DCMAKE_INSTALL_PREFIX=$PATH_TO_C2S_INSTALL_FOLDER -DCMAKE_BUILD_TYPE=Release -DLLVM_ENABLE_PROJECTS="clang" -DLLVM_TARGETS_TO_BUILD="X86;NVPTX" ../llvm -DCMAKE_C_COMPILER=`which gcc` -DCMAKE_CXX_COMPILER=`which g++`; ninja install-c2s

Verbose commandline:

/soft/compilers/gcc/x86_64-suse-linux/14.1.0/bin/gcc -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Dear_EXPORTS -I/vast/users/abagusetty/compilers/SYCLomatic/build_hip6.3.0_01-23-2025/tools/clang/tools/scan-build-py -I/vast/users/abagusetty/compilers/SYCLomatic/clang/tools/scan-build-py -I/vast/users/abagusetty/compilers/SYCLomatic/llvm/../llvm-spirv/include -I/vast/users/abagusetty/compilers/SYCLomatic/clang/include -I/vast/users/abagusetty/compilers/SYCLomatic/build_hip6.3.0_01-23-2025/tools/clang/include -I/vast/users/abagusetty/compilers/SYCLomatic/build_hip6.3.0_01-23-2025/include -I/vast/users/abagusetty/compilers/SYCLomatic/llvm/include -I/vast/users/abagusetty/compilers/SYCLomatic/clang/tools/scan-build-py/lib/libear -fPIC -fno-semantic-interposition -Werror=date-time -fno-lifetime-dse -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wimplicit-fallthrough -Wno-cast-function-type -Wno-parentheses -Wno-uninitialized -Wno-unused-function -Wno-write-strings -Wno-array-bounds -Wno-comment -fdiagnostics-color -ffunction-sections -fdata-sections -Wformat -Wformat-security -Werror=format-security -fstack-protector-strong -O3 -DNDEBUG -fPIC -std=c99 -MD -MT tools/clang/tools/scan-build-py/CMakeFiles/ear.dir/lib/libear/ear.c.o -MF tools/clang/tools/scan-build-py/CMakeFiles/ear.dir/lib/libear/ear.c.o.d -o tools/clang/tools/scan-build-py/CMakeFiles/ear.dir/lib/libear/ear.c.o -c /vast/users/abagusetty/compilers/SYCLomatic/clang/tools/scan-build-py/lib/libear/ear.c

Error:

/vast/users/abagusetty/compilers/SYCLomatic/clang/tools/scan-build-py/lib/libear/ear.c:526:38: error: passing argument 2 of ‘(int (*)(const char *, struct statbuf *))fp’ from incompatible pointer type [-Wincompatible-pointer-types]
  526 |   int const result = (*fp)(pathname, statbuf);
      |                                      ^~~~~~~
      |                                      |
      |                                      struct stat *

To reproduce

No response

Environment

  • OS: openSUSE Leap 15.4
  • Target device and vendor: AMD MI300x

Additional context

No response

@abagusetty abagusetty added the bug Something isn't working label Jan 23, 2025
@tomflinda
Copy link
Contributor

@abagusetty #2642 is submitted to fix this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants