fix_suppress_clang_-wdeprecated-declarations_in_libuv.patch 950 B

1234567891011121314151617181920212223242526272829
  1. From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
  2. From: deepak1556 <[email protected]>
  3. Date: Tue, 16 Nov 2021 20:05:57 +0900
  4. Subject: fix: suppress clang -Wdeprecated-declarations in libuv
  5. Should be upstreamed.
  6. diff --git a/deps/uv/src/win/util.c b/deps/uv/src/win/util.c
  7. index a96cb915930a30a49ba55fd7d15ea48f0b471f89..3c15f348bd3a9a42afcf0e4d0182d2d6f3d05cb1 100644
  8. --- a/deps/uv/src/win/util.c
  9. +++ b/deps/uv/src/win/util.c
  10. @@ -1537,10 +1537,17 @@ int uv_os_uname(uv_utsname_t* buffer) {
  11. #ifdef _MSC_VER
  12. #pragma warning(suppress : 4996)
  13. #endif
  14. + #ifdef __clang__
  15. + #pragma clang diagnostic push
  16. + #pragma clang diagnostic ignored "-Wdeprecated-declarations"
  17. + #endif
  18. if (GetVersionExW(&os_info) == 0) {
  19. r = uv_translate_sys_error(GetLastError());
  20. goto error;
  21. }
  22. + #ifdef __clang__
  23. + #pragma clang diagnostic pop
  24. + #endif
  25. }
  26. /* Populate the version field. */