Skip to content

Commit

Permalink
addon: Use C++17
Browse files Browse the repository at this point in the history
The build was failing on gcc 7.
  • Loading branch information
eilvelia committed Oct 5, 2023
1 parent e2420ca commit 85c90d0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ TDLib version 1.5.0 or newer is required.
- The tdjson shared library (`libtdjson.so` on Linux, `libtdjson.dylib` on macOS, `tdjson.dll` on Windows)
- In some cases, a C++ compiler and Python installed to build the node addon[^1]

[^1]: `tdl` is packaged with pre-built addons for Windows (x86_64), GNU/Linux (x86_64, glibc >= 2.17), and macOS (x86_64, aarch64). If a pre-built binary is not available for your system, then the node addon will be built using node-gyp, requiring Python and a C++ toolchain (C++14 is required) to be installed (on Windows, MSVS or Build Tools). Pass `--build-from-source` to never use the pre-built binaries. Note that macOS aarch64 binaries aren't tested.
[^1]: `tdl` is packaged with pre-built addons for Windows (x86_64), GNU/Linux (x86_64, glibc >= 2.17), and macOS (x86_64, aarch64). If a pre-built binary is not available for your system, then the node addon will be built using node-gyp, requiring Python and a C++ toolchain (C++17 is required) to be installed (on Windows, MSVS or Build Tools). Pass `--build-from-source` to never use the pre-built binaries. Note that macOS aarch64 binaries aren't tested.

<a name="installation"></a>
## Installation
Expand Down
4 changes: 2 additions & 2 deletions packages/tdl/binding.gyp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
'cflags!': [ '-fno-exceptions' ],
'cflags_cc!': [ '-fno-exceptions' ],
'cflags': [ '-Wall', '-Wextra' ],
'cflags_cc': [ '-Wall', '-Wextra', '-std=c++14' ],
'cflags_cc': [ '-Wall', '-Wextra', '-std=c++17' ],
'sources': [
'addon/td.cpp'
],
Expand All @@ -29,7 +29,7 @@
'xcode_settings': {
'GCC_SYMBOLS_PRIVATE_EXTERN': 'YES', # -fvisibility=hidden
'WARNING_CFLAGS': [ '-Wall', '-Wextra' ],
'OTHER_CPLUSPLUSFLAGS': [ '-std=c++14' ],
'OTHER_CPLUSPLUSFLAGS': [ '-std=c++17' ],
'MACOSX_DEPLOYMENT_TARGET': '10.14'
}
}]
Expand Down

0 comments on commit 85c90d0

Please sign in to comment.