Changes: first we have to load meegotouchconfig.pri before setting -Werror flag RevBy: MaxW,(Holger) Details: because HAVE_N900 comes from meegotouchconfig.pri

# Build configuration

QMAKE_TARGET_COMPANY = Nokia
QMAKE_TARGET_PRODUCT = DirectUI
QMAKE_TARGET_DESCRIPTION = DirectUI Framework
QMAKE_TARGET_COPYRIGHT = Copyright (C) 2010 Nokia

# Features
# Parts to build. Options: libs tests benchmarks demos doc debian
#M_BUILD_PARTS = libs tests benchmarks demos doc debian

# Load configure script results
!win32: {
    include($${M_BUILD_TREE}/mkspecs/meegotouchconfig.pri)
}

#disable werrors on windows and freemantle (HAVE_N900 comes from meegotouchconfig.pri)
win32 {
   } else {
         contains( DEFINES, HAVE_N900 ) {
         } else {
             QMAKE_CFLAGS *= -Werror
             QMAKE_CXXFLAGS *= -Werror
         }
    }

contains(TEMPLATE, app) {
    DEFINES += M_APPLICATION_NAME=\\\"${QMAKE_TARGET}\\\"
} else {
    contains(TEMPLATE, lib) {
        DEFINES += M_LIBRARY_NAME=\\\"lib${QMAKE_TARGET}\\\"
    } else {
        # error(Unknown template)
    }
}

mac {
    INCLUDEPATH += include
}

# Load global definitions
include($${M_BUILD_TREE}/mkspecs/features/meegotouch_defines.prf)

# Defines for directories, for use in source code.
{
    # THEMEDIR determines the location of the theme
    DEFINES += THEMEDIR=\\\"\"$$M_THEME_DIR\"\\\"

    # APPLET_LIBS determines the location where all applet binaries are
    DEFINES += APPLET_LIBS=\\\"\"$$M_APPLET_DIR\"\\\"

    # APPLET_INSTALLATION_SOURCES determines the location where applet installation source binaries are
    DEFINES += APPLET_INSTALLATION_SOURCES=\\\"\"$$M_APPLET_INSTALLATION_SOURCES_DIR\"\\\"

    # APPLET_DATA determines where the .desktop files are located
    DEFINES += APPLET_DATA=\\\"\"$$M_APPLET_DATA_DIR\"\\\"

    # APPLET_SETTINGS_DIR determines where the applet global and instance settings files are located
    DEFINES += APPLET_SETTINGS_DIR=\\\"\"$$M_APPLET_SETTINGS_DIR\"\\\"

    # APPLICATION_EXTENSION_LIBS determines the location of application extension binaries
    DEFINES += APPLICATION_EXTENSION_LIBS=\\\"\"$$M_APPLICATION_EXTENSION_DIR\"\\\"

    # APPLICATION_EXTENSION_DATA_DIR determines the location of application extension .desktop files
    DEFINES += APPLICATION_EXTENSION_DATA_DIR=\\\"\"$$M_APPLICATION_EXTENSION_DATA_DIR\"\\\"

    # TRANSLATION_DIR determines the default translation path
    DEFINES += TRANSLATION_DIR=\\\"\"$$M_TRANSLATION_DIR\"\\\"

    # extra data for libicu to be used be default
    DEFINES += M_ICUEXTRADATA_DIR=\\\"\"$$M_ICUEXTRADATA_DIR\"\\\"

    # M_THEME_PRELOAD_DIR and M_THEME_POST_PRELOAD_DIR defines from where
    # to get lists of images to be preloaded
    DEFINES += M_THEME_PRELOAD_DIR=\\\"\"$$M_THEME_PRELOAD_DIR\"\\\"
    DEFINES += M_THEME_POST_PRELOAD_DIR=\\\"\"$$M_THEME_POST_PRELOAD_DIR\"\\\"
    DEFINES += M_DBUS_SERVICES_DIR=\\\"\"$$M_DBUS_SERVICES_DIR\"\\\"
    DEFINES += M_XDG_DIR=\\\"\"$$M_XDG_DIR\"\\\"
    DEFINES += M_INSTALL_SYSCONFDIR=\\\"\"$$M_INSTALL_SYSCONFDIR\"\\\"

    # M_BINARY_SHADERS_DIR defines the location of precompiled shader programs
    DEFINES += M_SHADER_SOURCE_DIR=\\\"\"$$M_SHADER_SOURCE_DIR\"\\\"
    DEFINES += M_SHADER_BINARY_DIR=\\\"\"$$M_SHADER_BINARY_DIR\"\\\"

    # M_TARGETS_CONF_DIR defines the location of target device config files
    DEFINES += M_TARGETS_CONF_DIR=\\\"\"$$M_TARGETS_CONF_DIR\"\\\"
}

unix {
   DEFINES += CACHEDIR=\\\"\"/var/cache/meegotouch/\"\\\"
   # drop unneeded dependencies
   !macx {
      QMAKE_LFLAGS += "-Wl,--as-needed"
   }
}

# Compiler configuration for all subprojects in libm

!win32-msvc*:QMAKE_CXXFLAGS *= -g

# To use compiler cache, "export USE_CCACHE=true"
USE_CCACHE=$$(USE_CCACHE)
contains(USE_CCACHE, "true") {
    message("Using compiler cache")
    QMAKE_CC = ccache gcc
    QMAKE_CXX = ccache g++
}

contains( M_BUILD_FEATURES, coverage ) {
    QMAKE_CXXFLAGS += -ftest-coverage -fprofile-arcs
    LIBS += -lgcov

    QMAKE_CLEAN += \
    *.gcda \
    *.gcno
}

QMAKE_LIBDIR += $${M_BUILD_TREE}/lib

include(shared.pri)

# Build configuration

QMAKE_TARGET_COMPANY = Nokia
QMAKE_TARGET_PRODUCT = DirectUI
QMAKE_TARGET_DESCRIPTION = DirectUI Framework
QMAKE_TARGET_COPYRIGHT = Copyright (C) 2010 Nokia

# Features
# Parts to build. Options: libs tests benchmarks demos doc debian
#M_BUILD_PARTS = libs tests benchmarks demos doc debian

#disable werrors on windows and freemantle
win32 {
   } else {
         contains( DEFINES, HAVE_N900 ) {
         } else {
             QMAKE_CFLAGS *= -Werror
             QMAKE_CXXFLAGS *= -Werror
         }
    }

contains(TEMPLATE, app) {
    DEFINES += M_APPLICATION_NAME=\\\"${QMAKE_TARGET}\\\"
} else {
    contains(TEMPLATE, lib) {
        DEFINES += M_LIBRARY_NAME=\\\"lib${QMAKE_TARGET}\\\"
    } else {
        # error(Unknown template)
    }
}

mac {
    INCLUDEPATH += include
}

# Load configure script results
!win32: {
    include($${M_BUILD_TREE}/mkspecs/meegotouchconfig.pri)
}

# Load global definitions
include($${M_BUILD_TREE}/mkspecs/features/meegotouch_defines.prf)

# Defines for directories, for use in source code.
{
    # THEMEDIR determines the location of the theme
    DEFINES += THEMEDIR=\\\"\"$$M_THEME_DIR\"\\\"

    # APPLET_LIBS determines the location where all applet binaries are
    DEFINES += APPLET_LIBS=\\\"\"$$M_APPLET_DIR\"\\\"

    # APPLET_INSTALLATION_SOURCES determines the location where applet installation source binaries are
    DEFINES += APPLET_INSTALLATION_SOURCES=\\\"\"$$M_APPLET_INSTALLATION_SOURCES_DIR\"\\\"

    # APPLET_DATA determines where the .desktop files are located
    DEFINES += APPLET_DATA=\\\"\"$$M_APPLET_DATA_DIR\"\\\"

    # APPLET_SETTINGS_DIR determines where the applet global and instance settings files are located
    DEFINES += APPLET_SETTINGS_DIR=\\\"\"$$M_APPLET_SETTINGS_DIR\"\\\"

    # APPLICATION_EXTENSION_LIBS determines the location of application extension binaries
    DEFINES += APPLICATION_EXTENSION_LIBS=\\\"\"$$M_APPLICATION_EXTENSION_DIR\"\\\"

    # APPLICATION_EXTENSION_DATA_DIR determines the location of application extension .desktop files
    DEFINES += APPLICATION_EXTENSION_DATA_DIR=\\\"\"$$M_APPLICATION_EXTENSION_DATA_DIR\"\\\"

    # TRANSLATION_DIR determines the default translation path
    DEFINES += TRANSLATION_DIR=\\\"\"$$M_TRANSLATION_DIR\"\\\"

    # extra data for libicu to be used be default
    DEFINES += M_ICUEXTRADATA_DIR=\\\"\"$$M_ICUEXTRADATA_DIR\"\\\"

    # M_THEME_PRELOAD_DIR and M_THEME_POST_PRELOAD_DIR defines from where
    # to get lists of images to be preloaded
    DEFINES += M_THEME_PRELOAD_DIR=\\\"\"$$M_THEME_PRELOAD_DIR\"\\\"
    DEFINES += M_THEME_POST_PRELOAD_DIR=\\\"\"$$M_THEME_POST_PRELOAD_DIR\"\\\"
    DEFINES += M_DBUS_SERVICES_DIR=\\\"\"$$M_DBUS_SERVICES_DIR\"\\\"
    DEFINES += M_XDG_DIR=\\\"\"$$M_XDG_DIR\"\\\"
    DEFINES += M_INSTALL_SYSCONFDIR=\\\"\"$$M_INSTALL_SYSCONFDIR\"\\\"

    # M_BINARY_SHADERS_DIR defines the location of precompiled shader programs
    DEFINES += M_SHADER_SOURCE_DIR=\\\"\"$$M_SHADER_SOURCE_DIR\"\\\"
    DEFINES += M_SHADER_BINARY_DIR=\\\"\"$$M_SHADER_BINARY_DIR\"\\\"

    # M_TARGETS_CONF_DIR defines the location of target device config files
    DEFINES += M_TARGETS_CONF_DIR=\\\"\"$$M_TARGETS_CONF_DIR\"\\\"
}

unix {
   DEFINES += CACHEDIR=\\\"\"/var/cache/meegotouch/\"\\\"
   # drop unneeded dependencies
   !macx {
      QMAKE_LFLAGS += "-Wl,--as-needed"
   }
}

# Compiler configuration for all subprojects in libm

!win32-msvc*:QMAKE_CXXFLAGS += -g

# To use compiler cache, "export USE_CCACHE=true"
USE_CCACHE=$$(USE_CCACHE)
contains(USE_CCACHE, "true") {
    message("Using compiler cache")
    QMAKE_CC = ccache gcc
    QMAKE_CXX = ccache g++
}

contains( M_BUILD_FEATURES, coverage ) {
    QMAKE_CXXFLAGS += -ftest-coverage -fprofile-arcs
    LIBS += -lgcov

    QMAKE_CLEAN += \
    *.gcda \
    *.gcno
}

QMAKE_LIBDIR += $${M_BUILD_TREE}/lib

include(shared.pri)


libquotient.pri: fix a typo leading to qmake FTBFS

QT += network multimedia
QT -= gui

# TODO: Having moved to Qt 5.12, replace c++1z with c++17 below
CONFIG *= c++1z warn_on rtti_off create_prl object_parallel_to_source

win32-msvc* {
    # Quotient code base does not play well with NMake inference rules
    CONFIG *= no_batch
    QMAKE_CXXFLAGS_WARN_ON *= -wd4100 -wd4267
    QMAKE_CXXFLAGS *= /std:c++17 # Older Qt doesn't understand c++1z above
} else {
    QMAKE_CXXFLAGS_WARN_ON *= -Wno-unused-parameter
}

contains(DEFINES, Quotient_E2EE_ENABLED=.) {
    contains(DEFINES, USE_INTREE_LIBQOLM=.) {
        include(3rdparty/libQtOlm/libQtOlm.pri)
    } else {
        CONFIG += link_pkgconfig
        PKGCONFIG += QtOlm
    }
}

SRCPATH = $$PWD/lib
INCLUDEPATH += $$SRCPATH

