diff --git a/.travis.yml b/.travis.yml index 68a6c318..a809d1c5 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,8 +5,12 @@ git: matrix: include: - - sudo: required + - os: osx + compiler: clang + - os: linux + sudo: required dist: xenial + compiler: gcc addons: apt: sources: @@ -18,10 +22,19 @@ matrix: - libesd0-dev - libgl-dev -script: - - if [[ "$TRAVIS_OS_NAME" = "linux" ]]; then source /opt/qt59/bin/qt59-env.sh; fi +install: + - '[ "$TRAVIS_OS_NAME" != osx ] || brew install qt5' + - '[ "$TRAVIS_OS_NAME" != osx ] || brew link --force qt5' - if [[ "$TRAVIS_OS_NAME" = "linux" ]]; then export SDL2_VER=2.0.8 && wget https://www.libsdl.org/release/SDL2-$SDL2_VER.tar.gz && tar -xvf SDL2-$SDL2_VER.tar.gz && cd SDL2-$SDL2_VER && ./configure && make && sudo make install && cd ..; fi - - if [[ "$CC" == "gcc" ]]; then qmake moonlight-qt.pro -spec linux-g++; fi - - if [[ "$CC" == "clang" ]]; then qmake moonlight-qt.pro -spec linux-clang; fi + +before_script: + - '[ "$TRAVIS_OS_NAME" != "linux" ] || source /opt/qt59/bin/qt59-env.sh' + - qmake -v + - '[[ "$TRAVIS_OS_NAME" != linux || "$CXX" != clang++ ]] || export QMAKESPEC=linux-clang' + - '[[ "$TRAVIS_OS_NAME" != linux || "$CXX" != g++ ]] || export QMAKESPEC=linux-g++' + - '[ "$TRAVIS_OS_NAME" != osx ] || export QMAKESPEC=macx-clang' + +script: + - qmake moonlight-qt.pro -spec $QMAKESPEC - make debug - make release diff --git a/README.md b/README.md index 3ae4dd00..575de0ba 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,7 @@ This client is currently still in development (pre-alpha), but the streaming per You can follow development on our [Discord server](https://discord.gg/6ERtzFY). [![Windows AppVeyor Status](https://ci.appveyor.com/api/projects/status/glj5cxqwy2w3bglv/branch/master?svg=true)](https://ci.appveyor.com/project/cgutman/moonlight-qt/branch/master) + [![Mac and Linux Travis CI Status](https://travis-ci.org/moonlight-stream/moonlight-qt.svg?branch=master)](https://travis-ci.org/moonlight-stream/moonlight-qt) ## Features - Hardware accelerated video decoding on Windows, Mac, and Linux diff --git a/app/Info.plist b/app/Info.plist index 66e4048d..e9a56571 100644 --- a/app/Info.plist +++ b/app/Info.plist @@ -5,22 +5,26 @@ CFBundleExecutable Moonlight CFBundleGetInfoString - Created by Qt/QMake + Stream games from your NVIDIA GameStream-enabled PC CFBundleIconFile - macos + moonlight CFBundleIdentifier - com.yourcompany.moonlight-qt + com.moonlight-stream.Moonlight + NSHighResolutionCapable + CFBundlePackageType APPL CFBundleSignature ???? LSMinimumSystemVersion 10.10 - NOTE - This file was generated by Qt/QMake. NSPrincipalClass NSApplication NSSupportsAutomaticGraphicsSwitching + CFBundleVersion + 0.0.3 + CFBundleDisplayName + Moonlight diff --git a/app/app.pro b/app/app.pro index d1a8e9fb..4e2ff122 100644 --- a/app/app.pro +++ b/app/app.pro @@ -185,16 +185,15 @@ unix:!macx: { INSTALLS += target desktop icons appdata } - win32 { RC_ICONS = moonlight.ico } - macx { QMAKE_INFO_PLIST = $$PWD/Info.plist - APP_QML_FILES.files = res/macos.icns - APP_QML_FILES.path = Contents/Resources - QMAKE_BUNDLE_DATA += APP_QML_FILES + + APP_BUNDLE_RESOURCES.files = moonlight.icns + APP_BUNDLE_RESOURCES.path = Contents/Resources + QMAKE_BUNDLE_DATA += APP_BUNDLE_RESOURCES } VERSION = 0.0.3 diff --git a/app/moonlight.icns b/app/moonlight.icns new file mode 100644 index 00000000..e2e1abf9 Binary files /dev/null and b/app/moonlight.icns differ diff --git a/app/res/macos.icns b/app/res/macos.icns deleted file mode 100644 index 58d1527e..00000000 Binary files a/app/res/macos.icns and /dev/null differ diff --git a/libs/mac/lib/libavcodec.58.dylib b/libs/mac/lib/libavcodec.58.dylib index 917148a0..97fc4c0d 100755 Binary files a/libs/mac/lib/libavcodec.58.dylib and b/libs/mac/lib/libavcodec.58.dylib differ diff --git a/libs/mac/lib/libavutil.56.dylib b/libs/mac/lib/libavutil.56.dylib index 9730976f..40cc7827 100755 Binary files a/libs/mac/lib/libavutil.56.dylib and b/libs/mac/lib/libavutil.56.dylib differ diff --git a/libs/mac/lib/libcrypto.dylib b/libs/mac/lib/libcrypto.dylib index 5047dc33..e9cb6450 100755 Binary files a/libs/mac/lib/libcrypto.dylib and b/libs/mac/lib/libcrypto.dylib differ diff --git a/libs/mac/lib/libssl.dylib b/libs/mac/lib/libssl.dylib index f83d75b2..f775755d 100755 Binary files a/libs/mac/lib/libssl.dylib and b/libs/mac/lib/libssl.dylib differ diff --git a/libs/mac/lib/libswresample.3.dylib b/libs/mac/lib/libswresample.3.dylib index 1e2a9f1d..825f87b6 100755 Binary files a/libs/mac/lib/libswresample.3.dylib and b/libs/mac/lib/libswresample.3.dylib differ diff --git a/scripts/generate-dmg.sh b/scripts/generate-dmg.sh index e34f9743..03ef568b 100755 --- a/scripts/generate-dmg.sh +++ b/scripts/generate-dmg.sh @@ -34,13 +34,18 @@ popd echo Copying dylib dependencies mkdir $BUILD_FOLDER/app/Moonlight.app/Contents/lib -cp $SOURCE_ROOT/libs/mac/lib/*.dylib $BUILD_FOLDER/app/Moonlight.app/Contents/lib/ +cp $SOURCE_ROOT/libs/mac/lib/*.dylib $BUILD_FOLDER/app/Moonlight.app/Contents/lib/ || fail "Dylib copy failed!" echo Copying frameworks dependencies mkdir $BUILD_FOLDER/app/Moonlight.app/Contents/Frameworks -cp -R $SOURCE_ROOT/libs/mac/Frameworks/ $BUILD_FOLDER/app/Moonlight.app/Contents/Frameworks/ +cp -R $SOURCE_ROOT/libs/mac/Frameworks/ $BUILD_FOLDER/app/Moonlight.app/Contents/Frameworks/ || fail "Framework copy failed!" echo Creating DMG EXTRA_ARGS= -if [ "$BUILD_CONFIG" == "Debug" ]; then EXTRA_ARGS=-use-debug-libs; fi -macdeployqt $BUILD_FOLDER/app/Moonlight.app -dmg $EXTRA_ARGS -qmldir=$SOURCE_ROOT/app/gui -appstore-compliant \ No newline at end of file +if [ "$BUILD_CONFIG" == "Debug" ]; then EXTRA_ARGS="$EXTRA_ARGS -use-debug-libs"; fi +if [ "$SIGNING_KEY" != "" ]; then EXTRA_ARGS="$EXTRA_ARGS -codesign=$SIGNING_KEY"; fi +echo Extra deployment arguments: $EXTRA_ARGS +macdeployqt $BUILD_FOLDER/app/Moonlight.app -dmg $EXTRA_ARGS -qmldir=$SOURCE_ROOT/app/gui -appstore-compliant || fail "macdeployqt failed!" + +echo Deploying DMG +mv $BUILD_FOLDER/app/Moonlight.dmg $INSTALLER_FOLDER/ diff --git a/scripts/svg2icns b/scripts/svg2icns new file mode 100755 index 00000000..7ace8812 --- /dev/null +++ b/scripts/svg2icns @@ -0,0 +1,27 @@ +#!/bin/bash +# https://gist.github.com/zlbruce/883605a635df8d5964bab11ed75e46ad +echo "*** SVG 2 ICNS ***" +if [ $# -ne 1 ]; then + echo "Usage: svg2icns filename.svg" + exit 100 +fi +filename="$1" +name=${filename%.*} +ext=${filename##*.} +echo "processing: $name" +dest="$name".iconset +mkdir "$dest" + +convert -background none -resize '!16x16' "$1" "$dest/icon_16x16.png" +convert -background none -resize '!32x32' "$1" "$dest/icon_16x16@2x.png" +cp "$dest/icon_16x16@2x.png" "$dest/icon_32x32.png" +convert -background none -resize '!64x64' "$1" "$dest/icon_32x32@2x.png" +convert -background none -resize '!128x128' "$1" "$dest/icon_128x128.png" +convert -background none -resize '!256x256' "$1" "$dest/icon_128x128@2x.png" +cp "$dest/icon_128x128@2x.png" "$dest/icon_256x256.png" +convert -background none -resize '!512x512' "$1" "$dest/icon_256x256@2x.png" +cp "$dest/icon_256x256@2x.png" "$dest/icon_512x512.png" +convert -background none -resize '!1024x1024' "$1" "$dest/icon_512x512@2x.png" + +iconutil -c icns "$dest" +rm -R "$dest"