Bug 2229365 - clang error in gcc std
Summary: clang error in gcc std
Keywords:
Status: CLOSED COMPLETED
Alias: None
Product: Fedora
Classification: Fedora
Component: clang16
Version: 38
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Tulio Magno Quites Machado Filho
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-08-05 10:19 UTC by alex.krivoschecov
Modified: 2023-12-17 04:25 UTC (History)
1 user (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2023-08-18 09:37:13 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description alex.krivoschecov 2023-08-05 10:19:00 UTC
In file included from /usr/bin/../lib/gcc/x86_64-redhat-linux/13/../../../../include/c++/13/iostream:41: 
In file included from /usr/bin/../lib/gcc/x86_64-redhat-linux/13/../../../../include/c++/13/ostream:40: 
In file included from /usr/bin/../lib/gcc/x86_64-redhat-linux/13/../../../../include/c++/13/ios:40: 
In file included from /usr/bin/../lib/gcc/x86_64-redhat-linux/13/../../../../include/c++/13/iosfwd:42:
In file included from /usr/bin/../lib/gcc/x86_64-redhat-linux/13/../../../../include/c++/13/bits/postypes.h:40: 
In file included from /usr/bin/../lib/gcc/x86_64-redhat-linux/13/../../../../include/c++/13/cwchar:44: /usr/include/wchar.h:35:10: fatal error: 'stddef.h' file not found
#include <stddef.h>

Reproducible: Always

Steps to Reproduce:
1.Create simple hello world
2.clang++ -Wall  hello.cpp -o hello
3.error
Actual Results:  
error in std

Expected Results:  
compile a hello world programm

clang version 16.0.6(Fedora 16.0.6-4fc38
target: x86_64-redhat-linux-gnu
thread model:posix
installedDir: /usr/bin
gcc version 13.2.1 20230728(RedHat 13.2.1-1)

Comment 1 Tulio Magno Quites Machado Filho 2023-08-07 13:01:05 UTC
I can't reproduce this issue.

```
$ rpm -q clang clang-libs gcc
clang-16.0.6-2.fc38.x86_64
clang-libs-16.0.6-2.fc38.x86_64
gcc-13.2.1-1.fc38.x86_64
$ cat hello.cpp 
#include <iostream>

int main() {
  std::cout << "Hello World!" << std::endl;

  return 0;
}

$ clang++ -Wall  hello.cpp -o hello
$ ./hello 
Hello World!
```

@alex.krivoschecov Could you provide more details, please?
What is the output from `rpm -q clang clang-libs gcc` ?

Comment 2 Red Hat Bugzilla 2023-12-17 04:25:05 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 120 days


Note You need to log in before you can comment on or make changes to this bug.