HEADERS += \
    $$SRCPATH/connectiondata.h \
    $$SRCPATH/connection.h \
    $$SRCPATH/ssosession.h \
    $$SRCPATH/encryptionmanager.h \
    $$SRCPATH/eventitem.h \
    $$SRCPATH/room.h \
    $$SRCPATH/user.h \
    $$SRCPATH/avatar.h \
    $$SRCPATH/syncdata.h \
    $$SRCPATH/quotient_common.h \
    $$SRCPATH/util.h \
    $$SRCPATH/qt_connection_util.h \
    $$SRCPATH/events/event.h \
    $$SRCPATH/events/roomevent.h \
    $$SRCPATH/events/stateevent.h \
    $$SRCPATH/events/eventcontent.h \
    $$SRCPATH/events/roommessageevent.h \
    $$SRCPATH/events/simplestateevents.h \
    $$SRCPATH/events/roomcanonicalaliasevent.h \
    $$SRCPATH/events/roomcreateevent.h \
    $$SRCPATH/events/roomtombstoneevent.h \
    $$SRCPATH/events/roommemberevent.h \
    $$SRCPATH/events/roomavatarevent.h \
    $$SRCPATH/events/typingevent.h \
    $$SRCPATH/events/receiptevent.h \
    $$SRCPATH/events/reactionevent.h \
    $$SRCPATH/events/callanswerevent.h \
    $$SRCPATH/events/callcandidatesevent.h \
    $$SRCPATH/events/callhangupevent.h \
    $$SRCPATH/events/callinviteevent.h \
    $$SRCPATH/events/accountdataevents.h \
    $$SRCPATH/events/directchatevent.h \
    $$SRCPATH/events/encryptionevent.h \
    $$SRCPATH/events/encryptedevent.h \
    $$SRCPATH/events/roomkeyevent.h \
    $$SRCPATH/events/redactionevent.h \
    $$SRCPATH/events/eventloader.h \
    $$SRCPATH/events/roompowerlevelsevent.h \
    $$SRCPATH/jobs/requestdata.h \
    $$SRCPATH/jobs/basejob.h \
    $$SRCPATH/jobs/syncjob.h \
    $$SRCPATH/jobs/mediathumbnailjob.h \
    $$SRCPATH/jobs/downloadfilejob.h \
    $$SRCPATH/jobs/postreadmarkersjob.h \
    $$files($$SRCPATH/csapi/*.h, false) \
    $$files($$SRCPATH/csapi/definitions/*.h, false) \
    $$files($$SRCPATH/csapi/definitions/wellknown/*.h, false) \
    $$files($$SRCPATH/application-service/definitions/*.h, false) \
    $$files($$SRCPATH/identity/definitions/*.h, false) \
    $$SRCPATH/logging.h \
    $$SRCPATH/converters.h \
    $$SRCPATH/settings.h \
    $$SRCPATH/networksettings.h \
    $$SRCPATH/networkaccessmanager.h

SOURCES += \
    $$SRCPATH/connectiondata.cpp \
    $$SRCPATH/connection.cpp \
    $$SRCPATH/ssosession.cpp \
    $$SRCPATH/encryptionmanager.cpp \
    $$SRCPATH/eventitem.cpp \
    $$SRCPATH/room.cpp \
    $$SRCPATH/user.cpp \
    $$SRCPATH/avatar.cpp \
    $$SRCPATH/syncdata.cpp \
    $$SRCPATH/util.cpp \
    $$SRCPATH/events/event.cpp \
    $$SRCPATH/events/roomevent.cpp \
    $$SRCPATH/events/stateevent.cpp \
    $$SRCPATH/events/eventcontent.cpp \
    $$SRCPATH/events/roomcreateevent.cpp \
    $$SRCPATH/events/roomtombstoneevent.cpp \
    $$SRCPATH/events/roommessageevent.cpp \
    $$SRCPATH/events/roommemberevent.cpp \
    $$SRCPATH/events/typingevent.cpp \
    $$SRCPATH/events/reactionevent.cpp \
    $$SRCPATH/events/callanswerevent.cpp \
    $$SRCPATH/events/callcandidatesevent.cpp \
    $$SRCPATH/events/callhangupevent.cpp \
    $$SRCPATH/events/callinviteevent.cpp \
    $$SRCPATH/events/receiptevent.cpp \
    $$SRCPATH/events/directchatevent.cpp \
    $$SRCPATH/events/encryptionevent.cpp \
    $$SRCPATH/events/encryptedevent.cpp \
    $$SRCPATH/events/roomkeyevent.cpp \
    $$SRCPATH/events/roompowerlevelsevent.cpp \
    $$SRCPATH/jobs/requestdata.cpp \
    $$SRCPATH/jobs/basejob.cpp \
    $$SRCPATH/jobs/syncjob.cpp \
    $$SRCPATH/jobs/mediathumbnailjob.cpp \
    $$SRCPATH/jobs/downloadfilejob.cpp \
    $$files($$SRCPATH/csapi/*.cpp, false) \
    $$SRCPATH/logging.cpp \
    $$SRCPATH/converters.cpp \
    $$SRCPATH/settings.cpp \
    $$SRCPATH/networksettings.cpp \
    $$SRCPATH/networkaccessmanager.cpp

QT += network multimedia
QT -= gui

# TODO: Having moved to Qt 5.12, replace c++1z with c++17 below
CONFIG *= c++1z warn_on rtti_off create_prl object_parallel_to_source

win32-msvc* {
    # Quotient code base does not play well with NMake inference rules
    CONFIG *= no_batch
    QMAKE_CXXFLAGS_WARN_ON *= -wd4100 -wd4267
    QMAKE_CXXFLAGS *= /std:c++17 # Older Qt doesn't understand c++1z above
} else {
    QMAKE_CXXFLAGS_WARN_ON *= -Wno-unused-parameter
}

contains(DEFINES, Quotient_E2EE_ENABLED=.) {
    contains(DEFINES, USE_INTREE_LIBQOLM=.) {
        include(3rdparty/libQtOlm/libQtOlm.pri)
    } else {
        CONFIG += link_pkgconfig
        PKGCONFIG += QtOlm
    }
}

SRCPATH = $$PWD/lib
INCLUDEPATH += $$SRCPATH

HEADERS += \
    $$SRCPATH/connectiondata.h \
    $$SRCPATH/connection.h \
    $$SRCPATH/ssosession.h \
    $$SRCPATH/encryptionmanager.h \
    $$SRCPATH/eventitem.h \
    $$SRCPATH/room.h \
    $$SRCPATH/user.h \
    $$SRCPATH/avatar.h \
    $$SRCPATH/syncdata.h \
    $$SRCPATH/quotient_common.h
    $$SRCPATH/util.h \
    $$SRCPATH/qt_connection_util.h \
    $$SRCPATH/events/event.h \
    $$SRCPATH/events/roomevent.h \
    $$SRCPATH/events/stateevent.h \
    $$SRCPATH/events/eventcontent.h \
    $$SRCPATH/events/roommessageevent.h \
    $$SRCPATH/events/simplestateevents.h \
    $$SRCPATH/events/roomcanonicalaliasevent.h \
    $$SRCPATH/events/roomcreateevent.h \
    $$SRCPATH/events/roomtombstoneevent.h \
    $$SRCPATH/events/roommemberevent.h \
    $$SRCPATH/events/roomavatarevent.h \
    $$SRCPATH/events/typingevent.h \
    $$SRCPATH/events/receiptevent.h \
    $$SRCPATH/events/reactionevent.h \
    $$SRCPATH/events/callanswerevent.h \
    $$SRCPATH/events/callcandidatesevent.h \
    $$SRCPATH/events/callhangupevent.h \
    $$SRCPATH/events/callinviteevent.h \
    $$SRCPATH/events/accountdataevents.h \
    $$SRCPATH/events/directchatevent.h \
    $$SRCPATH/events/encryptionevent.h \
    $$SRCPATH/events/encryptedevent.h \
    $$SRCPATH/events/roomkeyevent.h \
    $$SRCPATH/events/redactionevent.h \
    $$SRCPATH/events/eventloader.h \
    $$SRCPATH/events/roompowerlevelsevent.h \
    $$SRCPATH/jobs/requestdata.h \
    $$SRCPATH/jobs/basejob.h \
    $$SRCPATH/jobs/syncjob.h \
    $$SRCPATH/jobs/mediathumbnailjob.h \
    $$SRCPATH/jobs/downloadfilejob.h \
    $$SRCPATH/jobs/postreadmarkersjob.h \
    $$files($$SRCPATH/csapi/*.h, false) \
    $$files($$SRCPATH/csapi/definitions/*.h, false) \
    $$files($$SRCPATH/csapi/definitions/wellknown/*.h, false) \
    $$files($$SRCPATH/application-service/definitions/*.h, false) \
    $$files($$SRCPATH/identity/definitions/*.h, false) \
    $$SRCPATH/logging.h \
    $$SRCPATH/converters.h \
    $$SRCPATH/settings.h \
    $$SRCPATH/networksettings.h \
    $$SRCPATH/networkaccessmanager.h

SOURCES += \
    $$SRCPATH/connectiondata.cpp \
    $$SRCPATH/connection.cpp \
    $$SRCPATH/ssosession.cpp \
    $$SRCPATH/encryptionmanager.cpp \
    $$SRCPATH/eventitem.cpp \
    $$SRCPATH/room.cpp \
    $$SRCPATH/user.cpp \
    $$SRCPATH/avatar.cpp \
    $$SRCPATH/syncdata.cpp \
    $$SRCPATH/util.cpp \
    $$SRCPATH/events/event.cpp \
    $$SRCPATH/events/roomevent.cpp \
    $$SRCPATH/events/stateevent.cpp \
    $$SRCPATH/events/eventcontent.cpp \
    $$SRCPATH/events/roomcreateevent.cpp \
    $$SRCPATH/events/roomtombstoneevent.cpp \
    $$SRCPATH/events/roommessageevent.cpp \
    $$SRCPATH/events/roommemberevent.cpp \
    $$SRCPATH/events/typingevent.cpp \
    $$SRCPATH/events/reactionevent.cpp \
    $$SRCPATH/events/callanswerevent.cpp \
    $$SRCPATH/events/callcandidatesevent.cpp \
    $$SRCPATH/events/callhangupevent.cpp \
    $$SRCPATH/events/callinviteevent.cpp \
    $$SRCPATH/events/receiptevent.cpp \
    $$SRCPATH/events/directchatevent.cpp \
    $$SRCPATH/events/encryptionevent.cpp \
    $$SRCPATH/events/encryptedevent.cpp \
    $$SRCPATH/events/roomkeyevent.cpp \
    $$SRCPATH/events/roompowerlevelsevent.cpp \
    $$SRCPATH/jobs/requestdata.cpp \
    $$SRCPATH/jobs/basejob.cpp \
    $$SRCPATH/jobs/syncjob.cpp \
    $$SRCPATH/jobs/mediathumbnailjob.cpp \
    $$SRCPATH/jobs/downloadfilejob.cpp \
    $$files($$SRCPATH/csapi/*.cpp, false) \
    $$SRCPATH/logging.cpp \
    $$SRCPATH/converters.cpp \
    $$SRCPATH/settings.cpp \
    $$SRCPATH/networksettings.cpp \
    $$SRCPATH/networkaccessmanager.cpp


o2 pri fixes

o2 pri fixes

QT *= network
lessThan(QT_MAJOR_VERSION, 5) {
QT *= script
}

INCLUDEPATH += $$PWD
SOURCES += \
    $$PWD/o1.cpp \
    $$PWD/o1requestor.cpp \
    $$PWD/o2.cpp \
    $$PWD/o2reply.cpp \
    $$PWD/o2replyserver.cpp \
    $$PWD/o2requestor.cpp \
    $$PWD/simplecrypt.cpp \
    $$PWD/o2settingsstore.cpp

HEADERS += \
    $$PWD/o1.h \
    $$PWD/o1requestor.h \
    $$PWD/o2.h \
    $$PWD/o2reply.h \
    $$PWD/o2replyserver.h \
    $$PWD/o2requestor.h \
    $$PWD/simplecrypt.h \
    $$PWD/o2globals.h \
    $$PWD/o2abstractstore.h \
    $$PWD/o2settingsstore.h

#SOURCES  += $$PWD/o2facebook.cpp \
#            $$PWD/o1dropbox.h \
#            $$PWD/o1flickr.h \
#            $$PWD/o2gft.h \
#            $$PWD/o2skydrive.cpp \
#            $$PWD/oxtwitter.cpp
#HEADERS  += $$PWD/o2facebook.h \
#            $$PWD/o2gft.cpp \
#            $$PWD/o2skydrive.h \
#            $$PWD/oxtwitter.h \
#            $$PWD/o1twitter.h \

QT *= network
lessThan(QT_MAJOR_VERSION, 5) {
QT *= script
}

INCLUDEPATH += $$PWD
SOURCES += \
    $$PWD/o1.cpp \
    $$PWD/o1requestor.cpp \
    $$PWD/o2.cpp \
    $$PWD/o2reply.cpp \
    $$PWD/o2replyserver.cpp \
    $$PWD/o2requestor.cpp \
    $$PWD/simplecrypt.cpp \
    $$PWD/o2settingsstore.cpp

HEADERS += \
    $$PWD/o1.h \
    $$PWD/o1dropbox.h \
    $$PWD/o1flickr.h \
    $$PWD/o1requestor.h \
    $$PWD/o2.h \
    $$PWD/o2reply.h \
    $$PWD/o2replyserver.h \
    $$PWD/o2requestor.h \
    $$PWD/simplecrypt.h \
    $$PWD/o2globals.h \
    $$PWD/o2abstractstore.h \
    $$PWD/o2settingsstore.h

#SOURCES  += $$PWD/o2facebook.cpp \
#            $$PWD/o2gft.h \
#            $$PWD/o2skydrive.cpp \
#            $$PWD/oxtwitter.cpp
#HEADERS  += $$PWD/o2facebook.h \
#            $$PWD/o2gft.cpp \
#            $$PWD/o2skydrive.h \
#            $$PWD/oxtwitter.h \
#            $$PWD/o1twitter.h \


Install the IdentityInfo header file

Install the IdentityInfo header file

This had been forgotten before. Also, reorder the file names
alphabetically.

include( ../../common-project-config.pri )
include( ../../common-vars.pri )
TEMPLATE = lib

greaterThan(QT_MAJOR_VERSION, 4) {
    TARGET = signon-qt5
} else {
    TARGET = signon-qt
}

# Input
public_headers += \
    sessiondata.h \
    identityinfo.h \
    authservice.h \
    identity.h \
    authsession.h \
    libsignoncommon.h \
    signon.h \
    signonerror.h

private_headers = authserviceimpl.h \
    identityimpl.h \
    authsessionimpl.h \
    identityinfoimpl.h \
    dbusoperationqueuehandler.h \
    dbusinterface.h

HEADERS = $$public_headers \
    $$private_headers

INCLUDEPATH += . \
    $$TOP_SRC_DIR/include

SOURCES += identityinfo.cpp \
    identity.cpp \
    identityimpl.cpp \
    authservice.cpp \
    authserviceimpl.cpp \
    authsession.cpp \
    authsessionimpl.cpp \
    identityinfoimpl.cpp \
    dbusoperationqueuehandler.cpp \
    dbusinterface.cpp

QT += core \
    dbus

CONFIG += \
    build_all \
    link_pkgconfig

DEFINES += \
    QT_NO_CAST_TO_ASCII \
    QT_NO_CAST_FROM_ASCII \
    LIBSIGNON_TRACE

include( $$TOP_SRC_DIR/common-installs-config.pri )

headers.files = $$public_headers \
    AuthService \
    AuthSession \
    Error \
    Identity \
    IdentityInfo \
    SessionData
headers.path = $${INSTALL_PREFIX}/include/$${TARGET}/SignOn
INSTALLS += headers

pkgconfig.files = lib$${TARGET}.pc
include($${TOP_SRC_DIR}/common-pkgconfig.pri)
INSTALLS += pkgconfig

include( ../../common-project-config.pri )
include( ../../common-vars.pri )
TEMPLATE = lib

greaterThan(QT_MAJOR_VERSION, 4) {
    TARGET = signon-qt5
} else {
    TARGET = signon-qt
}

# Input
public_headers += \
    sessiondata.h \
    identityinfo.h \
    authservice.h \
    identity.h \
    authsession.h \
    libsignoncommon.h \
    signon.h \
    signonerror.h

private_headers = authserviceimpl.h \
    identityimpl.h \
    authsessionimpl.h \
    identityinfoimpl.h \
    dbusoperationqueuehandler.h \
    dbusinterface.h

HEADERS = $$public_headers \
    $$private_headers

INCLUDEPATH += . \
    $$TOP_SRC_DIR/include

SOURCES += identityinfo.cpp \
    identity.cpp \
    identityimpl.cpp \
    authservice.cpp \
    authserviceimpl.cpp \
    authsession.cpp \
    authsessionimpl.cpp \
    identityinfoimpl.cpp \
    dbusoperationqueuehandler.cpp \
    dbusinterface.cpp

QT += core \
    dbus

CONFIG += \
    build_all \
    link_pkgconfig

DEFINES += \
    QT_NO_CAST_TO_ASCII \
    QT_NO_CAST_FROM_ASCII \
    LIBSIGNON_TRACE

include( $$TOP_SRC_DIR/common-installs-config.pri )

headers.files = $$public_headers \
    AuthService \
    AuthSession \
    Identity \
        SessionData \
        Error
headers.path = $${INSTALL_PREFIX}/include/$${TARGET}/SignOn
INSTALLS += headers

pkgconfig.files = lib$${TARGET}.pc
include($${TOP_SRC_DIR}/common-pkgconfig.pri)
INSTALLS += pkgconfig


* get the .pri file up to date for a possible linux build

# -----------------------------------------------------------
# This file is generated by the Qt Visual Studio Integration.
# -----------------------------------------------------------

#Header files
HEADERS += ./inc/customcolor.h \
    ./inc/models/dwarfmodel.h \
    ./inc/models/dwarfmodelproxy.h \
    ./inc/mainwindow.h \
    ./inc/docks/gridviewdock.h \
    ./inc/docks/skilllegenddock.h \
    ./inc/docks/viewcolumnsetdock.h \
    ./inc/aboutdialog.h \
    ./inc/customprofessionsexportdialog.h \
    ./inc/gridviewdialog.h \
    ./inc/optionsmenu.h \
    ./inc/viewcolumnsetdialog.h \
    ./inc/cp437codec.h \
    ./inc/defines.h \
    ./inc/dwarftherapist.h \
    ./inc/GameDataReader.h \
    ./inc/memorylayout.h \
    ./inc/truncatingfilelogger.h \
    ./inc/utils.h \
    ./inc/version.h \
    ./inc/win_structs.h \
    ./inc/customprofession.h \
    ./inc/dfinstance.h \
    ./inc/dwarf.h \
    ./inc/labor.h \
    ./inc/skill.h \
    ./inc/grid_view/columntypes.h \
    ./inc/grid_view/happinesscolumn.h \
    ./inc/grid_view/laborcolumn.h \
    ./inc/grid_view/skillcolumn.h \
    ./inc/grid_view/spacercolumn.h \
    ./inc/grid_view/viewcolumn.h \
    ./inc/grid_view/gridview.h \
    ./inc/statetableview.h \
    ./inc/grid_view/viewcolumnset.h \
    ./inc/viewmanager.h \
    ./inc/rotatedheader.h \
    ./inc/uberdelegate.h

#Source files
SOURCES += ./src/customcolor.cpp \
    ./src/models/dwarfmodel.cpp \
    ./src/models/dwarfmodelproxy.cpp \
    ./src/mainwindow.cpp \
    ./src/docks/gridviewdock.cpp \
    ./src/docks/skilllegenddock.cpp \
    ./src/docks/viewcolumnsetdock.cpp \
    ./src/aboutdialog.cpp \
    ./src/customprofessionsexportdialog.cpp \
    ./src/gridviewdialog.cpp \
    ./src/optionsmenu.cpp \
    ./src/viewcolumnsetdialog.cpp \
    ./src/dwarftherapist.cpp \
    ./src/GameDataReader.cpp \
    ./src/main.cpp \
    ./src/memorylayout.cpp \
    ./src/customprofession.cpp \
    ./src/dfinstance.cpp \
    ./src/dwarf.cpp \
    ./src/grid_view/happinesscolumn.cpp \
    ./src/grid_view/laborcolumn.cpp \
    ./src/grid_view/skillcolumn.cpp \
    ./src/grid_view/spacercolumn.cpp \
    ./src/grid_view/viewcolumn.cpp \
    ./src/grid_view/gridview.cpp \
    ./src/statetableview.cpp \
    ./src/grid_view/viewcolumnset.cpp \
    ./src/viewmanager.cpp \
    ./src/rotatedheader.cpp \
    ./src/uberdelegate.cpp

#Forms
FORMS += ./ui/about.ui \
    ./ui/columneditdialog.ui \
    ./ui/customprofession.ui \
    ./ui/customprofessionsexportdialog.ui \
    ./ui/gridviewdialog.ui \
    ./ui/gridviewdock.ui \
    ./ui/mainwindow.ui \
    ./ui/optionsmenu.ui \
    ./ui/pendingchanges.ui \
    ./ui/viewcolumnsetdialog.ui \
    ./ui/viewcolumnsetdock.ui

#Resource file(s)
RESOURCES += ./images.qrc

# -----------------------------------------------------------
# This file is generated by the Qt Visual Studio Integration.
# -----------------------------------------------------------

#Header files
HEADERS += ./inc/aboutdialog.h \
    ./inc/customcolor.h \
    ./inc/customprofession.h \
    ./inc/defines.h \
    ./inc/dfinstance.h \
    ./inc/dwarf.h \
    ./inc/dwarftherapist.h \
    ./inc/GameDataReader.h \
    ./inc/labor.h \
    ./inc/mainwindow.h \
    ./inc/memorylayout.h \
    ./inc/optionsmenu.h \
    ./inc/rotatedheader.h \
    ./inc/skill.h \
    ./inc/statetableview.h \
    ./inc/truncatingfilelogger.h \
    ./inc/uberdelegate.h \
    ./inc/utils.h \
    ./inc/version.h \
    ./inc/viewmanager.h \
    ./inc/win_structs.h \
    ./inc/grid_view/columntypes.h \
    ./inc/grid_view/gridview.h \
    ./inc/grid_view/happinesscolumn.h \
    ./inc/grid_view/laborcolumn.h \
    ./inc/grid_view/skillcolumn.h \
    ./inc/grid_view/spacercolumn.h \
    ./inc/grid_view/viewcolumn.h \
    ./inc/grid_view/viewcolumnset.h \
    ./inc/models/dwarfmodel.h \
    ./inc/models/dwarfmodelproxy.h

#Source files
SOURCES += ./src/aboutdialog.cpp \
    ./src/customcolor.cpp \
    ./src/customprofession.cpp \
    ./src/dfinstance.cpp \
    ./src/dwarf.cpp \
    ./src/dwarftherapist.cpp \
    ./src/GameDataReader.cpp \
    ./src/main.cpp \
    ./src/mainwindow.cpp \
    ./src/memorylayout.cpp \
    ./src/optionsmenu.cpp \
    ./src/rotatedheader.cpp \
    ./src/statetableview.cpp \
    ./src/uberdelegate.cpp \
    ./src/viewmanager.cpp \
    ./src/models/dwarfmodel.cpp \
    ./src/models/dwarfmodelproxy.cpp \
    ./src/grid_view/gridview.cpp \
    ./src/grid_view/happinesscolumn.cpp \
    ./src/grid_view/laborcolumn.cpp \
    ./src/grid_view/skillcolumn.cpp \
    ./src/grid_view/spacercolumn.cpp \
    ./src/grid_view/viewcolumn.cpp \
    ./src/grid_view/viewcolumnset.cpp


Plugin symbol visibility now defaults to hidden to speed up loading/reduce size

TEMPLATE     = lib
DEPENDPATH  += .
INCLUDEPATH += .
DESTDIR      = $$PWD/../plugins/script
QT          += script
CONFIG      += debug_and_release plugin hide_symbols

GENERATEDCPP = $$PWD/../generated_cpp
TARGET       = $$qtLibraryTarget($$TARGET)

TEMPLATE     = lib
DEPENDPATH  += .
INCLUDEPATH += .
DESTDIR      = $$PWD/../plugins/script
QT          += script
CONFIG      += debug_and_release plugin

GENERATEDCPP = $$PWD/../generated_cpp
TARGET       = $$qtLibraryTarget($$TARGET)


MacOS

MacOS

CORE_V8_PATH_INCLUDE    = $$PWD/v8
CORE_V8_PATH_LIBS       = $$CORE_V8_PATH_INCLUDE/out.gn/$$CORE_BUILDS_PLATFORM_PREFIX/obj

INCLUDEPATH += \
    $$CORE_V8_PATH_INCLUDE \
    $$CORE_V8_PATH_INCLUDE/include

core_windows {
    CORE_V8_PATH_LIBS = $$CORE_V8_PATH_INCLUDE/out.gn/$$CORE_BUILDS_PLATFORM_PREFIX/$$CORE_BUILDS_CONFIGURATION_PREFIX/obj

    LIBS += -L$$CORE_V8_PATH_LIBS -lv8_base -lv8_libplatform -lv8_libbase -lv8_snapshot -lv8_libsampler
    LIBS += -L$$CORE_V8_PATH_LIBS/third_party/icu -licui18n -licuuc

    LIBS += -lwinmm
    LIBS += -ladvapi32
    LIBS += -lShell32

    LIBS += -lDbgHelp
    LIBS += -lShlwapi
}

core_linux {
    LIBS += -L$$CORE_V8_PATH_LIBS -lv8_base -lv8_libplatform -lv8_libbase -lv8_snapshot -lv8_libsampler
    LIBS += -L$$CORE_V8_PATH_LIBS/third_party/icu -licui18n -licuuc
}

core_mac {
    LIBS += -L$$CORE_V8_PATH_LIBS -lv8_base -lv8_libplatform -lv8_libbase -lv8_snapshot -lv8_libsampler

    #LIBS += -L$$CORE_V8_PATH_LIBS/third_party/icu -licui18n -licuuc
    LIBS += $$CORE_V8_PATH_LIBS/third_party/icu/libicui18n.a
    LIBS += $$CORE_V8_PATH_LIBS/third_party/icu/libicuuc.a

    QMAKE_CXXFLAGS += -Wall -Wno-inconsistent-missing-override
    QMAKE_CFLAGS += -Wall -Wno-inconsistent-missing-override
}

CORE_V8_PATH_INCLUDE    = $$PWD/v8
CORE_V8_PATH_LIBS       = $$CORE_V8_PATH_INCLUDE/out.gn/$$CORE_BUILDS_PLATFORM_PREFIX/obj

INCLUDEPATH += \
    $$CORE_V8_PATH_INCLUDE \
    $$CORE_V8_PATH_INCLUDE/include

core_windows {
    CORE_V8_PATH_LIBS = $$CORE_V8_PATH_INCLUDE/out.gn/$$CORE_BUILDS_PLATFORM_PREFIX/$$CORE_BUILDS_CONFIGURATION_PREFIX/obj

    LIBS += -L$$CORE_V8_PATH_LIBS -lv8_base -lv8_libplatform -lv8_libbase -lv8_snapshot -lv8_libsampler
    LIBS += -L$$CORE_V8_PATH_LIBS/third_party/icu -licui18n -licuuc

    LIBS += -lwinmm
    LIBS += -ladvapi32
    LIBS += -lShell32

    LIBS += -lDbgHelp
    LIBS += -lShlwapi
}

core_linux {
    LIBS += -L$$CORE_V8_PATH_LIBS -lv8_base -lv8_libplatform -lv8_libbase -lv8_snapshot -lv8_libsampler
    LIBS += -L$$CORE_V8_PATH_LIBS/third_party/icu -licui18n -licuuc
}

core_mac {
    LIBS += -L$$CORE_V8_PATH_LIBS -lv8_base -lv8_libplatform -lv8_libbase -lv8_snapshot -lv8_libsampler
    LIBS += -L$$CORE_V8_PATH_LIBS/third_party/icu -licui18n -licuuc

    QMAKE_CXXFLAGS += -Wall -Wno-inconsistent-missing-override
    QMAKE_CFLAGS += -Wall -Wno-inconsistent-missing-override
}


Fixed static linking problem of sbml for release under Linux.

######################################################################
# $Revision: 1.26 $ $Author: shoops $ $Date: 2004/06/22 21:04:51 $
######################################################################

# In the case the BUILD_OS is not specified we make a guess.
isEmpty(BUILD_OS) {
  win32 {
    BUILD_OS = WIN32
  } else {
    BUILD_OS = $$system(uname)
  }
}
DEFINES += $$BUILD_OS
message("Configuring for $${BUILD_OS}.")

TARGETDEPS += Makefile
DEFINES+=XML_STATIC

# Common configuration settings
CONFIG += exceptions
CONFIG += rtti

debug {
  DEFINES += COPASI_DEBUG
}

!contains(BUILD_OS, WIN32) {
  QMAKE_QMAKE = $(QTDIR)/bin/qmake

  # The character # (hex 23) can not be escaped we therefore create
  # a variable containing it
  HASH = $$system(echo "\\043")
  contains(HASH, \\043){
    HASH = $$system(echo -e "\\043")
  }

  myLex = \
          $(LEX) -t $< | \
          sed -e 's/class istream;/$${HASH}include "copasi.h"/' \
              -e 's/<FlexLexer.h>/"FlexLexer.h"/' \
              -e 's/$${HASH}include <unistd.h>/using namespace std;/' > $@
}

contains(BUILD_OS, Darwin) {
  INCLUDEPATH += /System/Library/Frameworks/vecLib.framework/Headers
  LIBS += -framework vecLib
  LIBS += -framework Carbon
  LIBS += -framework QuickTime
  LIBS += -lz
}

contains(BUILD_OS, WIN32) {
  QMAKE_QMAKE = $(QTDIR)\bin\qmake.exe
  DEFINES -= UNICODE
  debug {
    QMAKE_LFLAGS_WINDOWS += /NODEFAULTLIB:"msvcrt.lib"
    QMAKE_LFLAGS_WINDOWS += /NODEFAULTLIB:"libcmt.lib"
  }
  release {
    QMAKE_LFLAGS_WINDOWS += /NODEFAULTLIB:"libcmt"
  }

  !isEmpty(MKL_PATH) {
    DEFINES += USE_MKL
    QMAKE_CXXFLAGS_DEBUG   += -I"$${MKL_PATH}\include"
    QMAKE_CXXFLAGS_RELEASE += -I"$${MKL_PATH}\include"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${MKL_PATH}\ia32\lib"
    LIBS += mkl_lapack.lib mkl_p3.lib mkl_c.lib
  } else {
    !isEmpty(CLAPACK_PATH) {
      DEFINES += USE_CLAPACK
      QMAKE_CXXFLAGS_DEBUG   += -I"$${CLAPACK_PATH}\include"
      QMAKE_CXXFLAGS_RELEASE += -I"$${CLAPACK_PATH}\include"
      QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${CLAPACK_PATH}\lib"
      LIBS += clapack.lib
    } else {
      error( "Either MKL_PATH or CLAPACK_PATH must be specified" )
    }
  }

  !isEmpty(EXPAT_PATH) {
    QMAKE_CXXFLAGS_DEBUG   += -I"$${EXPAT_PATH}\Source\lib"
    QMAKE_CXXFLAGS_RELEASE += -I"$${EXPAT_PATH}\Source\lib"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${EXPAT_PATH}\StaticLibs"
    LIBS += libexpat.lib
  } else {
    error( "EXPAT_PATH must be specified" )
  }

  !isEmpty(SBML_PATH) {
    QMAKE_CXXFLAGS_DEBUG   += -I"$${SBML_PATH}\include"
    QMAKE_CXXFLAGS_RELEASE += -I"$${SBML_PATH}\include"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${SBML_PATH}\lib"
    LIBS += libsbml.lib libexpat-compat.lib
  } else {
    error( "SBML_PATH must be specified" )
  }
}

contains(BUILD_OS, SunOS) {
  !isEmpty(CLAPACK_PATH) {
    DEFINES += USE_CLAPACK
    INCLUDEPATH += $${CLAPACK_PATH}/include
    LIBS += -llapack -lblas -lF77 -lfl
    LIBS += -L$${CLAPACK_PATH}/lib
  } else {
    error( "CLAPACK_PATH must be specified" )
  }
  LIBS += -lSM
}

contains(BUILD_OS, Linux) {
  QMAKE_LFLAGS_RELEASE += -static
  LIBS += -lsbml
  release {
    LIBS += -lexpat_compat
  }
  LIBS += -lexpat

  !isEmpty(QWT_PATH){
      LIBS+=  -L$${QWT_PATH}/lib
      INCLUDEPATH += $${QWT_PATH}/include
  }
#  else {
#      error( "QWT_PATH must be specified" )
#  }
  !isEmpty(EXPAT_PATH){
      LIBS+=  -L$${EXPAT_PATH}/lib
      INCLUDEPATH += $${EXPAT_PATH}/include
  }
  !isEmpty(SBML_PATH){
      LIBS+=  -L$${SBML_PATH}/lib
      INCLUDEPATH += $${SBML_PATH}/include
  }
  !isEmpty(MKL_PATH) {
    DEFINES += USE_MKL
    INCLUDEPATH += $${MKL_PATH}/include
    LIBS += -lmkl_lapack -lmkl_p3 -lg2c -lpthread
    LIBS +=  -L$${MKL_PATH}/lib/32
  } else {
    !isEmpty(CLAPACK_PATH) {
      DEFINES += USE_CLAPACK
      INCLUDEPATH += $${CLAPACK_PATH}/include
      INCLUDEPATH += /usr/include/qt3
      LIBS += -llapack -lblas -lF77 -lfl
      LIBS += -L$${CLAPACK_PATH}/lib
    } else {
      !isEmpty(LAPACK_PATH) {
        message("Using lapack.")
        DEFINES += USE_CLAPACK
        INCLUDEPATH += $${LAPACK_PATH}/include
        LIBS += -llapack -lblas  -lg2c
        LIBS += -L$${LAPACK_PATH}/lib
      } else {
        error( "Either MKL_PATH, CLAPACK_PATH, or LAPACK_PATH must be specified" )
      }
    }
  }
}

DEP1.target   = depend
DEP1.depends  = qmake

QMAKE_EXTRA_UNIX_TARGETS += DEP1

######################################################################
# $Revision: 1.25 $ $Author: gauges $ $Date: 2004/06/11 11:59:56 $
######################################################################

# In the case the BUILD_OS is not specified we make a guess.
isEmpty(BUILD_OS) {
  win32 {
    BUILD_OS = WIN32
  } else {
    BUILD_OS = $$system(uname)
  }
}
DEFINES += $$BUILD_OS
message("Configuring for $${BUILD_OS}.")

TARGETDEPS += Makefile
DEFINES+=XML_STATIC

# Common configuration settings
CONFIG += exceptions
CONFIG += rtti

debug {
  DEFINES += COPASI_DEBUG
}

!contains(BUILD_OS, WIN32) {
  QMAKE_QMAKE = $(QTDIR)/bin/qmake

  # The character # (hex 23) can not be escaped we therefore create
  # a variable containing it
  HASH = $$system(echo "\\043")
  contains(HASH, \\043){
    HASH = $$system(echo -e "\\043")
  }

  myLex = \
          $(LEX) -t $< | \
          sed -e 's/class istream;/$${HASH}include "copasi.h"/' \
              -e 's/<FlexLexer.h>/"FlexLexer.h"/' \
              -e 's/$${HASH}include <unistd.h>/using namespace std;/' > $@
}

contains(BUILD_OS, Darwin) {
  INCLUDEPATH += /System/Library/Frameworks/vecLib.framework/Headers
  LIBS += -framework vecLib
  LIBS += -framework Carbon
  LIBS += -framework QuickTime
  LIBS += -lz
}

contains(BUILD_OS, WIN32) {
  QMAKE_QMAKE = $(QTDIR)\bin\qmake.exe
  DEFINES -= UNICODE
  debug {
    QMAKE_LFLAGS_WINDOWS += /NODEFAULTLIB:"msvcrt.lib"
    QMAKE_LFLAGS_WINDOWS += /NODEFAULTLIB:"libcmt.lib"
  }
  release {
    QMAKE_LFLAGS_WINDOWS += /NODEFAULTLIB:"libcmt"
  }

  !isEmpty(MKL_PATH) {
    DEFINES += USE_MKL
    QMAKE_CXXFLAGS_DEBUG   += -I"$${MKL_PATH}\include"
    QMAKE_CXXFLAGS_RELEASE += -I"$${MKL_PATH}\include"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${MKL_PATH}\ia32\lib"
    LIBS += mkl_lapack.lib mkl_p3.lib mkl_c.lib
  } else {
    !isEmpty(CLAPACK_PATH) {
      DEFINES += USE_CLAPACK
      QMAKE_CXXFLAGS_DEBUG   += -I"$${CLAPACK_PATH}\include"
      QMAKE_CXXFLAGS_RELEASE += -I"$${CLAPACK_PATH}\include"
      QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${CLAPACK_PATH}\lib"
      LIBS += clapack.lib
    } else {
      error( "Either MKL_PATH or CLAPACK_PATH must be specified" )
    }
  }

  !isEmpty(EXPAT_PATH) {
    QMAKE_CXXFLAGS_DEBUG   += -I"$${EXPAT_PATH}\Source\lib"
    QMAKE_CXXFLAGS_RELEASE += -I"$${EXPAT_PATH}\Source\lib"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${EXPAT_PATH}\StaticLibs"
    LIBS += libexpat.lib
  } else {
    error( "EXPAT_PATH must be specified" )
  }
}

contains(BUILD_OS, SunOS) {
  !isEmpty(CLAPACK_PATH) {
    DEFINES += USE_CLAPACK
    INCLUDEPATH += $${CLAPACK_PATH}/include
    LIBS += -llapack -lblas -lF77 -lfl
    LIBS += -L$${CLAPACK_PATH}/lib
  } else {
    error( "CLAPACK_PATH must be specified" )
  }
  LIBS += -lSM
}

contains(BUILD_OS, Linux) {
  QMAKE_LFLAGS_RELEASE += -static
  LIBS += -lexpat
  !isEmpty(QWT_PATH){
      LIBS+=  -L$${QWT_PATH}/lib
      INCLUDEPATH += $${QWT_PATH}/include
  }
#  else {
#      error( "QWT_PATH must be specified" )
#  }
  !isEmpty(EXPAT_PATH){
      LIBS+=  -L$${EXPAT_PATH}/lib
      INCLUDEPATH += $${EXPAT_PATH}/include
  }
  !isEmpty(SBML_PATH){
      LIBS+=  -L$${SBML_PATH}/lib
      INCLUDEPATH += $${SBML_PATH}/include
  }
  !isEmpty(MKL_PATH) {
    DEFINES += USE_MKL
    INCLUDEPATH += $${MKL_PATH}/include
    LIBS += -lmkl_lapack -lmkl_p3 -lg2c -lpthread
    LIBS +=  -L$${MKL_PATH}/lib/32
  } else {
    !isEmpty(CLAPACK_PATH) {
      DEFINES += USE_CLAPACK
      INCLUDEPATH += $${CLAPACK_PATH}/include
      INCLUDEPATH += /usr/include/qt3
      LIBS += -llapack -lblas -lF77 -lfl
      LIBS += -L$${CLAPACK_PATH}/lib
    } else {
      !isEmpty(LAPACK_PATH) {
        message("Using lapack.")
        DEFINES += USE_CLAPACK
        INCLUDEPATH += $${LAPACK_PATH}/include
        LIBS += -llapack -lblas  -lg2c
        LIBS += -L$${LAPACK_PATH}/lib
      } else {
        error( "Either MKL_PATH, CLAPACK_PATH, or LAPACK_PATH must be specified" )
      }
    }
  }
}

DEP1.target   = depend
DEP1.depends  = qmake

QMAKE_EXTRA_UNIX_TARGETS += DEP1


Corrected and streamlined LFLAGS for WIN32.

# Begin CVS Header
#   $Source: /Volumes/Home/Users/shoops/cvs/copasi_dev/copasi/common.pri,v $
#   $Revision: 1.64 $
#   $Name:  $
#   $Author: shoops $
#   $Date: 2007/10/31 15:17:15 $
# End CVS Header

# Copyright (C) 2007 by Pedro Mendes, Virginia Tech Intellectual
# Properties, Inc. and EML Research, gGmbH.
# All rights reserved.

######################################################################
# $Revision: 1.64 $ $Author: shoops $ $Date: 2007/10/31 15:17:15 $
######################################################################

# In the case the BUILD_OS is not specified we make a guess.
isEmpty(BUILD_OS) {
  win32 {
    BUILD_OS = WIN32
  } else {
    BUILD_OS = $$system(uname)
  }
}
DEFINES += $$BUILD_OS
message("Configuring for $${BUILD_OS} with QTDIR=$(QTDIR).")

TARGETDEPS += Makefile

# Common configuration settings
CONFIG += exceptions
CONFIG += rtti
CONFIG += thread

#ifdef COPASI_LICENSE_COM
# COPASI License to use
DEFINES -= COPASI_LICENSE_US
DEFINES -= COPASI_LICENSE_DE
DEFINES -= COPASI_LICENSE_COM
DEFINES += COPASI_LICENSE_$$USE_LICENSE
#endif // COPASI_LICENSE_COM

INCLUDEPATH += ../..
QMAKE_CFLAGS   += $$(CFLAGS)
QMAKE_CXXFLAGS += $$(CXXFLAGS)
QMAKE_LFLAGS  += $$(LDFLAGS)

debug {
  DEFINES += COPASI_DEBUG
  #DEFINES += WITH_LAYOUT

  isEmpty(COPASI_SRC_PACKAGE) {
    DEFINES += COPASI_TSS
  }
}

isEmpty(COPASI_SRC_PACKAGE) {
  DEFINES += HAVE_MML
}

contains(STATIC_LINKAGE, yes) {
  DEFINES+=XML_STATIC
  DEFINES+=LIBSBML_STATIC
}

!contains(BUILD_OS, WIN32) {
  #Release code optimization
  QMAKE_CFLAGS_RELEASE -= -O1
  QMAKE_CFLAGS_RELEASE -= -O2
  QMAKE_CFLAGS_RELEASE -= -O4
  QMAKE_CFLAGS_RELEASE += -O3

  QMAKE_CXXFLAGS_RELEASE -= -O1
  QMAKE_CXXFLAGS_RELEASE -= -O2
  QMAKE_CXXFLAGS_RELEASE -= -O4
  QMAKE_CXXFLAGS_RELEASE += -O3

  QMAKE_QMAKE = $(QTDIR)/bin/qmake
  QMAKE_LEX = ../../admin/flex.sh
  QMAKE_YACC = ../../admin/yacc.sh

  # The character # (hex 23) can not be escaped we therefore create
  # a variable containing it
  HASH = $$system(echo "\\043")
  contains(HASH, \\043){
    HASH = $$system(echo -e "\\043")
  }

  myLex = \
          $(LEX) -t $< | \
          sed -e 's/class istream;/$${HASH}include "copasi.h"/' \
              -e 's/<FlexLexer.h>/"FlexLexer.h"/' \
              -e 's/$${HASH}include <unistd.h>/using namespace std;/' > $@
}

contains(BUILD_OS, Darwin) {
  release {
    contains(TEMPLATE, app) {
      QMAKE_POST_LINK = strip $(TARGET)
    }
  }

  INCLUDEPATH += /System/Library/Frameworks/Accelerate.framework/Headers
  INCLUDEPATH += /System/Library/Frameworks/Carbon.framework/Headers

  !isEmpty(SBML_PATH){
    LIBS +=  $${SBML_PATH}/lib/libsbml.a
    INCLUDEPATH += $${SBML_PATH}/include
  } else {
    LIBS += -lsbml
  }

  !isEmpty(EXPAT_PATH){
    LIBS+=  $${EXPAT_PATH}/lib/libexpat.a
    INCLUDEPATH += $${EXPAT_PATH}/include
  } else {
    LIBS += -lexpat
  }

  contains(CONFIG, qt) {
    !isEmpty(QWT_PATH){
       LIBS+=  $${QWT_PATH}/lib/libqwt.a
       INCLUDEPATH += $${QWT_PATH}/include
    } else {
      LIBS += -lqwt
    }

    LIBS += $(QTDIR)/lib/libqt-mt.a

    QMAKE_LIBS_QT =
    QMAKE_LIBS_QT_THREAD =
  }

  LIBS += -framework Accelerate
  LIBS += -framework Carbon
  LIBS += -framework QuickTime
  LIBS += -lz
}

contains(BUILD_OS, WIN32) {
  QMAKE_QMAKE = $(QTDIR)\bin\qmake.exe
  QMAKE_LEX = C:\cygwin\bin\bash ../../admin/flex.sh
  QMAKE_YACC = C:\cygwin\bin\bash ../../admin/yacc.sh

  DEFINES -= UNICODE
  debug {
    QMAKE_LFLAGS += /NODEFAULTLIB:"libcmt.lib"
    QMAKE_LFLAGS += /NODEFAULTLIB:"msvcrt.lib"
  }

  #Release code optimization
  QMAKE_CFLAGS_RELEASE -= -O1
  QMAKE_CFLAGS_RELEASE += -O2

  QMAKE_CXXFLAGS_RELEASE -= -O1
  QMAKE_CXXFLAGS_RELEASE += -O2

  !isEmpty(MKL_PATH) {
    DEFINES += USE_MKL
    QMAKE_CXXFLAGS_DEBUG   += -I"$${MKL_PATH}\include"
    QMAKE_CXXFLAGS_RELEASE += -I"$${MKL_PATH}\include"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${MKL_PATH}\32\lib"
    QMAKE_LFLAGS_CONSOLE += /LIBPATH:"$${MKL_PATH}\32\lib"
    LIBS += mkl_c.lib
  } else {
    !isEmpty(CLAPACK_PATH) {
      DEFINES += USE_CLAPACK
      QMAKE_CXXFLAGS   += -I"$${CLAPACK_PATH}\include"
      QMAKE_LFLAGS += /LIBPATH:"$${CLAPACK_PATH}\lib"
      LIBS += clapack.lib
    } else {
      error( "Either MKL_PATH or CLAPACK_PATH must be specified" )
    }
  }

  !isEmpty(EXPAT_PATH) {
    QMAKE_CXXFLAGS   += -I"$${EXPAT_PATH}\Source\lib"
    QMAKE_LFLAGS += /LIBPATH:"$${EXPAT_PATH}\StaticLibs"
    QMAKE_LFLAGS += /LIBPATH:"$${EXPAT_PATH}\bin"
    LIBS += libexpatMT.lib
  } else {
    error( "EXPAT_PATH must be specified" )
  }

  !isEmpty(SBML_PATH) {
    QMAKE_CXXFLAGS   += -I"$${SBML_PATH}\include"
    QMAKE_LFLAGS += /LIBPATH:"$${SBML_PATH}\lib"
    LIBS += libsbml.lib
  } else {
    error( "SBML_PATH must be specified" )
  }

  contains(CONFIG, qt) {
    LIBS += -lqwt
  }
}

contains(BUILD_OS, SunOS) {
contains(STATIC_LINKAGE, yes) {
# :TODO: This should be set through configure.
  LIBS += -L/export/home/shoops/copasi/gcc/lib
}

  release {
    contains(TEMPLATE, app) {
# Note: This must be the SunOS strip command.
      QMAKE_POST_LINK = /usr/ccs/bin/strip $(TARGET)
    }
  }

  !isEmpty(CLAPACK_PATH) {
    DEFINES += USE_CLAPACK
    INCLUDEPATH += $${CLAPACK_PATH}/include
    LIBS += -llapack -lblas -lF77 -lfl
    LIBS += -L$${CLAPACK_PATH}/lib
  } else {
    !isEmpty(LAPACK_PATH) {
      message("Using lapack.")
      DEFINES += USE_LAPACK
      INCLUDEPATH += $${LAPACK_PATH}/include
      LIBS += -llapack -lblas  -lg2c
      LIBS += -L$${LAPACK_PATH}/lib
    } else {
      message("Using sunperf.")
      DEFINES += USE_SUNPERF
      LIBS += -lsunperf
      QMAKE_CFLAGS   += -dalign
      QMAKE_CXXFLAGS   += -dalign
    }
  }
  !isEmpty(EXPAT_PATH){
      LIBS+=  -L$${EXPAT_PATH}/lib
      INCLUDEPATH += $${EXPAT_PATH}/include
  }
  !isEmpty(SBML_PATH){
      LIBS+=  -L$${SBML_PATH}/lib
      INCLUDEPATH += $${SBML_PATH}/include
  }

  LIBS += -lsbml -lexpat

  contains(CONFIG, qt) {
    !isEmpty(QWT_PATH){
       LIBS+=  -L$${QWT_PATH}/lib
       INCLUDEPATH += $${QWT_PATH}/include
    }
    LIBS += -lqwt
    LIBS += -lSM
  } else {
    QMAKE_LIBS_THREAD -= -lpthread
    QMAKE_LIBS_THREAD -= -lrt
  }
}

contains(BUILD_OS, Linux) {
  release {
    contains(TEMPLATE, app) {
      QMAKE_POST_LINK = strip $(TARGET)
    }
  }

  contains(STATIC_LINKAGE, yes) {
    QMAKE_LFLAGS += -static
  }

  !isEmpty(SBML_PATH){
    LIBS+=  -L$${SBML_PATH}/lib
    INCLUDEPATH += $${SBML_PATH}/include
    INCLUDEPATH += $${SBML_PATH}/include/sbml
  }
  LIBS += -lsbml

  !isEmpty(EXPAT_PATH){
    LIBS+=  -L$${EXPAT_PATH}/lib
    INCLUDEPATH += $${EXPAT_PATH}/include
  }
  LIBS += -lexpat

  !isEmpty(MKL_PATH) {
    DEFINES += USE_MKL
    INCLUDEPATH += $${MKL_PATH}/include
#    LIBS += -lmkl_lapack -lmkl_ia32 -lg2c -lpthread
    LIBS += -lmkl_lapack -lmkl_ia32 -lguide -lpthread
    LIBS +=  -L$${MKL_PATH}/lib/32
  } else {
    !isEmpty(CLAPACK_PATH) {
      DEFINES += USE_CLAPACK
      INCLUDEPATH += $${CLAPACK_PATH}/include
      INCLUDEPATH += /usr/include/qt3
      LIBS += -llapack -lblas -lF77 -lfl
      LIBS += -L$${CLAPACK_PATH}/lib
    } else {
      !isEmpty(LAPACK_PATH) {
        message("Using lapack.")
        DEFINES += USE_LAPACK
        INCLUDEPATH += $${LAPACK_PATH}/include
        LIBS += -llapack -lblas  -lg2c
        LIBS += -L$${LAPACK_PATH}/lib
      } else {
        error( "Either MKL_PATH, CLAPACK_PATH, or LAPACK_PATH must be specified" )
      }
    }
  }

  contains(CONFIG, qt) {
    !isEmpty(QWT_PATH){
       LIBS+=  -L$${QWT_PATH}/lib
       INCLUDEPATH += $${QWT_PATH}/include
    }
    LIBS += -lqwt
  }
}

DEP1.target   = depend
DEP1.depends  = qmake

QMAKE_EXTRA_UNIX_TARGETS += DEP1

!equals(TEMPLATE, subdirs) {
  # Copy the sources for the tar ball
  src_distribution.depends = Makefile
  src_distribution.commands =   \
    $(CHK_DIR_EXISTS) ../../copasi_src || $(MKDIR) ../../copasi_src; \
    $(CHK_DIR_EXISTS) ../../copasi_src/copasi || \
      $(MKDIR) ../../copasi_src/copasi; \
    $(CHK_DIR_EXISTS) ../../copasi_src/copasi/$$SRC_TARGET || \
      $(MKDIR) ../../copasi_src/copasi/$$SRC_TARGET; \
    $(COPY_FILE) --parents $(SOURCES) $(HEADERS) $(FORMS) $(DIST) \
      ../../copasi_src/copasi/$$SRC_TARGET/

  QMAKE_EXTRA_UNIX_TARGETS += src_distribution
}

# Begin CVS Header
#   $Source: /Volumes/Home/Users/shoops/cvs/copasi_dev/copasi/common.pri,v $
#   $Revision: 1.63 $
#   $Name:  $
#   $Author: shoops $
#   $Date: 2007/09/20 14:05:35 $
# End CVS Header

# Copyright (C) 2007 by Pedro Mendes, Virginia Tech Intellectual
# Properties, Inc. and EML Research, gGmbH.
# All rights reserved.

######################################################################
# $Revision: 1.63 $ $Author: shoops $ $Date: 2007/09/20 14:05:35 $
######################################################################

# In the case the BUILD_OS is not specified we make a guess.
isEmpty(BUILD_OS) {
  win32 {
    BUILD_OS = WIN32
  } else {
    BUILD_OS = $$system(uname)
  }
}
DEFINES += $$BUILD_OS
message("Configuring for $${BUILD_OS} with QTDIR=$(QTDIR).")

TARGETDEPS += Makefile

# Common configuration settings
CONFIG += exceptions
CONFIG += rtti
CONFIG += thread

#ifdef COPASI_LICENSE_COM
# COPASI License to use
DEFINES -= COPASI_LICENSE_US
DEFINES -= COPASI_LICENSE_DE
DEFINES -= COPASI_LICENSE_COM
DEFINES += COPASI_LICENSE_$$USE_LICENSE
#endif // COPASI_LICENSE_COM

INCLUDEPATH += ../..
QMAKE_CFLAGS   += $$(CFLAGS)
QMAKE_CXXFLAGS += $$(CXXFLAGS)
QMAKE_LFLAGS  += $$(LDFLAGS)

debug {
  DEFINES += COPASI_DEBUG
  #DEFINES += WITH_LAYOUT

  isEmpty(COPASI_SRC_PACKAGE) {
    DEFINES += COPASI_TSS
  }
}

isEmpty(COPASI_SRC_PACKAGE) {
  DEFINES += HAVE_MML
}

contains(STATIC_LINKAGE, yes) {
  DEFINES+=XML_STATIC
  DEFINES+=LIBSBML_STATIC
}

!contains(BUILD_OS, WIN32) {
  #Release code optimization
  QMAKE_CFLAGS_RELEASE -= -O1
  QMAKE_CFLAGS_RELEASE -= -O2
  QMAKE_CFLAGS_RELEASE -= -O4
  QMAKE_CFLAGS_RELEASE += -O3

  QMAKE_CXXFLAGS_RELEASE -= -O1
  QMAKE_CXXFLAGS_RELEASE -= -O2
  QMAKE_CXXFLAGS_RELEASE -= -O4
  QMAKE_CXXFLAGS_RELEASE += -O3

  QMAKE_QMAKE = $(QTDIR)/bin/qmake
  QMAKE_LEX = ../../admin/flex.sh
  QMAKE_YACC = ../../admin/yacc.sh

  # The character # (hex 23) can not be escaped we therefore create
  # a variable containing it
  HASH = $$system(echo "\\043")
  contains(HASH, \\043){
    HASH = $$system(echo -e "\\043")
  }

  myLex = \
          $(LEX) -t $< | \
          sed -e 's/class istream;/$${HASH}include "copasi.h"/' \
              -e 's/<FlexLexer.h>/"FlexLexer.h"/' \
              -e 's/$${HASH}include <unistd.h>/using namespace std;/' > $@
}

contains(BUILD_OS, Darwin) {
  release {
    contains(TEMPLATE, app) {
      QMAKE_POST_LINK = strip $(TARGET)
    }
  }

  INCLUDEPATH += /System/Library/Frameworks/Accelerate.framework/Headers
  INCLUDEPATH += /System/Library/Frameworks/Carbon.framework/Headers

  !isEmpty(SBML_PATH){
    LIBS +=  $${SBML_PATH}/lib/libsbml.a
    INCLUDEPATH += $${SBML_PATH}/include
  } else {
    LIBS += -lsbml
  }

  !isEmpty(EXPAT_PATH){
    LIBS+=  $${EXPAT_PATH}/lib/libexpat.a
    INCLUDEPATH += $${EXPAT_PATH}/include
  } else {
    LIBS += -lexpat
  }

  contains(CONFIG, qt) {
    !isEmpty(QWT_PATH){
       LIBS+=  $${QWT_PATH}/lib/libqwt.a
       INCLUDEPATH += $${QWT_PATH}/include
    } else {
      LIBS += -lqwt
    }

    LIBS += $(QTDIR)/lib/libqt-mt.a

    QMAKE_LIBS_QT =
    QMAKE_LIBS_QT_THREAD =
  }

  LIBS += -framework Accelerate
  LIBS += -framework Carbon
  LIBS += -framework QuickTime
  LIBS += -lz
}

contains(BUILD_OS, WIN32) {
  QMAKE_QMAKE = $(QTDIR)\bin\qmake.exe
  QMAKE_LEX = C:\cygwin\bin\bash ../../admin/flex.sh
  QMAKE_YACC = C:\cygwin\bin\bash ../../admin/yacc.sh

  DEFINES -= UNICODE
  debug {
    QMAKE_LFLAGS_WINDOWS += /NODEFAULTLIB:"msvcrt.lib"
    QMAKE_LFLAGS_CONSOLE += /NODEFAULTLIB:"msvcrt.lib"
  }

  #Release code optimization
  QMAKE_CFLAGS_RELEASE -= -O1
  QMAKE_CFLAGS_RELEASE += -O2

  QMAKE_CXXFLAGS_RELEASE -= -O1
  QMAKE_CXXFLAGS_RELEASE += -O2

  !isEmpty(MKL_PATH) {
    DEFINES += USE_MKL
    QMAKE_CXXFLAGS_DEBUG   += -I"$${MKL_PATH}\include"
    QMAKE_CXXFLAGS_RELEASE += -I"$${MKL_PATH}\include"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${MKL_PATH}\32\lib"
    QMAKE_LFLAGS_CONSOLE += /LIBPATH:"$${MKL_PATH}\32\lib"
    LIBS += mkl_c.lib
  } else {
    !isEmpty(CLAPACK_PATH) {
      DEFINES += USE_CLAPACK
      QMAKE_CXXFLAGS_DEBUG   += -I"$${CLAPACK_PATH}\include"
      QMAKE_CXXFLAGS_RELEASE += -I"$${CLAPACK_PATH}\include"
      QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${CLAPACK_PATH}\lib"
      QMAKE_LFLAGS_CONSOLE += /LIBPATH:"$${CLAPACK_PATH}\lib"
      LIBS += clapack.lib
    } else {
      error( "Either MKL_PATH or CLAPACK_PATH must be specified" )
    }
  }

  !isEmpty(EXPAT_PATH) {
    QMAKE_CXXFLAGS_DEBUG   += -I"$${EXPAT_PATH}\Source\lib"
    QMAKE_CXXFLAGS_RELEASE += -I"$${EXPAT_PATH}\Source\lib"
    QMAKE_LFLAGS += /LIBPATH:"$${EXPAT_PATH}\StaticLibs"
    QMAKE_LFLAGS += /LIBPATH:"$${EXPAT_PATH}\bin"
    LIBS += libexpatMT.lib
  } else {
    error( "EXPAT_PATH must be specified" )
  }

  !isEmpty(SBML_PATH) {
    QMAKE_CXXFLAGS_DEBUG   += -I"$${SBML_PATH}\include"
    QMAKE_CXXFLAGS_RELEASE += -I"$${SBML_PATH}\include"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${SBML_PATH}\lib"
    QMAKE_LFLAGS_CONSOLE += /LIBPATH:"$${SBML_PATH}\lib"
    LIBS += libsbml.lib
  } else {
    error( "SBML_PATH must be specified" )
  }

  contains(CONFIG, qt) {
    LIBS += -lqwt
  }
}

contains(BUILD_OS, SunOS) {
contains(STATIC_LINKAGE, yes) {
# :TODO: This should be set through configure.
  LIBS += -L/export/home/shoops/copasi/gcc/lib
}

  release {
    contains(TEMPLATE, app) {
# Note: This must be the SunOS strip command.
      QMAKE_POST_LINK = /usr/ccs/bin/strip $(TARGET)
    }
  }

  !isEmpty(CLAPACK_PATH) {
    DEFINES += USE_CLAPACK
    INCLUDEPATH += $${CLAPACK_PATH}/include
    LIBS += -llapack -lblas -lF77 -lfl
    LIBS += -L$${CLAPACK_PATH}/lib
  } else {
    !isEmpty(LAPACK_PATH) {
      message("Using lapack.")
      DEFINES += USE_LAPACK
      INCLUDEPATH += $${LAPACK_PATH}/include
      LIBS += -llapack -lblas  -lg2c
      LIBS += -L$${LAPACK_PATH}/lib
    } else {
      message("Using sunperf.")
      DEFINES += USE_SUNPERF
      LIBS += -lsunperf
      QMAKE_CFLAGS   += -dalign
      QMAKE_CXXFLAGS   += -dalign
    }
  }
  !isEmpty(EXPAT_PATH){
      LIBS+=  -L$${EXPAT_PATH}/lib
      INCLUDEPATH += $${EXPAT_PATH}/include
  }
  !isEmpty(SBML_PATH){
      LIBS+=  -L$${SBML_PATH}/lib
      INCLUDEPATH += $${SBML_PATH}/include
  }

  LIBS += -lsbml -lexpat

  contains(CONFIG, qt) {
    !isEmpty(QWT_PATH){
       LIBS+=  -L$${QWT_PATH}/lib
       INCLUDEPATH += $${QWT_PATH}/include
    }
    LIBS += -lqwt
    LIBS += -lSM
  } else {
    QMAKE_LIBS_THREAD -= -lpthread
    QMAKE_LIBS_THREAD -= -lrt
  }
}

contains(BUILD_OS, Linux) {
  release {
    contains(TEMPLATE, app) {
      QMAKE_POST_LINK = strip $(TARGET)
    }
  }

  contains(STATIC_LINKAGE, yes) {
    QMAKE_LFLAGS += -static
  }

  !isEmpty(SBML_PATH){
    LIBS+=  -L$${SBML_PATH}/lib
    INCLUDEPATH += $${SBML_PATH}/include
    INCLUDEPATH += $${SBML_PATH}/include/sbml
  }
  LIBS += -lsbml

  !isEmpty(EXPAT_PATH){
    LIBS+=  -L$${EXPAT_PATH}/lib
    INCLUDEPATH += $${EXPAT_PATH}/include
  }
  LIBS += -lexpat

  !isEmpty(MKL_PATH) {
    DEFINES += USE_MKL
    INCLUDEPATH += $${MKL_PATH}/include
#    LIBS += -lmkl_lapack -lmkl_ia32 -lg2c -lpthread
    LIBS += -lmkl_lapack -lmkl_ia32 -lguide -lpthread
    LIBS +=  -L$${MKL_PATH}/lib/32
  } else {
    !isEmpty(CLAPACK_PATH) {
      DEFINES += USE_CLAPACK
      INCLUDEPATH += $${CLAPACK_PATH}/include
      INCLUDEPATH += /usr/include/qt3
      LIBS += -llapack -lblas -lF77 -lfl
      LIBS += -L$${CLAPACK_PATH}/lib
    } else {
      !isEmpty(LAPACK_PATH) {
        message("Using lapack.")
        DEFINES += USE_LAPACK
        INCLUDEPATH += $${LAPACK_PATH}/include
        LIBS += -llapack -lblas  -lg2c
        LIBS += -L$${LAPACK_PATH}/lib
      } else {
        error( "Either MKL_PATH, CLAPACK_PATH, or LAPACK_PATH must be specified" )
      }
    }
  }

  contains(CONFIG, qt) {
    !isEmpty(QWT_PATH){
       LIBS+=  -L$${QWT_PATH}/lib
       INCLUDEPATH += $${QWT_PATH}/include
    }
    LIBS += -lqwt
  }
}

DEP1.target   = depend
DEP1.depends  = qmake

QMAKE_EXTRA_UNIX_TARGETS += DEP1

!equals(TEMPLATE, subdirs) {
  # Copy the sources for the tar ball
  src_distribution.depends = Makefile
  src_distribution.commands =   \
    $(CHK_DIR_EXISTS) ../../copasi_src || $(MKDIR) ../../copasi_src; \
    $(CHK_DIR_EXISTS) ../../copasi_src/copasi || \
      $(MKDIR) ../../copasi_src/copasi; \
    $(CHK_DIR_EXISTS) ../../copasi_src/copasi/$$SRC_TARGET || \
      $(MKDIR) ../../copasi_src/copasi/$$SRC_TARGET; \
    $(COPY_FILE) --parents $(SOURCES) $(HEADERS) $(FORMS) $(DIST) \
      ../../copasi_src/copasi/$$SRC_TARGET/

  QMAKE_EXTRA_UNIX_TARGETS += src_distribution
}


adding libsignoncrypto-qt into PKGCONFIG for libsignon-qt

include( ../../common-project-config.pri )
include( ../../common-vars.pri )
TEMPLATE = lib
TARGET = signon-qt

# Input
public_headers += \
    sessiondata.h \
    identityinfo.h \
    authservice.h \
    identity.h \
    authsession.h \
    libsignoncommon.h \
    signon.h \
    signonerror.h

private_headers = authserviceimpl.h \
    identityimpl.h \
    authsessionimpl.h \
    identityinfoimpl.h \
    dbusoperationqueuehandler.h

HEADERS = $$public_headers \
    $$private_headers

INCLUDEPATH += . \
    $$TOP_SRC_DIR/include

SOURCES += identityinfo.cpp \
    identity.cpp \
    identityimpl.cpp \
    authservice.cpp \
    authserviceimpl.cpp \
    authsession.cpp \
    authsessionimpl.cpp \
    identityinfoimpl.cpp \
    dbusoperationqueuehandler.cpp

QT += core \
    dbus

QT -= gui

CONFIG += qdbus \
    build_all \
    link_pkgconfig

PKGCONFIG += libsignoncrypto-qt

QMAKE_CXXFLAGS += -fno-exceptions \
    -fno-rtti
DEFINES += QT_NO_CAST_TO_ASCII QT_NO_CAST_FROM_ASCII
include( $$TOP_SRC_DIR/common-installs-config.pri )

headers.files = $$public_headers \
    AuthService \
    AuthSession \
    Identity \
        SessionData \
        Error
headers.path = $${INSTALL_PREFIX}/include/signon-qt/SignOn
INSTALLS += headers

pkgconfig.files = libsignon-qt.pc
pkgconfig.path = $${INSTALL_PREFIX}/lib/pkgconfig
INSTALLS += pkgconfig

include( ../../common-project-config.pri )
include( ../../common-vars.pri )
TEMPLATE = lib
TARGET = signon-qt

# Input
public_headers += \
    sessiondata.h \
    identityinfo.h \
    authservice.h \
    identity.h \
    authsession.h \
    libsignoncommon.h \
    signon.h \
    signonerror.h

private_headers = authserviceimpl.h \
    identityimpl.h \
    authsessionimpl.h \
    identityinfoimpl.h \
    dbusoperationqueuehandler.h

HEADERS = $$public_headers \
    $$private_headers

INCLUDEPATH += . \
    $$TOP_SRC_DIR/include

SOURCES += identityinfo.cpp \
    identity.cpp \
    identityimpl.cpp \
    authservice.cpp \
    authserviceimpl.cpp \
    authsession.cpp \
    authsessionimpl.cpp \
    identityinfoimpl.cpp \
    dbusoperationqueuehandler.cpp

QT += core \
    dbus

QT -= gui

CONFIG += qdbus \
    build_all \
    link_pkgconfig
QMAKE_CXXFLAGS += -fno-exceptions \
    -fno-rtti
DEFINES += QT_NO_CAST_TO_ASCII QT_NO_CAST_FROM_ASCII
include( $$TOP_SRC_DIR/common-installs-config.pri )

headers.files = $$public_headers \
	AuthService \
	AuthSession \
	Identity \
        SessionData \
        Error
headers.path = $${INSTALL_PREFIX}/include/signon-qt/SignOn
INSTALLS += headers

pkgconfig.files = libsignon-qt.pc
pkgconfig.path = $${INSTALL_PREFIX}/lib/pkgconfig
INSTALLS += pkgconfig


Use system libcurl

Use system libcurl

core_linux {
    INCLUDEPATH += $$PWD/$$CORE_BUILDS_PLATFORM_PREFIX/usr/local/include

    LIBS += -lcurl
}

core_linux {
    INCLUDEPATH += $$PWD/$$CORE_BUILDS_PLATFORM_PREFIX/usr/local/include

    LIBS        += $$PWD/$$CORE_BUILDS_PLATFORM_PREFIX/build/libcurl.a
}


*** empty log message ***

*** empty log message ***

######################################################################
# $Revision: 1.27 $ $Author: shoops $ $Date: 2004/09/29 04:02:58 $
######################################################################

# In the case the BUILD_OS is not specified we make a guess.
isEmpty(BUILD_OS) {
  win32 {
    BUILD_OS = WIN32
  } else {
    BUILD_OS = $$system(uname)
  }
}
DEFINES += $$BUILD_OS
message("Configuring for $${BUILD_OS}.")

TARGETDEPS += Makefile
DEFINES+=XML_STATIC

# Common configuration settings
CONFIG += exceptions
CONFIG += rtti

debug {
  DEFINES += COPASI_DEBUG
}

!contains(BUILD_OS, WIN32) {
  QMAKE_QMAKE = $(QTDIR)/bin/qmake

  # The character # (hex 23) can not be escaped we therefore create
  # a variable containing it
  HASH = $$system(echo "\\043")
  contains(HASH, \\043){
    HASH = $$system(echo -e "\\043")
  }

  myLex = \
          $(LEX) -t $< | \
          sed -e 's/class istream;/$${HASH}include "copasi.h"/' \
              -e 's/<FlexLexer.h>/"FlexLexer.h"/' \
              -e 's/$${HASH}include <unistd.h>/using namespace std;/' > $@
}

contains(BUILD_OS, Darwin) {
  INCLUDEPATH += /System/Library/Frameworks/vecLib.framework/Headers
  LIBS += -framework vecLib
  LIBS += -framework Carbon
  LIBS += -framework QuickTime
  LIBS += -lz
}

contains(BUILD_OS, WIN32) {
  QMAKE_QMAKE = $(QTDIR)\bin\qmake.exe
  DEFINES -= UNICODE
  debug {
    QMAKE_LFLAGS_WINDOWS += /NODEFAULTLIB:"msvcrt.lib"
    QMAKE_LFLAGS_WINDOWS += /NODEFAULTLIB:"libcmt.lib"
  }
  release {
    QMAKE_LFLAGS_WINDOWS += /NODEFAULTLIB:"libcmt"
  }

  !isEmpty(MKL_PATH) {
    DEFINES += USE_MKL
    QMAKE_CXXFLAGS_DEBUG   += -I"$${MKL_PATH}\include"
    QMAKE_CXXFLAGS_RELEASE += -I"$${MKL_PATH}\include"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${MKL_PATH}\ia32\lib"
    LIBS += mkl_lapack.lib mkl_p3.lib mkl_c.lib
  } else {
    !isEmpty(CLAPACK_PATH) {
      DEFINES += USE_CLAPACK
      QMAKE_CXXFLAGS_DEBUG   += -I"$${CLAPACK_PATH}\include"
      QMAKE_CXXFLAGS_RELEASE += -I"$${CLAPACK_PATH}\include"
      QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${CLAPACK_PATH}\lib"
      LIBS += clapack.lib
    } else {
      error( "Either MKL_PATH or CLAPACK_PATH must be specified" )
    }
  }

  !isEmpty(EXPAT_PATH) {
    QMAKE_CXXFLAGS_DEBUG   += -I"$${EXPAT_PATH}\Source\lib"
    QMAKE_CXXFLAGS_RELEASE += -I"$${EXPAT_PATH}\Source\lib"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${EXPAT_PATH}\StaticLibs"
    LIBS += libexpat.lib
  } else {
    error( "EXPAT_PATH must be specified" )
  }

  !isEmpty(SBML_PATH) {
    QMAKE_CXXFLAGS_DEBUG   += -I"$${SBML_PATH}\include"
    QMAKE_CXXFLAGS_RELEASE += -I"$${SBML_PATH}\include"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${SBML_PATH}\lib"
    LIBS += libsbml.lib libexpat-compat.lib
  } else {
    error( "SBML_PATH must be specified" )
  }
}

contains(BUILD_OS, SunOS) {
  !isEmpty(CLAPACK_PATH) {
    DEFINES += USE_CLAPACK
    INCLUDEPATH += $${CLAPACK_PATH}/include
    LIBS += -llapack -lblas -lF77 -lfl
    LIBS += -L$${CLAPACK_PATH}/lib
  } else {
    error( "CLAPACK_PATH must be specified" )
  }
  LIBS += -lSM
}

contains(BUILD_OS, Linux) {
  QMAKE_LFLAGS_RELEASE += -static

  LIBS += -lsbml -lexpat

  !isEmpty(QWT_PATH){
      LIBS+=  -L$${QWT_PATH}/lib
      INCLUDEPATH += $${QWT_PATH}/include
  }
#  else {
#      error( "QWT_PATH must be specified" )
#  }
  !isEmpty(EXPAT_PATH){
      LIBS+=  -L$${EXPAT_PATH}/lib
      INCLUDEPATH += $${EXPAT_PATH}/include
  }
  !isEmpty(SBML_PATH){
      LIBS+=  -L$${SBML_PATH}/lib
      INCLUDEPATH += $${SBML_PATH}/include
  }
  !isEmpty(MKL_PATH) {
    DEFINES += USE_MKL
    INCLUDEPATH += $${MKL_PATH}/include
    LIBS += -lmkl_lapack -lmkl_p3 -lg2c -lpthread
    LIBS +=  -L$${MKL_PATH}/lib/32
  } else {
    !isEmpty(CLAPACK_PATH) {
      DEFINES += USE_CLAPACK
      INCLUDEPATH += $${CLAPACK_PATH}/include
      INCLUDEPATH += /usr/include/qt3
      LIBS += -llapack -lblas -lF77 -lfl
      LIBS += -L$${CLAPACK_PATH}/lib
    } else {
      !isEmpty(LAPACK_PATH) {
        message("Using lapack.")
        DEFINES += USE_CLAPACK
        INCLUDEPATH += $${LAPACK_PATH}/include
        LIBS += -llapack -lblas  -lg2c
        LIBS += -L$${LAPACK_PATH}/lib
      } else {
        error( "Either MKL_PATH, CLAPACK_PATH, or LAPACK_PATH must be specified" )
      }
    }
  }
}

DEP1.target   = depend
DEP1.depends  = qmake

QMAKE_EXTRA_UNIX_TARGETS += DEP1

######################################################################
# $Revision: 1.26 $ $Author: shoops $ $Date: 2004/06/22 21:04:51 $
######################################################################

# In the case the BUILD_OS is not specified we make a guess.
isEmpty(BUILD_OS) {
  win32 {
    BUILD_OS = WIN32
  } else {
    BUILD_OS = $$system(uname)
  }
}
DEFINES += $$BUILD_OS
message("Configuring for $${BUILD_OS}.")

TARGETDEPS += Makefile
DEFINES+=XML_STATIC

# Common configuration settings
CONFIG += exceptions
CONFIG += rtti

debug {
  DEFINES += COPASI_DEBUG
}

!contains(BUILD_OS, WIN32) {
  QMAKE_QMAKE = $(QTDIR)/bin/qmake

  # The character # (hex 23) can not be escaped we therefore create
  # a variable containing it
  HASH = $$system(echo "\\043")
  contains(HASH, \\043){
    HASH = $$system(echo -e "\\043")
  }

  myLex = \
          $(LEX) -t $< | \
          sed -e 's/class istream;/$${HASH}include "copasi.h"/' \
              -e 's/<FlexLexer.h>/"FlexLexer.h"/' \
              -e 's/$${HASH}include <unistd.h>/using namespace std;/' > $@
}

contains(BUILD_OS, Darwin) {
  INCLUDEPATH += /System/Library/Frameworks/vecLib.framework/Headers
  LIBS += -framework vecLib
  LIBS += -framework Carbon
  LIBS += -framework QuickTime
  LIBS += -lz
}

contains(BUILD_OS, WIN32) {
  QMAKE_QMAKE = $(QTDIR)\bin\qmake.exe
  DEFINES -= UNICODE
  debug {
    QMAKE_LFLAGS_WINDOWS += /NODEFAULTLIB:"msvcrt.lib"
    QMAKE_LFLAGS_WINDOWS += /NODEFAULTLIB:"libcmt.lib"
  }
  release {
    QMAKE_LFLAGS_WINDOWS += /NODEFAULTLIB:"libcmt"
  }

  !isEmpty(MKL_PATH) {
    DEFINES += USE_MKL
    QMAKE_CXXFLAGS_DEBUG   += -I"$${MKL_PATH}\include"
    QMAKE_CXXFLAGS_RELEASE += -I"$${MKL_PATH}\include"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${MKL_PATH}\ia32\lib"
    LIBS += mkl_lapack.lib mkl_p3.lib mkl_c.lib
  } else {
    !isEmpty(CLAPACK_PATH) {
      DEFINES += USE_CLAPACK
      QMAKE_CXXFLAGS_DEBUG   += -I"$${CLAPACK_PATH}\include"
      QMAKE_CXXFLAGS_RELEASE += -I"$${CLAPACK_PATH}\include"
      QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${CLAPACK_PATH}\lib"
      LIBS += clapack.lib
    } else {
      error( "Either MKL_PATH or CLAPACK_PATH must be specified" )
    }
  }

  !isEmpty(EXPAT_PATH) {
    QMAKE_CXXFLAGS_DEBUG   += -I"$${EXPAT_PATH}\Source\lib"
    QMAKE_CXXFLAGS_RELEASE += -I"$${EXPAT_PATH}\Source\lib"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${EXPAT_PATH}\StaticLibs"
    LIBS += libexpat.lib
  } else {
    error( "EXPAT_PATH must be specified" )
  }

  !isEmpty(SBML_PATH) {
    QMAKE_CXXFLAGS_DEBUG   += -I"$${SBML_PATH}\include"
    QMAKE_CXXFLAGS_RELEASE += -I"$${SBML_PATH}\include"
    QMAKE_LFLAGS_WINDOWS += /LIBPATH:"$${SBML_PATH}\lib"
    LIBS += libsbml.lib libexpat-compat.lib
  } else {
    error( "SBML_PATH must be specified" )
  }
}

contains(BUILD_OS, SunOS) {
  !isEmpty(CLAPACK_PATH) {
    DEFINES += USE_CLAPACK
    INCLUDEPATH += $${CLAPACK_PATH}/include
    LIBS += -llapack -lblas -lF77 -lfl
    LIBS += -L$${CLAPACK_PATH}/lib
  } else {
    error( "CLAPACK_PATH must be specified" )
  }
  LIBS += -lSM
}

contains(BUILD_OS, Linux) {
  QMAKE_LFLAGS_RELEASE += -static
  LIBS += -lsbml
  release {
    LIBS += -lexpat_compat
  }
  LIBS += -lexpat

  !isEmpty(QWT_PATH){
      LIBS+=  -L$${QWT_PATH}/lib
      INCLUDEPATH += $${QWT_PATH}/include
  }
#  else {
#      error( "QWT_PATH must be specified" )
#  }
  !isEmpty(EXPAT_PATH){
      LIBS+=  -L$${EXPAT_PATH}/lib
      INCLUDEPATH += $${EXPAT_PATH}/include
  }
  !isEmpty(SBML_PATH){
      LIBS+=  -L$${SBML_PATH}/lib
      INCLUDEPATH += $${SBML_PATH}/include
  }
  !isEmpty(MKL_PATH) {
    DEFINES += USE_MKL
    INCLUDEPATH += $${MKL_PATH}/include
    LIBS += -lmkl_lapack -lmkl_p3 -lg2c -lpthread
    LIBS +=  -L$${MKL_PATH}/lib/32
  } else {
    !isEmpty(CLAPACK_PATH) {
      DEFINES += USE_CLAPACK
      INCLUDEPATH += $${CLAPACK_PATH}/include
      INCLUDEPATH += /usr/include/qt3
      LIBS += -llapack -lblas -lF77 -lfl
      LIBS += -L$${CLAPACK_PATH}/lib
    } else {
      !isEmpty(LAPACK_PATH) {
        message("Using lapack.")
        DEFINES += USE_CLAPACK
        INCLUDEPATH += $${LAPACK_PATH}/include
        LIBS += -llapack -lblas  -lg2c
        LIBS += -L$${LAPACK_PATH}/lib
      } else {
        error( "Either MKL_PATH, CLAPACK_PATH, or LAPACK_PATH must be specified" )
      }
    }
  }
}

DEP1.target   = depend
DEP1.depends  = qmake

QMAKE_EXTRA_UNIX_TARGETS += DEP1


Another test to build on appvoyer #5

Another test to build on appvoyer #5

# Load this from any subproject to link shared libs properly and easy.
#
# Takes a list of paths of shared libs (customLibs). The used list must
# contain 'path/to/lib/name's with path/to/lib relative to the caller.
#
# Example:
# - customLibs = ../path/to/lib/mylib ../other/path/to/otherlib
# - include(loadlibs.pri)
#
# Make sure to provide all libname.pri to set INCLUDEPATH & DEPENDPATH!
#
# Note: include(loadlibs.pri) will setup all given custom libs ->
# -> INCLUDEPATH, DEPENDPATH, LIBS, PRE_TARGETDEPS & QMAKE_LFLAGS.

QMAKE_PROJECT_DEPTH = 0 # Forces absolute paths

for(lib, customLibs) {
    !isEmpty(lib) {
        LIBDIR = $$dirname(lib)
        LIBNAME = $$basename(lib)
        #message("$${TARGET} is loading $$LIBNAME -> from: $$LIBDIR")

        # Load lib.pri to set INCLUDEPATH & DEPENDPATH
        exists($$_PRO_FILE_PWD_/$$LIBDIR/$$LIBNAME.pri) {
            include($$_PRO_FILE_PWD_/$$LIBDIR/$${LIBNAME}.pri)
        }
        #message($${INCLUDEPATH})

        LIB_EXTENSION = $$QMAKE_EXTENSION_SHLIB
        isEmpty(LIB_EXTENSION) {
            win32: LIB_EXTENSION = dll
            macx:  LIB_EXTENSION = dylib
            else:  LIB_EXTENSION = so
        }
        message($${LIB_EXTENSION})

        # Get dynamic lib binary directory
        OUTDIR = $$clean_path($$OUT_PWD/$${LIBDIR})

        macx {
            frameworks += $$files($${OUTDIR}/$${LIBNAME}.framework)
            LIBS += -F$${OUTDIR}/ -framework $${LIBNAME}
            PRE_TARGETDEPS += $${OUTDIR}/$${LIBNAME}.framework
            INCLUDEPATH += -F$${LIBDIR}
        }
        win32 {
            LIBS += $${OUTDIR}/release/$${LIBNAME}.$${LIB_EXTENSION}
            #DLLS.files += $${OUTDIR}/release/$${LIBNAME}.$${LIB_EXTENSION}
            PRE_TARGETDEPS += $${OUTDIR}/release/$${LIBNAME}.$${LIB_EXTENSION}
            #QMAKE_LFLAGS += $${OUTDIR}/release/$${LIBNAME}.$${LIB_EXTENSION}
            #INCLUDEPATH += $${OUTDIR}/release/
        }
        else {
            LIBS += -L$${OUTDIR}/ -l$${LIBNAME}
            PRE_TARGETDEPS += $${OUTDIR}/lib$${LIBNAME}.$${LIB_EXTENSION}
            QMAKE_LFLAGS += "-Wl,-rpath,\'$$OUTDIR\'"
        }
    }
}

macx { # Deploy all linked frameworks to target bundle
    APP_LIB_FILES.files = $$frameworks
    APP_LIB_FILES.path = Contents/Frameworks/
    QMAKE_BUNDLE_DATA += APP_LIB_FILES
}

#win32 {
#    DLLS.path = $$OUT_PWD
#    INSTALLS += DLLS
#}

# Load this from any subproject to link shared libs properly and easy.
#
# Takes a list of paths of shared libs (customLibs). The used list must
# contain 'path/to/lib/name's with path/to/lib relative to the caller.
#
# Example:
# - customLibs = ../path/to/lib/mylib ../other/path/to/otherlib
# - include(loadlibs.pri)
#
# Make sure to provide all libname.pri to set INCLUDEPATH & DEPENDPATH!
#
# Note: include(loadlibs.pri) will setup all given custom libs ->
# -> INCLUDEPATH, DEPENDPATH, LIBS, PRE_TARGETDEPS & QMAKE_LFLAGS.

QMAKE_PROJECT_DEPTH = 0 # Forces absolute paths

for(lib, customLibs) {
    !isEmpty(lib) {
        LIBDIR = $$dirname(lib)
        LIBNAME = $$basename(lib)
        #message("$${TARGET} is loading $$LIBNAME -> from: $$LIBDIR")

        # Load lib.pri to set INCLUDEPATH & DEPENDPATH
        exists($$_PRO_FILE_PWD_/$$LIBDIR/$$LIBNAME.pri) {
            include($$_PRO_FILE_PWD_/$$LIBDIR/$${LIBNAME}.pri)
        }
        #message($${INCLUDEPATH})

        LIB_EXTENSION = $$QMAKE_EXTENSION_SHLIB
        isEmpty(LIB_EXTENSION) {
            win32: LIB_EXTENSION = lib
            macx:  LIB_EXTENSION = dylib
            else:  LIB_EXTENSION = so
        }
        message($${LIB_EXTENSION})

        # Get dynamic lib binary directory
        OUTDIR = $$clean_path($$OUT_PWD/$${LIBDIR})

        macx {
            frameworks += $$files($${OUTDIR}/$${LIBNAME}.framework)
            LIBS += -F$${OUTDIR}/ -framework $${LIBNAME}
            PRE_TARGETDEPS += $${OUTDIR}/$${LIBNAME}.framework
            INCLUDEPATH += -F$${LIBDIR}
        }
        win32 {
            LIBS += -L$${OUTDIR}/release/ -l$${LIBNAME}
            PRE_TARGETDEPS += $${OUTDIR}/release/$${LIBNAME}.$${LIB_EXTENSION}
            INCLUDEPATH += $${OUTDIR}/release/
        }
        else {
            LIBS += -L$${OUTDIR}/ -l$${LIBNAME}
            PRE_TARGETDEPS += $${OUTDIR}/lib$${LIBNAME}.$${LIB_EXTENSION}
            QMAKE_LFLAGS += "-Wl,-rpath,\'$$OUTDIR\'"
        }
    }
}

macx { # Deploy all linked frameworks to target bundle
    APP_LIB_FILES.files = $$frameworks
    APP_LIB_FILES.path = Contents/Frameworks/
    QMAKE_BUNDLE_DATA += APP_LIB_FILES
}