Comments (4)
Recent gcc versions compile C++14 by default. If you're using an older version, add the flag to the "configure" command line:
./configure CXXFLAGS='-std=c++11'
(Of course you can also say c++14 to get a more modern dialect.)
I could add this option in the configure script, but that opens the door to questions like: What if your compiler uses a different option for this? Which C++ versions does your compiler version support? What if you want a different C++ version? What if the compiler defaults to a newer version?
So the best solution, I think, is to set this option in your "configure" until your systems are upgraded to more recent compiler versions. I was tempted to make C++14 the minimum, but I kept it to C++11 for now to minimise these problems...
from libpqxx.
Thanks, didn't know. I barely know autotools but CMake has CXX_STANDARD
option. If there is something similar you may add this to configure script.
from libpqxx.
I don't know of anything like that, but now that you bring it up, I did notice something strange: on an older gcc, if I passed -std=c++17
or -std=c++20
, the command line would still say -std=c++14
β I guess maybe that was the newest standard which that compiler supported.
So probably there is some logic for picking the C++ standard in there. But I'm sort of afraid to mess with it! :)
from libpqxx.
I just got "configure" to add the C++11 option. This does mean that autogen.sh now requires the autoconf-archive package.
from libpqxx.
Related Issues (20)
- c++17 compiler test needs -std=c++17 HOT 10
- Cant get pqxx to download on windows 64 HOT 3
- exec_prepared not working with runtime parameter list HOT 3
- Compilation Error: Invalid Use of 'this' at Top Level in range.hxx (libpqxx 7.8.0, openSUSE Leap 15.5) HOT 4
- Deprecated: `char_traits<T>` in LLVM 18 HOT 5
- Undefined symbols: `pqxx::usage_error::usage_error` on macOS ARM64 HOT 9
- `conn.close();` and `string_traits` errors HOT 6
- version 6.4.5 there is small issue. HOT 3
- VCPKG from 7.7.4 to 7.8.1 HOT 44
- Lib LNK failure on windows.I build the lib by myself HOT 14
- Cannot connect to DB with URL HOT 4
- win32 link ws2_32 dont work HOT 17
- Compile error - error: invalid use of βthisβ at top level HOT 10
- vcpkg installation - link errors HOT 7
- Bind results of selects directly to a variable of type std::vector for array types HOT 9
- Efficient UUIDs HOT 3
- How to pass custom class to postgres function HOT 65
- PQXX_VERSION says '7.9.0' but I used tag 7.8.1 HOT 1
- User code won't compile with C++20 or C++23 HOT 4
- `splitconfig` should be `splitconfig.py`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from libpqxx.