Skip to content

Commit

Permalink
SITL: cope with cygwin64
Browse files Browse the repository at this point in the history
  • Loading branch information
tridge committed Mar 2, 2018
1 parent 153ad95 commit d75e47a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions libraries/SITL/SIM_Aircraft.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#include <unistd.h>


#ifdef __CYGWIN__
#if defined(__CYGWIN__) || defined(__CYGWIN64__)
#include <windows.h>
#include <time.h>
#include <mmsystem.h>
Expand Down Expand Up @@ -54,7 +54,7 @@ Aircraft::Aircraft(const char *home_str, const char *frame_str) :
rate_hz(1200.0f),
autotest_dir(nullptr),
frame(frame_str),
#ifdef __CYGWIN__
#if defined(__CYGWIN__) || defined(__CYGWIN64__)
min_sleep_time(20000)
#else
min_sleep_time(5000)
Expand Down Expand Up @@ -429,7 +429,7 @@ void Aircraft::fill_fdm(struct sitl_fdm &fdm)

uint64_t Aircraft::get_wall_time_us() const
{
#ifdef __CYGWIN__
#if defined(__CYGWIN__) || defined(__CYGWIN64__)
static DWORD tPrev;
static uint64_t last_ret_us;
if (tPrev == 0) {
Expand Down
2 changes: 1 addition & 1 deletion libraries/SITL/SIM_FlightAxis.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ void *FlightAxis::update_thread(void *arg)
{
FlightAxis *flightaxis = (FlightAxis *)arg;

#ifdef __CYGWIN__
#if defined(__CYGWIN__) || defined(__CYGWIN64__)
//Cygwin doesn't support pthread_setname_np
#elif defined(__APPLE__) && defined(__MACH__)
pthread_setname_np("ardupilot-flightaxis");
Expand Down

0 comments on commit d75e47a

Please sign in to comment.