diff --git a/apps/RPiPlay/credits b/apps/RPiPlay/credits new file mode 100644 index 0000000000..6cac8da67f --- /dev/null +++ b/apps/RPiPlay/credits @@ -0,0 +1,2 @@ +FD- (GitHub) +CleanMachine1 (GitHub) diff --git a/apps/RPiPlay/description b/apps/RPiPlay/description new file mode 100644 index 0000000000..11cd6038f3 --- /dev/null +++ b/apps/RPiPlay/description @@ -0,0 +1,4 @@ +Open-source AirPlay mirroring server for the Raspberry Pi. Supports Apple devices with iOS 9 and up. +Note: To exit the application, press CTRL+C to exit or close the connection to your iOS device. + +Run from the Main Menu > Accessories > RPiPlay diff --git a/apps/RPiPlay/icon-24.png b/apps/RPiPlay/icon-24.png new file mode 100644 index 0000000000..0b918b17b4 Binary files /dev/null and b/apps/RPiPlay/icon-24.png differ diff --git a/apps/RPiPlay/icon-64.png b/apps/RPiPlay/icon-64.png new file mode 100644 index 0000000000..098a45eb72 Binary files /dev/null and b/apps/RPiPlay/icon-64.png differ diff --git a/apps/RPiPlay/install b/apps/RPiPlay/install new file mode 100755 index 0000000000..4fc6008ea0 --- /dev/null +++ b/apps/RPiPlay/install @@ -0,0 +1,46 @@ +#!/bin/bash + +# Install dependencies +install_packages cmake libavahi-compat-libdnssd-dev libplist-dev libssl-dev zenity || exit 1 + +# Prepare source +sudo rm -rf ~/RPiPlay +git_clone https://github.com/FD-/RPiPlay.git || error "Failed to git clone RPiPlay source code." +cd RPiPlay/ || error "Failed to enter RPiPlay directory." +mkdir build && cd build || error "Failed to create/enter build directory." + +# Compile +cmake .. || error "Failed to run cmake." +make || error "Failed to run make." +sudo make install || error "Failed to install RPiPlay system-wide." + +# Create run script +echo "#!/bin/bash +yn=$(zenity --title "RPiPlay" --text "Please configure whether you would like sound output from either \nHDMI or analog. \nNOTE: When the application starts press CTRL+C to exit or close the\nconnection from your iOS device." --list --radiolist --column "Choice" --column "Answer" HDMI HDMI Analog Analog ) +if [ "$yn" = "HDMI" ]; then + echo "RPiPlay starting with HDMI audio output." + $DIRECTORY/etc/terminal-run "rpiplay -a hdmi -b auto" RPiPlay +elif [ "$yn" = "Analog" ]; then + echo "RPiPlay starting with analog audio output." + $DIRECTORY/etc/terminal-run "rpiplay -a analog -b auto" RPiPlay +else + echo "RPiPlay starting with automatic audio output selection." + $DIRECTORY/etc/terminal-run "rpiplay -b auto" RPiPlay +fi" > startrpiplay || error "Failed to create start script." +chmod +x startrpiplay +sudo mv startrpiplay /usr/local/bin/ || error "Failed to move start script to /usr/local/bin." + +# Create desktop entry +echo "[Desktop Entry] +Name=RPiPlay +GenericName=AirPlay Mirroring +Comment=Open-source AirPlay mirroring server +Exec=startrpiplay +Icon=$(dirname "$0")/icon-64.png +Terminal=false +StartupNotify=true +Type=Application +Categories=Utility;" > ~/.local/share/applications/rpiplay.desktop || error "Failed to create desktop entry." + +# Clean up +sudo rm -rf ~/RPiPlay diff --git a/apps/RPiPlay/uninstall b/apps/RPiPlay/uninstall new file mode 100755 index 0000000000..912e334038 --- /dev/null +++ b/apps/RPiPlay/uninstall @@ -0,0 +1,7 @@ +#!/bin/bash + +sudo rm -rf ~/RPiPlay +sudo rm -f /usr/local/bin/rpiplay || error "Failed to remove /usr/local/bin/rpiplay binary." +sudo rm -f /usr/local/bin/startrpiplay || error "Failed to remove /usr/local/bin/startrpiplay script." + +purge_packages || exit 1 diff --git a/apps/RPiPlay/website b/apps/RPiPlay/website new file mode 100644 index 0000000000..a5fe02a8a9 --- /dev/null +++ b/apps/RPiPlay/website @@ -0,0 +1 @@ +https://github.com/FD-/RPiPlay