From 6d7bff2476459049f4f554291a680e0f6003ea66 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20Mr=C3=A1zek?= Date: Sun, 7 Jun 2015 21:10:18 +0200 Subject: GH-1060 remove updater code --- CMakeLists.txt | 1 - mmc_updater/CMakeLists.txt | 52 - mmc_updater/LICENSE | 19 - mmc_updater/README.md | 138 - .../cmake/modules/GenerateCppResourceFile.cmake | 23 - mmc_updater/depends/AnyOption/CMakeLists.txt | 9 - mmc_updater/depends/AnyOption/README | 16 - mmc_updater/depends/AnyOption/anyoption.cpp | 1176 ------ mmc_updater/depends/AnyOption/anyoption.h | 270 -- mmc_updater/depends/tinyxml/CMakeLists.txt | 24 - mmc_updater/depends/tinyxml/readme.txt | 530 --- mmc_updater/depends/tinyxml/tinystr.cpp | 111 - mmc_updater/depends/tinyxml/tinystr.h | 305 -- mmc_updater/depends/tinyxml/tinyxml.cpp | 1886 --------- mmc_updater/depends/tinyxml/tinyxml.h | 1805 --------- mmc_updater/depends/tinyxml/tinyxmlerror.cpp | 52 - mmc_updater/depends/tinyxml/tinyxmlparser.cpp | 1638 -------- mmc_updater/depends/win32cpp/controls.h | 1074 ----- mmc_updater/depends/win32cpp/copyright.txt | 33 - mmc_updater/depends/win32cpp/cstring.h | 905 ----- mmc_updater/depends/win32cpp/default_resource.h | 94 - mmc_updater/depends/win32cpp/default_resource.rc | 250 -- mmc_updater/depends/win32cpp/dialog.h | 876 ---- mmc_updater/depends/win32cpp/docking.h | 4214 -------------------- mmc_updater/depends/win32cpp/file.h | 392 -- mmc_updater/depends/win32cpp/frame.h | 3303 --------------- mmc_updater/depends/win32cpp/gdi.h | 3944 ------------------ mmc_updater/depends/win32cpp/info.txt | 205 - mmc_updater/depends/win32cpp/listview.h | 867 ---- mmc_updater/depends/win32cpp/mdi.h | 783 ---- mmc_updater/depends/win32cpp/menu.h | 600 --- mmc_updater/depends/win32cpp/propertysheet.h | 960 ----- mmc_updater/depends/win32cpp/rebar.h | 709 ---- mmc_updater/depends/win32cpp/release notes.txt | 116 - mmc_updater/depends/win32cpp/ribbon.h | 527 --- mmc_updater/depends/win32cpp/shared_ptr.h | 199 - mmc_updater/depends/win32cpp/socket.h | 778 ---- mmc_updater/depends/win32cpp/statusbar.h | 226 -- mmc_updater/depends/win32cpp/stdcontrols.h | 1000 ----- mmc_updater/depends/win32cpp/tab.h | 1658 -------- mmc_updater/depends/win32cpp/taskdialog.h | 811 ---- mmc_updater/depends/win32cpp/thread.h | 241 -- mmc_updater/depends/win32cpp/toolbar.h | 1361 ------- mmc_updater/depends/win32cpp/treeview.h | 624 --- mmc_updater/depends/win32cpp/wceframe.h | 420 -- mmc_updater/depends/win32cpp/wcestddef.h | 58 - mmc_updater/depends/win32cpp/webbrowser.h | 760 ---- mmc_updater/depends/win32cpp/wincore.h | 2977 -------------- mmc_updater/depends/win32cpp/winutils.h | 649 --- mmc_updater/src/AppInfo.cpp | 23 - mmc_updater/src/AppInfo.h | 39 - mmc_updater/src/CMakeLists.txt | 116 - mmc_updater/src/DirIterator.cpp | 85 - mmc_updater/src/DirIterator.h | 43 - mmc_updater/src/FileUtils.cpp | 517 --- mmc_updater/src/FileUtils.h | 141 - mmc_updater/src/Log.cpp | 65 - mmc_updater/src/Log.h | 46 - mmc_updater/src/MacBundle.cpp | 53 - mmc_updater/src/MacBundle.h | 35 - mmc_updater/src/Platform.h | 34 - mmc_updater/src/ProcessUtils.cpp | 536 --- mmc_updater/src/ProcessUtils.h | 101 - mmc_updater/src/StandardDirs.cpp | 63 - mmc_updater/src/StandardDirs.h | 22 - mmc_updater/src/StandardDirs.mm | 18 - mmc_updater/src/StlSymbolsLeopard.cpp | 81 - mmc_updater/src/StringUtils.h | 46 - mmc_updater/src/UpdateDialog.cpp | 25 - mmc_updater/src/UpdateDialog.h | 29 - mmc_updater/src/UpdateDialogAscii.cpp | 70 - mmc_updater/src/UpdateDialogAscii.h | 32 - mmc_updater/src/UpdateDialogCocoa.h | 32 - mmc_updater/src/UpdateDialogCocoa.mm | 194 - mmc_updater/src/UpdateDialogGtk.cpp | 155 - mmc_updater/src/UpdateDialogGtk.h | 42 - mmc_updater/src/UpdateDialogGtkFactory.cpp | 59 - mmc_updater/src/UpdateDialogGtkFactory.h | 13 - mmc_updater/src/UpdateDialogWin32.cpp | 215 - mmc_updater/src/UpdateDialogWin32.h | 39 - mmc_updater/src/UpdateInstaller.cpp | 479 --- mmc_updater/src/UpdateInstaller.h | 74 - mmc_updater/src/UpdateMessage.h | 42 - mmc_updater/src/UpdateObserver.h | 15 - mmc_updater/src/UpdateScript.cpp | 99 - mmc_updater/src/UpdateScript.h | 82 - mmc_updater/src/UpdaterOptions.cpp | 87 - mmc_updater/src/UpdaterOptions.h | 26 - mmc_updater/src/main.cpp | 206 - mmc_updater/src/resources/Info.plist | 38 - mmc_updater/src/resources/icon128.png | Bin 3802 -> 0 bytes mmc_updater/src/resources/icon64.png | Bin 2182 -> 0 bytes mmc_updater/src/resources/mac.icns | Bin 43606 -> 0 bytes mmc_updater/src/resources/updater.ico | Bin 82726 -> 0 bytes mmc_updater/src/resources/updater.manifest | 27 - mmc_updater/src/resources/updater.rc | 30 - mmc_updater/src/tests/CMakeLists.txt | 47 - mmc_updater/src/tests/TestFileUtils.cpp | 79 - mmc_updater/src/tests/TestFileUtils.h | 10 - mmc_updater/src/tests/TestParseScript.cpp | 24 - mmc_updater/src/tests/TestParseScript.h | 8 - mmc_updater/src/tests/TestUtils.h | 108 - mmc_updater/src/tests/file_list.xml | 37 - mmc_updater/src/tests/new_app.cpp | 8 - mmc_updater/src/tests/old_app.cpp | 7 - mmc_updater/src/tests/test.manifest | 27 - mmc_updater/src/tests/test.rc | 28 - 107 files changed, 44226 deletions(-) delete mode 100644 mmc_updater/CMakeLists.txt delete mode 100644 mmc_updater/LICENSE delete mode 100644 mmc_updater/README.md delete mode 100644 mmc_updater/cmake/modules/GenerateCppResourceFile.cmake delete mode 100644 mmc_updater/depends/AnyOption/CMakeLists.txt delete mode 100644 mmc_updater/depends/AnyOption/README delete mode 100644 mmc_updater/depends/AnyOption/anyoption.cpp delete mode 100644 mmc_updater/depends/AnyOption/anyoption.h delete mode 100644 mmc_updater/depends/tinyxml/CMakeLists.txt delete mode 100644 mmc_updater/depends/tinyxml/readme.txt delete mode 100644 mmc_updater/depends/tinyxml/tinystr.cpp delete mode 100644 mmc_updater/depends/tinyxml/tinystr.h delete mode 100644 mmc_updater/depends/tinyxml/tinyxml.cpp delete mode 100644 mmc_updater/depends/tinyxml/tinyxml.h delete mode 100644 mmc_updater/depends/tinyxml/tinyxmlerror.cpp delete mode 100644 mmc_updater/depends/tinyxml/tinyxmlparser.cpp delete mode 100644 mmc_updater/depends/win32cpp/controls.h delete mode 100644 mmc_updater/depends/win32cpp/copyright.txt delete mode 100644 mmc_updater/depends/win32cpp/cstring.h delete mode 100644 mmc_updater/depends/win32cpp/default_resource.h delete mode 100644 mmc_updater/depends/win32cpp/default_resource.rc delete mode 100644 mmc_updater/depends/win32cpp/dialog.h delete mode 100644 mmc_updater/depends/win32cpp/docking.h delete mode 100644 mmc_updater/depends/win32cpp/file.h delete mode 100644 mmc_updater/depends/win32cpp/frame.h delete mode 100644 mmc_updater/depends/win32cpp/gdi.h delete mode 100644 mmc_updater/depends/win32cpp/info.txt delete mode 100644 mmc_updater/depends/win32cpp/listview.h delete mode 100644 mmc_updater/depends/win32cpp/mdi.h delete mode 100644 mmc_updater/depends/win32cpp/menu.h delete mode 100644 mmc_updater/depends/win32cpp/propertysheet.h delete mode 100644 mmc_updater/depends/win32cpp/rebar.h delete mode 100644 mmc_updater/depends/win32cpp/release notes.txt delete mode 100644 mmc_updater/depends/win32cpp/ribbon.h delete mode 100644 mmc_updater/depends/win32cpp/shared_ptr.h delete mode 100644 mmc_updater/depends/win32cpp/socket.h delete mode 100644 mmc_updater/depends/win32cpp/statusbar.h delete mode 100644 mmc_updater/depends/win32cpp/stdcontrols.h delete mode 100644 mmc_updater/depends/win32cpp/tab.h delete mode 100644 mmc_updater/depends/win32cpp/taskdialog.h delete mode 100644 mmc_updater/depends/win32cpp/thread.h delete mode 100644 mmc_updater/depends/win32cpp/toolbar.h delete mode 100644 mmc_updater/depends/win32cpp/treeview.h delete mode 100644 mmc_updater/depends/win32cpp/wceframe.h delete mode 100644 mmc_updater/depends/win32cpp/wcestddef.h delete mode 100644 mmc_updater/depends/win32cpp/webbrowser.h delete mode 100644 mmc_updater/depends/win32cpp/wincore.h delete mode 100644 mmc_updater/depends/win32cpp/winutils.h delete mode 100644 mmc_updater/src/AppInfo.cpp delete mode 100644 mmc_updater/src/AppInfo.h delete mode 100644 mmc_updater/src/CMakeLists.txt delete mode 100644 mmc_updater/src/DirIterator.cpp delete mode 100644 mmc_updater/src/DirIterator.h delete mode 100644 mmc_updater/src/FileUtils.cpp delete mode 100644 mmc_updater/src/FileUtils.h delete mode 100644 mmc_updater/src/Log.cpp delete mode 100644 mmc_updater/src/Log.h delete mode 100644 mmc_updater/src/MacBundle.cpp delete mode 100644 mmc_updater/src/MacBundle.h delete mode 100644 mmc_updater/src/Platform.h delete mode 100644 mmc_updater/src/ProcessUtils.cpp delete mode 100644 mmc_updater/src/ProcessUtils.h delete mode 100644 mmc_updater/src/StandardDirs.cpp delete mode 100644 mmc_updater/src/StandardDirs.h delete mode 100644 mmc_updater/src/StandardDirs.mm delete mode 100644 mmc_updater/src/StlSymbolsLeopard.cpp delete mode 100644 mmc_updater/src/StringUtils.h delete mode 100644 mmc_updater/src/UpdateDialog.cpp delete mode 100644 mmc_updater/src/UpdateDialog.h delete mode 100644 mmc_updater/src/UpdateDialogAscii.cpp delete mode 100644 mmc_updater/src/UpdateDialogAscii.h delete mode 100644 mmc_updater/src/UpdateDialogCocoa.h delete mode 100644 mmc_updater/src/UpdateDialogCocoa.mm delete mode 100644 mmc_updater/src/UpdateDialogGtk.cpp delete mode 100644 mmc_updater/src/UpdateDialogGtk.h delete mode 100644 mmc_updater/src/UpdateDialogGtkFactory.cpp delete mode 100644 mmc_updater/src/UpdateDialogGtkFactory.h delete mode 100644 mmc_updater/src/UpdateDialogWin32.cpp delete mode 100644 mmc_updater/src/UpdateDialogWin32.h delete mode 100644 mmc_updater/src/UpdateInstaller.cpp delete mode 100644 mmc_updater/src/UpdateInstaller.h delete mode 100644 mmc_updater/src/UpdateMessage.h delete mode 100644 mmc_updater/src/UpdateObserver.h delete mode 100644 mmc_updater/src/UpdateScript.cpp delete mode 100644 mmc_updater/src/UpdateScript.h delete mode 100644 mmc_updater/src/UpdaterOptions.cpp delete mode 100644 mmc_updater/src/UpdaterOptions.h delete mode 100644 mmc_updater/src/main.cpp delete mode 100644 mmc_updater/src/resources/Info.plist delete mode 100644 mmc_updater/src/resources/icon128.png delete mode 100644 mmc_updater/src/resources/icon64.png delete mode 100644 mmc_updater/src/resources/mac.icns delete mode 100644 mmc_updater/src/resources/updater.ico delete mode 100644 mmc_updater/src/resources/updater.manifest delete mode 100644 mmc_updater/src/resources/updater.rc delete mode 100644 mmc_updater/src/tests/CMakeLists.txt delete mode 100644 mmc_updater/src/tests/TestFileUtils.cpp delete mode 100644 mmc_updater/src/tests/TestFileUtils.h delete mode 100644 mmc_updater/src/tests/TestParseScript.cpp delete mode 100644 mmc_updater/src/tests/TestParseScript.h delete mode 100644 mmc_updater/src/tests/TestUtils.h delete mode 100644 mmc_updater/src/tests/file_list.xml delete mode 100644 mmc_updater/src/tests/new_app.cpp delete mode 100644 mmc_updater/src/tests/old_app.cpp delete mode 100644 mmc_updater/src/tests/test.manifest delete mode 100644 mmc_updater/src/tests/test.rc diff --git a/CMakeLists.txt b/CMakeLists.txt index 06401d04..5c93a490 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -137,4 +137,3 @@ add_subdirectory(logic) add_subdirectory(application) -add_subdirectory(mmc_updater) diff --git a/mmc_updater/CMakeLists.txt b/mmc_updater/CMakeLists.txt deleted file mode 100644 index 8d425b5a..00000000 --- a/mmc_updater/CMakeLists.txt +++ /dev/null @@ -1,52 +0,0 @@ -project(updater) - -cmake_minimum_required(VERSION 2.6) -enable_testing() -set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules") - -include_directories(depends) - -if(WIN32) - include_directories(depends/win32cpp) - - # static all the things. The updater must have no dependencies, or it will fail. - if(MINGW) - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -static-libgcc -static") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -static-libgcc -static-libstdc++ -static") -#set(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "${CMAKE_SHARED_LIBRARY_LINK_C_FLAGS} -static-libgcc -s") -#set(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS "${CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS} -static-libgcc -static-libstdc++ -s") - endif() - - if(MSVC) - # - Link the updater binary statically with the Visual C++ runtime - # so that the executable can function standalone. - # - Enable PDB generation for release builds - set(CMAKE_CXX_FLAGS_DEBUG "/MT") - set(CMAKE_C_FLAGS_DEBUG "/MT") - - set(CMAKE_CXX_FLAGS_RELEASE "/MT /Zi /O2 /Ob2 /D NDEBUG") - set(CMAKE_C_FLAGS_RELEASE "/MT /Zi /O2 /Ob2 /D NDEBUG") - remove_definitions(-DUNICODE -D_UNICODE) - endif() -else() - # optimize for reduced code size - set(CMAKE_CXX_FLAGS_RELEASE "-Os") - set(CMAKE_C_FLAGS_RELEASE "-Os") -endif() - -if(APPLE) - # Build the updater as a dual 32/64bit binary. If only one architecture - # is required, removing the other architecture will reduce the size - # of the updater binary - set(CMAKE_OSX_ARCHITECTURES i386;x86_64) - - # Build the updater so that it works on OS X 10.7 and above. - set(MIN_OSX_VERSION 10.7) - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mmacosx-version-min=${MIN_OSX_VERSION}") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -mmacosx-version-min=${MIN_OSX_VERSION}") -endif() - -add_subdirectory(src) -add_subdirectory(depends/AnyOption) -add_subdirectory(depends/tinyxml) - diff --git a/mmc_updater/LICENSE b/mmc_updater/LICENSE deleted file mode 100644 index f71a89be..00000000 --- a/mmc_updater/LICENSE +++ /dev/null @@ -1,19 +0,0 @@ - -This project is licensed under a BSD license. - -The Mendeley Desktop icon graphics and name are trademarks of Mendeley Ltd. -and must be removed or replaced - see src/AppInfo.cpp and the files -in src/resources. - -=== - -Copyright (c) 2011, Mendeley Ltd. - -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - - Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/mmc_updater/README.md b/mmc_updater/README.md deleted file mode 100644 index fa3c41ae..00000000 --- a/mmc_updater/README.md +++ /dev/null @@ -1,138 +0,0 @@ -This tool is a component of a cross-platform auto-update system. -It is responsible for performing the installation of an update after -the necessary files have been downloaded to a temporary directory. - -It was originally written for use with Mendeley Desktop (see www.mendeley.com) - -The tool consists of a single small binary which performs update installation, -an XML file format describing the contents of an update (an 'update script') -and a tool to create update scripts from a directory containing an installed application. - -To perform an update, the application (or another separate tool) needs to download -the updater binary, an update script and one or more compressed packages -containing the files for the update to a temporary directory. It then needs -to invoke the updater, specifying the location where the application is installed, -the location of the compressed packages and the path to the update script. - -Once the updater has been started, it: - - 1. Waits for the application to exit - 2. Acquires the necessary priviledges to install the updates, prompting - the user if necessary. - 3. Installs the updates, displaying progress to the user in a small dialog - 4. Performs cleanup and any additional actions required as part of the update - 5. Starts the new version of the main application. - - In the event of a failure during the update, the installation is rolled back - to its previous state and a message is presented to the user. - -## Building the Updater - - Create a new directory for the build and from that directory run: - - cmake - make - - The updater binary will be built in the src/ directory. - - You should also run the tests in src/tests to verify that the updater is - functioning correctly. - -## Preparing an Update - - 1. Create a directory containing your application's files, - laid out in the same way and with the same permissions as they would be when installed. - 2. Create a config file specifying how the application's files should be - partitioned into packages - see tools/config-template.json - 3. Use the tools/create-packages.rb script to create a file_list.xml file - and a set of package files required for updates. - 4. Upload the file_list.xml file and packages to a server - - After step 4 is done, you need to notify existing installs that an update - is available. The installed application then needs to download the - relevant packages, file_list.xml file and updater binary to a temporary - directory and invoke the updater. - - See doc/update-hosting for more details on hosting and delivering the updates. - -## Invoking the Updater - - Once the application has downloaded an update, it needs to invoke it. The syntax is: - - updater --install-dir --package-dir --script