Skip to content

Commit

Permalink
Move EV_STANDALONE definition to extconf.rb (#250)
Browse files Browse the repository at this point in the history
Move the EV_STANDALONE to extconf.rb
  • Loading branch information
boazsegev committed Sep 15, 2020
1 parent 77f859a commit bc5e5b6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 2 additions & 0 deletions ext/nio4r/extconf.rb
Expand Up @@ -22,6 +22,8 @@
$defs << "-DEV_USE_PORT" if have_type("port_event_t", "port.h")
$defs << "-DHAVE_SYS_RESOURCE_H" if have_header("sys/resource.h")

$defs << "-DEV_STANDALONE" # prevent libev from assuming "config.h" exists

CONFIG["optflags"] << " -fno-strict-aliasing" unless RUBY_PLATFORM =~ /mswin/

dir_config "nio4r_ext"
Expand Down
2 changes: 0 additions & 2 deletions ext/nio4r/libev.h
@@ -1,5 +1,3 @@
#define EV_STANDALONE /* keeps ev from requiring config.h */

#ifdef _WIN32
#define EV_SELECT_IS_WINSOCKET 1
#define EV_USE_MONOTONIC 0
Expand Down

0 comments on commit bc5e5b6

Please sign in to comment.