Skip to content
qgroundcontrol.pri 3.8 KiB
Newer Older
Hugo Vincent's avatar
Hugo Vincent committed
#-------------------------------------------------
#
# MAVGround - Micro Air Vehicle Groundstation
# 
# Please see our website at <http://qgroundcontrol.org>
Hugo Vincent's avatar
Hugo Vincent committed
#
# 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/>.
#
#-------------------------------------------------

QT       += network opengl svg xml phonon
Hugo Vincent's avatar
Hugo Vincent committed

TEMPLATE = app
TARGET = qgroundcontrol
Hugo Vincent's avatar
Hugo Vincent committed

BASEDIR = .
BUILDDIR = build
LANGUAGE = C++

pixhawk's avatar
pixhawk committed
CONFIG += debug_and_release console
Hugo Vincent's avatar
Hugo Vincent committed

OBJECTS_DIR = $$BUILDDIR/obj
MOC_DIR = $$BUILDDIR/moc
UI_HEADERS_DIR = src/ui/generated

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

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



# MAC OS X
macx { 
    HARDWARE_PLATFORM = $$system(uname -a)
pixhawk's avatar
pixhawk committed
    contains( HARDWARE_PLATFORM, 9.8.0 ) {
        # 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)

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

Hugo Vincent's avatar
Hugo Vincent committed
    QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.5
Hugo Vincent's avatar
Hugo Vincent committed

    DESTDIR = $$BASEDIR/bin/mac
    INCLUDEPATH += -framework SDL \
lm's avatar
lm committed
        $$BASEDIR/../mavlink/include
Hugo Vincent's avatar
Hugo Vincent committed

    LIBS += -framework IOKit \
Hugo Vincent's avatar
Hugo Vincent committed
        -framework SDL \
        -framework CoreFoundation \
        -framework ApplicationServices \
Hugo Vincent's avatar
Hugo Vincent committed
        -lm
    
    ICON = $$BASEDIR/images/icons/macx.icns
}

# GNU/Linux
linux-g++ { 
Hugo Vincent's avatar
Hugo Vincent committed
    
    debug {
        DESTDIR = $$BASEDIR
    }

    release {
        DESTDIR = $$BASEDIR
    }
    INCLUDEPATH += /usr/include \
pixhawk's avatar
pixhawk committed
                   /usr/include/qt4/phonon
lm's avatar
lm committed
              # $$BASEDIR/lib/flite/include \
              # $$BASEDIR/lib/flite/lang
Hugo Vincent's avatar
Hugo Vincent committed

    HARDWARE_PLATFORM = $$system(uname -a)
Hugo Vincent's avatar
Hugo Vincent committed
    contains( HARDWARE_PLATFORM, x86_64 ) {
        # 64-bit Linux
lm's avatar
lm committed
        #LIBS += \
            #-L$$BASEDIR/lib/flite/linux64
        message(Building for GNU/Linux 64bit/x64)
Hugo Vincent's avatar
Hugo Vincent committed
    } else {
        # 32-bit Linux
lm's avatar
lm committed
        #LIBS += \
           #-L$$BASEDIR/lib/flite/linux32
        message(Building for GNU/Linux 32bit/i386)
Hugo Vincent's avatar
Hugo Vincent committed
    }
    LIBS += -lm \
lm's avatar
lm committed
        #-lflite_cmu_us_rms \
        #-lflite_cmu_us_slt \
        #-lflite_cmu_us_kal16 \
        #-lflite_usenglish \
        #-lflite_cmulex \
        #-lflite \
Hugo Vincent's avatar
Hugo Vincent committed
        -lSDL \
        -lSDLmain
}


Hugo Vincent's avatar
Hugo Vincent committed
# Windows (32bit/64bit)
Hugo Vincent's avatar
Hugo Vincent committed
win32 { 

    message(Building for Windows Platform (32/64bit))
    
    # Special settings for debug
Hugo Vincent's avatar
Hugo Vincent committed
    #CONFIG += CONSOLE
Hugo Vincent's avatar
Hugo Vincent committed
    LIBS += -L$$BASEDIR\lib\sdl\win32 \
        -lmingw32 -lSDLmain -lSDL -mwindows
    
pixhawk's avatar
pixhawk committed
    INCLUDEPATH += $$BASEDIR/lib/sdl/include #\
                   #"C:\Program Files\Microsoft SDKs\Windows\v7.0\Include"
Hugo Vincent's avatar
Hugo Vincent committed

    debug {
        DESTDIR = $$BASEDIR/bin
    }

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