diff --git a/.azure.yml b/.azure.yml index 837563e3..c0ae0d4f 100644 --- a/.azure.yml +++ b/.azure.yml @@ -85,8 +85,8 @@ jobs: - script: | cd $(Build.SourcesDirectory) python -m pip install aqtinstall - python -m aqt install -O c:\Qt 5.14.0 windows desktop win64_msvc2017_64 - displayName: 'Install Qt 5.14.0' + python -m aqt install -O c:\Qt 5.15.0 windows desktop win64_msvc2019_64 + displayName: 'Install Qt 5.15.0' # build process - bash: ./.ci/ci_build.sh env: diff --git a/.editorconfig b/.editorconfig index c0384a55..f62c1558 100644 --- a/.editorconfig +++ b/.editorconfig @@ -18,4 +18,8 @@ indent_size = 4 # js and webui [*.{ts,js,html}] indent_style = space -indent_size = 2 \ No newline at end of file +indent_size = 2 + +# version file +[version] +insert_final_newline = false diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index 3cf3ebcd..28d3bc7e 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -137,9 +137,9 @@ jobs: - name: Install Qt uses: jurplel/install-qt-action@v2 with: - version: '5.14.1' + version: '5.15.0' target: 'desktop' - arch: 'win64_msvc2017_64' + arch: 'win64_msvc2019_64' - name: Install Python uses: actions/setup-python@v1 diff --git a/.github/workflows/push-master.yml b/.github/workflows/push-master.yml index 579e8d91..91c54e8b 100644 --- a/.github/workflows/push-master.yml +++ b/.github/workflows/push-master.yml @@ -101,9 +101,9 @@ jobs: - name: Install Qt uses: jurplel/install-qt-action@v2 with: - version: '5.14.1' + version: '5.15.0' target: 'desktop' - arch: 'win64_msvc2017_64' + arch: 'win64_msvc2019_64' - name: Install Python uses: actions/setup-python@v1 diff --git a/.vscode/c_cpp_properties.json b/.vscode/c_cpp_properties.json index 506560e5..d25bb8d3 100644 --- a/.vscode/c_cpp_properties.json +++ b/.vscode/c_cpp_properties.json @@ -17,7 +17,7 @@ "name": "Win32", "includePath": [ "${workspaceFolder}/**", - "G:/Programme/Qt/5.14.1/msvc2017_64/include/**" + "C:/Qt/5.15.0/msvc2019_64/include/**" ], "defines": [ "_DEBUG", diff --git a/.vscode/hyperion.code-workspace b/.vscode/hyperion.code-workspace index 55ecea61..a86bfc59 100644 --- a/.vscode/hyperion.code-workspace +++ b/.vscode/hyperion.code-workspace @@ -7,8 +7,6 @@ "settings": { "editor.formatOnSave": false, "cmake.environment": { - "Qt5_DIR":"G:/Programme/Qt/5.14.1/msvc2017_64/lib/cmake/Qt5", - "CMAKE_PREFIX_PATH": "G:/Programme/Qt/5.14.1/msvc2017_64" }, }, "extensions": { diff --git a/.vscode/launch.json b/.vscode/launch.json index 909e3c07..90c1d1b3 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -27,7 +27,7 @@ "name": "(Windows) hyperiond", "type": "cppvsdbg", "request": "launch", - "program": "${workspaceFolder}/build/bin/hyperiond.exe", + "program": "${workspaceFolder}/build/bin/Debug/hyperiond.exe", "args": [], "stopAtEntry": false, "cwd": "${workspaceFolder}", diff --git a/CMakeLists.txt b/CMakeLists.txt index c96ade6f..292fe8ff 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -95,7 +95,7 @@ MACRO(FIRSTSUBDIR result curdir) FOREACH(child ${children}) IF(IS_DIRECTORY ${curdir}/${child}) LIST(APPEND dirlist "${curdir}/${child}") - #BREAK() + BREAK() ENDIF() ENDFOREACH() SET(${result} ${dirlist}) @@ -283,10 +283,10 @@ if (CMAKE_CXX_COMPILER_ID MATCHES "MSVC") # The Qt5_DIR should point to Qt5Config.cmake -> C:/Qt/5.xx/msvc2017_64/lib/cmake/Qt5 # The CMAKE_PREFIX_PATH should point to the install directory -> C:/Qt/5.xx/msvc2017_64 FIRSTSUBDIR(SUBDIRQT "C:/Qt") - SET(CMAKE_PREFIX_PATH ${CMAKE_PREFIX_PATH} "${SUBDIRQT}/msvc2017_64") + SET(CMAKE_PREFIX_PATH ${CMAKE_PREFIX_PATH} "${SUBDIRQT}/msvc2019_64") if (NOT DEFINED ENV{Qt5_DIR}) - message(STATUS "Set Qt5_DIR to default install path C:/Qt") - SET(Qt5_DIR "${SUBDIRQT}/msvc2017_64/lib/cmake/Qt5") + message(STATUS "Set Qt5 module path: ${SUBDIRQT}") + SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${SUBDIRQT}/msvc2019_64/lib/cmake/Qt5") endif() endif() diff --git a/CompileHowto.md b/CompileHowto.md index 34ba37ec..59518043 100644 --- a/CompileHowto.md +++ b/CompileHowto.md @@ -78,18 +78,18 @@ brew install doxygen We assume a 64bit Windows 7 or higher. Install the following - [Git](https://git-scm.com/downloads) (Check: Add to PATH) - [Python 3 (Windows x86-64 executable installer)](https://www.python.org/downloads/windows/) (Check: Add to PATH and Debug Symbols) + - Open a console window and execute `pip install aqtinstall`. + - Now we can download Qt to _C:\Qt_ `mkdir c:\Qt && aqt install -O c:\Qt 5.15.0 windows desktop win64_msvc2019_64` - [CMake (Windows win64-x64 Installer)](https://cmake.org/download/) (Check: Add to PATH) -- [Qt5](https://www.qt.io/download-open-source) (Check: Component install: msvc 2017 64bit). No configuration for PATH is set, we assume the default install path. -- [Visual Studio 2019 Build Tools](https://go.microsoft.com/fwlink/?linkid=840931) - - The Visual Studio 2019 Community Editor is not required but will be installed as part of the compiler and Windows SDK - - Select C++ Desktop Development Tools - - Now just select `MSVC v142 VS 2019 C++ x64/x86-Buildtools`, `C++-CMake Tools for Windows` and `Windows 10 SDK`. Everything else is not needed. +- [Visual Studio 2019 Build Tools](https://go.microsoft.com/fwlink/?linkid=840931) ([direct link](https://aka.ms/vs/16/release/vs_buildtools.exe)) + - Select C++ Buildtools + - On the right, just select `MSVC v142 VS 2019 C++ x64/x86-Buildtools` and latest `Windows 10 SDK`. Everything else is not needed. # Compiling and installing Hyperion ### The general quick way (without big comments) -complete automated process: +complete automated process for Mac/Linux: ```bash wget -qO- https://raw.githubusercontent.com/hyperion-project/hyperion.ng/master/bin/compile.sh | sh ``` @@ -161,7 +161,10 @@ cmake -DPLATFORM=osx -DCMAKE_BUILD_TYPE=Release .. To generate files on Windows (Release+Debug capable): Platform should be auto detected and refer to windows, you can also force windows: -``` + +```sh +# You might need to setup MSVC env first +call "C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Auxiliary\Build\vcvars64.bat" cmake -DPLATFORM=windows -G "Windows 16 2019" .. ``` @@ -181,6 +184,7 @@ On Windows run ```bash cmake --build . --config Release -- -maxcpucount ``` +Maintainer: To build installer, install [NSIS](https://nsis.sourceforge.io/Main_Page) and set env `VCINSTALLDIR="C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC"` ### Install hyperion into your system