From 92778160416cc19d2067a563fb4a77365286889e Mon Sep 17 00:00:00 2001 From: smk762 Date: Sat, 31 Dec 2022 00:01:42 +0800 Subject: [PATCH 01/20] cache qt --- .github/workflows/atomicdex-desktop-ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index b5589050ec..ebb531d1d7 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -115,6 +115,7 @@ jobs: target: 'desktop' dir: '${{ github.workspace }}' modules: 'qtcharts qtwidgets debug_info qtwebengine qtwebview' + cache: true - name: Install QT (Linux) if: runner.os == 'Linux' @@ -128,6 +129,7 @@ jobs: modules: 'qtcharts qtwidgets debug_info qtwebengine qtwebview' aqtversion: '==0.8' py7zrversion: '==0.6' + cache: true - name: Install QT (Windows) if: runner.os == 'Windows' @@ -139,6 +141,7 @@ jobs: arch: 'win64_msvc2019_64' dir: 'C:\' modules: 'qtcharts qtwidgets debug_info qtwebview qtwebengine' + cache: true - name: Install QT IFW (MacOS) if: runner.os == 'macOS' From 7f55c3771e28694df4e6ecace312d8ea6a97d099 Mon Sep 17 00:00:00 2001 From: smk762 Date: Sun, 1 Jan 2023 19:56:14 +0800 Subject: [PATCH 02/20] cache linux apt --- .github/workflows/atomicdex-desktop-ci.yml | 7 ++++++ .../ci_scripts/linux_script.sh | 25 ------------------- 2 files changed, 7 insertions(+), 25 deletions(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index ebb531d1d7..dbe0dc3b11 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -169,6 +169,13 @@ jobs: export PATH=/home/runner/.nimble/bin:$PATH chmod +x /home/runner/.choosenim/toolchains/nim-1.4.8/bin/* + - name: Install deps (Linux) + uses: awalsh128/cache-apt-pkgs-action@latest + with: + packages: build-essential libgl1-mesa-dev ninja-build curl wget zstd software-properties-common lsb-release libpulse-dev libtool autoconf unzip libssl-dev libxkbcommon-x11-0 libxcb-icccm4 libxcb-image0 libxcb1-dev libxcb-keysyms1-dev libxcb-render-util0-dev libxcb-xinerama0 libgstreamer-plugins-base1.0-dev git + version: 1.0 + execute_install_scripts: true + - name: Install deps (Linux) if: runner.os == 'Linux' run: | diff --git a/ci_tools_atomic_dex/ci_scripts/linux_script.sh b/ci_tools_atomic_dex/ci_scripts/linux_script.sh index c6d84279ab..8f573c03a5 100755 --- a/ci_tools_atomic_dex/ci_scripts/linux_script.sh +++ b/ci_tools_atomic_dex/ci_scripts/linux_script.sh @@ -2,31 +2,6 @@ sudo apt-get update # prevents repo404 errors on apt-remove below sudo apt-get remove php* msodbcsql17 mysql* -sudo apt-get update -sudo ACCEPT_EULA=Y apt-get upgrade -y -# base deps -sudo apt-get install build-essential \ - libgl1-mesa-dev \ - ninja-build \ - curl \ - wget \ - zstd \ - software-properties-common \ - lsb-release \ - libpulse-dev \ - libtool \ - autoconf \ - unzip \ - libssl-dev \ - libxkbcommon-x11-0 \ - libxcb-icccm4 \ - libxcb-image0 \ - libxcb1-dev \ - libxcb-keysyms1-dev \ - libxcb-render-util0-dev \ - libxcb-xinerama0 \ - libgstreamer-plugins-base1.0-dev \ - git -y # get llvm wget https://apt.llvm.org/llvm.sh From 9d1c37b519ad79619de1e3bd35405887dc2e4560 Mon Sep 17 00:00:00 2001 From: smk762 Date: Sun, 1 Jan 2023 20:04:27 +0800 Subject: [PATCH 03/20] try vcpkg v 10 --- .github/workflows/atomicdex-desktop-ci.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index dbe0dc3b11..b981b68c09 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -169,12 +169,11 @@ jobs: export PATH=/home/runner/.nimble/bin:$PATH chmod +x /home/runner/.choosenim/toolchains/nim-1.4.8/bin/* - - name: Install deps (Linux) + - name: Cache apt deps (Linux) uses: awalsh128/cache-apt-pkgs-action@latest with: packages: build-essential libgl1-mesa-dev ninja-build curl wget zstd software-properties-common lsb-release libpulse-dev libtool autoconf unzip libssl-dev libxkbcommon-x11-0 libxcb-icccm4 libxcb-image0 libxcb1-dev libxcb-keysyms1-dev libxcb-render-util0-dev libxcb-xinerama0 libgstreamer-plugins-base1.0-dev git version: 1.0 - execute_install_scripts: true - name: Install deps (Linux) if: runner.os == 'Linux' @@ -201,7 +200,7 @@ jobs: echo "CC=clang-12" >> $GITHUB_ENV - name: vcpkg deps (All) - uses: KomodoPlatform/run-vcpkg@v7 + uses: lukka/run-vcpkg@v10 with: vcpkgDirectory: '${{ github.workspace }}/ci_tools_atomic_dex/vcpkg-repo' setupOnly: true From d0ba24a9a674bd306f96fbed391c990c9ed35ee6 Mon Sep 17 00:00:00 2001 From: smk762 Date: Sun, 1 Jan 2023 20:08:28 +0800 Subject: [PATCH 04/20] apt cache on linux only --- .github/workflows/atomicdex-desktop-ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index b981b68c09..fa68abe5f5 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -170,6 +170,7 @@ jobs: chmod +x /home/runner/.choosenim/toolchains/nim-1.4.8/bin/* - name: Cache apt deps (Linux) + if: runner.os == 'Linux' uses: awalsh128/cache-apt-pkgs-action@latest with: packages: build-essential libgl1-mesa-dev ninja-build curl wget zstd software-properties-common lsb-release libpulse-dev libtool autoconf unzip libssl-dev libxkbcommon-x11-0 libxcb-icccm4 libxcb-image0 libxcb1-dev libxcb-keysyms1-dev libxcb-render-util0-dev libxcb-xinerama0 libgstreamer-plugins-base1.0-dev git From f274afa249164dc3e6541ada45306207d25e2069 Mon Sep 17 00:00:00 2001 From: smk762 Date: Mon, 2 Jan 2023 14:34:25 +0800 Subject: [PATCH 05/20] try latest qt-install-action --- .github/workflows/atomicdex-desktop-ci.yml | 37 +++++++--------------- 1 file changed, 12 insertions(+), 25 deletions(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index fa68abe5f5..2b50bd45fe 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -107,55 +107,42 @@ jobs: - name: Install QT (macOS) if: runner.os == 'macOS' - uses: KomodoPlatform/install-qt-action@v2.14.0 + uses: jurplel/install-qt-action@v3.0.0 with: version: ${{ matrix.qt }} - setup-python: 'false' host: ${{ matrix.host }} - target: 'desktop' dir: '${{ github.workspace }}' + target: 'desktop' modules: 'qtcharts qtwidgets debug_info qtwebengine qtwebview' + tools: 'tools_ifw' + setup-python: 'false' cache: true - name: Install QT (Linux) if: runner.os == 'Linux' - uses: KomodoPlatform/install-qt-action@v2.14.0 + uses: jurplel/install-qt-action@v3.0.0 with: version: ${{ matrix.qt }} - setup-python: 'false' host: ${{ matrix.host }} - target: 'desktop' dir: '${{ github.workspace }}' + target: 'desktop' modules: 'qtcharts qtwidgets debug_info qtwebengine qtwebview' - aqtversion: '==0.8' - py7zrversion: '==0.6' + setup-python: 'false' cache: true - name: Install QT (Windows) if: runner.os == 'Windows' - uses: KomodoPlatform/install-qt-action@v2.14.0 + uses: jurplel/install-qt-action@v3.0.0 with: version: ${{ matrix.qt }} host: ${{ matrix.host }} - target: 'desktop' - arch: 'win64_msvc2019_64' dir: 'C:\' + target: 'desktop' modules: 'qtcharts qtwidgets debug_info qtwebview qtwebengine' + tools: 'tools_ifw' + arch: 'win64_msvc2019_64' cache: true - - name: Install QT IFW (MacOS) - if: runner.os == 'macOS' - run: | - python3 -m aqt tool ${{ matrix.host }} tools_ifw 4.5.1 qt.tools.ifw.45 --outputdir ${{ github.workspace }}/Qt - echo "${{ github.workspace }}/Qt/Tools/QtInstallerFramework/4.5/bin" >> $GITHUB_PATH - - - name: Install QT IFW (Windows) - if: runner.os == 'Windows' - run: | - python -m pip install --upgrade pip - python -m aqt tool ${{ matrix.host }} tools_ifw 4.5.1 qt.tools.ifw.45 --outputdir C:/Qt - echo "C:/Qt/Tools/QtInstallerFramework/4.5/bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append - - name: Install nim (Linux) if: runner.os == 'Linux' run: | @@ -204,8 +191,8 @@ jobs: uses: lukka/run-vcpkg@v10 with: vcpkgDirectory: '${{ github.workspace }}/ci_tools_atomic_dex/vcpkg-repo' - setupOnly: true appendedCacheKey: ${{ hashFiles('vcpkg.json') }} + vcpkgJsonGlob: '**/vcpkg.json' - name: import code signing certificates (macos) From 09306b66da46f86a1c6a698dec83666e897d6649 Mon Sep 17 00:00:00 2001 From: smk762 Date: Mon, 2 Jan 2023 14:43:33 +0800 Subject: [PATCH 06/20] rm qt modules causing fail --- .github/workflows/atomicdex-desktop-ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index 2b50bd45fe..fbca54fb5b 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -113,7 +113,7 @@ jobs: host: ${{ matrix.host }} dir: '${{ github.workspace }}' target: 'desktop' - modules: 'qtcharts qtwidgets debug_info qtwebengine qtwebview' + modules: 'qtcharts debug_info qtwebengine' tools: 'tools_ifw' setup-python: 'false' cache: true @@ -126,7 +126,7 @@ jobs: host: ${{ matrix.host }} dir: '${{ github.workspace }}' target: 'desktop' - modules: 'qtcharts qtwidgets debug_info qtwebengine qtwebview' + modules: 'qtcharts debug_info qtwebengine' setup-python: 'false' cache: true @@ -138,7 +138,7 @@ jobs: host: ${{ matrix.host }} dir: 'C:\' target: 'desktop' - modules: 'qtcharts qtwidgets debug_info qtwebview qtwebengine' + modules: 'qtcharts debug_info qtwebengine' tools: 'tools_ifw' arch: 'win64_msvc2019_64' cache: true From be7c5975e37191c6c1af68a42ca76baeb1fb43a9 Mon Sep 17 00:00:00 2001 From: smk762 Date: Mon, 2 Jan 2023 15:27:14 +0800 Subject: [PATCH 07/20] fix vcpkg cache key --- .github/workflows/atomicdex-desktop-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index fbca54fb5b..23241a65af 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -192,7 +192,7 @@ jobs: with: vcpkgDirectory: '${{ github.workspace }}/ci_tools_atomic_dex/vcpkg-repo' appendedCacheKey: ${{ hashFiles('vcpkg.json') }} - vcpkgJsonGlob: '**/vcpkg.json' + vcpkgJsonGlob: 'vcpkg.json' - name: import code signing certificates (macos) From 1e507891edd6b712b9b607f703b258638547561d Mon Sep 17 00:00:00 2001 From: smk762 Date: Mon, 2 Jan 2023 16:55:12 +0800 Subject: [PATCH 08/20] use latest nim --- .github/workflows/atomicdex-desktop-ci.yml | 6 +++--- ci_tools_atomic_dex/ci_scripts/osx_script.sh | 10 ++-------- 2 files changed, 5 insertions(+), 11 deletions(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index 23241a65af..a6d2812324 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -148,13 +148,13 @@ jobs: run: | export DEBIAN_FRONTEND=noninteractive export SHELL=/bin/bash - echo "CHOOSENIM_CHOOSE_VERSION=1.4.8" >> $GITHUB_ENV - export CHOOSENIM_CHOOSE_VERSION=1.4.8 + echo "CHOOSENIM_CHOOSE_VERSION=1.6.10" >> $GITHUB_ENV + export CHOOSENIM_CHOOSE_VERSION=1.6.10 curl https://nim-lang.org/choosenim/init.sh > choosenim.sh chmod +x choosenim.sh ./choosenim.sh -y export PATH=/home/runner/.nimble/bin:$PATH - chmod +x /home/runner/.choosenim/toolchains/nim-1.4.8/bin/* + chmod +x /home/runner/.choosenim/toolchains/nim-1.6.10/bin/* - name: Cache apt deps (Linux) if: runner.os == 'Linux' diff --git a/ci_tools_atomic_dex/ci_scripts/osx_script.sh b/ci_tools_atomic_dex/ci_scripts/osx_script.sh index 3eb78b7d6f..68579c15b3 100755 --- a/ci_tools_atomic_dex/ci_scripts/osx_script.sh +++ b/ci_tools_atomic_dex/ci_scripts/osx_script.sh @@ -2,18 +2,12 @@ brew update -brew tap-new $USER/local-nim -brew extract --version=1.4.8 nim $USER/local-nim - -brew unlink libtool -wget https://raw.githubusercontent.com/Homebrew/homebrew-core/0fbd6e24c4122e18ade1ec6c5916cb21de14f352/Formula/libtool.rb -brew install libtool.rb - brew install autoconf \ automake \ pkgconfig \ + libtool \ wget \ - nim@1.4.8 \ + nim@1.6.10 \ ninja \ gnu-sed \ coreutils \ From 7aab286eaef4985a481864a0869c1ce50bf555ce Mon Sep 17 00:00:00 2001 From: smk762 Date: Mon, 2 Jan 2023 17:09:21 +0800 Subject: [PATCH 09/20] try latest nim --- ci_tools_atomic_dex/ci_scripts/osx_script.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci_tools_atomic_dex/ci_scripts/osx_script.sh b/ci_tools_atomic_dex/ci_scripts/osx_script.sh index 68579c15b3..4f35015c62 100755 --- a/ci_tools_atomic_dex/ci_scripts/osx_script.sh +++ b/ci_tools_atomic_dex/ci_scripts/osx_script.sh @@ -7,7 +7,7 @@ brew install autoconf \ pkgconfig \ libtool \ wget \ - nim@1.6.10 \ + nim \ ninja \ gnu-sed \ coreutils \ From c8ca2456b15d8f0219df73ac0ff44058406a3b8c Mon Sep 17 00:00:00 2001 From: smk762 Date: Mon, 2 Jan 2023 17:53:45 +0800 Subject: [PATCH 10/20] update deprecated nim funcs, find sdk path --- .github/workflows/atomicdex-desktop-ci.yml | 1 + ci_tools_atomic_dex/src/clean.nim | 6 +++--- ci_tools_atomic_dex/src/generate.nim | 2 +- ci_tools_atomic_dex/src/vcpkg.nim | 4 ++-- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index a6d2812324..eb7dd2c7e2 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -219,6 +219,7 @@ jobs: - name: Build AtomicDEX (MacOS) if: runner.os == 'macOS' run: | + xcrun --sdk macosx --show-sdk-path export MAC_SIGN_IDENTITY="${{ secrets.MAC_SIGN_IDENTITY }}" export INSTALLER_MAC_SIGN_IDENTITY="${{ secrets.INSTALLER_MAC_SIGN_IDENTITY }}" export APPLE_ATOMICDEX_PASSWORD="${{ secrets.APPLE_ATOMICDEX_PASSWORD }}" diff --git a/ci_tools_atomic_dex/src/clean.nim b/ci_tools_atomic_dex/src/clean.nim index a84a1ad28d..888368a376 100644 --- a/ci_tools_atomic_dex/src/clean.nim +++ b/ci_tools_atomic_dex/src/clean.nim @@ -1,13 +1,13 @@ import os proc remove_vcpkg()= - if os.existsDir("vcpkg-repo"): + if os.dirExists("vcpkg-repo"): os.removeDir("vcpkg-repo") proc remove_build()= - if os.existsDir("build-Debug"): + if os.dirExists("build-Debug"): os.removeDir("build-Debug") - if os.existsDir("build-Release"): + if os.dirExists("build-Release"): os.removeDir("build-Release") proc clean*(clean_type: string) = diff --git a/ci_tools_atomic_dex/src/generate.nim b/ci_tools_atomic_dex/src/generate.nim index d2462a201f..5e2f9cbeea 100644 --- a/ci_tools_atomic_dex/src/generate.nim +++ b/ci_tools_atomic_dex/src/generate.nim @@ -6,7 +6,7 @@ import dependencies proc generate_solution*(build_type: string, osx_sdk_path: string, compiler_path: string) = download_packages() var full_name = "build-" & build_type - if not os.existsDir(os.getCurrentDir().joinPath(full_name)): + if not os.dirExists(os.getCurrentDir().joinPath(full_name)): echo "creating directory: " & full_name os.createDir(full_name) else: diff --git a/ci_tools_atomic_dex/src/vcpkg.nim b/ci_tools_atomic_dex/src/vcpkg.nim index c679f29a8e..fca94fc080 100644 --- a/ci_tools_atomic_dex/src/vcpkg.nim +++ b/ci_tools_atomic_dex/src/vcpkg.nim @@ -5,10 +5,10 @@ var g_vcpkg_local_path* = "" var g_vcpkg_cmake_script_path* = "" proc check_if_vcpkg_exists*(): bool = - result = os.existsDir("vcpkg-repo") + result = os.dirExists("vcpkg-repo") proc build_vcpkg() = - if not os.existsFile(g_vcpkg_local_path): + if not os.fileExists(g_vcpkg_local_path): echo "building vcpkg" os.setCurrentDir("vcpkg-repo") when defined(windows): From 14dfaea47b339032ce23d58b3fb7c3f62d597ed4 Mon Sep 17 00:00:00 2001 From: smk762 Date: Mon, 2 Jan 2023 18:14:19 +0800 Subject: [PATCH 11/20] try new sdk path --- .github/workflows/atomicdex-desktop-ci.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index eb7dd2c7e2..da3e0f3e31 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -220,6 +220,9 @@ jobs: if: runner.os == 'macOS' run: | xcrun --sdk macosx --show-sdk-path + export SDK_PATH=$(xcrun --sdk macosx --show-sdk-path) + ls /Applications/Xcode_13.2.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs + ls $HOME/sdk export MAC_SIGN_IDENTITY="${{ secrets.MAC_SIGN_IDENTITY }}" export INSTALLER_MAC_SIGN_IDENTITY="${{ secrets.INSTALLER_MAC_SIGN_IDENTITY }}" export APPLE_ATOMICDEX_PASSWORD="${{ secrets.APPLE_ATOMICDEX_PASSWORD }}" @@ -232,7 +235,7 @@ jobs: export CXX=clang++ cd ci_tools_atomic_dex nimble build -y - ./ci_tools_atomic_dex bundle ${{ matrix.type }} --osx_sdk=$HOME/sdk/MacOSX10.15.sdk --compiler=clang++ + ./ci_tools_atomic_dex bundle ${{ matrix.type }} --osx_sdk=$HOME/sdk/$SDK_PATH --compiler=clang++ - name: Build AtomicDEX (Linux) From 31f61f62f170def5c16a066cc2f0ae3783bb9109 Mon Sep 17 00:00:00 2001 From: smk762 Date: Mon, 2 Jan 2023 18:33:00 +0800 Subject: [PATCH 12/20] test path --- .github/workflows/atomicdex-desktop-ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index da3e0f3e31..b1b9716fae 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -222,6 +222,7 @@ jobs: xcrun --sdk macosx --show-sdk-path export SDK_PATH=$(xcrun --sdk macosx --show-sdk-path) ls /Applications/Xcode_13.2.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs + echo $HOME/sdk ls $HOME/sdk export MAC_SIGN_IDENTITY="${{ secrets.MAC_SIGN_IDENTITY }}" export INSTALLER_MAC_SIGN_IDENTITY="${{ secrets.INSTALLER_MAC_SIGN_IDENTITY }}" @@ -235,7 +236,8 @@ jobs: export CXX=clang++ cd ci_tools_atomic_dex nimble build -y - ./ci_tools_atomic_dex bundle ${{ matrix.type }} --osx_sdk=$HOME/sdk/$SDK_PATH --compiler=clang++ + ./ci_tools_atomic_dex bundle ${{ matrix.type }} --osx_sdk=$HOME/sdk/MacOSX10.15.sdk --compiler=clang++ + - name: Build AtomicDEX (Linux) From be16f341396b6817c89d4e5917c85b186bc2c024 Mon Sep 17 00:00:00 2001 From: smk762 Date: Mon, 2 Jan 2023 19:00:43 +0800 Subject: [PATCH 13/20] use upstream libwally --- .github/workflows/atomicdex-desktop-ci.yml | 4 ++-- ci_tools_atomic_dex/ci_scripts/linux_script.sh | 2 +- ci_tools_atomic_dex/ci_scripts/osx_script.sh | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index b1b9716fae..4270a4defd 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -92,7 +92,7 @@ jobs: if: runner.os == 'Windows' run: | cd '${{ github.workspace }}' - git clone -b v0.8.5 --recurse-submodules https://github.com/KomodoPlatform/libwally-core.git + git clone -b master --recurse-submodules https://github.com/ElementsProject/libwally-core.git cd '${{ github.workspace }}\libwally-core' git submodule init git submodule sync --recursive @@ -237,7 +237,7 @@ jobs: cd ci_tools_atomic_dex nimble build -y ./ci_tools_atomic_dex bundle ${{ matrix.type }} --osx_sdk=$HOME/sdk/MacOSX10.15.sdk --compiler=clang++ - + - name: Build AtomicDEX (Linux) diff --git a/ci_tools_atomic_dex/ci_scripts/linux_script.sh b/ci_tools_atomic_dex/ci_scripts/linux_script.sh index 8f573c03a5..c882f0e0c4 100755 --- a/ci_tools_atomic_dex/ci_scripts/linux_script.sh +++ b/ci_tools_atomic_dex/ci_scripts/linux_script.sh @@ -29,7 +29,7 @@ sudo cp -r * /usr/local/ cmake --version # get libwally -git clone https://github.com/KomodoPlatform/libwally-core.git +git clone https://github.com/ElementsProject/libwally-core.git cd libwally-core ./tools/autogen.sh ./configure --disable-shared diff --git a/ci_tools_atomic_dex/ci_scripts/osx_script.sh b/ci_tools_atomic_dex/ci_scripts/osx_script.sh index 4f35015c62..c2b39e1717 100755 --- a/ci_tools_atomic_dex/ci_scripts/osx_script.sh +++ b/ci_tools_atomic_dex/ci_scripts/osx_script.sh @@ -28,7 +28,7 @@ export MACOSX_DEPLOYMENT_TARGET=10.15 #make -j3 install #cd ../ -git clone https://github.com/KomodoPlatform/libwally-core.git +git clone https://github.com/ElementsProject/libwally-core.git cd libwally-core ./tools/autogen.sh ./configure --disable-shared From 0547d23f148c26ba8475b29c8cdd79ff0da647ea Mon Sep 17 00:00:00 2001 From: smk762 Date: Mon, 2 Jan 2023 19:06:27 +0800 Subject: [PATCH 14/20] use old libwally & new nim --- .github/workflows/atomicdex-desktop-ci.yml | 4 ++-- ci_tools_atomic_dex/ci_scripts/linux_script.sh | 2 +- ci_tools_atomic_dex/ci_scripts/osx_script.sh | 7 +++++-- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index 4270a4defd..b1b9716fae 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -92,7 +92,7 @@ jobs: if: runner.os == 'Windows' run: | cd '${{ github.workspace }}' - git clone -b master --recurse-submodules https://github.com/ElementsProject/libwally-core.git + git clone -b v0.8.5 --recurse-submodules https://github.com/KomodoPlatform/libwally-core.git cd '${{ github.workspace }}\libwally-core' git submodule init git submodule sync --recursive @@ -237,7 +237,7 @@ jobs: cd ci_tools_atomic_dex nimble build -y ./ci_tools_atomic_dex bundle ${{ matrix.type }} --osx_sdk=$HOME/sdk/MacOSX10.15.sdk --compiler=clang++ - + - name: Build AtomicDEX (Linux) diff --git a/ci_tools_atomic_dex/ci_scripts/linux_script.sh b/ci_tools_atomic_dex/ci_scripts/linux_script.sh index c882f0e0c4..8f573c03a5 100755 --- a/ci_tools_atomic_dex/ci_scripts/linux_script.sh +++ b/ci_tools_atomic_dex/ci_scripts/linux_script.sh @@ -29,7 +29,7 @@ sudo cp -r * /usr/local/ cmake --version # get libwally -git clone https://github.com/ElementsProject/libwally-core.git +git clone https://github.com/KomodoPlatform/libwally-core.git cd libwally-core ./tools/autogen.sh ./configure --disable-shared diff --git a/ci_tools_atomic_dex/ci_scripts/osx_script.sh b/ci_tools_atomic_dex/ci_scripts/osx_script.sh index c2b39e1717..949442963e 100755 --- a/ci_tools_atomic_dex/ci_scripts/osx_script.sh +++ b/ci_tools_atomic_dex/ci_scripts/osx_script.sh @@ -2,10 +2,13 @@ brew update +brew unlink libtool +wget https://raw.githubusercontent.com/Homebrew/homebrew-core/0fbd6e24c4122e18ade1ec6c5916cb21de14f352/Formula/libtool.rb +brew install libtool.rb + brew install autoconf \ automake \ pkgconfig \ - libtool \ wget \ nim \ ninja \ @@ -28,7 +31,7 @@ export MACOSX_DEPLOYMENT_TARGET=10.15 #make -j3 install #cd ../ -git clone https://github.com/ElementsProject/libwally-core.git +git clone https://github.com/KomodoPlatform/libwally-core.git cd libwally-core ./tools/autogen.sh ./configure --disable-shared From f24a92d21702e74dba6a751190aeb49d01933135 Mon Sep 17 00:00:00 2001 From: smk762 Date: Mon, 2 Jan 2023 19:27:21 +0800 Subject: [PATCH 15/20] nim path check --- ci_tools_atomic_dex/src/generate.nim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci_tools_atomic_dex/src/generate.nim b/ci_tools_atomic_dex/src/generate.nim index 5e2f9cbeea..d53b6a1ff8 100644 --- a/ci_tools_atomic_dex/src/generate.nim +++ b/ci_tools_atomic_dex/src/generate.nim @@ -16,7 +16,7 @@ proc generate_solution*(build_type: string, osx_sdk_path: string, compiler_path: var cmd_line = "cmake -GNinja -DCMAKE_BUILD_TYPE=" & build_type & " " & os.getCurrentDir().parentDir().parentDir() when defined(osx): - if not osx_sdk_path.isNil() and osx_sdk_path != "nil": + if os.dirExists(osx_sdk_path): cmd_line = cmd_line & " -DCMAKE_OSX_SYSROOT=" & osx_sdk_path & " -DCMAKE_OSX_DEPLOYMENT_TARGET=10.15" echo "cmd line: " & cmd_line discard execCmd(cmd_line) From 159af122cb4ad2fd8a9f10999c0c8eb368830ce9 Mon Sep 17 00:00:00 2001 From: smk762 Date: Mon, 2 Jan 2023 21:43:59 +0800 Subject: [PATCH 16/20] update actions/checkout and actions/upload-artifact --- .github/workflows/atomicdex-desktop-ci.yml | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index b1b9716fae..9afd6ed513 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -74,7 +74,7 @@ jobs: host: 'windows' steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 with: ref: ${{ github.event.pull_request.head.sha }} submodules: 'true' @@ -237,7 +237,7 @@ jobs: cd ci_tools_atomic_dex nimble build -y ./ci_tools_atomic_dex bundle ${{ matrix.type }} --osx_sdk=$HOME/sdk/MacOSX10.15.sdk --compiler=clang++ - + - name: Build AtomicDEX (Linux) @@ -279,7 +279,7 @@ jobs: - name: Upload bundle artifact (Linux ZSTD) if: runner.os == 'Linux' - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v3 with: name: ${{ env.artifact_name_zstd }} path: ./bundled/linux/${{ env.target_name_zstd }} @@ -287,7 +287,7 @@ jobs: - name: Upload bundle artifact (Linux ZIP) if: runner.os == 'Linux' - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v3 with: name: ${{ env.artifact_name_zip }} path: ./bundled/linux/${{ env.target_name_zip }} @@ -295,7 +295,7 @@ jobs: - name: Upload bundle artifact (Linux AppImage) if: runner.os == 'Linux' - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v3 with: name: ${{ env.artifact_name_appimage }} path: ./bundled/linux/${{ env.target_name_appimage }} @@ -309,7 +309,7 @@ jobs: - name: Upload artifacts (MacOS dmg) if: runner.os == 'macOS' - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v3 with: name: ${{ env.artifact_name_dmg }} path: ./bundled/osx/${{ env.DEX_PROJECT_NAME }}.dmg @@ -317,7 +317,7 @@ jobs: - name: Upload artifacts (MacOS installer) if: runner.os == 'macOS' - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v3 with: name: ${{ env.artifact_name_installer }} path: ./bundled/osx/${{ env.DEX_PROJECT_NAME }}_installer.7z @@ -332,7 +332,7 @@ jobs: - name: Upload artifacts (Windows zip) if: runner.os == 'Windows' - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v3 with: name: ${{ env.artifact_name_zip }} path: ./bundled/windows/bin.zip @@ -340,7 +340,7 @@ jobs: - name: Upload artifacts (Windows installer) if: runner.os == 'Windows' - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v3 with: name: ${{ env.artifact_name_installer }} path: ./bundled/windows/${{ env.DEX_PROJECT_NAME }}_installer.exe From d38e41bcbc32b88965fc5f526d00d3c0a21d5f01 Mon Sep 17 00:00:00 2001 From: smk762 Date: Mon, 2 Jan 2023 21:47:14 +0800 Subject: [PATCH 17/20] update action msvc-dev-cmd --- .github/workflows/atomicdex-desktop-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index 9afd6ed513..2b52ec2db2 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -86,7 +86,7 @@ jobs: - name: Install MSVC if: runner.os == 'Windows' - uses: ilammy/msvc-dev-cmd@v1.4.1 + uses: ilammy/msvc-dev-cmd@v1.12.0 - name: Build libwally (Windows) if: runner.os == 'Windows' From 0cafe5084f1113b8d33c370873af8a353d5489c6 Mon Sep 17 00:00:00 2001 From: smk762 Date: Tue, 3 Jan 2023 17:03:28 +0800 Subject: [PATCH 18/20] update setup-python action to v4 --- .github/workflows/atomicdex-desktop-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index 2b52ec2db2..a814d3936b 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -80,7 +80,7 @@ jobs: submodules: 'true' - name: Setup Python - uses: actions/setup-python@v3 + uses: actions/setup-python@v4 with: python-version: '3.9' From 8d0d26884be92cf625d2ab070d1c6555ea2d1bfd Mon Sep 17 00:00:00 2001 From: smk762 Date: Tue, 3 Jan 2023 17:11:45 +0800 Subject: [PATCH 19/20] update cache-apt-pkgs-action to v1.2.2 --- .github/workflows/atomicdex-desktop-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index a814d3936b..3980325e1c 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -161,7 +161,7 @@ jobs: uses: awalsh128/cache-apt-pkgs-action@latest with: packages: build-essential libgl1-mesa-dev ninja-build curl wget zstd software-properties-common lsb-release libpulse-dev libtool autoconf unzip libssl-dev libxkbcommon-x11-0 libxcb-icccm4 libxcb-image0 libxcb1-dev libxcb-keysyms1-dev libxcb-render-util0-dev libxcb-xinerama0 libgstreamer-plugins-base1.0-dev git - version: 1.0 + version: 1.2.2 - name: Install deps (Linux) if: runner.os == 'Linux' From 2c8a4f991bfce16d34fd28ce6d6b1c0234ec642f Mon Sep 17 00:00:00 2001 From: smk762 Date: Tue, 3 Jan 2023 17:58:25 +0800 Subject: [PATCH 20/20] rm failing apt-cache action, restore apt section to linux script --- .github/workflows/atomicdex-desktop-ci.yml | 7 ------ .../ci_scripts/linux_script.sh | 25 +++++++++++++++++++ 2 files changed, 25 insertions(+), 7 deletions(-) diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index 3980325e1c..f1dc595d33 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -156,13 +156,6 @@ jobs: export PATH=/home/runner/.nimble/bin:$PATH chmod +x /home/runner/.choosenim/toolchains/nim-1.6.10/bin/* - - name: Cache apt deps (Linux) - if: runner.os == 'Linux' - uses: awalsh128/cache-apt-pkgs-action@latest - with: - packages: build-essential libgl1-mesa-dev ninja-build curl wget zstd software-properties-common lsb-release libpulse-dev libtool autoconf unzip libssl-dev libxkbcommon-x11-0 libxcb-icccm4 libxcb-image0 libxcb1-dev libxcb-keysyms1-dev libxcb-render-util0-dev libxcb-xinerama0 libgstreamer-plugins-base1.0-dev git - version: 1.2.2 - - name: Install deps (Linux) if: runner.os == 'Linux' run: | diff --git a/ci_tools_atomic_dex/ci_scripts/linux_script.sh b/ci_tools_atomic_dex/ci_scripts/linux_script.sh index 8f573c03a5..c6d84279ab 100755 --- a/ci_tools_atomic_dex/ci_scripts/linux_script.sh +++ b/ci_tools_atomic_dex/ci_scripts/linux_script.sh @@ -2,6 +2,31 @@ sudo apt-get update # prevents repo404 errors on apt-remove below sudo apt-get remove php* msodbcsql17 mysql* +sudo apt-get update +sudo ACCEPT_EULA=Y apt-get upgrade -y +# base deps +sudo apt-get install build-essential \ + libgl1-mesa-dev \ + ninja-build \ + curl \ + wget \ + zstd \ + software-properties-common \ + lsb-release \ + libpulse-dev \ + libtool \ + autoconf \ + unzip \ + libssl-dev \ + libxkbcommon-x11-0 \ + libxcb-icccm4 \ + libxcb-image0 \ + libxcb1-dev \ + libxcb-keysyms1-dev \ + libxcb-render-util0-dev \ + libxcb-xinerama0 \ + libgstreamer-plugins-base1.0-dev \ + git -y # get llvm wget https://apt.llvm.org/llvm.sh