Skip to content

Commit

Permalink
add config tests in GPSBabel.pro.
Browse files Browse the repository at this point in the history
specifically, we look for stdarg.h and unistd.h for zlib.
  • Loading branch information
tsteven4 committed May 12, 2018
1 parent 86668e0 commit a8e4d14
Show file tree
Hide file tree
Showing 8 changed files with 24 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
/gpsbabel.html
/gpsbabel.pdf
/Makefile
/.qmake.cache
/.qmake.stash
/GPSBabel
*.o
/GPSBabel[0-9]*.[0-9]*.[0-9]*/
/GPSBabel[0-9]*.[0-9]*.[0-9]*.tar.bz2
Expand Down
12 changes: 11 additions & 1 deletion GPSBabel.pro
Original file line number Diff line number Diff line change
Expand Up @@ -134,8 +134,18 @@ HEADERS = \

INCLUDEPATH += zlib

load(configure)

macx|linux {
DEFINES += HAVE_NANOSLEEP HAVE_LIBUSB HAVE_GLOB HAVE_UNISTD_H
qtCompileTest(unistd) {
# this is used by zlib
DEFINES += HAVE_UNISTD_H
}
qtCompileTest(stdarg) {
# this is used by zlib
DEFINES += HAVE_STDARG_H
}
DEFINES += HAVE_NANOSLEEP HAVE_LIBUSB HAVE_GLOB
SOURCES += gbser_posix.cc
JEEPS += jeeps/gpslibusb.cc
INCLUDEPATH += jeeps
Expand Down
2 changes: 2 additions & 0 deletions config.tests/stdarg/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/Makefile
/stdarg
2 changes: 2 additions & 0 deletions config.tests/stdarg/main.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#include <stdarg.h>
int main() { return 0; }
1 change: 1 addition & 0 deletions config.tests/stdarg/stdarg.pro
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
SOURCES = main.cpp
2 changes: 2 additions & 0 deletions config.tests/unistd/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/Makefile
/unistd
2 changes: 2 additions & 0 deletions config.tests/unistd/main.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#include <unistd.h>
int main() { return 0; }
1 change: 1 addition & 0 deletions config.tests/unistd/unistd.pro
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
SOURCES = main.cpp

0 comments on commit a8e4d14

Please sign in to comment.