qgroundcontrol.pri 4.79 KB
Newer Older
Hugo Vincent's avatar
Hugo Vincent committed
1 2 3 4
#-------------------------------------------------
#
# MAVGround - Micro Air Vehicle Groundstation
# 
5
# Please see our website at <http://qgroundcontrol.org>
Hugo Vincent's avatar
Hugo Vincent committed
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
#
# Original Author:
# Lorenz Meier <mavteam@student.ethz.ch>
#
# Contributing Authors (in alphabetical order):
# 
# (c) 2009 PIXHAWK Team
#
# This file is part of the mav groundstation project
# MAVGround is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# MAVGround is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with MAVGround. If not, see <http://www.gnu.org/licenses/>.
#
#-------------------------------------------------

pixhawk's avatar
pixhawk committed
28 29 30 31
#$$BASEDIR/lib/qextserialport/include
#               $$BASEDIR/lib/openjaus/libjaus/include \
#               $$BASEDIR/lib/openjaus/libopenJaus/include

Hugo Vincent's avatar
Hugo Vincent committed
32 33
message(Qt version $$[QT_VERSION])

34 35 36 37
release {
#    DEFINES += QT_NO_DEBUG_OUTPUT
#    DEFINES += QT_NO_WARNING_OUTPUT
}
Hugo Vincent's avatar
Hugo Vincent committed
38 39 40

# MAC OS X
macx { 
41

42
    HARDWARE_PLATFORM = $$system(uname -a)
43 44
    contains( HARDWARE_PLATFORM, 9.6.0 ) || contains( HARDWARE_PLATFORM, 9.7.0 ) || contains( HARDWARE_PLATFORM, 9.8.0 ) || || contains( HARDWARE_PLATFORM, 9.9.0 )
    {
pixhawk's avatar
pixhawk committed
45 46 47
        # x86 Mac OS X Leopard 10.5 and earlier
        CONFIG += x86 cocoa phonon
        message(Building for Mac OS X 32bit/Leopard 10.5 and earlier)
48

49 50
                # Enable function-profiling with the OS X saturn tool
                debug {
51 52
                        #QMAKE_CXXFLAGS += -finstrument-functions
                        #LIBS += -lSaturn
53
                }
pixhawk's avatar
pixhawk committed
54
    } else {
55 56
        # x64 Mac OS X Snow Leopard 10.6 and later
        CONFIG += x86_64 cocoa
pixhawk's avatar
pixhawk committed
57
        CONFIG -= x86 phonon
58
        message(Building for Mac OS X 64bit/Snow Leopard 10.6 and later)
59
    }
Hugo Vincent's avatar
Hugo Vincent committed
60

61
    QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.6
Hugo Vincent's avatar
Hugo Vincent committed
62 63 64

    DESTDIR = $$BASEDIR/bin/mac
    INCLUDEPATH += -framework SDL \
65
        $$BASEDIR/../mavlink/contrib/slugs/include \
lm's avatar
lm committed
66
        $$BASEDIR/../mavlink/include
Hugo Vincent's avatar
Hugo Vincent committed
67 68

    LIBS += -framework IOKit \
Hugo Vincent's avatar
Hugo Vincent committed
69 70 71
        -framework SDL \
        -framework CoreFoundation \
        -framework ApplicationServices \
pixhawk's avatar
pixhawk committed
72
 #       -framework GLUT \
Hugo Vincent's avatar
Hugo Vincent committed
73 74 75 76 77 78 79
        -lm
    
    ICON = $$BASEDIR/images/icons/macx.icns
}

