pkgsrc-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: boost-libs on macOS Ventura (13.x)
On 5/23/23 08:49, Greg Troxel wrote:
But is it really that -x c is wrong, or that it is calling c++?
I think the question to resolve is whether it is proper to call a c++
compile to compile a C file, in general (across all compilers).
"Proper" is a fuzzy term. Compiling C files with a C++ compiler is
supported by GCC and LLVM, though. This is why the -x flag exists.
Neither compiler issues any warnings when -x c is used.
clang++ -x c hello.c
./a.out
Hello!
g++ -x c hello.c
./a.out
Hello!
clang++ hello.c
clang++: warning: treating 'c' input as 'c++' when in C++ mode, this
behavior is deprecated [-Wdeprecated]
I consider it rather hokey myself, but as long as the compilers support
it, we'll have to deal with it occasionally as packagers.
The question, as I see it, is do we deal with it once via a check in the
wrapper, or multiple times using redundant patches for individual packages?
Home |
Main Index |
Thread Index |
Old Index