Version 6.7.3 #401
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build check | |
on: | |
push: | |
branches: | |
- "**" | |
tags-ignore: | |
- "*" # We don't want this to run on release | |
pull_request: | |
jobs: | |
build-windows: | |
name: Windows | |
runs-on: windows-2022 | |
env: | |
BOOST_ROOT: C:/local/boost_1_83_0 | |
steps: | |
- uses: actions/checkout@master | |
- name: Setup msbuild | |
uses: microsoft/[email protected] | |
- name: Restore Boost | |
uses: actions/cache@v3 | |
id: restore-boost | |
with: | |
path: ${{env.BOOST_ROOT}} | |
key: boost_1_83_0-msvc-14.3-64 | |
- name: Install Boost | |
if: steps.restore-boost.outputs.cache-hit != 'true' | |
shell: powershell | |
run: | | |
$Url = "https://sourceforge.net/projects/boost/files/boost-binaries/1.83.0/boost_1_83_0-msvc-14.3-64.exe" | |
(New-Object System.Net.WebClient).DownloadFile($Url, "$env:TEMP\boost.exe") | |
Start-Process -Wait -FilePath "$env:TEMP\boost.exe" "/SILENT","/SP-","/SUPPRESSMSGBOXES","/DIR=${env:BOOST_ROOT}" | |
- name: Install Qt | |
uses: jurplel/install-qt-action@v3 | |
with: | |
host: "windows" | |
target: "desktop" | |
modules: "qtcharts" | |
install-deps: "true" | |
- name: Clone conceal-core | |
shell: powershell | |
run: | | |
Remove-Item cryptonote -Recurse -Force -ErrorAction Ignore | |
git clone https://github.com/ConcealNetwork/conceal-core.git cryptonote | |
./.github/checkout.bat | |
- name: Pre-build setup | |
shell: powershell | |
run: | | |
$search = "set\(CN_VERSION " | |
$ccx_version = ((Get-Content CryptoNoteWallet.cmake | Select-String $search) | %{$_ -replace $search, ""}) | %{$_ -replace "\)", ""} | |
# Update "CMakeLists.txt" with cmake dir | |
$qt5_cmake = "${{ env.Qt5_Dir }}/lib/cmake" -replace '[\\]', '\\' -replace '[/]', '\\' | |
$file = "CMakeLists.txt" | |
$find = '^set\(CMAKE_PREFIX_PATH.+' | |
$replace = "set(CMAKE_PREFIX_PATH `"$($qt5_cmake)`")" | |
(Get-Content $file) | %{$_ -replace $find, $replace} | Set-Content $file | |
# Update installer/windows/ConcealInstaller.iss with the current version | |
$file = "installer/windows/ConcealInstaller.iss" | |
$find = "^#define AppVersion.+" | |
$replace = "#define AppVersion '$ccx_version'" | |
(Get-Content $file) | %{$_ -replace $find, $replace} | Set-Content $file | |
- name: Build | |
shell: powershell | |
id: build | |
run: | | |
$build_folder = "build" | |
$release_folder = "Release" | |
$sha = "${{ github.sha }}" | |
$ccx_version = $sha.SubString(0,7) | |
$release_name = "ccx-desktop-win64-dev-$ccx_version" | |
lrelease src/languages/cn.ts | |
lrelease src/languages/ru.ts | |
lrelease src/languages/tr.ts | |
New-Item "$build_folder\$release_folder" -ItemType Directory | |
cd "$build_folder" | |
cmake -G "Visual Studio 17 2022" .. | |
msbuild conceal-desktop.sln /p:Configuration=Release /m:2 | |
echo "build_folder=${build_folder}" >> $env:GITHUB_OUTPUT | |
echo "release_folder=${release_folder}" >> $env:GITHUB_OUTPUT | |
echo "release_name=${release_name}" >> $env:GITHUB_OUTPUT | |
- name: Pack | |
shell: powershell | |
id: pack | |
run: | | |
$build_folder = "${{ steps.build.outputs.build_folder }}" | |
$release_name = "${{ steps.build.outputs.release_name }}" | |
$release_folder = "${{ steps.build.outputs.release_folder }}" | |
cd "$build_folder/$release_folder" | |
mkdir "Final" | |
cp "C:\Program Files\OpenSSL\libcrypto*.dll" "Final/" | |
cp "C:\Program Files\OpenSSL\libssl*.dll" "Final/" | |
windeployqt --release conceal-desktop.exe --dir "Final/" --no-translations --no-opengl-sw | |
mv Final ../../installer/windows/build | |
mv conceal-desktop.exe ../../installer/windows/build/ | |
cd ../../installer/windows/ | |
iscc ConcealInstaller.iss | |
cd ../.. | |
mkdir $release_name | |
mv installer/windows/bin/Conceal*.exe $release_name/ | |
- name: Upload To GH Artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{ steps.build.outputs.release_name }} | |
path: ${{ steps.build.outputs.release_name }} | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
build-appimage: | |
name: AppImage | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@master | |
- name: Install dependencies | |
run: | | |
sudo apt-get update -y | |
sudo apt-get install -y qt5-default qttools5-dev qttools5-dev-tools libqt5charts5-dev libboost-all-dev openssl | |
- name: Clone conceal-core | |
run: | | |
rm -rf cryptonote | |
git clone https://github.com/ConcealNetwork/conceal-core.git cryptonote | |
./.github/checkout.sh | |
- name: Build | |
id: build | |
run: | | |
ccx_version=${GITHUB_SHA::7} | |
lrelease src/languages/*.ts | |
make -j2 build-release | |
echo "ccx_version=${ccx_version}" >> $GITHUB_OUTPUT | |
- name: Create AppImage | |
id: appimage | |
run: | | |
ccx_version="${{steps.build.outputs.ccx_version}}" | |
release_name=ccx-desktop-appimage-dev-"$ccx_version" | |
appimage_name=Conceal_Desktop-dev-"$ccx_version"-x86_64.AppImage | |
mkdir $release_name | |
cd appimage | |
./create-appimage.sh | |
mv Conceal_Desktop*.AppImage ../$release_name/$appimage_name | |
cd .. | |
echo "release_name=${release_name}" >> $GITHUB_OUTPUT | |
- name: Upload To GH Artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{ steps.appimage.outputs.release_name }} | |
path: ${{ steps.appimage.outputs.release_name }} | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
build-ubuntu20: | |
name: Ubuntu 20.04 | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@master | |
- name: Install dependencies | |
run: | | |
sudo apt-get update -y | |
sudo apt-get install -y qt5-default qttools5-dev qttools5-dev-tools libqt5charts5-dev libboost-all-dev | |
- name: Clone conceal-core | |
run: | | |
rm -rf cryptonote | |
git clone https://github.com/ConcealNetwork/conceal-core.git cryptonote | |
./.github/checkout.sh | |
- name: Build | |
id: build | |
run: | | |
ccx_version=${GITHUB_SHA::7} | |
release_name=ccx-desktop-ubuntu-2004-dev-"$ccx_version" | |
lrelease src/languages/*.ts | |
make -j2 build-release | |
mkdir $release_name | |
mkdir -p $release_name/icon | |
mv build/release/conceal-desktop $release_name | |
cp conceal-desktop.desktop $release_name | |
cp src/images/conceal.png $release_name/icon | |
echo "release_name=${release_name}" >> $GITHUB_OUTPUT | |
- name: Upload To GH Artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{ steps.build.outputs.release_name }} | |
path: ${{ steps.build.outputs.release_name }} | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
build-ubuntu22: | |
name: Ubuntu 22.04 | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@master | |
- name: Install dependencies | |
run: | | |
sudo apt-get update -y | |
sudo apt-get install -y qtbase5-dev qttools5-dev qttools5-dev-tools libqt5charts5-dev libboost-all-dev | |
- name: Clone conceal-core | |
run: | | |
rm -rf cryptonote | |
git clone https://github.com/ConcealNetwork/conceal-core.git cryptonote | |
./.github/checkout.sh | |
- name: Build | |
id: build | |
run: | | |
ccx_version=${GITHUB_SHA::7} | |
release_name=ccx-desktop-ubuntu-2204-dev-"$ccx_version" | |
lrelease src/languages/*.ts | |
make -j2 build-release | |
mkdir $release_name | |
mkdir -p $release_name/icon | |
mv build/release/conceal-desktop $release_name | |
cp conceal-desktop.desktop $release_name | |
cp src/images/conceal.png $release_name/icon | |
echo "release_name=${release_name}" >> $GITHUB_OUTPUT | |
- name: Upload To GH Artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{ steps.build.outputs.release_name }} | |
path: ${{ steps.build.outputs.release_name }} | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
build-macos: | |
name: macOS | |
runs-on: macos-12 | |
steps: | |
- uses: actions/checkout@master | |
- name: Install dependencies | |
run: | | |
brew install boost qt@5 | |
- name: Clone conceal-core | |
run: | | |
rm -rf cryptonote | |
git clone https://github.com/ConcealNetwork/conceal-core.git cryptonote | |
./.github/checkout.sh | |
- name: Build | |
id: build | |
run: | | |
export PATH="/usr/local/opt/qt@5/bin:$PATH" | |
build_folder="build/release" | |
ccx_version=${GITHUB_SHA::7} | |
release_name="ccx-desktop-macOS-dev-$ccx_version" | |
app_name="conceal-desktop.app" | |
lrelease src/languages/*.ts | |
make -j3 build-release | |
cd "$build_folder" | |
macdeployqt "$app_name" | |
cpack | |
mkdir "$release_name" | |
mv *.dmg "$release_name".dmg | |
mv "$release_name".dmg "$release_name" | |
echo "release_name=${release_name}" >> $GITHUB_OUTPUT | |
echo "artifact_path=${build_folder}/${release_name}" >> $GITHUB_OUTPUT | |
- name: Upload To GH Artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{ steps.build.outputs.release_name }} | |
path: ${{ steps.build.outputs.artifact_path }} | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |