Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@ platform:
- x64

#environment:
environment:
matrix:
- BUILD_WIN_PORTABLE: OFF
- BUILD_WIN_PORTABLE: ON

# build Configuration, i.e. Debug, Release, etc.
configuration: Release
Expand All @@ -37,6 +41,9 @@ test: off
matrix:
fast_finish: true # stop all jobs if any job fails
#allow_failures: # list jobs allowed to fail without stopping the rest
exclude:
- platform: x64 # do not build Win64 portable
BUILD_WIN_PORTABLE: ON

install:
- cd %APPVEYOR_BUILD_FOLDER%
Expand Down
4 changes: 4 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
build/PortableApps/**/*.ini eol=crlf
build/PortableApps/**/*.txt eol=crlf
build/PortableApps/**/*.ini.in eol=crlf
build/PortableApps/**/*.html eol=crlf
Comment on lines +1 to +4
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not really sure these are needed, but the target is a Windows machine

1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ vtest/Thumbnails
vtest/Pictures
.vs
dependencies
MuseScorePortable

# Downloaded files during build process
MuseScore_General.sf3
Expand Down
9 changes: 7 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@ option(COVERAGE "Build with instrumentation to record code coverage." OFF)
option(BUILD_64 "Build 64 bit version of editor" ON)
option(BUILD_AUTOUPDATE "Build with autoupdate support" OFF)
option(BUILD_CRASH_REPORTER "Build with crash reporter" OFF)
option(BUILD_PORTABLEAPPS "Windows build for PortableApps.com" OFF)
set(CRASH_REPORT_URL "http://127.0.0.1:1127/post" CACHE STRING "URL where to send crash reports (valid if BUILD_CRASH_REPORTER is set to ON)")
option(BUILD_TELEMETRY_MODULE "Build with telemetry module" ON)
set(TELEMETRY_TRACK_ID "" CACHE STRING "Telemetry track id")
Expand Down Expand Up @@ -211,6 +212,10 @@ else (BUILD_64 STREQUAL "ON")
SET (DEPENDENCIES_DIR "${PROJECT_SOURCE_DIR}/dependencies/libx86")
endif (BUILD_64 STREQUAL "ON")

if (BUILD_PORTABLEAPPS STREQUAL "ON")
SET (WIN_PORTABLE 1)
endif (BUILD_PORTABLEAPPS STREQUAL "ON")

#
# Sparkle/WinSparkle routine
#
Expand All @@ -224,14 +229,14 @@ if (BUILD_AUTOUPDATE STREQUAL "ON")
set(MAC_APPCAST_URL "https://sparkle.musescore.org/${MSCORE_RELEASE_CHANNEL}/3/macos/appcast.xml")
endif(SPARKLE_FOUND)
elseif (MSVC)
if (NOT MSCORE_UNSTABLE)
if ((NOT MSCORE_UNSTABLE) AND (NOT DEFINED WIN_PORTABLE)) # do not include WinSparkle in unstable and portable builds
include(FindWinSparkle)
add_library(winsparkledll SHARED IMPORTED)
set_target_properties(winsparkledll PROPERTIES IMPORTED_IMPLIB ${WINSPARKLE_LIBRARY})
set(WIN_SPARKLE_ENABLED 1)
set(WIN_SPARKLE_APPCAST_URL "https://sparkle.musescore.org/${MSCORE_RELEASE_CHANNEL}/3/win/appcast${ARCH_TYPE}.xml")
message("Win Sparkle Url: " ${WIN_SPARKLE_APPCAST_URL})
endif (NOT MSCORE_UNSTABLE)
endif ((NOT MSCORE_UNSTABLE) AND (NOT DEFINED WIN_PORTABLE))
else (APPLE)
message("Sparkle is not supported on your system.")
endif (APPLE)
Expand Down
Binary file added assets/mscx-icon.ico
Binary file not shown.
Binary file added assets/mscz-icon.ico
Binary file not shown.
60 changes: 60 additions & 0 deletions build/PortableApps/App/AppInfo/Launcher/MuseScorePortable.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
[Launch]
ProgramExecutable=MuseScore\bin\MuseScore3.exe
WaitForProgram=true
DirectoryMoveOK=yes

[Activate]
Registry=true

[RegistryKeys]
qtfiledialog=HKCU\Software\QtProject\OrganizationDefaults\FileDialog
qtcustomcolors=HKCU\Software\QtProject\OrganizationDefaults\Qt\customColors

[RegistryCleanupIfEmpty]
1=HKCU\Software\QtProject\OrganizationDefaults\FileDialog
2=HKCU\Software\QtProject\OrganizationDefaults\Qt\customColors
3=HKCU\Software\QtProject\OrganizationDefaults\Qt
4=HKCU\Software\QtProject\OrganizationDefaults
5=HKCU\Software\QtProject

[FileWrite1]
Type=replace
File=%PAL:DataDir%\settings\MuseScore\MuseScore*.ini
Find=%PAL:LastDrive%%PAL:LastPackagePartialDir:ForwardSlash%/
Replace=%PAL:Drive%%PAL:PackagePartialDir:ForwardSlash%/

[FileWrite2]
Type=replace
File=%PAL:DataDir%\settings\plugins.xml
Find=<path>%PAL:LastDrive%
Replace=<path>%PAL:Drive%

[FileWrite3]
Type=replace
File=%PAL:DataDir%\settings\plugins.xml
Find=%PAL:LastPackagePartialDir:ForwardSlash%/
Replace=%PAL:PackagePartialDir:ForwardSlash%/

[FileWrite4]
Type=replace
File=%PAL:DataDir%\settings\session
Find=<path>%PAL:LastDrive%
Replace=<path>%PAL:Drive%

[FileWrite5]
Type=replace
File=%PAL:DataDir%\settings\session
Find=%PAL:LastPackagePartialDir:ForwardSlash%/
Replace=%PAL:PackagePartialDir:ForwardSlash%/

[FileWrite6]
Type=replace
File=%PAL:DataDir%\settings\qtfiledialog.reg
Find=file:///%PAL:LastDrive%
Replace=file:///%PAL:Drive%

[FileWrite7]
Type=replace
File=%PAL:DataDir%\settings\qtfiledialog.reg
Find=%PAL:LastPackagePartialDir:ForwardSlash%/
Replace=%PAL:PackagePartialDir:ForwardSlash%/
1 change: 1 addition & 0 deletions build/PortableApps/App/readme.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
The files in this directory are necessary for MuseScore Portable to function. There is normally no need to directly access or alter any of the files within these directories.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added build/PortableApps/Other/Help/images/favicon.ico
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 6 additions & 0 deletions build/PortableApps/Other/Source/AppNamePortable.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
AdditionalParameters=
DisableSplashScreen=true
RunLocally=false

# The above options are explained in the included readme.txt
# This INI file is an example only and is not used unless it is placed as described in the included readme.txt
1 change: 1 addition & 0 deletions build/PortableApps/Other/Source/AppSource.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
The source code for the base application in this package is available from the portable applications website mentioned in the help.html file.
Loading