Shuai Zhang
65896fe00d
feat(bazel): enable symbolization ( #1116 )
...
Symbolization support on Linux and BSD requires link.h which is usually
provided by the GNU C Library (glibc). Assume the header to be present
at all times by unconditionally defining HAVE_SYMBOLIZE on the
corresponding platforms.
2024-08-02 20:38:49 +02:00
Vertexwahn
d76999015c
feat(bazel): port to bzlmod ( #1097 )
2024-06-08 16:02:59 +02:00
Victor Zheng PhD
31429d85b8
fix(bazel): add missing emscripten defines ( #1082 )
2024-03-11 11:20:22 +01:00
Sergiu Deitsch
7e6fca90e8
cmake: rework elf detection ( #1058 )
2024-01-10 14:06:18 +01:00
Sergiu Deitsch
ec455f2cc1
fix: better encapsulate internals ( #1055 )
2024-01-09 23:51:43 +01:00
Sergiu Deitsch
9377254062
feat(dbghelp): show source line number if present ( #1051 )
2024-01-08 19:04:22 +01:00
Sergiu Deitsch
89f5977468
cmake: determine when to use port.h ( #1037 )
...
Allow building using MSYS2 (without MinGW).
2024-01-05 19:57:34 +01:00
Sergiu Deitsch
8775a454c1
feat: make headers self-contained ( #1030 )
2024-01-04 21:03:55 +01:00
Sergiu Deitsch
dfce35c97c
fix: cleanup exports ( #1029 )
...
Reduce unnecessary utility function exports.
2024-01-04 16:57:18 +01:00
Sergiu Deitsch
0032896711
feat: use standard threads ( #1019 )
2024-01-03 02:24:52 +01:00
Sergiu Deitsch
8ff1a7db04
feat: use standard mutexes ( #1015 )
2024-01-02 00:47:22 +01:00
Sergiu Deitsch
e3f5398aa1
rework public header structure ( #1012 )
...
Promote generated headers to regular headers. This enables direct
editing of corresponding files and running automatic source code
formatting and static analysis tools, such as clang-format and
clang-tidy on the whole project which previously was not
straightforward.
2023-12-30 19:05:26 +01:00
Sergiu Deitsch
43792b8a13
rework (lib)unwind integration
...
Allow to switch between the two backends.
2023-12-30 00:50:52 +01:00
Sergiu Deitsch
3fcf77a691
fix: drop custom (v)snprintf definition ( #992 )
...
The functions are available since C++11.
2023-12-20 20:49:08 +01:00
Huy Q. Bui
4dbc26af72
feat: support log file truncation on windows ( #960 )
2023-10-08 14:03:10 +02:00
Rodrigo Queiro
3a0d4d22c5
Warn about dragons in the Bazel include path ( #927 )
...
https://github.com/google/glog/issues/837 has caused a couple of
disappointments for PR authors, so I'm hoping this comment can save them
some time, or even help them towards finding a complete solution for the
problem.
2023-06-05 11:08:12 +02:00
Mai Hussien
888f93947b
Move commandlineflags.h to shared_headers
2023-05-15 16:31:45 +02:00
Mai Hussien
4ffdf0dc78
Move shared headers to a private filegroup
2023-05-15 16:31:45 +02:00
Mai Hussien
7a62819e43
Fix targets for layering_check
2023-05-15 16:31:45 +02:00
Sergiu Deitsch
6742834201
move to C++14 ( #902 )
2023-02-28 12:26:49 +01:00
Peng Xiao
35f4efbb0a
bazel: Add HAVE_EXECINFO_H copts to fix empty stack trace
2023-02-28 12:10:03 +01:00
Sergiu Deitsch
1b59cb0905
drop custom prefix option ( #898 )
2023-02-24 20:40:09 +01:00
Rodrigo Queiro
9ad08ac6cc
Remove symbolize Bazel test
...
It is broken on Windows CI (#859 ) in a way that I don't understand.
2022-09-15 16:42:46 +02:00
Marek Cirkos
bfee415a1d
bazel: fix broken stacktrace ( #851 )
...
Since #846 , `HAVE_UNWIND_H` is not really in use. Instead we should use `HAVE__UNWIND_BACKTRACE` and `HAVE__UNWIND_GETIP` (added in #846 ). To prevent that from happening again, also added Bazel tests that confirm stacktrace are still working.
2022-08-16 18:48:59 +02:00
Sergiu Deitsch
a34226ca94
support ndk r25 ( #844 )
2022-08-01 10:46:35 +02:00
Yun Peng
79d692c645
Strip only the first leading @
...
This change is needed for glog to work with future version of Bazel when
canonical label literals is used in Bzlmod.
Context: https://docs.google.com/document/d/1N81qfCa8oskCk5LqTW-LNthy6EBrDot7bdUsjz6JFC4/edit#heading=h.5mcn15i0e1ch
2022-06-15 18:05:23 +02:00
Rodrigo Queiro
5addeedc0a
Fix "'GLOG_EXPORT' macro redefined" on clang-cl
...
The previous approach used
--incompatible_enable_cc_toolchain_resolution, which is recommended by
the docs, but a Bazel developer told me it's obsolete. The new, old
approach is simpler and should stop the warning from being user-visible.
2022-03-08 13:39:50 +01:00
Sergiu Deitsch
9f0b7d3bfe
renamed GOOGLE_GLOG_DLL_DECL to GLOG_EXPORT
...
Use a consistent naming and avoid platform specific terms. Also remove
copy and paste code.
2022-02-14 10:32:44 +01:00
Sergiu Deitsch
4ffa98388f
ensure _Unwind_Backtrace to actually be available
2021-12-21 11:38:12 +01:00
Sergiu Deitsch
dfb9ffc324
provide backward compatible send overload
2021-12-15 11:14:23 +01:00
Sergiu Deitsch
4a55b11580
ci: added linux github workflow
2021-10-11 15:54:42 +02:00
huangqinjin
3965584721
support stack unwind on Android
2021-10-08 22:14:20 +02:00
Sergiu Deitsch
8474b7854b
added gmock support
2021-10-07 19:53:08 +02:00
Artur
c34dbe9873
Fix syscall warning in Bazel Build
...
This commit resolves [#717 ](https://github.com/google/glog/issues/717 ) issue.
2021-10-07 19:43:48 +02:00
Sergiu Deitsch
f7407d4d27
export OS_* defines ( fixes #715 )
2021-10-01 11:26:07 +02:00
Dmitriy A
a1374c4200
Implement LOG_EVERY_T.
...
Use <chrono> and <atomic> for C++11 or greater.
For non-Windows pre-C++11 systems, use <time.h> and built-in atomic operations.
For Windows pre-C++11, use the Windows implementations for time and atomic operations.
2021-07-05 07:25:12 -07:00
luliyucoordinate
6e46c125e3
bazel: add GLOG_CUSTOM_PREFIX_SUPPORT
2021-07-01 08:04:18 +02:00
Sergiu Deitsch
d25a1b7bc0
cmake: export <atomic> availability ( fixes #667 )
2021-06-15 18:36:24 +02:00
Bret McKee
c7656c3ec1
CHECK support for nullptr ( fixes #341 )
...
This allows CHECK_NE(foo, nullptr) to compile and produces "nullptr" for the
string representation of nullptr.
2021-04-09 20:10:08 +02:00
Sergiu Deitsch
efc341d768
fixed windows builds
2021-04-08 18:16:42 +02:00
Rodrigo Queiro
1041a221b8
Use generated config.h for Windows.
...
This unblocks a simplification of the Windows CMake build.
2021-04-06 14:02:21 +02:00
Rodrigo Queiro
30bb9086d2
bazel: use expand_template instead of genrules
...
This lets us drop the dependency on the preprocessed headers in
src/windows/glog/.
For some reason, this lets Bazel realize we've failed to declare a
dependency on dirent.h, so I added that too.
2021-03-31 16:08:50 +02:00
Sergiu Deitsch
b442ef8070
build: set ac_cv___attribute___printf_4_5
2021-03-30 21:12:09 +02:00
Rodrigo Queiro
0863ad797c
bazel: declare headers in top-level rule
...
Fixes #596 .
2021-03-02 10:32:06 +01:00
Rodrigo Queiro
ce50c57b9e
Rename BUILD to BUILD.bazel.
...
This avoids conflicts with build/ on case-insensitive filesystems.
Fixes #606 .
2021-03-01 13:23:27 +01:00
Liang Zou
6d14ac3efe
Fix the symlink creation bug if using bazel
2021-02-20 17:34:31 +01:00
Phillipp Schoppmann
0a2e5931bd
Fix build for Emscripten ( #546 )
...
Add back config_setting for WASM (no HAVE_SYSCALL_H)
Since there is no config_setting for Linux
(https://github.com/bazelbuild/bazel/issues/11107 ), Linux needs to be
the default case.
2020-05-13 09:36:55 +09:00
Doug Rabson
3ba8976592
fix bazel build for freebsd
2020-03-25 10:17:39 +01:00
Rodrigo Queiro
1b7d541431
Add note about namespace on Win32.
2019-11-27 18:24:27 +01:00
Rodrigo Queiro
95a3655796
Remove unnecessary defines
...
The only macro referenced by the public headers is GOOGLE_GLOG_DLL_DECL.
This means fewer defines are propagated to rules that depend on glog.
2019-11-27 18:24:27 +01:00