# GNU/Linux
linux-g++ { 
80 81

    CONFIG += debug
Hugo Vincent's avatar
Hugo Vincent committed
82 83 84 85 86 87 88 89
    
    debug {
        DESTDIR = $$BASEDIR
    }

    release {
        DESTDIR = $$BASEDIR
    }
90
    INCLUDEPATH += /usr/include \
pixhawk's avatar
pixhawk committed
91
                   /usr/include/qt4/phonon
lm's avatar
lm committed
92 93
              # $$BASEDIR/lib/flite/include \
              # $$BASEDIR/lib/flite/lang
94

Hugo Vincent's avatar
Hugo Vincent committed
95

96
    HARDWARE_PLATFORM = $$system(uname -a)
Hugo Vincent's avatar
Hugo Vincent committed
97 98
    contains( HARDWARE_PLATFORM, x86_64 ) {
        # 64-bit Linux
lm's avatar
lm committed
99 100
        #LIBS += \
            #-L$$BASEDIR/lib/flite/linux64
101
        message(Building for GNU/Linux 64bit/x64)
Hugo Vincent's avatar
Hugo Vincent committed
102 103
    } else {
        # 32-bit Linux
lm's avatar
lm committed
104 105
        #LIBS += \
           #-L$$BASEDIR/lib/flite/linux32
106
        message(Building for GNU/Linux 32bit/i386)
107
    }
108 109 110
    LIBS += \
        -L/usr/lib \
        -lm \
111
        -lflite_cmu_us_kal \
112 113 114 115
        -lflite_usenglish \
        -lflite_cmulex \
        -lflite \
        -lSDL \
pixhawk's avatar
pixhawk committed
116
        -lSDLmain
117

lm's avatar
lm committed
118 119
        #-lflite_cmu_us_rms \
        #-lflite_cmu_us_slt \
120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152
}

linux-g++-64 {
    CONFIG += debug

    debug {
        DESTDIR = $$BASEDIR
    }

    release {
        DESTDIR = $$BASEDIR
    }
    INCLUDEPATH += /usr/include \
                   /usr/include/qt4/phonon
              # $$BASEDIR/lib/flite/include \
              # $$BASEDIR/lib/flite/lang


    HARDWARE_PLATFORM = $$system(uname -a)
    contains( HARDWARE_PLATFORM, x86_64 ) {
        # 64-bit Linux
        #LIBS += \
            #-L$$BASEDIR/lib/flite/linux64
        message(Building for GNU/Linux 64bit/x64)
    } else {
        # 32-bit Linux
        #LIBS += \
           #-L$$BASEDIR/lib/flite/linux32
        message(Building for GNU/Linux 32bit/i386)
    }
    LIBS += \
        -L/usr/lib \
        -lm \
153
        -lflite_cmu_us_kal \
154 155 156
        -lflite_usenglish \
        -lflite_cmulex \
        -lflite \
Hugo Vincent's avatar
Hugo Vincent committed
157
        -lSDL \
pixhawk's avatar
pixhawk committed
158
        -lSDLmain
Hugo Vincent's avatar
Hugo Vincent committed
159 160 161
}


Hugo Vincent's avatar
Hugo Vincent committed
162
# Windows (32bit/64bit)
Hugo Vincent's avatar
Hugo Vincent committed
163 164 165 166 167
win32 { 

    message(Building for Windows Platform (32/64bit))
    
    # Special settings for debug
Hugo Vincent's avatar
Hugo Vincent committed
168
    #CONFIG += CONSOLE
unknown's avatar
unknown committed
169

170 171
    INCLUDEPATH += $$BASEDIR\lib\sdl\include \
                   $$BASEDIR\lib\opal\include #\ #\
pixhawk's avatar
pixhawk committed
172
                   #"C:\Program Files\Microsoft SDKs\Windows\v7.0\Include"
Hugo Vincent's avatar
Hugo Vincent committed
173

unknown's avatar
unknown committed
174 175 176 177 178
    LIBS += -L$$BASEDIR\lib\sdl\win32 \
             -lmingw32 -lSDLmain -lSDL -mwindows



Hugo Vincent's avatar
Hugo Vincent committed
179 180 181 182 183 184 185 186
    debug {
        DESTDIR = $$BASEDIR/bin
    }

    release {
        DESTDIR = $$BASEDIR/bin
    }
        
187
    RC_FILE = $$BASEDIR/qgroundcontrol.rc
Hugo Vincent's avatar
Hugo Vincent committed
188 189
}

190

191