From 87d2ce8a7ef4100be5097f34624643c9884e3639 Mon Sep 17 00:00:00 2001 From: n8tb1t Date: Wed, 30 Oct 2019 20:39:55 +0500 Subject: [PATCH 1/3] fix: fix config + ci --- .github/workflows/matrix.yml | 22 +++++++++++----------- src/CMakeLists.txt | 4 ++-- src/config/CryptoNoteConfig.h | 26 +++++++++++++++++++++++--- 3 files changed, 36 insertions(+), 16 deletions(-) diff --git a/.github/workflows/matrix.yml b/.github/workflows/matrix.yml index ae424e5c..558ed611 100644 --- a/.github/workflows/matrix.yml +++ b/.github/workflows/matrix.yml @@ -31,7 +31,7 @@ jobs: run: | sudo apt update sudo apt install -y libboost-all-dev libssl-dev ${{ matrix.package_name }} - + # Configure the project with cmake - name: Configure if: matrix.build_name != 'aarch64' @@ -41,7 +41,7 @@ jobs: run: | mkdir build && cd build cmake -DARCH=default -DCMAKE_BUILD_TYPE=Release -DSTATIC=true .. - + # Build for linux - name: Build if: matrix.build_name != 'aarch64' @@ -59,7 +59,7 @@ jobs: mkdir build && cd build cmake -DARCH=default -DCMAKE_BUILD_TYPE=Release -DSTATIC=true .. make -j2 - + # Test the crypto - name: Test Crypto if: matrix.build_name != 'aarch64' @@ -76,26 +76,26 @@ jobs: CXX: /usr/local/opt/llvm@8/bin/clang++ steps: - uses: actions/checkout@v1 - + # Fetch Dependencies - name: Dependencies run: | brew install --force boost llvm@8 brew link --force llvm@8 ln -s /usr/local/opt/llvm@8 /usr/local/opt/llvm - + # Configure project with cmake - name: Configure run: | mkdir build && cd build cmake -DARCH=default -DCMAKE_BUILD_TYPE=Release -DSTATIC=true .. - + # Build for macOS - name: Build run: | cd build make -j2 - + # Test the crypto - name: Test Crypto run: | @@ -110,7 +110,7 @@ jobs: MSBUILD_PATH: "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/MSBuild/Current/Bin" steps: - uses: actions/checkout@v1 - + - name: Setup MSBuild.exe uses: warrenbuckley/Setup-MSBuild@v1 @@ -120,13 +120,13 @@ jobs: mkdir build cd build cmake -G "Visual Studio 16 2019" -A x64 .. -DARCH=default - + # Build for Windows - name: Build run: | cd build - MSBuild TurtleCoin.sln /p:Configuration=Release /m - + MSBuild Catalyst.sln /p:Configuration=Release /m + # Test the crypto - name: Test Crypto shell: bash diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 39a0d0e2..413efebc 100755 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -200,7 +200,7 @@ set_property(TARGET WalletApi PROPERTY OUTPUT_NAME "wallet-api") set_property(TARGET WalletUpgrader PROPERTY OUTPUT_NAME "wallet-upgrader") # Additional make targets, can be used to build a subset of the targets -# e.g. make pool will build only TurtleCoind and service -add_custom_target(pool DEPENDS Catalystd service) +# e.g. make pool will build only Catalystd and service +add_custom_target(pool DEPENDS Catalystd WalletService) add_custom_target(solominer DEPENDS Catalystd zedwallet miner) add_custom_target(cli DEPENDS Catalystd zedwallet) diff --git a/src/config/CryptoNoteConfig.h b/src/config/CryptoNoteConfig.h index 923c6028..9ece7917 100644 --- a/src/config/CryptoNoteConfig.h +++ b/src/config/CryptoNoteConfig.h @@ -82,13 +82,13 @@ namespace CryptoNote const uint64_t MINIMUM_MIXIN_V2 = 3; const uint64_t MAXIMUM_MIXIN_V2 = 5; - const uint64_t MINIMUM_MIXIN_V3 = 3; - const uint64_t MAXIMUM_MIXIN_V3 = 5; + const uint64_t MINIMUM_MIXIN_V3 = 3; + const uint64_t MAXIMUM_MIXIN_V3 = 5; /* The heights to activate the mixin limits at */ const uint32_t MIXIN_LIMITS_V1_HEIGHT = 0; const uint32_t MIXIN_LIMITS_V2_HEIGHT = 1; - const uint32_t MIXIN_LIMITS_V3_HEIGHT = 770000; + const uint32_t MIXIN_LIMITS_V3_HEIGHT = 770000; /* The mixin to use by default with zedwallet and turtle-service */ /* DEFAULT_MIXIN_V0 is the mixin used before MIXIN_LIMITS_V1_HEIGHT is started */ @@ -125,6 +125,26 @@ namespace CryptoNote const uint64_t MAX_EXTRA_SIZE_V2 = 1024; const uint64_t MAX_EXTRA_SIZE_V2_HEIGHT = 170000; + + /* 25 trillion atomic, or 2 million TRTL -> Max supply / mixin+1 outputs */ + + /* This is enforced on the daemon side. An output > 250 billion causes + * an invalid block. */ + + /* IDK 2 million for example*/ + const uint64_t MAX_OUTPUT_SIZE_NODE = 2'000'000'00; + + /* 100 billion atomic, or 1 billion TRTL */ + /* This is enforced on the client side. An output > 1 billion will not + * be created in a transaction */ + + /* IDK 1 million for example*/ + const uint64_t MAX_OUTPUT_SIZE_CLIENT = 1'000'000'00; + + /* We need to plan a fork, currently some value in the future */ + const uint64_t MAX_OUTPUT_SIZE_HEIGHT = 500000; + + /* For new projects forked from this code base, the values immediately below should be changed to 0 to prevent issues with transaction processing and other possible unexpected behavior */ From 2147ddc43b01717c70fa42423fb2c45e44a56d05 Mon Sep 17 00:00:00 2001 From: zach Date: Wed, 30 Oct 2019 20:42:01 +0500 Subject: [PATCH 2/3] fix: GH actions init --- .github/workflows/matrix.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/matrix.yml b/.github/workflows/matrix.yml index 558ed611..440d8cd7 100644 --- a/.github/workflows/matrix.yml +++ b/.github/workflows/matrix.yml @@ -1,6 +1,7 @@ name: Build on: [push, pull_request] + jobs: # Common Build matrix for builds on Ubuntu VM ubuntu_build: From 6eb81353d87a1d0da44658e99252fedfc0cc0a74 Mon Sep 17 00:00:00 2001 From: zach Date: Wed, 30 Oct 2019 20:44:14 +0500 Subject: [PATCH 3/3] start ci --- .github/workflows/matrix.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/matrix.yml b/.github/workflows/matrix.yml index 440d8cd7..558ed611 100644 --- a/.github/workflows/matrix.yml +++ b/.github/workflows/matrix.yml @@ -1,7 +1,6 @@ name: Build on: [push, pull_request] - jobs: # Common Build matrix for builds on Ubuntu VM ubuntu_build: