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 errors using Linux (both with gcc 13.2.1 and clang 17.0.6) #435

Open
plafl opened this issue Aug 24, 2024 · 3 comments
Open

Build errors using Linux (both with gcc 13.2.1 and clang 17.0.6) #435

plafl opened this issue Aug 24, 2024 · 3 comments

Comments

@plafl
Copy link

plafl commented Aug 24, 2024

My system:

Linux fedora 6.6.4-200.fc39.x86_64 #1 SMP PREEMPT_DYNAMIC Sun Dec  3 18:13:11 UTC 2023 x86_64 GNU/Linux
Fedora release 39 (Thirty Nine)

Compiler versions:

gcc (GCC) 13.2.1 20231205 (Red Hat 13.2.1-6)
clang version 17.0.6 (Fedora 17.0.6-1.fc39)

Commit (latest on main): 39e01e61f8de07b99859df04b271a02a53d9aeb2

Errors detected with both compilers (in several submodules: OpenEXR, flip for the first, glfw for the second):

  • uintptr_t and uint32_t not defined, compiler suggests to include missing stdint header file
  • Implicit function declaration not allowed

Possible fix (it works on my machine): add the following two lines to CMakeLists.txt:

add_definitions(-include stdint.h)
add_definitions(-Wno-implicit-function-declaration)
@pbrt4bounty
Copy link
Contributor

I have a similar issue with 'stdint' when I uses LLVM-mingw under Windows. I solved here adding new flag in PtexInt.h
imagen
FYI.. I always use this compilers here: https://github.com/mstorsjo/llvm-mingw
Cheers..!

@genmeblog
Copy link

Similar here... src/pbrt-v4/src/ext/openexr/OpenEXR/IlmImf/ImfDwaCompressor.cpp:176:1: note: ‘uintptr_t’ is defined in header ‘<cstdint>’; did you forget to ‘#include <cstdint>’
Since I don't know cmake any idea what to add and where to make it working?

@mmp
Copy link
Owner

mmp commented Nov 24, 2024

  • The OpenEXR one be fixed now in ebd7bfa.
  • I see #include <cstdint> already in flip/flip.cpp. What error are you seeing there?
  • glfw was updated to the latest release, 3.4, in e9e1180. Can you see if that fixes it?
  • ptex should be fixed in c9b2d99.

When you have a chance, could you update pbrt to the latest version and see if it build correctly now?

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

No branches or pull requests

4 participants