From e05065f58c36d3cf9c7da4f5703c0fb5775f7a41 Mon Sep 17 00:00:00 2001 From: Catalin Petrescu Date: Sun, 26 Nov 2017 21:26:30 -0500 Subject: [PATCH] Small adjustment so it builds on FreeBSD --- gcode.cpp | 2 +- rs232.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/gcode.cpp b/gcode.cpp index a998aca..8ddb100 100644 --- a/gcode.cpp +++ b/gcode.cpp @@ -50,7 +50,7 @@ void GCode::openPort(QString commPortStr, QString baudRate) addList(tr("-Is hardware connected to USB?") ); addList(tr("-Is correct port chosen?") ); addList(tr("-Does current user have sufficient permissions?") ); -#if defined(Q_OS_LINUX) +#if defined(Q_OS_LINUX) || defined(Q_OS_FREEBSD) addList("-Is current user in sudoers group?"); #endif //QMessageBox(QMessageBox::Critical,"Error","Could not open port.",QMessageBox::Ok).exec(); diff --git a/rs232.h b/rs232.h index a70ec55..95596d4 100644 --- a/rs232.h +++ b/rs232.h @@ -15,7 +15,7 @@ #include #include -#if defined(Q_OS_LINUX) || defined(Q_OS_MACX) || defined(Q_OS_ANDROID) +#if defined(Q_OS_LINUX) || defined(Q_OS_FREEBSD) || defined(Q_OS_MACX) || defined(Q_OS_ANDROID) #include #include "../termiosext.h" #include @@ -40,7 +40,7 @@ #include "definitions.h" -#if defined(Q_OS_LINUX) || defined(Q_OS_MACX) || defined(Q_OS_ANDROID) +#if defined(Q_OS_LINUX) || defined(Q_OS_FREEBSD) || defined(Q_OS_MACX) || defined(Q_OS_ANDROID) #define SLEEP(x) usleep(1000 * x); #else #define SLEEP(x) Sleep(x);