Skip to content

Commit

Permalink
Merge pull request #3 from dlech/mac
Browse files Browse the repository at this point in the history
Mac
  • Loading branch information
mindsensors committed Jul 13, 2017
2 parents 56259b4 + 103e5bb commit 729d81e
Show file tree
Hide file tree
Showing 16 changed files with 59 additions and 292 deletions.
1 change: 0 additions & 1 deletion qt-creator/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ wrapper.bat
*.qmlproject.user*
*.pyqtc.user*
/src/plugins/**/*.json
/src/app/Info.plist
app_version.h
/src/plugins/coreplugin/ide_version.h
/share/qtcreator/externaltools
Expand Down
20 changes: 10 additions & 10 deletions qt-creator/qtcreator.pri
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ osx {
#OPENMV-DIFF#
#IDE_APP_TARGET = "Qt Creator"
#OPENMV-DIFF#
IDE_APP_TARGET = "OpenMV IDE"
IDE_APP_TARGET = "NXTCamView5"
#OPENMV-DIFF#

IDE_APP_BUNDLE = $$IDE_APP_PATH/$${IDE_APP_TARGET}.app
Expand Down Expand Up @@ -111,28 +111,28 @@ osx {
# target output path if not set manually
isEmpty(IDE_OUTPUT_PATH): IDE_OUTPUT_PATH = $$IDE_BUILD_TREE

IDE_LIBRARY_PATH = $$IDE_OUTPUT_PATH/$$IDE_LIBRARY_BASENAME/qtcreator
IDE_LIBRARY_PATH = $$IDE_OUTPUT_PATH/$$IDE_LIBRARY_BASENAME/nxtcamview5
IDE_PLUGIN_PATH = $$IDE_LIBRARY_PATH/plugins
IDE_DATA_PATH = $$IDE_OUTPUT_PATH/share/qtcreator
IDE_DOC_PATH = $$IDE_OUTPUT_PATH/share/doc/qtcreator
IDE_DATA_PATH = $$IDE_OUTPUT_PATH/share/nxtcamview5
IDE_DOC_PATH = $$IDE_OUTPUT_PATH/share/doc/nxtcamview5
IDE_BIN_PATH = $$IDE_OUTPUT_PATH/bin
win32: \
IDE_LIBEXEC_PATH = $$IDE_OUTPUT_PATH/bin
else: \
IDE_LIBEXEC_PATH = $$IDE_OUTPUT_PATH/libexec/qtcreator
IDE_LIBEXEC_PATH = $$IDE_OUTPUT_PATH/libexec/nxtcamview5
!isEqual(IDE_SOURCE_TREE, $$IDE_OUTPUT_PATH):copydata = 1

LINK_LIBRARY_PATH = $$IDE_BUILD_TREE/$$IDE_LIBRARY_BASENAME/qtcreator
LINK_LIBRARY_PATH = $$IDE_BUILD_TREE/$$IDE_LIBRARY_BASENAME/nxtcamview5
LINK_PLUGIN_PATH = $$LINK_LIBRARY_PATH/plugins

INSTALL_LIBRARY_PATH = $$QTC_PREFIX/$$IDE_LIBRARY_BASENAME/qtcreator
INSTALL_LIBRARY_PATH = $$QTC_PREFIX/$$IDE_LIBRARY_BASENAME/nxtcamview5
INSTALL_PLUGIN_PATH = $$INSTALL_LIBRARY_PATH/plugins
win32: \
INSTALL_LIBEXEC_PATH = $$QTC_PREFIX/bin
else: \
INSTALL_LIBEXEC_PATH = $$QTC_PREFIX/libexec/qtcreator
INSTALL_DATA_PATH = $$QTC_PREFIX/share/qtcreator
INSTALL_DOC_PATH = $$QTC_PREFIX/share/doc/qtcreator
INSTALL_LIBEXEC_PATH = $$QTC_PREFIX/libexec/nxtcamview5
INSTALL_DATA_PATH = $$QTC_PREFIX/share/nxtcamview5
INSTALL_DOC_PATH = $$QTC_PREFIX/share/doc/nxtcamview5
INSTALL_BIN_PATH = $$QTC_PREFIX/bin
}

Expand Down
4 changes: 2 additions & 2 deletions qt-creator/qtcreator.pro
Original file line number Diff line number Diff line change
Expand Up @@ -106,12 +106,12 @@ macx {
#OPENMV-DIFF#
#APPBUNDLE = "$$OUT_PWD/bin/Qt Creator.app"
#OPENMV-DIFF#
APPBUNDLE = "$$OUT_PWD/bin/OpenMV IDE.app"
APPBUNDLE = "$$OUT_PWD/bin/NXTCamView5.app"
#OPENMV-DIFF#
#OPENMV-DIFF#
#BINDIST_SOURCE = "$$OUT_PWD/bin/Qt Creator.app"
#OPENMV-DIFF#
BINDIST_SOURCE = "$$OUT_PWD/bin/OpenMV IDE.app"
BINDIST_SOURCE = "$$OUT_PWD/bin/NXTCamView5.app"
#OPENMV-DIFF#
BINDIST_INSTALLER_SOURCE = $$BINDIST_SOURCE
deployqt.commands = $$PWD/scripts/deployqtHelper_mac.sh \"$${APPBUNDLE}\" \"$$[QT_INSTALL_TRANSLATIONS]\" \"$$[QT_INSTALL_PLUGINS]\" \"$$[QT_INSTALL_IMPORTS]\" \"$$[QT_INSTALL_QML]\"
Expand Down
2 changes: 1 addition & 1 deletion qt-creator/qtcreator.qbs
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Project {
}
property string ide_data_path: qbs.targetOS.contains("osx")
? ide_app_target + ".app/Contents/Resources"
: "share/qtcreator"
: "share/nxtcamview5"
property string ide_libexec_path: qbs.targetOS.contains("osx")
? ide_data_path : qbs.targetOS.contains("windows")
? ide_app_path
Expand Down
Empty file modified qt-creator/scripts/deployqtHelper_mac.sh
100644 → 100755
Empty file.
2 changes: 1 addition & 1 deletion qt-creator/scripts/makedmg.sh
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ finalDMGName="$2"
#OPENMV-DIFF#
#title="Qt Creator"
#OPENMV-DIFF#
title="OpenMV IDE"
title="NXTCamView5"
#OPENMV-DIFF#

echo Preparing image artifacts...
Expand Down
28 changes: 28 additions & 0 deletions qt-creator/src/app/Info.plist
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSPrincipalClass</key>
<string>NSApplication</string>
<key>NSSupportsAutomaticGraphicsSwitching</key>
<true/>
<key>NSHumanReadableCopyright</key>
<string>(C) 2017 mindsensors.com</string>
<key>CFBundleIconFile</key>
<string>@ICON@</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleExecutable</key>
<string>@EXECUTABLE@</string>
<key>CFBundleIdentifier</key>
<string>@BUNDLEIDENTIFIER@</string>
<key>CFBundleVersion</key>
<string>@FULL_VERSION@</string>
<key>CFBundleShortVersionString</key>
<string>@SHORT_VERSION@</string>
<key>LSMinimumSystemVersion</key>
<string>10.7.0</string>
</dict>
</plist>
3 changes: 2 additions & 1 deletion qt-creator/src/app/app.pro
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ TEMPLATE = app
CONFIG += qtc_runnable
TARGET = $$IDE_APP_TARGET
DESTDIR = $$IDE_APP_PATH
VERSION = $$QTCREATOR_VERSION
VERSION = $$NXTCAMVIEW_VERSION
QT -= testlib

HEADERS += ../tools/qtcreatorcrashhandler/crashhandlersetup.h
Expand Down Expand Up @@ -45,6 +45,7 @@ win32 {
#OPENMV-DIFF#
ICON = ../../../nxtcamview-media/icons/nxtcamview-icon/nxtcamview.icns
#OPENMV-DIFF#
QMAKE_TARGET_BUNDLE_PREFIX = com.mindsensors
QMAKE_INFO_PLIST = Info.plist
} else {
target.path = $$INSTALL_BIN_PATH
Expand Down
6 changes: 3 additions & 3 deletions qt-creator/src/app/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ static inline QStringList getPluginPaths()
pluginPath = rootDirPath;
pluginPath += QLatin1Char('/');
pluginPath += QLatin1String(IDE_LIBRARY_BASENAME);
pluginPath += QLatin1String("/qtcreator/plugins");
pluginPath += QLatin1String("/nxtcamview5/plugins");
rc.push_back(pluginPath);
}
// 3) <localappdata>/plugins/<ideversion>
Expand All @@ -239,7 +239,7 @@ static inline QStringList getPluginPaths()
pluginPath += QLatin1Char('/')
+ QLatin1String(Core::Constants::IDE_SETTINGSVARIANT_STR)
+ QLatin1Char('/');
pluginPath += QLatin1String(Utils::HostOsInfo::isMacHost() ? "Qt Creator" : "qtcreator");
pluginPath += QLatin1String(Utils::HostOsInfo::isMacHost() ? "NXTCamView5" : "nxtcamview5");
pluginPath += QLatin1String("/plugins/");
pluginPath += QLatin1String(Core::Constants::IDE_VERSION_LONG);
rc.push_back(pluginPath);
Expand Down Expand Up @@ -301,7 +301,7 @@ static inline QSettings *userSettings()
}

static const char *SHARE_PATH =
Utils::HostOsInfo::isMacHost() ? "/../Resources" : "/../share/qtcreator";
Utils::HostOsInfo::isMacHost() ? "/../Resources" : "/../share/nxtcamview5";

int main(int argc, char **argv)
{
Expand Down
Loading

0 comments on commit 729d81e

Please sign in to comment.