Skip to main content

Questions tagged [clang]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
23 votes
3 answers
4k views

Why does clang generate unintelligible text when redirected?

I am trying to save the output of a command to a file. The command is: clang -Xclang -ast-dump -fsyntax-only main.cpp > output.txt However the resulting output.txt file when opened (by gedit and ...
abzullah's user avatar
  • 347
11 votes
2 answers
8k views

How to install clangd (not clang) on mac os

I installed xcode, llvm, brew, and I have clang on my system but not clangd ..., I googled around and only find how install clang not clangd. I tried brew install clangd but not found clangd. I even ...
shelper's user avatar
  • 637
9 votes
2 answers
10k views

Which binary clang version I should use for CentOS

Based on http://llvm.org/releases/download.html Clang Binaries for FreeBSD9/x86_64 (69M)(.sig) Clang Binaries for Ubuntu-12.04/x86 (67M)(.sig) Clang Binaries for Ubuntu-12.04/x86_64 (71M)(.sig) ...
q0987's user avatar
  • 966
8 votes
5 answers
24k views

How to install clang-format on MinGW (Windows)?

I tried searching with pacman -Ss for clang-format, git-clang-format, etc, but I'm not having any luck. However, I have seen some references to it on some other websites, implying it may exist (or ...
Tyler Shellberg's user avatar
8 votes
0 answers
1k views

Change compile flags for Homebrew

We're building a large C++ application on OS X Yosemite 10.10. This application relies on a number of third-party libraries which we install using Homebrew prior to building our application. Our ...
François Beaune's user avatar
6 votes
1 answer
7k views

How do I install Clang 4.0 on Ubuntu 14.04?

I need to install Clang 4.0 and Clang++ 4.0 on my Ubuntu 14.04 box. The most recent version I can find in the apt-get package list is 3.5. How do I install 4.0?
Robert Oschler's user avatar
4 votes
1 answer
4k views

Install a deleted homebrew formulae

Recently, homebrew decided to remove clang-omp from the list of formulae available to install from. Is there any way to retrieve it? Or would I have to download and build clang-omp bit manually?
coatless's user avatar
  • 171
3 votes
1 answer
5k views

install LLVM 9 wiht WSL Ubuntu

I am trying to install the last stable version with the script in the page: https://apt.llvm.org/ However I have the following error: Reading package lists... Done + apt-get install -y clang-9 lldb-...
Mac Fly's user avatar
  • 131
3 votes
1 answer
291 views

Does a better/newer C or C++ compiler produce more performant compiled code? Or do they just perform faster/better while compiling?

I am not a C or C++ programmer myself, but I often use software that needs to be compiled or otherwise depends on a compiler, like some R packages. Will that software actually perform better if I use ...
shadowtalker's user avatar
3 votes
2 answers
2k views

Clang can't locate Homebrew-installed libportaudio

I installed libportaudio using Homebrew on OS X. The install succeeded and I verified there were symlinks to the actual headers and libraries in /usr/local/include and /usr/local/lib. However, I am ...
GolDDranks's user avatar
2 votes
1 answer
3k views

cmath compilation errors with clang-10 on Mac OS Catalina

I recently installed llvm via brew with brew install llvm, in order to use clang with OpenMP, on Mac OS 10.15.4 Catalina $ which clang /usr/local/opt/llvm/bin/clang $ clang -v clang version 10.0.0 ...
EB2127's user avatar
  • 123
2 votes
1 answer
565 views

cmake error encountered when build clang-query

I encountered the following error when I was trying to build clang-query. parallels@ubuntu18:~/myllvm/llvm/tools/clang/tools/extra/clang-query$ cmake . -- The C compiler identification is GNU 7.3.0 --...
isPrime's user avatar
  • 21
2 votes
1 answer
2k views

Are clang and llvm no longer maintained in cygwin?

I cannot find binaries for clang or llvm using cygwin's setup.exe. Are they no longer maintained?
Nevermoe's user avatar
  • 121
2 votes
0 answers
348 views

Custom-defined type highlighting in Sublime Text

I am looking for a configuration/combination of plugins + clang (or any other parser) that can allow sublime text to highlight all custom defined types just like it highlights native types such as int,...
niko's user avatar
  • 408
1 vote
1 answer
402 views

Cannot Build Swift on FreeBSD - REPL error

I am attempting to install Swift 3 on FreeBSD 10.2 using the official build script but am unable to do so. I am receiving the following error: fatal error: too many errors emitted, stopping now [-...
Brandon Bradley's user avatar
1 vote
1 answer
118 views

clang (even with no args) takes 0.7 seconds to execute

$ time nonexistent-command zsh: command not found: nonexistent-command nonexistent-command 0.00s user 0.00s system 0% cpu 0.425 total $ time clang clang: error: no input files clang 0.01s user 0.68s ...
Kalle's user avatar
  • 121
1 vote
1 answer
575 views

QT android make returns cannot find -lc++

I'm on Pop!_OS (ubuntu based distro) running Qt creator 4.9.2 with Qt 5.13.0 and am currently trying to build an app for android. When I try to build my app for desktop I have no error, but when I try ...
faz95's user avatar
  • 21
1 vote
0 answers
147 views

How to get the list of vendor/CPU/FPU/ABI/etc. from LLVM CL, and their meaningI?

I got all the "architectures" using this: llc --version It lists the architectures. Then for each architecture, you can get the CPUs and "features" (not sure what "features&...
Lance's user avatar
  • 387
1 vote
0 answers
786 views

Clang disable Case Sensitive header file inclusion

In Linux when invoking clang compiler with clang++ with Command for the code, main.cpp: #include "Sample.h" int main() { return 0; } include/sample.h # HEADER FILE IMPLEMENTATION ...
Veno's user avatar
  • 119
1 vote
0 answers
229 views

OpenMP with Clang in Visual Studio

I am trying to get access to version 4.0 of OpenMP. In order to do that I used the Visual Studio installer to get Clang, which is supposed to have support for OpenMP. However, when I try to build my ...
JHadamard's user avatar
1 vote
0 answers
779 views

clang on cygwin fails to produce executable from C++ source

I'm trying to use clang on cygwin to compile C++ files but the executable it produces fails to run. I get runtime failures from cygwin: Cygwin runtime failure: a.exe: Invalid relocation. Offset ...
it3q's user avatar
  • 11
1 vote
1 answer
1k views

How can I install python3-clang on Linux Mint 18.04?

I have a vim plugin called CLighter8 that requires the package python3-clang, but unfortnuately I can't find it in the default repository nor any other repository. So I can't really find a way to ...
user2741831's user avatar
1 vote
0 answers
219 views

What does "selecting 'python-clang-3.8' for regex 'clang-3.8'" mean?

I'm working on a Raspberry Pi 3. The device uses Raspbian, which is Debian derivative. I'm trying to install Clang 3.8 because Clang 3.7 appears to lack proper sanitizer support. When I run the ...
jww's user avatar
  • 12.2k
1 vote
1 answer
2k views

How to update the Clang compiler from version 3.1 to version 3.4 in Debian Linux?

It is as what the question is saying, I am new on Linux. I need the Clang++ compiler update to version 3.4 for the assignment that I need to do. I simply just typed in Terminal sudo apt-get install ...
user3595342's user avatar
1 vote
0 answers
153 views

Sublime TextEditor 2 in Vintage mode completion

I have several problem with my autocompletion which I want to fix: I have completion by Space. I want that when I press Space means I don't want completion I want a space symbol now. I want to choose ...
user14416's user avatar
  • 378
0 votes
1 answer
1k views

If you have to use the `-llibary` option in clang

Wondering if you have to use the -llib option in clang. For instance: clang -lasdf foo.c -o foo.o will link library /usr/local/lib/libasdf.dylib to foo.c, but wondering if there is any way to not ...
Lance's user avatar
  • 387
0 votes
0 answers
31 views

Need Clang version at least 16

I am tried to compile the Apache Doris on macOS 13.3.1 follow by this document: https://doris.apache.org/docs/install/source-install/compilation-mac/. When I run the bash build.sh command, shows error ...
Dolphin's user avatar
  • 197
0 votes
0 answers
208 views

How can I determine the compiler which processes a header file?

I want to compile a C/C++ project in an Ubuntu environment. My problem is that at some point it encounters a header file where __stdc_version__ is not defined and since both -Werror and -Wundef are ...
Felix Crazzolara's user avatar
0 votes
0 answers
388 views

Where to find/how to install libclang-*.so.1 on CentOS?

I am trying to find a library of libclang-*.so.1 on centOS, but didn't find it anywhere. I have already installed clang. Any suggestions are welcome.
John M.'s user avatar
  • 143
0 votes
0 answers
472 views

Questions on ungoogled-chromium compile time

I started the ungoogled-chromium install from the aur last night, went to bed, and woke up and it's still only about 3/4 of the way complete. I was expecting it to take awhile, but I did not think it ...
alrob's user avatar
  • 125
0 votes
1 answer
87 views

Linker Issue(s) with Compilation Configuration Settings on Catalina for Building Octave

I am getting linker errors building Octave on OS X 10.15.7 with clang++. E.g. "bsxfun_add(intNDArray<octave_int > const&, intNDArray<octave_int > const&)", referenced ...
dbl001's user avatar
  • 129
0 votes
1 answer
3k views

What version of Clang does Visual Studio 2019 16.1.3 come with?

I've been trying to find out so I can determine what clang-format options are supported or not. However, I cannot find the clang executable anywhere, it is not in the same location in the Community ...
Tyler Shellberg's user avatar
0 votes
0 answers
267 views

Which shell do VS Code extensions use?

here,I got the problem that the same command run in the Windows CMD as run by the clang-tidy extension works for CMD but not in VS Code. Therefore I ask myself if (and if yes, which) another type of ...
bambino307's user avatar
0 votes
1 answer
4k views

The C compiler "/usr/bin/clang" is not able to compile a simple test program

Why does my C compiler (Clang) fail to compile a simple test program when opening a CMake project in CLion? I'm trying to setup CLion to run with CMake, Ninja, Clang and Clang++. To test it I tried ...
Kim Viggedal's user avatar
0 votes
0 answers
147 views

How do I install Clang 4.0 or above on Ubuntu 16.04 LTS?

I need to install Clang 3.4 and above on Ubuntu 16.04 LTS, as a prerequisite to this Package that I need to use. Not sure should if I go for the latest Clang version, and if yes, how can I do it for ...
innuendo's user avatar
  • 103
0 votes
1 answer
519 views

clang: error: no such file or directory: '_REENTRANT'

I am trying to install UDUNITS-2 package for the graphical visual browser: ncview. Can anyone help me understand the following error message: clang: error: no such file or directory: '_REENTRANT' A ...
Brendan Darrer's user avatar
0 votes
1 answer
2k views

Doxygen cannot find the shared library(s) 'libclang.so.6: version `LLVM_6.0'' which it requires to run

I installed doxygen from the binary distribution for Linux x86-64. I'm running Ubuntu 17.10. The installation went smoothly. When I try to run doxygen, it shows the following error: doxygen: error ...
Sreyam's user avatar
  • 3
0 votes
1 answer
606 views

Unknown option -pthread in LD

This is a follow up from this issue on Github. Basically, on OS X El Capitan, I get this message: ld: unknown option: -pthread clang: error: linker command failed with exit code 1 (use -v to see ...
hpm's user avatar
  • 113
0 votes
0 answers
754 views

Installing Homebrew on OSX 10.9

I am trying to install Homebrew with this commands: ruby -e "$(curl -fsSL https://raw.github.com/Homebrew/homebrew/go/install)" # Add Homebrews binary path to the front of the $PATH echo 'export ...
MaPi's user avatar
  • 113
-1 votes
1 answer
203 views

Conditional statements with braces versus without braces - which is fast in C, C++ [closed]

I know this is silly, but I'm quite curious to know that is there any speed difference using conditional statement (i.e. for, if, while, do while) in C++ with braces and without braces. FYI : I know ...
Deepam Gupta's user avatar