Skip to content

Commit

Permalink
fix ci windows
Browse files Browse the repository at this point in the history
  • Loading branch information
uchenily committed May 17, 2024
1 parent 3a75654 commit aebd562
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 10 deletions.
2 changes: 2 additions & 0 deletions meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ if cxx.get_id() == 'clang' and cxx.find_library('c++', required: false).found()
add_project_arguments(['-stdlib=libc++'], language: 'cpp')
add_project_link_arguments(['-stdlib=libc++', '-lc++abi'], language: 'cpp')
message('Compiler: LLVM/clang')
elif cxx.get_id() == 'msvc'
add_project_arguments('-DNOMINMAX', language : 'cpp')
endif

compile_args = []
Expand Down
11 changes: 1 addition & 10 deletions uvio/platform.hpp
Original file line number Diff line number Diff line change
@@ -1,17 +1,8 @@
#pragma once

// define NOMINMAX in front of windows.h
#if !defined(NOMINMAX) && defined(_WIN32)
#define WIN32_LEAN_AND_MEAN
// https://github.com/randombit/botan/issues/1852
#define NOMINMAX 1
#endif

// define macro NOMINMAX in build script
#if defined(_WIN32)
// winsock2.h must be in front of windows.h
#include <winsock2.h>
//
#include <windows.h>
#else
#include <netinet/in.h>
#include <sys/socket.h>
Expand Down

0 comments on commit aebd562

Please sign in to comment.