diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml
new file mode 100644
index 0000000000..520f226ea5
--- /dev/null
+++ b/.github/FUNDING.yml
@@ -0,0 +1 @@
+custom: ["http://bit.ly/PRCYcryptoDonations", prcycoin.com, "http://bit.ly/PRCYfiatDonations"]
diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md
new file mode 100644
index 0000000000..dd84ea7824
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/bug_report.md
@@ -0,0 +1,38 @@
+---
+name: Bug report
+about: Create a report to help us improve
+title: ''
+labels: ''
+assignees: ''
+
+---
+
+**Describe the bug**
+A clear and concise description of what the bug is.
+
+**To Reproduce**
+Steps to reproduce the behavior:
+1. Go to '...'
+2. Click on '....'
+3. Scroll down to '....'
+4. See error
+
+**Expected behavior**
+A clear and concise description of what you expected to happen.
+
+**Screenshots**
+If applicable, add screenshots to help explain your problem.
+
+**Desktop (please complete the following information):**
+ - OS: [e.g. iOS]
+ - Browser [e.g. chrome, safari]
+ - Version [e.g. 22]
+
+**Smartphone (please complete the following information):**
+ - Device: [e.g. iPhone6]
+ - OS: [e.g. iOS8.1]
+ - Browser [e.g. stock browser, safari]
+ - Version [e.g. 22]
+
+**Additional context**
+Add any other context about the problem here.
diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md
new file mode 100644
index 0000000000..bbcbbe7d61
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/feature_request.md
@@ -0,0 +1,20 @@
+---
+name: Feature request
+about: Suggest an idea for this project
+title: ''
+labels: ''
+assignees: ''
+
+---
+
+**Is your feature request related to a problem? Please describe.**
+A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
+
+**Describe the solution you'd like**
+A clear and concise description of what you want to happen.
+
+**Describe alternatives you've considered**
+A clear and concise description of any alternative solutions or features you've considered.
+
+**Additional context**
+Add any other context or screenshots about the feature request here.
diff --git a/.github/workflows/prcy-build-factory-debug.yml b/.github/workflows/prcy-build-factory-debug.yml
new file mode 100644
index 0000000000..662448c25e
--- /dev/null
+++ b/.github/workflows/prcy-build-factory-debug.yml
@@ -0,0 +1,379 @@
+# Copyright (c) 2018-2020 The Veil developers
+# Copyright (c) 2020 The DAPS Project
+# Copyright (c) 2020 The PRivaCY Coin Developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+name: Github Actions CI for PRCY (Ubuntu 20 --enable-debug)
+on: [push, pull_request]
+env:
+ SOURCE_ARTIFACT: source
+jobs:
+ create-source-distribution:
+ name: Create Source Distribution
+ runs-on: ubuntu-20.04
+ if: "contains(github.event.head_commit.message, '[debug]')"
+ env:
+ ARTIFACT_DIR: source
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v3
+ - name: Create Version Variable
+ run: |
+ export VERSION=$(cat version.txt | sed 's/[^0-9,.]//g')
+ export TAG=v${VERSION}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ echo "TAG=${TAG}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Print Variables
+ run: |
+ echo "VERSION=${VERSION}"
+ echo "TAG=${TAG}"
+ printenv
+ - name: Create Distribution Tarball
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ touch prcycoin.tar.gz
+ tar -czf prcycoin.tar.gz --exclude=prcycoin.tar.gz .
+ - name: Download Dependencies
+ run: make -C depends download
+ - name: Create Dependencies Tarball
+ run: tar -czf depends.tar.gz depends
+ - name: Prepare Files for Artifact
+ run: |
+ mv depends.tar.gz prcycoin.tar.gz $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ path: ${{ env.ARTIFACT_DIR }}
+ build-x86_64-linux:
+ name: Build for x86 Linux 64bit
+ needs: create-source-distribution
+ runs-on: ubuntu-20.04
+ env:
+ ARTIFACT_DIR: prcycoin-x86_64-linux-debug
+ TEST_LOG_ARTIFACT_DIR: test-logs
+ steps:
+ - name: Getting Source
+ uses: actions/download-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ - name: Extract Archives
+ run: |
+ tar -xzf depends.tar.gz
+ tar -xzf prcycoin.tar.gz --strip-components=1
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Set Env
+ shell: bash
+ run: |
+ export VERSION=$(cat $SOURCE_ARTIFACT/version.txt | sed 's/[^0-9,.]//g')
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Install Required Packages
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y python3-zmq
+ - name: Build Dependencies
+ run: make -C depends -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build PRCY
+ run: |
+ ./autogen.sh
+ CONFIG_SITE=$(realpath depends/x86_64-pc-linux-gnu/share/config.site) ./configure --disable-jni --disable-tests --disable-gui-tests --disable-bench --enable-upnp-default --enable-glibc-back-compat --enable-reduce-exports --enable-debug
+ make -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Prepare Files for Artifact
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ strip $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt}
+ chmod +x $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt}
+ mv $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt} $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: prcycoin-v${{ env.VERSION }}-x86_64-linux-debug
+ path: ${{ env.ARTIFACT_DIR }}
+ build-win64:
+ name: Build for Win64
+ needs: create-source-distribution
+ runs-on: ubuntu-20.04
+ env:
+ ARTIFACT_DIR: prcycoin-win64-debug
+ steps:
+ - name: Getting Source
+ uses: actions/download-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ - name: Extract Archives
+ run: |
+ tar -xzf depends.tar.gz
+ tar -xzf prcycoin.tar.gz --strip-components=1
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Set Env
+ shell: bash
+ run: |
+ export VERSION=$(cat $SOURCE_ARTIFACT/version.txt | sed 's/[^0-9,.]//g')
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Install Required Packages
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y g++-mingw-w64-x86-64 gcc-mingw-w64-x86-64 nsis
+ - name: Switch MinGW GCC and G++ to POSIX Threading
+ run: |
+ sudo update-alternatives --set x86_64-w64-mingw32-gcc /usr/bin/x86_64-w64-mingw32-gcc-posix
+ sudo update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix
+ - name: Build Dependencies
+ run: make -C depends -j$(nproc) HOST=x86_64-w64-mingw32
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build PRCY
+ run: |
+ ./autogen.sh
+ CONFIG_SITE=$(realpath depends/x86_64-w64-mingw32/share/config.site) ./configure --disable-jni --disable-tests --disable-gui-tests --disable-bench --enable-upnp-default --enable-reduce-exports --enable-debug
+ make -j$(nproc)
+ make deploy -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Prepare Files for Artifact
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ strip $SOURCE_ARTIFACT/src/{prcycoin-cli.exe,prcycoin-tx.exe,prcycoind.exe,qt/prcycoin-qt.exe}
+ mv $SOURCE_ARTIFACT/{prcycoin-*.exe,src/prcycoin-cli.exe,src/prcycoin-tx.exe,src/prcycoind.exe,src/qt/prcycoin-qt.exe} $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: prcycoin-v${{ env.VERSION }}-win64-debug
+ path: ${{ env.ARTIFACT_DIR }}
+ build-osx64:
+ name: Build for MacOSX
+ needs: create-source-distribution
+ runs-on: ubuntu-20.04
+ env:
+ ARTIFACT_DIR: prcycoin-macosx-debug
+ SDK_URL: https://bitcoincore.org/depends-sources/sdks
+ steps:
+ - name: Getting Source
+ uses: actions/download-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ - name: Extract Archives
+ run: |
+ tar -xzf depends.tar.gz
+ tar -xzf prcycoin.tar.gz --strip-components=1
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Set Env
+ shell: bash
+ run: |
+ export VERSION=$(cat $SOURCE_ARTIFACT/version.txt | sed 's/[^0-9,.]//g')
+ export XCODE_VERSION=12.1
+ export XCODE_BUILD_ID=12A7403
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ echo "XCODE_VERSION=${XCODE_VERSION}" >> $GITHUB_ENV
+ echo "XCODE_BUILD_ID=${XCODE_BUILD_ID}" >> $GITHUB_ENV
+ export OSX_SDK_BASENAME=Xcode-$XCODE_VERSION-$XCODE_BUILD_ID-extracted-SDK-with-libcxx-headers.tar.gz
+ export OSX_SDK_PATH=depends/sdk-sources/$OSX_SDK_BASENAME
+ echo "OSX_SDK_BASENAME=${OSX_SDK_BASENAME}" >> $GITHUB_ENV
+ echo "OSX_SDK_PATH=${OSX_SDK_PATH}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Install Required Packages
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y python3-setuptools libcap-dev libtinfo5
+ - name: Get macOS SDK
+ run: |
+ mkdir -p depends/sdk-sources depends/SDKs
+ if [ -n "${{ env.XCODE_VERSION }}" ] && [ ! -f "${{ env.OSX_SDK_PATH }}" ]; then
+ curl --location --fail "${{ env.SDK_URL }}/${{ env.OSX_SDK_BASENAME }}" -o "${{ env.OSX_SDK_PATH }}"
+ fi
+ if [ -n "${{ env.XCODE_VERSION }}" ] && [ -f "${{ env.OSX_SDK_PATH }}" ]; then
+ tar -C "depends/SDKs" -xf "${{ env.OSX_SDK_PATH }}"
+ fi
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build Dependencies
+ run: make -C depends HOST=x86_64-apple-darwin18 -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build PRCY
+ run: |
+ ./autogen.sh
+ CONFIG_SITE=$(realpath depends/x86_64-apple-darwin18/share/config.site) ./configure --disable-jni --disable-tests --disable-gui-tests --disable-bench --enable-upnp-default --enable-reduce-exports --enable-debug
+ make -j$(nproc)
+ make deploy -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Prepare Files for Artifact
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ mv $SOURCE_ARTIFACT/{*.dmg,src/prcycoin-cli,src/prcycoin-tx,src/prcycoind,src/qt/prcycoin-qt} $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: prcycoin-v${{ env.VERSION }}-macosx-debug
+ path: ${{ env.ARTIFACT_DIR }}
+ build-aarch64-linux:
+ name: Build for ARM Linux 64bit
+ needs: create-source-distribution
+ runs-on: ubuntu-20.04
+ env:
+ ARTIFACT_DIR: prcycoin-aarch64-linux-debug
+ steps:
+ - name: Getting Source
+ uses: actions/download-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ - name: Extract Archives
+ run: |
+ tar -xzf depends.tar.gz
+ tar -xzf prcycoin.tar.gz --strip-components=1
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Set Env
+ shell: bash
+ run: |
+ export VERSION=$(cat $SOURCE_ARTIFACT/version.txt | sed 's/[^0-9,.]//g')
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Install Required Packages
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y python3-zmq g++-aarch64-linux-gnu
+ - name: Build Dependencies
+ run: make -C depends HOST=aarch64-linux-gnu -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build PRCY
+ run: |
+ ./autogen.sh
+ CONFIG_SITE=$(realpath depends/aarch64-linux-gnu/share/config.site) ./configure --disable-jni --disable-tests --disable-gui-tests --disable-bench --enable-upnp-default --enable-glibc-back-compat --enable-reduce-exports --enable-debug
+ make -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Prepare Files for Artifact
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ chmod +x $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt}
+ mv $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt} $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: prcycoin-v${{ env.VERSION }}-aarch64-linux-debug
+ path: ${{ env.ARTIFACT_DIR }}
+ build-arm-linux-gnueabihf:
+ name: Build for ARM Linux 32bit
+ needs: create-source-distribution
+ runs-on: ubuntu-20.04
+ env:
+ ARTIFACT_DIR: prcycoin-arm32-debug
+ steps:
+ - name: Getting Source
+ uses: actions/download-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ - name: Extract Archives
+ run: |
+ tar -xzf depends.tar.gz
+ tar -xzf prcycoin.tar.gz --strip-components=1
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Set Env
+ shell: bash
+ run: |
+ export VERSION=$(cat $SOURCE_ARTIFACT/version.txt | sed 's/[^0-9,.]//g')
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Install Required Packages
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y g++-arm-linux-gnueabihf
+ - name: Build Dependencies
+ run: make -C depends -j$(nproc) HOST=arm-linux-gnueabihf
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build PRCY
+ run: |
+ ./autogen.sh
+ CONFIG_SITE=$(realpath depends/arm-linux-gnueabihf/share/config.site) ./configure --disable-jni --disable-tests --disable-gui-tests --disable-bench --enable-glibc-back-compat --enable-reduce-exports --enable-upnp-default CXXFLAGS=-Wno-psabi --enable-debug
+ make -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Prepare Files for Artifact
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ chmod +x $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt}
+ mv $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt} $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: prcycoin-v${{ env.VERSION }}-arm32-debug
+ path: ${{ env.ARTIFACT_DIR }}
+ build-riscv64-linux-gnu:
+ name: Build for RISC-V 64-bit
+ needs: create-source-distribution
+ runs-on: ubuntu-20.04
+ env:
+ ARTIFACT_DIR: prcycoin-riscv64-debug
+ steps:
+ - name: Getting Source
+ uses: actions/download-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ - name: Extract Archives
+ run: |
+ tar -xzf depends.tar.gz
+ tar -xzf prcycoin.tar.gz --strip-components=1
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Set Env
+ shell: bash
+ run: |
+ export VERSION=$(cat $SOURCE_ARTIFACT/version.txt | sed 's/[^0-9,.]//g')
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Install Required Packages
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y g++-riscv64-linux-gnu binutils-riscv64-linux-gnu
+ - name: Build Dependencies
+ run: make -C depends -j$(nproc) HOST=riscv64-linux-gnu
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build PRCY
+ run: |
+ ./autogen.sh
+ CONFIG_SITE=$(realpath depends/riscv64-linux-gnu/share/config.site) ./configure --disable-jni --disable-tests --disable-gui-tests --disable-bench --enable-reduce-exports --enable-upnp-default --enable-debug
+ make -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Prepare Files for Artifact
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ chmod +x $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt}
+ mv $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt} $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: prcycoin-v${{ env.VERSION }}-riscv64-debug
+ path: ${{ env.ARTIFACT_DIR }}
diff --git a/.github/workflows/prcy-build-factory.yml b/.github/workflows/prcy-build-factory.yml
new file mode 100644
index 0000000000..c74a8baa8e
--- /dev/null
+++ b/.github/workflows/prcy-build-factory.yml
@@ -0,0 +1,379 @@
+# Copyright (c) 2018-2020 The Veil developers
+# Copyright (c) 2020 The DAPS Project
+# Copyright (c) 2020 The PRivaCY Coin Developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+name: Github Actions CI for PRCY (Ubuntu 20)
+on: [push, pull_request]
+env:
+ SOURCE_ARTIFACT: source
+jobs:
+ create-source-distribution:
+ name: Create Source Distribution
+ runs-on: ubuntu-20.04
+ if: "!contains(github.event.head_commit.message, '[debug]')"
+ env:
+ ARTIFACT_DIR: source
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v3
+ - name: Create Version Variable
+ run: |
+ export VERSION=$(cat version.txt | sed 's/[^0-9,.]//g')
+ export TAG=v${VERSION}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ echo "TAG=${TAG}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Print Variables
+ run: |
+ echo "VERSION=${VERSION}"
+ echo "TAG=${TAG}"
+ printenv
+ - name: Create Distribution Tarball
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ touch prcycoin.tar.gz
+ tar -czf prcycoin.tar.gz --exclude=prcycoin.tar.gz .
+ - name: Download Dependencies
+ run: make -C depends download
+ - name: Create Dependencies Tarball
+ run: tar -czf depends.tar.gz depends
+ - name: Prepare Files for Artifact
+ run: |
+ mv depends.tar.gz prcycoin.tar.gz $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ path: ${{ env.ARTIFACT_DIR }}
+ build-x86_64-linux:
+ name: Build for x86 Linux 64bit
+ needs: create-source-distribution
+ runs-on: ubuntu-20.04
+ env:
+ ARTIFACT_DIR: prcycoin-x86_64-linux
+ TEST_LOG_ARTIFACT_DIR: test-logs
+ steps:
+ - name: Getting Source
+ uses: actions/download-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ - name: Extract Archives
+ run: |
+ tar -xzf depends.tar.gz
+ tar -xzf prcycoin.tar.gz --strip-components=1
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Set Env
+ shell: bash
+ run: |
+ export VERSION=$(cat $SOURCE_ARTIFACT/version.txt | sed 's/[^0-9,.]//g')
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Install Required Packages
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y python3-zmq
+ - name: Build Dependencies
+ run: make -C depends -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build PRCY
+ run: |
+ ./autogen.sh
+ CONFIG_SITE=$(realpath depends/x86_64-pc-linux-gnu/share/config.site) ./configure --disable-jni --disable-tests --disable-gui-tests --disable-bench --enable-upnp-default --enable-glibc-back-compat --enable-reduce-exports
+ make -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Prepare Files for Artifact
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ strip $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt}
+ chmod +x $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt}
+ mv $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt} $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: prcycoin-v${{ env.VERSION }}-x86_64-linux
+ path: ${{ env.ARTIFACT_DIR }}
+ build-win64:
+ name: Build for Win64
+ needs: create-source-distribution
+ runs-on: ubuntu-20.04
+ env:
+ ARTIFACT_DIR: prcycoin-win64
+ steps:
+ - name: Getting Source
+ uses: actions/download-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ - name: Extract Archives
+ run: |
+ tar -xzf depends.tar.gz
+ tar -xzf prcycoin.tar.gz --strip-components=1
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Set Env
+ shell: bash
+ run: |
+ export VERSION=$(cat $SOURCE_ARTIFACT/version.txt | sed 's/[^0-9,.]//g')
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Install Required Packages
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y g++-mingw-w64-x86-64 gcc-mingw-w64-x86-64 nsis
+ - name: Switch MinGW GCC and G++ to POSIX Threading
+ run: |
+ sudo update-alternatives --set x86_64-w64-mingw32-gcc /usr/bin/x86_64-w64-mingw32-gcc-posix
+ sudo update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix
+ - name: Build Dependencies
+ run: make -C depends -j$(nproc) HOST=x86_64-w64-mingw32
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build PRCY
+ run: |
+ ./autogen.sh
+ CONFIG_SITE=$(realpath depends/x86_64-w64-mingw32/share/config.site) ./configure --disable-jni --disable-tests --disable-gui-tests --disable-bench --enable-upnp-default --enable-reduce-exports
+ make -j$(nproc)
+ make deploy -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Prepare Files for Artifact
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ strip $SOURCE_ARTIFACT/src/{prcycoin-cli.exe,prcycoin-tx.exe,prcycoind.exe,qt/prcycoin-qt.exe}
+ mv $SOURCE_ARTIFACT/{prcycoin-*.exe,src/prcycoin-cli.exe,src/prcycoin-tx.exe,src/prcycoind.exe,src/qt/prcycoin-qt.exe} $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: prcycoin-v${{ env.VERSION }}-win64
+ path: ${{ env.ARTIFACT_DIR }}
+ build-osx64:
+ name: Build for MacOSX
+ needs: create-source-distribution
+ runs-on: ubuntu-20.04
+ env:
+ ARTIFACT_DIR: prcycoin-macosx
+ SDK_URL: https://bitcoincore.org/depends-sources/sdks
+ steps:
+ - name: Getting Source
+ uses: actions/download-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ - name: Extract Archives
+ run: |
+ tar -xzf depends.tar.gz
+ tar -xzf prcycoin.tar.gz --strip-components=1
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Set Env
+ shell: bash
+ run: |
+ export VERSION=$(cat $SOURCE_ARTIFACT/version.txt | sed 's/[^0-9,.]//g')
+ export XCODE_VERSION=12.1
+ export XCODE_BUILD_ID=12A7403
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ echo "XCODE_VERSION=${XCODE_VERSION}" >> $GITHUB_ENV
+ echo "XCODE_BUILD_ID=${XCODE_BUILD_ID}" >> $GITHUB_ENV
+ export OSX_SDK_BASENAME=Xcode-$XCODE_VERSION-$XCODE_BUILD_ID-extracted-SDK-with-libcxx-headers.tar.gz
+ export OSX_SDK_PATH=depends/sdk-sources/$OSX_SDK_BASENAME
+ echo "OSX_SDK_BASENAME=${OSX_SDK_BASENAME}" >> $GITHUB_ENV
+ echo "OSX_SDK_PATH=${OSX_SDK_PATH}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Install Required Packages
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y python3-setuptools libcap-dev libtinfo5
+ - name: Get macOS SDK
+ run: |
+ mkdir -p depends/sdk-sources depends/SDKs
+ if [ -n "${{ env.XCODE_VERSION }}" ] && [ ! -f "${{ env.OSX_SDK_PATH }}" ]; then
+ curl --location --fail "${{ env.SDK_URL }}/${{ env.OSX_SDK_BASENAME }}" -o "${{ env.OSX_SDK_PATH }}"
+ fi
+ if [ -n "${{ env.XCODE_VERSION }}" ] && [ -f "${{ env.OSX_SDK_PATH }}" ]; then
+ tar -C "depends/SDKs" -xf "${{ env.OSX_SDK_PATH }}"
+ fi
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build Dependencies
+ run: make -C depends HOST=x86_64-apple-darwin18 -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build PRCY
+ run: |
+ ./autogen.sh
+ CONFIG_SITE=$(realpath depends/x86_64-apple-darwin18/share/config.site) ./configure --disable-jni --disable-tests --disable-gui-tests --disable-bench --enable-upnp-default --enable-reduce-exports
+ make -j$(nproc)
+ make deploy -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Prepare Files for Artifact
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ mv $SOURCE_ARTIFACT/{*.dmg,src/prcycoin-cli,src/prcycoin-tx,src/prcycoind,src/qt/prcycoin-qt} $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: prcycoin-v${{ env.VERSION }}-macosx
+ path: ${{ env.ARTIFACT_DIR }}
+ build-aarch64-linux:
+ name: Build for ARM Linux 64bit
+ needs: create-source-distribution
+ runs-on: ubuntu-20.04
+ env:
+ ARTIFACT_DIR: prcycoin-aarch64-linux
+ steps:
+ - name: Getting Source
+ uses: actions/download-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ - name: Extract Archives
+ run: |
+ tar -xzf depends.tar.gz
+ tar -xzf prcycoin.tar.gz --strip-components=1
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Set Env
+ shell: bash
+ run: |
+ export VERSION=$(cat $SOURCE_ARTIFACT/version.txt | sed 's/[^0-9,.]//g')
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Install Required Packages
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y python3-zmq g++-aarch64-linux-gnu
+ - name: Build Dependencies
+ run: make -C depends HOST=aarch64-linux-gnu -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build PRCY
+ run: |
+ ./autogen.sh
+ CONFIG_SITE=$(realpath depends/aarch64-linux-gnu/share/config.site) ./configure --disable-jni --disable-tests --disable-gui-tests --disable-bench --enable-upnp-default --enable-glibc-back-compat --enable-reduce-exports
+ make -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Prepare Files for Artifact
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ chmod +x $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt}
+ mv $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt} $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: prcycoin-v${{ env.VERSION }}-aarch64-linux
+ path: ${{ env.ARTIFACT_DIR }}
+ build-arm-linux-gnueabihf:
+ name: Build for ARM Linux 32bit
+ needs: create-source-distribution
+ runs-on: ubuntu-20.04
+ env:
+ ARTIFACT_DIR: prcycoin-arm32
+ steps:
+ - name: Getting Source
+ uses: actions/download-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ - name: Extract Archives
+ run: |
+ tar -xzf depends.tar.gz
+ tar -xzf prcycoin.tar.gz --strip-components=1
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Set Env
+ shell: bash
+ run: |
+ export VERSION=$(cat $SOURCE_ARTIFACT/version.txt | sed 's/[^0-9,.]//g')
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Install Required Packages
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y g++-arm-linux-gnueabihf
+ - name: Build Dependencies
+ run: make -C depends -j$(nproc) HOST=arm-linux-gnueabihf
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build PRCY
+ run: |
+ ./autogen.sh
+ CONFIG_SITE=$(realpath depends/arm-linux-gnueabihf/share/config.site) ./configure --disable-jni --disable-tests --disable-gui-tests --disable-bench --enable-glibc-back-compat --enable-reduce-exports --enable-upnp-default CXXFLAGS=-Wno-psabi
+ make -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Prepare Files for Artifact
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ chmod +x $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt}
+ mv $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt} $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: prcycoin-v${{ env.VERSION }}-arm32
+ path: ${{ env.ARTIFACT_DIR }}
+ build-riscv64-linux-gnu:
+ name: Build for RISC-V 64-bit
+ needs: create-source-distribution
+ runs-on: ubuntu-20.04
+ env:
+ ARTIFACT_DIR: prcycoin-riscv64
+ steps:
+ - name: Getting Source
+ uses: actions/download-artifact@v1
+ with:
+ name: ${{ env.SOURCE_ARTIFACT }}
+ - name: Extract Archives
+ run: |
+ tar -xzf depends.tar.gz
+ tar -xzf prcycoin.tar.gz --strip-components=1
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Set Env
+ shell: bash
+ run: |
+ export VERSION=$(cat $SOURCE_ARTIFACT/version.txt | sed 's/[^0-9,.]//g')
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Append Commit Hash to Development Builds
+ if: "!contains(github.ref, 'master')"
+ shell: bash
+ run: |
+ export VERSION=${{ env.VERSION }}-${GITHUB_SHA::7}
+ echo "VERSION=${VERSION}" >> $GITHUB_ENV
+ - name: Install Required Packages
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y g++-riscv64-linux-gnu binutils-riscv64-linux-gnu
+ - name: Build Dependencies
+ run: make -C depends -j$(nproc) HOST=riscv64-linux-gnu
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Build PRCY
+ run: |
+ ./autogen.sh
+ CONFIG_SITE=$(realpath depends/riscv64-linux-gnu/share/config.site) ./configure --disable-jni --disable-tests --disable-gui-tests --disable-bench --enable-reduce-exports --enable-upnp-default
+ make -j$(nproc)
+ working-directory: ${{ env.SOURCE_ARTIFACT }}
+ - name: Prepare Files for Artifact
+ run: |
+ mkdir -p $ARTIFACT_DIR
+ chmod +x $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt}
+ mv $SOURCE_ARTIFACT/src/{prcycoin-cli,prcycoin-tx,prcycoind,qt/prcycoin-qt} $ARTIFACT_DIR
+ - name: Upload Artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: prcycoin-v${{ env.VERSION }}-riscv64
+ path: ${{ env.ARTIFACT_DIR }}
diff --git a/.gitignore b/.gitignore
index d524dde1aa..10b2d8046c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -6,12 +6,12 @@ reset-files.bash
*.tar.gz
*.exe
-src/dapscoin
-src/dapscoind
-src/dapscoin-cli
-src/dapscoin-tx
-src/test/test_dapscoin
-src/qt/test/test_dapscoin-qt
+src/prcycoin
+src/prcycoind
+src/prcycoin-cli
+src/prcycoin-tx
+src/test/test_prcycoin
+src/qt/test/test_prcycoin-qt
# autoreconf
Makefile.in
@@ -37,15 +37,28 @@ confdefs.h
conftest.cpp
conftest.err
libtool
-src/config/dapscoin-config.h
-src/config/dapscoin-config.h.in
+src/config/prcycoin-config.h
+src/config/prcycoin-config.h.in
src/config/stamp-h1
+src/obj
+src/secp256k1-mw/build-aux/compile
+src/secp256k1-mw/build-aux/config.guess
+src/secp256k1-mw/build-aux/config.sub
+src/secp256k1-mw/build-aux/depcomp
+src/secp256k1-mw/build-aux/install-sh
+src/secp256k1-mw/build-aux/ltmain.sh
+src/secp256k1-mw/build-aux/m4/libtool.m4
+src/secp256k1-mw/build-aux/missing
+src/secp256k1-mw/build-aux/test-driver
+src/secp256k1-mw/gen_context
+src/secp256k1-mw/libsecp256k1.pc
+src/secp256k1-mw/src/libsecp256k1-config.h
share/setup.nsi
share/qt/Info.plist
contrib/devtools/split-debug.sh
-src/qt/dapscoin-qt-multisig
-src/qt/test/test_dapscoin-qt-multisig
+src/qt/prcycoin-qt-multisig
+src/qt/test/test_prcycoin-qt-multisig
src/univalue/gen
src/qt/*.moc
@@ -67,7 +80,7 @@ src/qt/test/moc*.cpp
*.o
*.o-*
*.patch
-.dapscoin
+.prcycoin
*.a
!libchilkat*.a
*.pb.cc
@@ -77,7 +90,6 @@ src/qt/test/moc*.cpp
*.trs
*.dmg
-*.json.h
*.raw.h
#libtool object files
@@ -87,12 +99,12 @@ src/qt/test/moc*.cpp
# Compilation and Qt preprocessor part
*.qm
Makefile
-dapscoin-qt
-DAPScoin-Qt.app
+prcycoin-qt
+PRCYcoin-Qt.app
# Unit-tests
Makefile.test
-dapscoin-qt_test
+prcycoin-qt_test
src/test/buildenv.py
# Resources cpp
@@ -104,11 +116,13 @@ qrc_*.cpp
# Mac specific
.DS_Store
build
+osx_volname
+dist/
#lcov
*.gcno
/*.info
-test_dapscoin.coverage/
+test_prcycoin.coverage/
total.coverage/
coverage_percent.txt
@@ -116,25 +130,28 @@ coverage_percent.txt
linux-coverage-build
linux-build
win32-build
+test/config.ini
+test/cache/*
qa/pull-tester/run-bitcoind-for-test.sh
qa/pull-tester/tests-config.sh
qa/pull-tester/cache/*
qa/pull-tester/test.*/*
+cache/*
!src/leveldb*/Makefile
!depends/Makefile
-!depends/patches/*/*.patch
+!depends/patches/**/*.patch
.cproject
.project
/doc/doxygen/
/nbproject/
+libbitcoinconsensus.pc
.idea
CMakeLists.txt
cmake-build-debug
.vscode/*
BackupWallet*
-
-#ChainParams
-src/chainparams.cpp
+prcycoin-qt.pro
+!contrib/prcycoin-qt.pro
diff --git a/.python-version b/.python-version
new file mode 100644
index 0000000000..8b7b0b52e5
--- /dev/null
+++ b/.python-version
@@ -0,0 +1 @@
+3.6.12
diff --git a/.travis.yml b/.travis.yml
index 4bd872a314..ef88979392 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,82 +1,131 @@
sudo: required
dist: trusty
-
-#workaround for https://github.com/travis-ci/travis-ci/issues/5227
-addons:
- hostname: dapscoin-tester
-
os: linux
-language: generic
+language: minimal
cache:
+ ccache: true
directories:
- depends/built
- depends/sdk-sources
- $HOME/.ccache
+stages:
+ - lint
+ - test
env:
global:
- MAKEJOBS=-j3
- - RUN_TESTS=false
- - CHECK_DOC=0
- - CHECK_LOGPRINT=0
+ - RUN_UNIT_TESTS=true
+ - RUN_FUNCTIONAL_TESTS=false # Not Yet Implemented
+ - RUN_BENCH=false # Set to true for any one job that has debug enabled, to quickly check bench is not crashing or hitting assertions
+ - DOCKER_NAME_TAG=ubuntu:18.04
- BOOST_TEST_RANDOM=1$TRAVIS_BUILD_ID
- CCACHE_SIZE=100M
- CCACHE_TEMPDIR=/tmp/.ccache-temp
- CCACHE_COMPRESS=1
+ - CCACHE_DIR=$HOME/.ccache
- BASE_OUTDIR=$TRAVIS_BUILD_DIR/out
- SDK_URL=https://bitcoincore.org/depends-sources/sdks
- - PYTHON_DEBUG=1
- WINEDEBUG=fixme-all
- matrix:
-# ARM
- - HOST=arm-linux-gnueabihf PACKAGES="g++-arm-linux-gnueabihf" CHECK_DOC=1 CHECK_LOGPRINT=1 GOAL="install" BITCOIN_CONFIG="--enable-glibc-back-compat --enable-reduce-exports"
-# Win32
- - HOST=i686-w64-mingw32 DPKG_ADD_ARCH="i386" DEP_OPTS="NO_QT=1" PACKAGES="python3 nsis g++-mingw-w64-i686 wine1.6 bc" RUN_TESTS=true GOAL="install" BITCOIN_CONFIG="--enable-reduce-exports"
-# 32-bit + dash
- - HOST=i686-pc-linux-gnu PACKAGES="g++-multilib bc python3-zmq" DEP_OPTS="NO_QT=1" RUN_TESTS=true GOAL="install" BITCOIN_CONFIG="--enable-zmq --enable-glibc-back-compat --enable-reduce-exports LDFLAGS=-static-libstdc++" USE_SHELL="/bin/dash" PYZMQ=true
-# Win64
- - HOST=x86_64-w64-mingw32 DPKG_ADD_ARCH="i386" DEP_OPTS="NO_QT=1" PACKAGES="python3 nsis g++-mingw-w64-x86-64 wine1.6 bc" RUN_TESTS=true GOAL="install" BITCOIN_CONFIG="--enable-reduce-exports"
-# dapscoind
- - HOST=x86_64-unknown-linux-gnu PACKAGES="bc python3-zmq" DEP_OPTS="NO_QT=1 NO_UPNP=1 DEBUG=1" RUN_TESTS=true GOAL="install" BITCOIN_CONFIG="--enable-zmq --enable-glibc-back-compat --enable-reduce-exports CPPFLAGS=-DDEBUG_LOCKORDER" PYZMQ=true
-
-# No wallet
-# - HOST=x86_64-unknown-linux-gnu PACKAGES="python3" DEP_OPTS="NO_WALLET=1" RUN_TESTS=true GOAL="install" BITCOIN_CONFIG="--enable-glibc-back-compat --enable-reduce-exports"
-# Cross-Mac
- - HOST=x86_64-apple-darwin11 PACKAGES="cmake imagemagick libcap-dev librsvg2-bin libz-dev libbz2-dev libtiff-tools python-dev" BITCOIN_CONFIG="--enable-reduce-exports" OSX_SDK=10.11 GOAL="deploy"
+ - DOCKER_PACKAGES="build-essential libtool autotools-dev automake pkg-config bsdmainutils curl git ca-certificates ccache"
before_install:
- - export PATH=$(echo $PATH | tr ':' "\n" | sed '/\/opt\/python/d' | tr "\n" ":" | sed "s|::|:|g")
+ - set -o errexit; source .travis/test_03_before_install.sh
install:
- - if [ "$PYZMQ" = "true" ]; then pip install pyzmq --user ; fi
- - if [ -n "$PPA" ]; then travis_retry sudo add-apt-repository "$PPA" -y; fi
- - if [ -n "$DPKG_ADD_ARCH" ]; then sudo dpkg --add-architecture "$DPKG_ADD_ARCH" ; fi
- - if [ -n "$PACKAGES" ]; then travis_retry sudo apt-get update; fi
- - if [ -n "$PACKAGES" ]; then travis_retry sudo apt-get install --no-install-recommends --no-upgrade -qq $PACKAGES; fi
+ - set -o errexit; source .travis/test_04_install.sh
before_script:
- - unset CC; unset CXX
- - if [ "$CHECK_DOC" = 1 ]; then contrib/devtools/check-doc.py; fi
- - if [ "$CHECK_LOGPRINT" = 1 ]; then contrib/devtools/logprint-scanner.py; fi
- - mkdir -p depends/SDKs depends/sdk-sources
- - if [ -n "$OSX_SDK" -a ! -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then curl --location --fail $SDK_URL/MacOSX${OSX_SDK}.sdk.tar.gz -o depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz; fi
- - if [ -n "$OSX_SDK" -a -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then tar -C depends/SDKs -xf depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz; fi
- - make $MAKEJOBS -C depends HOST=$HOST $DEP_OPTS
+ - set -o errexit; source .travis/test_05_before_script.sh
script:
- - export TRAVIS_COMMIT_LOG=`git log --format=fuller -1`
- - if [ -n "$USE_SHELL" ]; then export CONFIG_SHELL="$USE_SHELL"; fi
- - OUTDIR=$BASE_OUTDIR/$TRAVIS_PULL_REQUEST/$TRAVIS_JOB_NUMBER-$HOST
- - BITCOIN_CONFIG_ALL="--disable-dependency-tracking --prefix=$TRAVIS_BUILD_DIR/depends/$HOST --bindir=$OUTDIR/bin --libdir=$OUTDIR/lib"
- - depends/$HOST/native/bin/ccache --max-size=$CCACHE_SIZE
- - test -n "$USE_SHELL" && eval '"$USE_SHELL" -c "./autogen.sh"' || ./autogen.sh
- - ./configure --cache-file=config.cache $BITCOIN_CONFIG_ALL $BITCOIN_CONFIG || ( cat config.log && false)
- - make distdir PACKAGE=bitcoin VERSION=$HOST
- - cd bitcoin-$HOST
- - ./configure --cache-file=../config.cache $BITCOIN_CONFIG_ALL $BITCOIN_CONFIG || ( cat config.log && false)
- - make $MAKEJOBS $GOAL || ( echo "Build failure. Verbose build follows." && make $GOAL V=1 ; false )
- - export LD_LIBRARY_PATH=$TRAVIS_BUILD_DIR/depends/$HOST/lib
- - if [ "$RUN_TESTS" = "true" ]; then make $MAKEJOBS check VERBOSE=1; fi
- #- if [ "$RUN_TESTS" = "true" ]; then qa/pull-tester/rpc-tests.py --coverage; fi
+ - set -o errexit; source .travis/test_06_script.sh
after_script:
- echo $TRAVIS_COMMIT_RANGE
- echo $TRAVIS_COMMIT_LOG
-notifications:
- slack:
- secure: w22XjHoG/3xplxWzddS9Ma7i99Q/hq4FA3Q56xS+RtO2vlFgDT+eDzCppstdx96mn2/4e+/V1aiQ4E6GVEvJMeldqSUhPv9OBnKR0KJVAOwu4haNXt+0ZeQFt8lIndKB5cMVyOJkoq6peGoHNXslClM0lGuBn7g7VC2QPQYNWrJNrrGL7IiVb6fNOIKHWcC4URkzSvXAhO/WIqSSlmKxAAx0B2oEsM8LhdAbcjbp7Sm7zH87TIVGBZ7iTVuMc6B9+SfClbE8bBuRtvjTX57Q4UUZzn0zDtKdPdCte0oXdaQF4RdVim9mDodBGIpDo+avW4WL7EE+AK33fs94pwH5bu0LEandR/aeEvVpbSpQ2XsEKSe+6woizgl5i4GXFVZduJF62y/o1f+S/zC3qW9lIEEpiZc4PpX7pDy30X3p6S5nMrW7T/zNh+SjLhS1VP6XKdQtpD3WRCY4GKZYammZhk5RbOy3jTXAahIXuttWdhl/Q3Rb5VqfFJWlrG/qQXt73qOk2/DgJnABxXE6gnWO4MpHAq+kdomNR+nod4HeXI3DOk1wRuQRVoW1rSjiqQd6Db+TP56RKYgt4M4csOD0DG9G+W0AOtZkuKHTeoEtmQfkKFPZLYAQumv41cDN2UE9gKIECmvJSevj4sMCDTWtozKWqay/W4n2+cmhbzmGflY=
+
+jobs:
+ include:
+# lint stage
+ - stage: lint
+ env:
+ sudo: false
+ cache: false
+ language: python
+ python: '3.6'
+ install:
+ - set -o errexit; source .travis/lint_04_install.sh
+ before_script:
+ - set -o errexit; source .travis/lint_05_before_script.sh
+ script:
+ - set -o errexit; source .travis/lint_06_script.sh
+# ARM
+ - stage: test
+ env: >-
+ HOST=arm-linux-gnueabihf
+ PACKAGES="python3 g++-arm-linux-gnueabihf"
+ DEP_OPTS="NO_QT=1"
+ RUN_UNIT_TESTS=false
+ RUN_FUNCTIONAL_TESTS=false
+ GOAL="install"
+ # -Wno-psabi is to disable ABI warnings: "note: parameter passing for argument of type ... changed in GCC 7.1"
+ # This could be removed once the ABI change warning does not show up by default
+ BITCOIN_CONFIG="--enable-glibc-back-compat --enable-reduce-exports CXXFLAGS=-Wno-psabi"
+# AArch64
+ - stage: test
+ env: >-
+ HOST=aarch64-linux-gnu
+ PACKAGES="python3 g++-aarch64-linux-gnu"
+ DEP_OPTS="NO_QT=1"
+ RUN_UNIT_TESTS=false
+ RUN_FUNCTIONAL_TESTS=false
+ GOAL="install"
+ BITCOIN_CONFIG="--enable-glibc-back-compat --enable-reduce-exports"
+# Win64
+ - stage: test
+ env: >-
+ HOST=x86_64-w64-mingw32
+ DEP_OPTS="NO_QT=1"
+ PACKAGES="python3 nsis g++-mingw-w64-x86-64 wine-binfmt wine64"
+ GOAL="install"
+ BITCOIN_CONFIG="--enable-reduce-exports"
+# x86_64 Linux (uses qt5 dev package instead of depends Qt to speed up build and avoid timeout)
+ - stage: test
+ env: >-
+ HOST=x86_64-unknown-linux-gnu
+ PACKAGES="python3-zmq qtbase5-dev qttools5-dev-tools libdbus-1-dev libharfbuzz-dev"
+ DEP_OPTS="NO_QT=1 NO_UPNP=1 DEBUG=1 ALLOW_HOST_PACKAGES=1"
+ GOAL="install"
+ BITCOIN_CONFIG="--enable-zmq --with-gui=qt5 --enable-glibc-back-compat --enable-reduce-exports CPPFLAGS=-DDEBUG_LOCKORDER"
+# x86_64 Linux (no depends, only system libs)
+ - stage: test
+ env: >-
+ HOST=x86_64-unknown-linux-gnu
+ PACKAGES="python3-zmq qtbase5-dev qttools5-dev-tools libssl1.0-dev libevent-dev bsdmainutils libboost-system-dev libboost-filesystem-dev libboost-chrono-dev libboost-program-options-dev libboost-test-dev libboost-thread-dev libdb5.3++-dev libminiupnpc-dev libzmq3-dev libqrencode-dev"
+ NO_DEPENDS=1
+ GOAL="install"
+ BITCOIN_CONFIG="--enable-zmq --with-incompatible-bdb --enable-glibc-back-compat --enable-reduce-exports --with-gui=qt5 CPPFLAGS=-DDEBUG_LOCKORDER"
+# x86_64 Linux (sanitizers)
+# - stage: test
+# env: >-
+# HOST=x86_64-unknown-linux-gnu
+# PACKAGES="clang python3-zmq qtbase5-dev qttools5-dev-tools libssl1.0-dev libevent-dev bsdmainutils libboost-system-dev libboost-filesystem-dev libboost-chrono-dev libboost-program-options-dev libboost-test-dev libboost-thread-dev libdb5.3++-dev libminiupnpc-dev libzmq3-dev libqrencode-dev"
+# NO_DEPENDS=1
+# RUN_BENCH=true
+# RUN_FUNCTIONAL_TESTS=false # Disabled for now, can be combined with the other x86_64 linux NO_DEPENDS job when functional tests pass the sanitizers
+# GOAL="install"
+# BITCOIN_CONFIG="--enable-zmq --with-incompatible-bdb --enable-glibc-back-compat --enable-reduce-exports --with-gui=qt5 CPPFLAGS=-DDEBUG_LOCKORDER --with-sanitizers=undefined CC=clang CXX=clang++"
+# x86_64 Linux, No wallet
+# - stage: test
+# env: >-
+# HOST=x86_64-unknown-linux-gnu
+# PACKAGES="python3"
+# DEP_OPTS="NO_WALLET=1"
+# GOAL="install"
+# BITCOIN_CONFIG="--enable-glibc-back-compat --enable-reduce-exports"
+# Cross-Mac
+ - stage: test
+ env: >-
+ HOST=x86_64-apple-darwin18
+ PACKAGES="cmake imagemagick libcap-dev librsvg2-bin libz-dev libbz2-dev libtiff-tools python-dev python3-setuptools-git"
+ OSX_SDK=10.14
+ RUN_UNIT_TESTS=false
+ RUN_FUNCTIONAL_TESTS=false
+ GOAL="all deploy"
+ BITCOIN_CONFIG="--enable-gui --enable-reduce-exports --enable-werror"
diff --git a/.travis/README.md b/.travis/README.md
new file mode 100644
index 0000000000..21d1b9cc03
--- /dev/null
+++ b/.travis/README.md
@@ -0,0 +1,8 @@
+## travis build scripts
+
+The `.travis` directory contains scripts for each build step in each build stage.
+Currently the travis build defines two stages `lint` and `test`. Each stage has
+it's own [lifecycle](https://docs.travis-ci.com/user/customizing-the-build/#the-build-lifecycle).
+Every script in here is named and numbered according to which stage and lifecycle
+step it belongs to.
+
diff --git a/.travis/lint_04_install.sh b/.travis/lint_04_install.sh
new file mode 100755
index 0000000000..34118a57c3
--- /dev/null
+++ b/.travis/lint_04_install.sh
@@ -0,0 +1,9 @@
+#!/usr/bin/env bash
+#
+# Copyright (c) 2018 The Bitcoin Core developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+export LC_ALL=C
+
+travis_retry pip install flake8
diff --git a/.travis/lint_05_before_script.sh b/.travis/lint_05_before_script.sh
new file mode 100755
index 0000000000..28bcbb47f7
--- /dev/null
+++ b/.travis/lint_05_before_script.sh
@@ -0,0 +1,9 @@
+#!/usr/bin/env bash
+#
+# Copyright (c) 2018 The Bitcoin Core developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+export LC_ALL=C
+
+git fetch --unshallow
diff --git a/.travis/lint_06_script.sh b/.travis/lint_06_script.sh
new file mode 100755
index 0000000000..0ae2f98636
--- /dev/null
+++ b/.travis/lint_06_script.sh
@@ -0,0 +1,18 @@
+#!/usr/bin/env bash
+#
+# Copyright (c) 2018 The Bitcoin Core developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+export LC_ALL=C
+
+
+contrib/devtools/git-subtree-check.sh src/secp256k1
+contrib/devtools/git-subtree-check.sh src/univalue
+contrib/devtools/git-subtree-check.sh src/leveldb
+contrib/devtools/check-doc.py
+contrib/devtools/logprint-scanner.py
+
+if [ "$TRAVIS_EVENT_TYPE" = "pull_request" ]; then
+ contrib/devtools/lint-whitespace.sh
+fi
diff --git a/.travis/test_03_before_install.sh b/.travis/test_03_before_install.sh
new file mode 100755
index 0000000000..d091a67ca9
--- /dev/null
+++ b/.travis/test_03_before_install.sh
@@ -0,0 +1,25 @@
+#!/usr/bin/env bash
+#
+# Copyright (c) 2018 The Bitcoin Core developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+export LC_ALL=C.UTF-8
+
+PATH=$(echo $PATH | tr ':' "\n" | sed '/\/opt\/python/d' | tr "\n" ":" | sed "s|::|:|g")
+export PATH
+
+BEGIN_FOLD () {
+ echo ""
+ CURRENT_FOLD_NAME=$1
+ echo "travis_fold:start:${CURRENT_FOLD_NAME}"
+}
+
+END_FOLD () {
+ RET=$?
+ echo "travis_fold:end:${CURRENT_FOLD_NAME}"
+ if [ $RET != 0 ]; then
+ echo "${CURRENT_FOLD_NAME} failed with status code ${RET}"
+ fi
+}
+
diff --git a/.travis/test_04_install.sh b/.travis/test_04_install.sh
new file mode 100755
index 0000000000..ef595287b7
--- /dev/null
+++ b/.travis/test_04_install.sh
@@ -0,0 +1,26 @@
+#!/usr/bin/env bash
+#
+# Copyright (c) 2018 The Bitcoin Core developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+export LC_ALL=C.UTF-8
+
+travis_retry docker pull "$DOCKER_NAME_TAG"
+env | grep -E '^(CCACHE_|WINEDEBUG|LC_ALL|BOOST_TEST_RANDOM|CONFIG_SHELL)' | tee /tmp/env
+if [[ $HOST = *-mingw32 ]]; then
+ DOCKER_ADMIN="--cap-add SYS_ADMIN"
+fi
+DOCKER_ID=$(docker run $DOCKER_ADMIN -idt --mount type=bind,src=$TRAVIS_BUILD_DIR,dst=$TRAVIS_BUILD_DIR --mount type=bind,src=$CCACHE_DIR,dst=$CCACHE_DIR -w $TRAVIS_BUILD_DIR --env-file /tmp/env $DOCKER_NAME_TAG)
+
+DOCKER_EXEC () {
+ docker exec $DOCKER_ID bash -c "cd $PWD && $*"
+}
+
+if [ -n "$DPKG_ADD_ARCH" ]; then
+ DOCKER_EXEC dpkg --add-architecture "$DPKG_ADD_ARCH"
+fi
+
+travis_retry DOCKER_EXEC apt-get update
+travis_retry DOCKER_EXEC apt-get install --no-install-recommends --no-upgrade -qq $PACKAGES $DOCKER_PACKAGES
+
diff --git a/.travis/test_05_before_script.sh b/.travis/test_05_before_script.sh
new file mode 100755
index 0000000000..e082eaa9f9
--- /dev/null
+++ b/.travis/test_05_before_script.sh
@@ -0,0 +1,25 @@
+#!/usr/bin/env bash
+#
+# Copyright (c) 2018 The Bitcoin Core developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+export LC_ALL=C.UTF-8
+
+#DOCKER_EXEC echo \> \$HOME/.prcycoin # Make sure default datadir does not exist and is never read by creating a dummy file
+
+mkdir -p depends/SDKs depends/sdk-sources
+
+if [ -n "$OSX_SDK" -a ! -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then
+ curl --location --fail $SDK_URL/MacOSX${OSX_SDK}.sdk.tar.gz -o depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz
+fi
+if [ -n "$OSX_SDK" -a -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then
+ tar -C depends/SDKs -xf depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz
+fi
+if [[ $HOST = *-mingw32 ]]; then
+ DOCKER_EXEC update-alternatives --set $HOST-g++ \$\(which $HOST-g++-posix\)
+fi
+if [ -z "$NO_DEPENDS" ]; then
+ DOCKER_EXEC CONFIG_SHELL= make $MAKEJOBS -C depends HOST=$HOST $DEP_OPTS
+fi
+
diff --git a/.travis/test_06_script.sh b/.travis/test_06_script.sh
new file mode 100755
index 0000000000..0057a04f73
--- /dev/null
+++ b/.travis/test_06_script.sh
@@ -0,0 +1,67 @@
+#!/usr/bin/env bash
+#
+# Copyright (c) 2018 The Bitcoin Core developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+export LC_ALL=C.UTF-8
+
+TRAVIS_COMMIT_LOG=$(git log --format=fuller -1)
+export TRAVIS_COMMIT_LOG
+
+OUTDIR=$BASE_OUTDIR/$TRAVIS_PULL_REQUEST/$TRAVIS_JOB_NUMBER-$HOST
+BITCOIN_CONFIG_ALL="--disable-dependency-tracking --prefix=$TRAVIS_BUILD_DIR/depends/$HOST --bindir=$OUTDIR/bin --libdir=$OUTDIR/lib"
+if [ -z "$NO_DEPENDS" ]; then
+ DOCKER_EXEC ccache --max-size=$CCACHE_SIZE
+fi
+
+BEGIN_FOLD autogen
+if [ -n "$CONFIG_SHELL" ]; then
+ DOCKER_EXEC "$CONFIG_SHELL" -c "./autogen.sh"
+else
+ DOCKER_EXEC ./autogen.sh
+fi
+END_FOLD
+
+mkdir build
+cd build || (echo "could not enter build directory"; exit 1)
+
+BEGIN_FOLD configure
+DOCKER_EXEC ../configure --cache-file=config.cache $BITCOIN_CONFIG_ALL $BITCOIN_CONFIG || ( cat config.log && false)
+END_FOLD
+
+BEGIN_FOLD distdir
+DOCKER_EXEC make distdir VERSION=$HOST
+END_FOLD
+
+cd "prcycoin-$HOST" || (echo "could not enter distdir prcycoin-$HOST"; exit 1)
+
+BEGIN_FOLD configure
+DOCKER_EXEC ./configure --cache-file=../config.cache $BITCOIN_CONFIG_ALL $BITCOIN_CONFIG || ( cat config.log && false)
+END_FOLD
+
+BEGIN_FOLD build
+DOCKER_EXEC make $MAKEJOBS $GOAL || ( echo "Build failure. Verbose build follows." && DOCKER_EXEC make $GOAL V=1 ; false )
+END_FOLD
+
+if [ "$RUN_UNIT_TESTS" = "true" ]; then
+ BEGIN_FOLD unit-tests
+ DOCKER_EXEC LD_LIBRARY_PATH=$TRAVIS_BUILD_DIR/depends/$HOST/lib make $MAKEJOBS check VERBOSE=1
+ END_FOLD
+fi
+
+if [ "$RUN_BENCH" = "true" ]; then
+ BEGIN_FOLD bench
+ DOCKER_EXEC LD_LIBRARY_PATH=$TRAVIS_BUILD_DIR/depends/$HOST/lib $OUTDIR/bin/bench_prcycoin -scaling=0.001
+ END_FOLD
+fi
+
+if [ "$TRAVIS_EVENT_TYPE" = "cron" ]; then
+ extended="--extended --exclude feature_pruning,feature_dbcrash"
+fi
+
+if [ "$RUN_FUNCTIONAL_TESTS" = "true" ]; then
+ BEGIN_FOLD functional-tests
+ DOCKER_EXEC test/functional/test_runner.py --combinedlogslen=4000 --coverage --quiet --failfast ${extended}
+ END_FOLD
+fi
diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md
new file mode 100644
index 0000000000..4e659e8a31
--- /dev/null
+++ b/CODE_OF_CONDUCT.md
@@ -0,0 +1,76 @@
+# Contributor Covenant Code of Conduct
+
+## Our Pledge
+
+In the interest of fostering an open and welcoming environment, we as
+contributors and maintainers pledge to making participation in our project and
+our community a harassment-free experience for everyone, regardless of age, body
+size, disability, ethnicity, sex characteristics, gender identity and expression,
+level of experience, education, socio-economic status, nationality, personal
+appearance, race, religion, or sexual identity and orientation.
+
+## Our Standards
+
+Examples of behavior that contributes to creating a positive environment
+include:
+
+* Using welcoming and inclusive language
+* Being respectful of differing viewpoints and experiences
+* Gracefully accepting constructive criticism
+* Focusing on what is best for the community
+* Showing empathy towards other community members
+
+Examples of unacceptable behavior by participants include:
+
+* The use of sexualized language or imagery and unwelcome sexual attention or
+ advances
+* Trolling, insulting/derogatory comments, and personal or political attacks
+* Public or private harassment
+* Publishing others' private information, such as a physical or electronic
+ address, without explicit permission
+* Other conduct which could reasonably be considered inappropriate in a
+ professional setting
+
+## Our Responsibilities
+
+Project maintainers are responsible for clarifying the standards of acceptable
+behavior and are expected to take appropriate and fair corrective action in
+response to any instances of unacceptable behavior.
+
+Project maintainers have the right and responsibility to remove, edit, or
+reject comments, commits, code, wiki edits, issues, and other contributions
+that are not aligned to this Code of Conduct, or to ban temporarily or
+permanently any contributor for other behaviors that they deem inappropriate,
+threatening, offensive, or harmful.
+
+## Scope
+
+This Code of Conduct applies both within project spaces and in public spaces
+when an individual is representing the project or its community. Examples of
+representing a project or community include using an official project e-mail
+address, posting via an official social media account, or acting as an appointed
+representative at an online or offline event. Representation of a project may be
+further defined and clarified by project maintainers.
+
+## Enforcement
+
+Instances of abusive, harassing, or otherwise unacceptable behavior may be
+reported by contacting the project team at support@prcycoin.com. All
+complaints will be reviewed and investigated and will result in a response that
+is deemed necessary and appropriate to the circumstances. The project team is
+obligated to maintain confidentiality with regard to the reporter of an incident.
+Further details of specific enforcement policies may be posted separately.
+
+Project maintainers who do not follow or enforce the Code of Conduct in good
+faith may face temporary or permanent repercussions as determined by other
+members of the project's leadership.
+
+## Attribution
+
+This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
+available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
+
+[homepage]: https://www.contributor-covenant.org
+
+For answers to common questions about this code of conduct, see
+https://www.contributor-covenant.org/faq
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index b05f2bf105..c883b17953 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -1,7 +1,7 @@
-Contributing to DAPS
+Contributing to PRCYCoin
============================
-The DAPS project operates an open contributor model where anyone is
+The PRCYCoin project operates an open contributor model where anyone is
welcome to contribute towards development in the form of peer review, testing
and patches. This document explains the practical process and guidelines for
contributing.
@@ -24,9 +24,9 @@ facilitates social contribution, easy testing and peer review.
To contribute a patch, the workflow is as follows:
- - Fork repository
- - Create topic branch
- - Commit patches
+ 1. Fork repository
+ 2. Create topic branch
+ 3. Commit patches
The project coding conventions in the [developer notes](doc/developer-notes.md)
must be adhered to.
@@ -40,12 +40,14 @@ Commit messages should be verbose by default consisting of a short subject line
paragraph(s), unless the title alone is self-explanatory (like "Corrected typo
in init.cpp") in which case a single title line is sufficient. Commit messages should be
helpful to people reading your code in the future, so explain the reasoning for
-your decisions. Further explanation [here](http://chris.beams.io/posts/git-commit/).
+your decisions. Further explanation [here](https://chris.beams.io/posts/git-commit/).
-If a particular commit references another issue, please add the reference, for
-example `refs #1234`, or `fixes #4321`. Using the `fixes` or `closes` keywords
+If a particular commit references another issue, please add the reference. For
+example: `refs #1234` or `fixes #4321`. Using the `fixes` or `closes` keywords
will cause the corresponding issue to be closed when the pull request is merged.
+Commit messages should never contain any `@` mentions.
+
Please refer to the [Git manual](https://git-scm.com/doc) for more information
about Git.
@@ -57,12 +59,12 @@ the pull request affects. Valid areas as:
- *Consensus* for changes to consensus critical code
- *Docs* for changes to the documentation
- - *Qt* for changes to dapscoin-qt
+ - *Qt* for changes to prcycoin-qt
- *Minting* for changes to the minting code
- *Net* or *P2P* for changes to the peer-to-peer network code
- *RPC/REST* for changes to the RPC or REST APIs
- *Scripts and tools* for changes to the scripts and tools
- - *Tests* for changes to the dapscoin unit tests or QA tests
+ - *Tests* for changes to the prcycoin unit tests or QA tests
- *Trivial* should **only** be used for PRs that do not change generated
executable code. Notably, refactors (change of function arguments and code
reorganization) and changes in behavior should **not** be marked as trivial.
@@ -81,7 +83,11 @@ Examples:
Qt: Add feed bump button
Trivial: Fix typo in init.cpp
-If a pull request is specifically not to be considered for merging (yet) please
+Note that translations should not be submitted as pull requests, please see
+[Translation Process](https://github.com/PRCYCoin/PRCYCoin/blob/master/doc/translation_process.md)
+for more information on helping with translations.
+
+If a pull request is not to be considered for merging (yet), please
prefix the title with [WIP] or use [Tasks Lists](https://help.github.com/articles/basic-writing-and-formatting-syntax/#task-lists)
in the body of the pull request to indicate tasks are pending.
@@ -94,6 +100,8 @@ At this stage one should expect comments and review from other contributors. You
can add more commits to your pull request by committing them locally and pushing
to your fork until you have satisfied all feedback.
+Note: Code review is a burdensome but important part of the development process, and as such, certain types of pull requests are rejected. In general, if the **improvements** do not warrant the **review effort** required, the PR has a high chance of being rejected. It is up to the PR author to convince the reviewers that the changes warrant the review effort, and if reviewers are "Concept NAK'ing" the PR, the author may need to present arguments and/or do research backing their suggested changes.
+
Squashing Commits
---------------------------
If your pull request is accepted for merging, you may be asked by a maintainer
@@ -102,12 +110,16 @@ before it will be merged. The basic squashing workflow is shown below.
git checkout your_branch_name
git rebase -i HEAD~n
- # n is normally the number of commits in the pull
- # set commits from 'pick' to 'squash', save and quit
- # on the next screen, edit/refine commit messages
- # save and quit
+ # n is normally the number of commits in the pull request.
+ # Set commits (except the one in the first line) from 'pick' to 'squash', save and quit.
+ # On the next screen, edit/refine commit messages.
+ # Save and quit.
git push -f # (force push to GitHub)
+Please update the resulting commit message if needed, it should read as a
+coherent message. In most cases this means that you should not just list the
+interim commits.
+
If you have problems with squashing (or other workflows with `git`), you can
alternatively enable "Allow edits from maintainers" in the right GitHub
sidebar and ask for help in the pull request.
@@ -120,11 +132,37 @@ the respective change set.
The length of time required for peer review is unpredictable and will vary from
pull request to pull request.
+Rebasing Pull Requests
+-------------------------
+It may become necessary for a pull request to be rebased after other pull requests have been
+merged. This is typically due to mutually exclusive changes (conflicts) between your pull
+request and the current `master` branch.
+
+When a rebase is needed, a comment will be added to the pull request indicating this need.
+Rather than simply merge the `master` branch into your pull request (which results in an
+ugly and confusing merge commit), it is better to use git's rebase feature. The basic
+workflow is as follows:
+
+ # replace 'origin' with the remote name for the main project repo in the example
+ git checkout your_branch_name
+ git fetch origin
+ git pull --rebase origin master
+
+This will "rewind" your branch commits, pull any new commits from `master`, then attempt to
+re-apply your commits on top of the new HEAD. If any conflicts are found, the process will
+pause and allow you to resolve any conflicts. Once conflicts have been resolved:
+
+ git rebase --continue
+
+Repeat as necessary until there are no more conflicts and your git tree is in a clean state.
+The final step is to push your rebased branch back up to github:
+
+ git push -f # force pushes the branch to github
Pull Request Philosophy
-----------------------
-Patch sets should always be focused. For example, a pull request could add a
+Patchsets should always be focused. For example, a pull request could add a
feature, fix a bug, or refactor code; but not a mixture. Please also avoid super
pull requests which attempt to do too much, are overly large, or overly complex
as this makes review difficult.
@@ -148,19 +186,27 @@ There are three categories of refactoring, code only moves, code style fixes,
code refactoring. In general refactoring pull requests should not mix these
three kinds of activity in order to make refactoring pull requests easy to
review and uncontroversial. In all cases, refactoring PRs must not change the
-behavior of code within the pull request (bugs must be preserved as is).
+behaviour of code within the pull request (bugs must be preserved as is).
Project maintainers aim for a quick turnaround on refactoring pull requests, so
-where possible keep them short, un-complex and easy to verify.
+where possible keep them short, uncomplex and easy to verify.
+
+Pull requests that refactor the code should not be made by new contributors. It
+requires a certain level of experience to know where the code belongs and to
+understand the full ramification (including rebase effort of open pull requests).
+
+Trivial pull requests or pull requests that refactor the code with no clear
+benefits may be immediately closed by the maintainers to reduce unnecessary
+workload on reviewing.
"Decision Making" Process
-------------------------
-The following applies to code changes to the DAPS project, and is not to be
-confused with overall DAPS Network Protocol consensus changes.
+The following applies to code changes to the PRCYCoin project, and is not to be
+confused with overall PRCYCoin Network Protocol consensus changes.
-Whether a pull request is merged into DAPS rests with the project merge
+Whether a pull request is merged into PRCYCoin rests with the project merge
maintainers and ultimately the project lead.
Maintainers will take into consideration if a patch is in line with the general
@@ -169,12 +215,12 @@ judge the general consensus of contributors.
In general, all pull requests must:
- - have a clear use case, fix a demonstrable bug or serve the greater good of
+ - Have a clear use case, fix a demonstrable bug or serve the greater good of
the project (for example refactoring for modularisation);
- - be well peer reviewed;
+ - Be well peer reviewed;
- follow code style guidelines;
-Patches that change DAPS consensus rules are considerably more involved than
+Patches that change PRCYCoin consensus rules are considerably more involved than
normal because they affect the entire ecosystem and so must be preceded by
extensive discussions and clear detailing. While each case will be different,
one should be prepared to expend more time and effort than for other kinds of
@@ -185,13 +231,16 @@ patches because of increased peer review and consensus building requirements.
Anyone may participate in peer review which is expressed by comments in the pull
request. Typically reviewers will review the code for obvious errors, as well as
-test out the patch set and opine on the technical merits of the patch. Project
+test out the patchset and opine on the technical merits of the patch. Project
maintainers take into account the peer review when determining if there is
consensus to merge a pull request (remember that discussions may have been
-spread out over GitHub, forums, email, and Slack discussions). The following
+spread out over GitHub, forums, email, and Discord/Telegram discussions). The following
language is used within pull-request comments:
- - ACK means "I have tested the code and I agree it should be merged";
+ - (t)ACK means "I have tested the code and I agree it should be merged", involving
+ change-specific manual testing in addition to running the unit and functional
+ tests, and in case it is not obvious how the manual testing was done, it should
+ be described;
- NACK means "I disagree this should be merged", and must be accompanied by
sound technical justification (or in certain cases of copyright/patent/licensing
issues, legal justification). NACKs without accompanying reasoning may be
@@ -209,13 +258,13 @@ that have demonstrated a deeper commitment and understanding towards the project
(over time) or have clear domain expertise may naturally have more weight, as
one would expect in all walks of life.
-Where a patch set affects consensus critical code, the bar will be set much
+Where a patchset affects consensus critical code, the bar will be set much
higher in terms of discussion and peer review requirements, keeping in mind that
mistakes could be very costly to the wider community. This includes refactoring
of consensus critical code.
-Where a patch set proposes to change the DAPS consensus, it must have been
-discussed extensively on the forums and Slack, be accompanied by a widely
+Where a patchset proposes to change the PRCYCoin consensus, it must have been
+discussed extensively on the forums and Discord/Telegram, be accompanied by a widely
discussed Proposal and have a generally widely perceived technical consensus of being
a worthwhile change based on the judgement of the maintainers.
@@ -237,7 +286,7 @@ about:
that personally, though! Instead, take another critical look at what you are suggesting
and see if it: changes too much, is too broad, doesn't adhere to the
[developer notes](doc/developer-notes.md), is dangerous or insecure, is messily written, etc.
- Identify and address any of the issues you find. Then ask e.g. on Slack if someone could give
+ Identify and address any of the issues you find. Then ask e.g. on Discord/Telegram if someone could give
their opinion on the concept itself.
- It may be because your code is too complex for all but a few people. And those people
may not have realized your pull request even exists. A great way to find people who
@@ -245,7 +294,7 @@ about:
[Git Blame feature](https://help.github.com/articles/tracing-changes-in-a-file/). Simply
find the person touching the code you are touching before you and see if you can find
them and give them a nudge. Don't be incessant about the nudging though.
- - Finally, if all else fails, ask on Slack or elsewhere for someone to give your pull request
+ - Finally, if all else fails, ask on Discord/Telegram or elsewhere for someone to give your pull request
a look. If you think you've been waiting an unreasonably long amount of time (month+) for
no particular reason (few lines changed, etc), this is totally fine. Try to return the favor
when someone else is asking for feedback on their code, and universe balances out.
@@ -254,7 +303,7 @@ about:
Release Policy
--------------
-The project leader is the release manager for each DAPS release.
+The project leader is the release manager for each PRCYCoin release.
Copyright
---------
diff --git a/COPYING b/COPYING
index 208fdac7e4..f765ab8bf2 100644
--- a/COPYING
+++ b/COPYING
@@ -1,7 +1,8 @@
Copyright (c) 2009-2015 Bitcoin Developers
Copyright (c) 2014-2015 Dash Developers
Copyright (c) 2015-2018 PIVX Developers
-Copyright (c) 2018-2019 DAPScoin Developers
+Copyright (c) 2018-2020 DAPScoin Developers
+Copyright (c) 2020-2023 PRCYcoin Developers
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
diff --git a/Dockerfile b/Dockerfile
index d84cab7844..6a2c5ec2f0 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,38 +1,22 @@
-
-# DAPS DEPS IMG
+# PRCY DEPS IMG
FROM ubuntu:18.04
-RUN apt-get update
-RUN apt-get install gnupg software-properties-common debconf dialog apt-utils gcc-5 bsdmainutils curl git -y --fix-missing
-RUN add-apt-repository ppa:bitcoin/bitcoin -y
-RUN apt-get update
-
-RUN apt-get install autotools-dev build-essential autoconf make automake openssl -y --fix-missing
-
-RUN apt-get install libssl-dev libboost-dev libtool pkg-config -y --fix-missing
-RUN apt-get install libminiupnpc-dev miniupnpc libdb4.8++-dev libdb4.8-dev libqrencode-dev libevent-dev -y --fix-missing
-
-RUN apt-get install libqt5gui5 libqt5core5a libqt5dbus5 qttools5-dev qttools5-dev-tools libprotobuf-dev libboost-all-dev protobuf-compiler -y --fix-missing
-RUN apt-get install libqrencode-dev libzmq3-dev -y --fix-missing
-
-RUN apt-get install g++-5 libcurl4-openssl-dev libjansson-dev -y --fix-missing
-RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-5 1
-#compile for windows
-RUN apt-get install g++-mingw-w64-x86-64 -y --fix-missing
-RUN update-alternatives --config x86_64-w64-mingw32-g++
-RUN PATH=$(echo "$PATH" | sed -e 's/:\/mnt.*//g') # strip out problematic Windows %PATH% imported var
+COPY ./prcycoin.conf /root/.prcycoin/prcycoin.conf
+COPY . /prcycoin
+WORKDIR /prcycoin
-
-
-RUN mkdir /DAPS/
-COPY . /DAPS/
-
-RUN make -C DAPS/depends HOST=x86_64-w64-mingw32
-#RUN make -C /DAPS/depends
-
-RUN bash /DAPS/autogen.sh
-RUN CONFIG_SITE=$PWD/depends/x86_64-w64-mingw32/share/config.site ./configure --prefix=/
-RUN bash /DAPS/configure
-
-RUN ls -a
\ No newline at end of file
+RUN apt-get update
+RUN apt-get install -y build-essential libtool bsdmainutils autotools-dev autoconf pkg-config automake python3
+RUN apt-get install -y libssl1.0-dev libzmq5 libgmp-dev libevent-dev libboost-all-dev libsodium-dev cargo
+RUN apt-get install -y libqt5gui5 libqt5core5a libqt5dbus5 qttools5-dev qttools5-dev-tools libprotobuf-dev protobuf-compiler libqrencode-dev
+RUN apt-get install -y software-properties-common g++-multilib binutils-gold patch
+RUN add-apt-repository ppa:pivx/pivx
+RUN apt-get update
+RUN apt-get install -y libdb4.8-dev libdb4.8++-dev
+RUN ./autogen.sh
+RUN ./configure --disable-jni --disable-tests --disable-gui-tests --disable-bench
+RUN make
+RUN make install
+EXPOSE 59682 59683 59684 59685s
+CMD ["prcycoind", "--printtoconsole"]
diff --git a/INSTALL b/INSTALL
index c4918c9e76..d7ff9d48ef 100644
--- a/INSTALL
+++ b/INSTALL
@@ -1,4 +1,4 @@
-Building DAPScoin
+Building PRCYcoin
Use the autogen script to prepare the build environment.
@@ -8,6 +8,6 @@ Use the autogen script to prepare the build environment.
Always verify the signatures and checksums.
-See doc/build-*.md for instructions on building dapscoind,
+See doc/build-*.md for instructions on building prcycoind,
the intended-for-services, no-graphical-interface, reference
-implementation of DAPScoin.
+implementation of PRCYcoin.
diff --git a/Makefile.am b/Makefile.am
index eb5b832ca9..877d154de3 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -2,66 +2,78 @@
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+# Pattern rule to print variables, e.g. make print-top_srcdir
+print-%:
+ @echo '$*' = '$($*)'
+
ACLOCAL_AMFLAGS = -I build-aux/m4
SUBDIRS = src
+if ENABLE_MAN
+SUBDIRS += doc/man
+endif
.PHONY: deploy FORCE
-GZIP_ENV="-9n"
export PYTHONPATH
+if BUILD_BITCOIN_LIBS
+pkgconfigdir = $(libdir)/pkgconfig
+pkgconfig_DATA = libbitcoinconsensus.pc
+endif
+
BITCOIND_BIN=$(top_builddir)/src/$(BITCOIN_DAEMON_NAME)$(EXEEXT)
BITCOIN_QT_BIN=$(top_builddir)/src/qt/$(BITCOIN_GUI_NAME)$(EXEEXT)
BITCOIN_CLI_BIN=$(top_builddir)/src/$(BITCOIN_CLI_NAME)$(EXEEXT)
BITCOIN_TX_BIN=$(top_builddir)/src/$(BITCOIN_TX_NAME)$(EXEEXT)
-BITCOIN_WIN_INSTALLER=$(PACKAGE)-$(PACKAGE_VERSION)-win$(WINDOWS_BITS)-setup$(EXEEXT)
+BITCOIN_WIN_INSTALLER=$(PACKAGE)-$(PACKAGE_VERSION)-win64-setup$(EXEEXT)
empty :=
space := $(empty) $(empty)
-OSX_APP=DAPScoin-Qt.app
+OSX_APP=PRCYcoin-Qt.app
OSX_VOLNAME = $(subst $(space),-,$(PACKAGE_NAME))
OSX_DMG = $(OSX_VOLNAME).dmg
-OSX_BACKGROUND_SVG=background.svg
-OSX_BACKGROUND_IMAGE=background.tiff
-OSX_BACKGROUND_IMAGE_DPIS=36 72
-OSX_DSSTORE_GEN=$(top_srcdir)/contrib/macdeploy/custom_dsstore.py
OSX_DEPLOY_SCRIPT=$(top_srcdir)/contrib/macdeploy/macdeployqtplus
-OSX_FANCY_PLIST=$(top_srcdir)/contrib/macdeploy/fancy.plist
OSX_INSTALLER_ICONS=$(top_srcdir)/src/qt/res/icons/bitcoin.icns
OSX_PLIST=$(top_builddir)/share/qt/Info.plist #not installed
-OSX_QT_TRANSLATIONS = da,de,es,hu,ru,uk,zh_CN,zh_TW
-
-DIST_DOCS = $(wildcard doc/*.md) $(wildcard doc/release-notes/*.md)
-WINDOWS_PACKAGING = $(top_srcdir)/share/pixmaps/bitcoin.ico \
+DIST_DOCS = \
+ README.md \
+ $(wildcard doc/*.md) \
+ $(wildcard doc/release-notes/*.md)
+DIST_CONTRIB = $(top_srcdir)/contrib/prcycoin-cli.bash-completion \
+ $(top_srcdir)/contrib/prcycoin-tx.bash-completion \
+ $(top_srcdir)/contrib/prcycoind.bash-completion \
+ $(top_srcdir)/contrib/init \
+ $(top_srcdir)/contrib/install_db4.sh
+
+DIST_SHARE = \
+ $(top_srcdir)/share/genbuild.sh \
+ $(top_srcdir)/share/rpcauth
+
+BIN_CHECKS=$(top_srcdir)/contrib/devtools/symbol-check.py \
+ $(top_srcdir)/contrib/devtools/security-check.py
+
+WINDOWS_PACKAGING = $(top_srcdir)/share/pixmaps/prcycoin.ico \
$(top_srcdir)/share/pixmaps/nsis-header.bmp \
$(top_srcdir)/share/pixmaps/nsis-wizard.bmp \
$(top_srcdir)/doc/README_windows.txt
-OSX_PACKAGING = $(OSX_DEPLOY_SCRIPT) $(OSX_FANCY_PLIST) $(OSX_INSTALLER_ICONS) \
- $(top_srcdir)/contrib/macdeploy/$(OSX_BACKGROUND_SVG) \
- $(OSX_DSSTORE_GEN) \
+LINUX_PACKAGING = $(top_srcdir)/share/pixmaps/prcycoin16.xpm \
+ $(top_srcdir)/share/pixmaps/prcycoin32.xpm \
+ $(top_srcdir)/share/pixmaps/prcycoin128.png
+
+OSX_PACKAGING = $(OSX_DEPLOY_SCRIPT) $(OSX_INSTALLER_ICONS) \
$(top_srcdir)/contrib/macdeploy/detached-sig-apply.sh \
$(top_srcdir)/contrib/macdeploy/detached-sig-create.sh
-COVERAGE_INFO = baseline_filtered_combined.info baseline.info block_test.info \
- leveldb_baseline.info test_dapscoin_filtered.info total_coverage.info \
- baseline_filtered.info block_test_filtered.info \
- leveldb_baseline_filtered.info test_dapscoin_coverage.info test_dapscoin.info
+COVERAGE_INFO = baseline.info \
+ test_prcycoin_filtered.info total_coverage.info \
+ baseline_filtered.info functional_test.info functional_test_filtered.info \
+ test_prcycoin_coverage.info test_prcycoin.info
dist-hook:
- -$(MAKE) -C $(top_distdir)/src/leveldb clean
- -$(MAKE) -C $(top_distdir)/src/secp256k1 distclean
-$(GIT) archive --format=tar HEAD -- src/clientversion.cpp | $(AMTAR) -C $(top_distdir) -xf -
-distcheck-hook:
- $(MKDIR_P) $(top_distdir)/_build/src/leveldb
- cp -rf $(top_srcdir)/src/leveldb/* $(top_distdir)/_build/src/leveldb/
- -$(MAKE) -C $(top_distdir)/_build/src/leveldb clean
-
-distcleancheck:
- @:
-
$(BITCOIN_WIN_INSTALLER): all-recursive
$(MKDIR_P) $(top_builddir)/release
STRIPPROG="$(STRIP)" $(INSTALL_STRIP_PROGRAM) $(BITCOIND_BIN) $(top_builddir)/release
@@ -88,9 +100,9 @@ $(OSX_APP)/Contents/Resources/bitcoin.icns: $(OSX_INSTALLER_ICONS)
$(MKDIR_P) $(@D)
$(INSTALL_DATA) $< $@
-$(OSX_APP)/Contents/MacOS/DAPScoin-Qt: $(BITCOIN_QT_BIN)
+$(OSX_APP)/Contents/MacOS/PRCYcoin-Qt: all-recursive
$(MKDIR_P) $(@D)
- STRIPPROG="$(STRIP)" $(INSTALL_STRIP_PROGRAM) $< $@
+ STRIPPROG="$(STRIP)" $(INSTALL_STRIP_PROGRAM) $(BITCOIN_QT_BIN) $@
$(OSX_APP)/Contents/Resources/Base.lproj/InfoPlist.strings:
$(MKDIR_P) $(@D)
@@ -98,54 +110,29 @@ $(OSX_APP)/Contents/Resources/Base.lproj/InfoPlist.strings:
OSX_APP_BUILT=$(OSX_APP)/Contents/PkgInfo $(OSX_APP)/Contents/Resources/empty.lproj \
$(OSX_APP)/Contents/Resources/bitcoin.icns $(OSX_APP)/Contents/Info.plist \
- $(OSX_APP)/Contents/MacOS/DAPScoin-Qt $(OSX_APP)/Contents/Resources/Base.lproj/InfoPlist.strings
+ $(OSX_APP)/Contents/MacOS/PRCYcoin-Qt $(OSX_APP)/Contents/Resources/Base.lproj/InfoPlist.strings
osx_volname:
echo $(OSX_VOLNAME) >$@
if BUILD_DARWIN
-$(OSX_DMG): $(OSX_APP_BUILT) $(OSX_PACKAGING) $(OSX_BACKGROUND_IMAGE)
- $(PYTHON) $(OSX_DEPLOY_SCRIPT) $(OSX_APP) -add-qt-tr $(OSX_QT_TRANSLATIONS) -translations-dir=$(QT_TRANSLATION_DIR) -dmg -fancy $(OSX_FANCY_PLIST) -verbose 2 -volname $(OSX_VOLNAME)
-
-$(OSX_BACKGROUND_IMAGE).png: contrib/macdeploy/$(OSX_BACKGROUND_SVG)
- sed 's/PACKAGE_NAME/$(PACKAGE_NAME)/' < "$<" | $(RSVG_CONVERT) -f png -d 36 -p 36 -o $@
-$(OSX_BACKGROUND_IMAGE)@2x.png: contrib/macdeploy/$(OSX_BACKGROUND_SVG)
- sed 's/PACKAGE_NAME/$(PACKAGE_NAME)/' < "$<" | $(RSVG_CONVERT) -f png -d 72 -p 72 -o $@
-$(OSX_BACKGROUND_IMAGE): $(OSX_BACKGROUND_IMAGE).png $(OSX_BACKGROUND_IMAGE)@2x.png
- tiffutil -cathidpicheck $^ -out $@
+$(OSX_DMG): $(OSX_APP_BUILT) $(OSX_PACKAGING)
+ $(PYTHON) $(OSX_DEPLOY_SCRIPT) $(OSX_APP) $(OSX_VOLNAME) -translations-dir=$(QT_TRANSLATION_DIR) -dmg
deploydir: $(OSX_DMG)
else
APP_DIST_DIR=$(top_builddir)/dist
-APP_DIST_EXTRAS=$(APP_DIST_DIR)/.background/$(OSX_BACKGROUND_IMAGE) $(APP_DIST_DIR)/.DS_Store $(APP_DIST_DIR)/Applications
-
-$(APP_DIST_DIR)/Applications:
- @rm -f $@
- @cd $(@D); $(LN_S) /Applications $(@F)
-
-$(APP_DIST_EXTRAS): $(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/DAPScoin-Qt
-
-$(OSX_DMG): $(APP_DIST_EXTRAS)
- $(GENISOIMAGE) -no-cache-inodes -D -l -probe -V "$(OSX_VOLNAME)" -no-pad -r -dir-mode 0755 -apple -o $@ dist
-dpi%.$(OSX_BACKGROUND_IMAGE): contrib/macdeploy/$(OSX_BACKGROUND_SVG)
- sed 's/PACKAGE_NAME/$(PACKAGE_NAME)/' < "$<" | $(RSVG_CONVERT) -f png -d $* -p $* | $(IMAGEMAGICK_CONVERT) - $@
-OSX_BACKGROUND_IMAGE_DPIFILES := $(foreach dpi,$(OSX_BACKGROUND_IMAGE_DPIS),dpi$(dpi).$(OSX_BACKGROUND_IMAGE))
-$(APP_DIST_DIR)/.background/$(OSX_BACKGROUND_IMAGE): $(OSX_BACKGROUND_IMAGE_DPIFILES)
- $(MKDIR_P) $(@D)
- $(TIFFCP) -c none $(OSX_BACKGROUND_IMAGE_DPIFILES) $@
-
-$(APP_DIST_DIR)/.DS_Store: $(OSX_DSSTORE_GEN)
- $(PYTHON) $< "$@" "$(OSX_VOLNAME)"
+$(OSX_DMG): deploydir
+ $(XORRISOFS) -D -l -V "$(OSX_VOLNAME)" -no-pad -r -dir-mode 0755 -o $@ dist -- $(if $(SOURCE_DATE_EPOCH),-volume_date all_file_dates =$(SOURCE_DATE_EPOCH))
-$(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/DAPScoin-Qt: $(OSX_APP_BUILT) $(OSX_PACKAGING)
- INSTALLNAMETOOL=$(INSTALLNAMETOOL) OTOOL=$(OTOOL) STRIP=$(STRIP) $(PYTHON) $(OSX_DEPLOY_SCRIPT) $(OSX_APP) -translations-dir=$(QT_TRANSLATION_DIR) -add-qt-tr $(OSX_QT_TRANSLATIONS) -verbose 2
+$(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/PRCYcoin-Qt: $(OSX_APP_BUILT) $(OSX_PACKAGING)
+ INSTALL_NAME_TOOL=$(INSTALL_NAME_TOOL) OTOOL=$(OTOOL) STRIP=$(STRIP) $(PYTHON) $(OSX_DEPLOY_SCRIPT) $(OSX_APP) $(OSX_VOLNAME) -translations-dir=$(QT_TRANSLATION_DIR)
-deploydir: $(APP_DIST_EXTRAS)
+deploydir: $(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/PRCYcoin-Qt
endif
if TARGET_DARWIN
-appbundle: $(OSX_APP_BUILT)
deploy: $(OSX_DMG)
endif
if TARGET_WINDOWS
@@ -165,66 +152,102 @@ $(BITCOIN_TX_BIN): FORCE
$(MAKE) -C src $(@F)
if USE_LCOV
+LCOV_FILTER_PATTERN=-p "/usr/include/" -p "/usr/lib/" -p "src/leveldb/" -p "src/crc32c/" -p "src/univalue" -p "src/secp256k1" -p "src/secp256k1-mw"
baseline.info:
$(LCOV) -c -i -d $(abs_builddir)/src -o $@
baseline_filtered.info: baseline.info
- $(LCOV) -r $< "/usr/include/*" -o $@
-
-leveldb_baseline.info: baseline_filtered.info
- $(LCOV) -c -i -d $(abs_builddir)/src/leveldb -b $(abs_builddir)/src/leveldb -o $@
+ $(abs_builddir)/contrib/filter-lcov.py $(LCOV_FILTER_PATTERN) $< $@
+ $(LCOV) -a $@ $(LCOV_OPTS) -o $@
-leveldb_baseline_filtered.info: leveldb_baseline.info
- $(LCOV) -r $< "/usr/include/*" -o $@
-
-baseline_filtered_combined.info: leveldb_baseline_filtered.info baseline_filtered.info
- $(LCOV) -a leveldb_baseline_filtered.info -a baseline_filtered.info -o $@
-
-test_dapscoin.info: baseline_filtered_combined.info
+test_prcycoin.info: baseline_filtered.info
$(MAKE) -C src/ check
- $(LCOV) -c -d $(abs_builddir)/src -t test_dapscoin -o $@
- $(LCOV) -z -d $(abs_builddir)/src
- $(LCOV) -z -d $(abs_builddir)/src/leveldb
+ $(LCOV) -c $(LCOV_OPTS) -d $(abs_builddir)/src -t test_prcycoin -o $@
+ $(LCOV) -z $(LCOV_OPTS) -d $(abs_builddir)/src
-test_dapscoin_filtered.info: test_dapscoin.info
- $(LCOV) -r $< "/usr/include/*" -o $@
+test_prcycoin_filtered.info: test_prcycoin.info
+ $(abs_builddir)/contrib/filter-lcov.py $(LCOV_FILTER_PATTERN) $< $@
+ $(LCOV) -a $@ $(LCOV_OPTS) -o $@
-block_test.info: test_dapscoin_filtered.info
- $(MKDIR_P) qa/tmp
- -@TIMEOUT=15 qa/pull-tester/run-bitcoind-for-test.sh $(JAVA) -jar $(JAVA_COMPARISON_TOOL) qa/tmp/compTool 0
- $(LCOV) -c -d $(abs_builddir)/src --t BitcoinJBlockTest -o $@
- $(LCOV) -z -d $(abs_builddir)/src
- $(LCOV) -z -d $(abs_builddir)/src/leveldb
+functional_test.info: test_prcycoin_filtered.info
+ -@TIMEOUT=15 test/functional/test_runner.py $(EXTENDED_FUNCTIONAL_TESTS)
+ $(LCOV) -c $(LCOV_OPTS) -d $(abs_builddir)/src --t functional-tests -o $@
+ $(LCOV) -z $(LCOV_OPTS) -d $(abs_builddir)/src
-block_test_filtered.info: block_test.info
- $(LCOV) -r $< "/usr/include/*" -o $@
+functional_test_filtered.info: functional_test.info
+ $(abs_builddir)/contrib/filter-lcov.py $(LCOV_FILTER_PATTERN) $< $@
+ $(LCOV) -a $@ $(LCOV_OPTS) -o $@
-test_dapscoin_coverage.info: baseline_filtered_combined.info test_dapscoin_filtered.info
- $(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_dapscoin_filtered.info -o $@
+test_prcycoin_coverage.info: baseline_filtered.info test_prcycoin_filtered.info
+ $(LCOV) -a $(LCOV_OPTS) baseline_filtered.info -a test_prcycoin_filtered.info -o $@
-total_coverage.info: baseline_filtered_combined.info test_dapscoin_filtered.info block_test_filtered.info
- $(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_dapscoin_filtered.info -a block_test_filtered.info -o $@ | $(GREP) "\%" | $(AWK) '{ print substr($$3,2,50) "/" $$5 }' > coverage_percent.txt
+total_coverage.info: test_prcycoin_filtered.info functional_test_filtered.info
+ $(LCOV) -a $(LCOV_OPTS) baseline_filtered.info -a test_prcycoin_filtered.info -a functional_test_filtered.info -o $@ | $(GREP) "\%" | $(AWK) '{ print substr($$3,2,50) "/" $$5 }' > coverage_percent.txt
-test_dapscoin.coverage/.dirstamp: test_dapscoin_coverage.info
- $(GENHTML) -s $< -o $(@D)
+test_prcycoin.coverage/.dirstamp: test_prcycoin_coverage.info
+ $(GENHTML) -s $(LCOV_OPTS) $< -o $(@D)
@touch $@
total.coverage/.dirstamp: total_coverage.info
- $(GENHTML) -s $< -o $(@D)
+ $(GENHTML) -s $(LCOV_OPTS) $< -o $(@D)
@touch $@
-cov: test_dapscoin.coverage/.dirstamp total.coverage/.dirstamp
+cov: test_prcycoin.coverage/.dirstamp total.coverage/.dirstamp
endif
dist_noinst_SCRIPTS = autogen.sh
-EXTRA_DIST = $(top_srcdir)/share/genbuild.sh qa/pull-tester/rpc-tests.sh qa/pull-tester/run-bitcoin-cli qa/rpc-tests $(DIST_DOCS) $(WINDOWS_PACKAGING) $(OSX_PACKAGING)
+EXTRA_DIST = $(DIST_SHARE) test/functional/test_runner.py test/functional $(DIST_CONTRIB) $(DIST_DOCS) $(WINDOWS_PACKAGING) $(LINUX_PACKAGING) $(OSX_PACKAGING) $(BIN_CHECKS)
+
+#EXTRA_DIST += \
+ #test/functional
+
+EXTRA_DIST += \
+ test/util/bitcoin-util-test.py \
+ test/util/data/bitcoin-util-test.json \
+ test/util/data/blanktxv1.hex \
+ test/util/data/blanktxv1.json \
+ test/util/data/tt-delin1-out.hex \
+ test/util/data/tt-delin1-out.json \
+ test/util/data/tt-delout1-out.hex \
+ test/util/data/tt-delout1-out.json \
+ test/util/data/tt-locktime317000-out.hex \
+ test/util/data/tt-locktime317000-out.json \
+ test/util/data/tx394b54bb.hex \
+ test/util/data/txcreate1.hex \
+ test/util/data/txcreate1.json \
+ test/util/data/txcreate2.hex \
+ test/util/data/txcreate2.json \
+ test/util/data/txcreatescript1.hex \
+ test/util/data/txcreatescript1.json \
+ test/util/data/txcreatesign.hex \
+ test/util/data/txcreatesign.json \
+ test/util/rpcauth-test.py
CLEANFILES = $(OSX_DMG) $(BITCOIN_WIN_INSTALLER)
.INTERMEDIATE: $(COVERAGE_INFO)
-clean-local:
- rm -rf test_dapscoin.coverage/ total.coverage/ $(OSX_APP)
+DISTCHECK_CONFIGURE_FLAGS = --enable-man
+
+doc/doxygen/.stamp: doc/Doxyfile FORCE
+ $(MKDIR_P) $(@D)
+ $(DOXYGEN) $^
+ $(AM_V_at) touch $@
+
+if HAVE_DOXYGEN
+docs: doc/doxygen/.stamp
+else
+docs:
+ @echo "error: doxygen not found"
+endif
+
+clean-docs:
+ rm -rf doc/doxygen
+
+clean-local: clean-docs
+ rm -rf coverage_percent.txt test_prcycoin.coverage/ total.coverage/ test/tmp/ cache/ $(OSX_APP)
+ rm -rf test/functional/__pycache__ test/functional/test_framework/__pycache__ test/cache share/rpcauth/__pycache__
+ rm -rf osx_volname dist/
diff --git a/Makefile1 b/Makefile1
deleted file mode 100644
index 65563e5369..0000000000
--- a/Makefile1
+++ /dev/null
@@ -1,1178 +0,0 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
-# Makefile. Generated from Makefile.in by configure.
-
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
-
-# This Makefile.in is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-
-
-# Copyright (c) 2013-2016 The Bitcoin Core developers
-# Distributed under the MIT software license, see the accompanying
-# file COPYING or http://www.opensource.org/licenses/mit-license.php.
-
-
-am__is_gnu_make = { \
- if test -z '$(MAKELEVEL)'; then \
- false; \
- elif test -n '$(MAKE_HOST)'; then \
- true; \
- elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
- true; \
- else \
- false; \
- fi; \
-}
-am__make_running_with_option = \
- case $${target_option-} in \
- ?) ;; \
- *) echo "am__make_running_with_option: internal error: invalid" \
- "target option '$${target_option-}' specified" >&2; \
- exit 1;; \
- esac; \
- has_opt=no; \
- sane_makeflags=$$MAKEFLAGS; \
- if $(am__is_gnu_make); then \
- sane_makeflags=$$MFLAGS; \
- else \
- case $$MAKEFLAGS in \
- *\\[\ \ ]*) \
- bs=\\; \
- sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
- | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
- esac; \
- fi; \
- skip_next=no; \
- strip_trailopt () \
- { \
- flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
- }; \
- for flg in $$sane_makeflags; do \
- test $$skip_next = yes && { skip_next=no; continue; }; \
- case $$flg in \
- *=*|--*) continue;; \
- -*I) strip_trailopt 'I'; skip_next=yes;; \
- -*I?*) strip_trailopt 'I';; \
- -*O) strip_trailopt 'O'; skip_next=yes;; \
- -*O?*) strip_trailopt 'O';; \
- -*l) strip_trailopt 'l'; skip_next=yes;; \
- -*l?*) strip_trailopt 'l';; \
- -[dEDm]) skip_next=yes;; \
- -[JT]) skip_next=yes;; \
- esac; \
- case $$flg in \
- *$$target_option*) has_opt=yes; break;; \
- esac; \
- done; \
- test $$has_opt = yes
-am__make_dryrun = (target_option=n; $(am__make_running_with_option))
-am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
-pkgdatadir = $(datadir)/dapscoin
-pkgincludedir = $(includedir)/dapscoin
-pkglibdir = $(libdir)/dapscoin
-pkglibexecdir = $(libexecdir)/dapscoin
-am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
-install_sh_DATA = $(install_sh) -c -m 644
-install_sh_PROGRAM = $(install_sh) -c
-install_sh_SCRIPT = $(install_sh) -c
-INSTALL_HEADER = $(INSTALL_DATA)
-transform = $(program_transform_name)
-NORMAL_INSTALL = :
-PRE_INSTALL = :
-POST_INSTALL = :
-NORMAL_UNINSTALL = :
-PRE_UNINSTALL = :
-POST_UNINSTALL = :
-build_triplet = x86_64-pc-linux-gnu
-host_triplet = x86_64-pc-linux-gnu
-subdir = .
-ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
-am__aclocal_m4_deps = $(top_srcdir)/build-aux/m4/ax_boost_base.m4 \
- $(top_srcdir)/build-aux/m4/ax_boost_chrono.m4 \
- $(top_srcdir)/build-aux/m4/ax_boost_filesystem.m4 \
- $(top_srcdir)/build-aux/m4/ax_boost_program_options.m4 \
- $(top_srcdir)/build-aux/m4/ax_boost_system.m4 \
- $(top_srcdir)/build-aux/m4/ax_boost_thread.m4 \
- $(top_srcdir)/build-aux/m4/ax_boost_unit_test_framework.m4 \
- $(top_srcdir)/build-aux/m4/ax_check_compile_flag.m4 \
- $(top_srcdir)/build-aux/m4/ax_check_link_flag.m4 \
- $(top_srcdir)/build-aux/m4/ax_check_preproc_flag.m4 \
- $(top_srcdir)/build-aux/m4/ax_cxx_compile_stdcxx.m4 \
- $(top_srcdir)/build-aux/m4/ax_gcc_func_attribute.m4 \
- $(top_srcdir)/build-aux/m4/ax_pthread.m4 \
- $(top_srcdir)/build-aux/m4/bitcoin_find_bdb48.m4 \
- $(top_srcdir)/build-aux/m4/bitcoin_qt.m4 \
- $(top_srcdir)/build-aux/m4/bitcoin_subdir_to_include.m4 \
- $(top_srcdir)/build-aux/m4/libtool.m4 \
- $(top_srcdir)/build-aux/m4/ltoptions.m4 \
- $(top_srcdir)/build-aux/m4/ltsugar.m4 \
- $(top_srcdir)/build-aux/m4/ltversion.m4 \
- $(top_srcdir)/build-aux/m4/lt~obsolete.m4 \
- $(top_srcdir)/configure.ac
-am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
- $(ACLOCAL_M4)
-DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \
- $(am__configure_deps) $(dist_noinst_SCRIPTS) \
- $(am__DIST_COMMON)
-am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
- configure.lineno config.status.lineno
-mkinstalldirs = $(install_sh) -d
-CONFIG_HEADER = $(top_builddir)/src/config/dapscoin-config.h
-CONFIG_CLEAN_FILES = share/setup.nsi share/qt/Info.plist \
- src/test/buildenv.py qa/pull-tester/run-bitcoind-for-test.sh \
- qa/pull-tester/tests-config.sh contrib/devtools/split-debug.sh
-CONFIG_CLEAN_VPATH_FILES =
-SCRIPTS = $(dist_noinst_SCRIPTS)
-AM_V_P = $(am__v_P_$(V))
-am__v_P_ = $(am__v_P_$(AM_DEFAULT_VERBOSITY))
-am__v_P_0 = false
-am__v_P_1 = :
-AM_V_GEN = $(am__v_GEN_$(V))
-am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
-am__v_GEN_0 = @echo " GEN " $@;
-am__v_GEN_1 =
-AM_V_at = $(am__v_at_$(V))
-am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
-am__v_at_0 = @
-am__v_at_1 =
-SOURCES =
-DIST_SOURCES =
-RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
- ctags-recursive dvi-recursive html-recursive info-recursive \
- install-data-recursive install-dvi-recursive \
- install-exec-recursive install-html-recursive \
- install-info-recursive install-pdf-recursive \
- install-ps-recursive install-recursive installcheck-recursive \
- installdirs-recursive pdf-recursive ps-recursive \
- tags-recursive uninstall-recursive
-am__can_run_installinfo = \
- case $$AM_UPDATE_INFO_DIR in \
- n|no|NO) false;; \
- *) (install-info --version) >/dev/null 2>&1;; \
- esac
-RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
- distclean-recursive maintainer-clean-recursive
-am__recursive_targets = \
- $(RECURSIVE_TARGETS) \
- $(RECURSIVE_CLEAN_TARGETS) \
- $(am__extra_recursive_targets)
-AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
- cscope distdir dist dist-all distcheck
-am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
-# Read a list of newline-separated strings from the standard input,
-# and print each of them once, without duplicates. Input order is
-# *not* preserved.
-am__uniquify_input = $(AWK) '\
- BEGIN { nonempty = 0; } \
- { items[$$0] = 1; nonempty = 1; } \
- END { if (nonempty) { for (i in items) print i; }; } \
-'
-# Make sure the list of sources is unique. This is necessary because,
-# e.g., the same source file might be shared among _SOURCES variables
-# for different programs/libraries.
-am__define_uniq_tagged_files = \
- list='$(am__tagged_files)'; \
- unique=`for i in $$list; do \
- if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
- done | $(am__uniquify_input)`
-ETAGS = etags
-CTAGS = ctags
-CSCOPE = cscope
-DIST_SUBDIRS = $(SUBDIRS)
-am__DIST_COMMON = $(srcdir)/Makefile.in \
- $(top_srcdir)/build-aux/compile \
- $(top_srcdir)/build-aux/config.guess \
- $(top_srcdir)/build-aux/config.sub \
- $(top_srcdir)/build-aux/install-sh \
- $(top_srcdir)/build-aux/ltmain.sh \
- $(top_srcdir)/build-aux/missing \
- $(top_srcdir)/contrib/devtools/split-debug.sh.in \
- $(top_srcdir)/qa/pull-tester/run-bitcoind-for-test.sh.in \
- $(top_srcdir)/qa/pull-tester/tests-config.sh.in \
- $(top_srcdir)/share/qt/Info.plist.in \
- $(top_srcdir)/share/setup.nsi.in \
- $(top_srcdir)/src/config/dapscoin-config.h.in \
- $(top_srcdir)/src/test/buildenv.py.in COPYING INSTALL \
- build-aux/compile build-aux/config.guess build-aux/config.sub \
- build-aux/depcomp build-aux/install-sh build-aux/ltmain.sh \
- build-aux/missing
-DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
-distdir = $(PACKAGE)-$(VERSION)
-top_distdir = $(distdir)
-am__remove_distdir = \
- if test -d "$(distdir)"; then \
- find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \
- && rm -rf "$(distdir)" \
- || { sleep 5 && rm -rf "$(distdir)"; }; \
- else :; fi
-am__post_remove_distdir = $(am__remove_distdir)
-am__relativize = \
- dir0=`pwd`; \
- sed_first='s,^\([^/]*\)/.*$$,\1,'; \
- sed_rest='s,^[^/]*/*,,'; \
- sed_last='s,^.*/\([^/]*\)$$,\1,'; \
- sed_butlast='s,/*[^/]*$$,,'; \
- while test -n "$$dir1"; do \
- first=`echo "$$dir1" | sed -e "$$sed_first"`; \
- if test "$$first" != "."; then \
- if test "$$first" = ".."; then \
- dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
- dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
- else \
- first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
- if test "$$first2" = "$$first"; then \
- dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
- else \
- dir2="../$$dir2"; \
- fi; \
- dir0="$$dir0"/"$$first"; \
- fi; \
- fi; \
- dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
- done; \
- reldir="$$dir2"
-DIST_ARCHIVES = $(distdir).tar.gz
-DIST_TARGETS = dist-gzip
-distuninstallcheck_listfiles = find . -type f -print
-am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \
- | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$'
-distcleancheck_listfiles = find . -type f -print
-ACLOCAL = ${SHELL} /home/dapscoin/DAPS/build-aux/missing aclocal-1.15
-AMTAR = $${TAR-tar}
-AM_DEFAULT_VERBOSITY = 0
-AR = /usr/bin/ar
-AUTOCONF = ${SHELL} /home/dapscoin/DAPS/build-aux/missing autoconf
-AUTOHEADER = ${SHELL} /home/dapscoin/DAPS/build-aux/missing autoheader
-AUTOMAKE = ${SHELL} /home/dapscoin/DAPS/build-aux/missing automake-1.15
-AWK = gawk
-BDB_CPPFLAGS =
-BDB_LIBS = -ldb_cxx-4.8
-BITCOIN_CLI_NAME = dapscoin-cli
-BITCOIN_DAEMON_NAME = dapscoind
-BITCOIN_GUI_NAME = dapscoin-qt
-BITCOIN_TX_NAME = dapscoin-tx
-BOOST_CHRONO_LIB = -lboost_chrono
-BOOST_CPPFLAGS = -pthread -I/usr/include
-BOOST_FILESYSTEM_LIB = -lboost_filesystem
-BOOST_LDFLAGS = -L/usr/lib/x86_64-linux-gnu
-BOOST_LIBS = -L/usr/lib/x86_64-linux-gnu -lboost_system -lboost_filesystem -lboost_program_options -lboost_thread -lboost_chrono
-BOOST_PROGRAM_OPTIONS_LIB = -lboost_program_options
-BOOST_SYSTEM_LIB = -lboost_system
-BOOST_THREAD_LIB = -lboost_thread
-BOOST_UNIT_TEST_FRAMEWORK_LIB = -lboost_unit_test_framework
-BREW =
-BUILD_QT =
-BUILD_TEST = test
-BUILD_TEST_QT =
-CC = gcc
-CCACHE =
-CCDEPMODE = depmode=gcc3
-CFLAGS = -g -O2
-CLIENT_VERSION_BUILD = 0
-CLIENT_VERSION_IS_RELEASE = true
-CLIENT_VERSION_MAJOR = 3
-CLIENT_VERSION_MINOR = 0
-CLIENT_VERSION_REVISION = 6
-COMPARISON_TOOL_REORG_TESTS = 0
-COPYRIGHT_YEAR = 2017
-CPP = gcc -E
-CPPFILT = /usr/bin/c++filt
-CPPFLAGS = -DBOOST_SPIRIT_THREADSAFE -DHAVE_BUILD_INFO -D__STDC_FORMAT_MACROS -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2
-CRYPTO_CFLAGS =
-CRYPTO_LIBS = -lcrypto
-CXX = g++ -std=c++11
-CXXCPP = g++ -std=c++11 -E
-CXXDEPMODE = depmode=gcc3
-CXXFLAGS = -g -O2 -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameter -Wstack-protector -fstack-protector-all -fPIC -fvisibility=hidden
-CYGPATH_W = echo
-DEFS = -DHAVE_CONFIG_H
-DEPDIR = .deps
-DLLTOOL = false
-DSYMUTIL =
-DUMPBIN =
-ECHO_C =
-ECHO_N = -n
-ECHO_T =
-EGREP = /bin/grep -E
-EVENT_CFLAGS =
-EVENT_LIBS = -levent
-EVENT_PTHREADS_CFLAGS = -pthread
-EVENT_PTHREADS_LIBS = -levent_pthreads -levent
-EXEEXT =
-FGREP = /bin/grep -F
-GCOV = /usr/bin/gcov
-GENHTML =
-GENISOIMAGE =
-GIT = /usr/bin/git
-GREP = /bin/grep
-HAVE_CXX11 = 1
-HEXDUMP = /usr/bin/hexdump
-IMAGEMAGICK_CONVERT =
-INSTALL = /usr/bin/install -c
-INSTALLNAMETOOL =
-INSTALL_DATA = ${INSTALL} -m 644
-INSTALL_PROGRAM = ${INSTALL}
-INSTALL_SCRIPT = ${INSTALL}
-INSTALL_STRIP_PROGRAM = $(install_sh) -c -s
-JAVA =
-JAVA_COMPARISON_TOOL =
-LCOV =
-LD = /usr/bin/ld -m elf_x86_64
-LDFLAGS = -L/usr/local/lib -lsecp256k1_2 -static -Wl,-z,relro -Wl,-z,now
-LEVELDB_CPPFLAGS =
-LEVELDB_TARGET_FLAGS =
-LIBLEVELDB =
-LIBMEMENV =
-LIBOBJS =
-LIBS =
-LIBTOOL = $(SHELL) $(top_builddir)/libtool
-LIBTOOL_APP_LDFLAGS =
-LIPO =
-LN_S = ln -s
-LRELEASE =
-LTLIBOBJS =
-LT_SYS_LIBRARY_PATH =
-LUPDATE =
-MAINT =
-MAKEINFO = ${SHELL} /home/dapscoin/DAPS/build-aux/missing makeinfo
-MAKENSIS =
-MANIFEST_TOOL = :
-MINIUPNPC_CPPFLAGS =
-MINIUPNPC_LIBS = -lminiupnpc
-MKDIR_P = /bin/mkdir -p
-MOC =
-MOC_DEFS = -DHAVE_CONFIG_H -I$(srcdir)
-NM = /usr/bin/nm -B
-NMEDIT =
-OBJCOPY = /usr/bin/objcopy
-OBJCXX = g++ -std=c++11
-OBJCXXDEPMODE = depmode=gcc3
-OBJCXXFLAGS = -g -O2 -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameter -Wstack-protector -fstack-protector-all -fPIC
-OBJDUMP = objdump
-OBJEXT = o
-OTOOL =
-OTOOL64 =
-PACKAGE = dapscoin
-PACKAGE_BUGREPORT = www.dapscoin.org
-PACKAGE_NAME = Dapscoin Core
-PACKAGE_STRING = Dapscoin Core 3.0.6
-PACKAGE_TARNAME = dapscoin
-PACKAGE_URL =
-PACKAGE_VERSION = 3.0.6
-PATH_SEPARATOR = :
-PKG_CONFIG = /usr/bin/pkg-config
-PKG_CONFIG_LIBDIR =
-PKG_CONFIG_PATH =
-PORT =
-PROTOBUF_CFLAGS =
-PROTOBUF_LIBS =
-PROTOC =
-PTHREAD_CC = gcc
-PTHREAD_CFLAGS = -pthread
-PTHREAD_LIBS =
-PYTHON = /usr/bin/python3
-PYTHONPATH =
-QR_CFLAGS =
-QR_LIBS =
-QTPLATFORM_CFLAGS =
-QTPLATFORM_LIBS =
-QTPRINT_CFLAGS =
-QTPRINT_LIBS =
-QTXCBQPA_CFLAGS =
-QTXCBQPA_LIBS =
-QT_CFLAGS =
-QT_DBUS_CFLAGS =
-QT_DBUS_INCLUDES =
-QT_DBUS_LIBS =
-QT_INCLUDES =
-QT_LDFLAGS =
-QT_LIBS =
-QT_PIE_FLAGS =
-QT_SELECT = qt5
-QT_TEST_CFLAGS =
-QT_TEST_INCLUDES =
-QT_TEST_LIBS =
-QT_TRANSLATION_DIR =
-RANLIB = /usr/bin/ranlib
-RCC =
-READELF = /usr/bin/readelf
-RELDFLAGS = -Wl,--exclude-libs,ALL
-RSVG_CONVERT =
-SED = /bin/sed
-SET_MAKE =
-SHELL = /bin/bash
-SSL_CFLAGS =
-SSL_LIBS = -lssl
-STRIP = /usr/bin/strip
-TESTDEFS =
-TIFFCP =
-UIC =
-USE_QRCODE =
-USE_UPNP =
-VERSION = 3.0.6
-WINDOWS_BITS =
-WINDRES =
-X11XCB_CFLAGS =
-X11XCB_LIBS =
-XGETTEXT =
-ZMQ_CFLAGS =
-ZMQ_LIBS = -lzmq
-abs_builddir = /home/dapscoin/DAPS
-abs_srcdir = /home/dapscoin/DAPS
-abs_top_builddir = /home/dapscoin/DAPS
-abs_top_srcdir = /home/dapscoin/DAPS
-ac_ct_AR = ar
-ac_ct_CC = gcc
-ac_ct_CXX = g++
-ac_ct_DUMPBIN =
-ac_ct_OBJCXX =
-am__include = include
-am__leading_dot = .
-am__quote =
-am__tar = $${TAR-tar} chof - "$$tardir"
-am__untar = $${TAR-tar} xf -
-ax_pthread_config =
-bindir = ${exec_prefix}/bin
-build = x86_64-pc-linux-gnu
-build_alias =
-build_cpu = x86_64
-build_os = linux-gnu
-build_vendor = pc
-builddir = .
-datadir = ${datarootdir}
-datarootdir = ${prefix}/share
-docdir = ${datarootdir}/doc/${PACKAGE_TARNAME}
-dvidir = ${docdir}
-exec_prefix = ${prefix}
-host = x86_64-pc-linux-gnu
-host_alias =
-host_cpu = x86_64
-host_os = linux-gnu
-host_vendor = pc
-htmldir = ${docdir}
-includedir = ${prefix}/include
-infodir = ${datarootdir}/info
-install_sh = ${SHELL} /home/dapscoin/DAPS/build-aux/install-sh
-libdir = ${exec_prefix}/lib
-libexecdir = ${exec_prefix}/libexec
-localedir = ${datarootdir}/locale
-localstatedir = ${prefix}/var
-mandir = ${datarootdir}/man
-mkdir_p = $(MKDIR_P)
-oldincludedir = /usr/include
-pdfdir = ${docdir}
-prefix = /usr/local
-program_transform_name = s,x,x,
-psdir = ${docdir}
-runstatedir = ${localstatedir}/run
-sbindir = ${exec_prefix}/sbin
-sharedstatedir = ${prefix}/com
-srcdir = .
-subdirs = src/secp256k1 src/secp256k1-mw
-sysconfdir = ${prefix}/etc
-target_alias =
-top_build_prefix =
-top_builddir = .
-top_srcdir = .
-ACLOCAL_AMFLAGS = -I build-aux/m4
-SUBDIRS = src
-GZIP_ENV = "-9n"
-BITCOIND_BIN = $(top_builddir)/src/$(BITCOIN_DAEMON_NAME)$(EXEEXT)
-BITCOIN_QT_BIN = $(top_builddir)/src/qt/$(BITCOIN_GUI_NAME)$(EXEEXT)
-BITCOIN_CLI_BIN = $(top_builddir)/src/$(BITCOIN_CLI_NAME)$(EXEEXT)
-BITCOIN_WIN_INSTALLER = $(PACKAGE)-$(PACKAGE_VERSION)-win$(WINDOWS_BITS)-setup$(EXEEXT)
-empty :=
-space := $(empty) $(empty)
-OSX_APP = DAPScoin-Qt.app
-OSX_VOLNAME = $(subst $(space),-,$(PACKAGE_NAME))
-OSX_DMG = $(OSX_VOLNAME).dmg
-OSX_BACKGROUND_SVG = background.svg
-OSX_BACKGROUND_IMAGE = background.tiff
-OSX_BACKGROUND_IMAGE_DPIS = 36 72
-OSX_DSSTORE_GEN = $(top_srcdir)/contrib/macdeploy/custom_dsstore.py
-OSX_DEPLOY_SCRIPT = $(top_srcdir)/contrib/macdeploy/macdeployqtplus
-OSX_FANCY_PLIST = $(top_srcdir)/contrib/macdeploy/fancy.plist
-OSX_INSTALLER_ICONS = $(top_srcdir)/src/qt/res/icons/bitcoin.icns
-OSX_PLIST = $(top_builddir)/share/qt/Info.plist #not installed
-OSX_QT_TRANSLATIONS = da,de,es,hu,ru,uk,zh_CN,zh_TW
-DIST_DOCS = $(wildcard doc/*.md) $(wildcard doc/release-notes/*.md)
-WINDOWS_PACKAGING = $(top_srcdir)/share/pixmaps/bitcoin.ico \
- $(top_srcdir)/share/pixmaps/nsis-header.bmp \
- $(top_srcdir)/share/pixmaps/nsis-wizard.bmp \
- $(top_srcdir)/doc/README_windows.txt
-
-OSX_PACKAGING = $(OSX_DEPLOY_SCRIPT) $(OSX_FANCY_PLIST) $(OSX_INSTALLER_ICONS) \
- $(top_srcdir)/contrib/macdeploy/$(OSX_BACKGROUND_SVG) \
- $(OSX_DSSTORE_GEN) \
- $(top_srcdir)/contrib/macdeploy/detached-sig-apply.sh \
- $(top_srcdir)/contrib/macdeploy/detached-sig-create.sh
-
-COVERAGE_INFO = baseline_filtered_combined.info baseline.info block_test.info \
- leveldb_baseline.info test_dapscoin_filtered.info total_coverage.info \
- baseline_filtered.info block_test_filtered.info \
- leveldb_baseline_filtered.info test_dapscoin_coverage.info test_dapscoin.info
-
-OSX_APP_BUILT = $(OSX_APP)/Contents/PkgInfo $(OSX_APP)/Contents/Resources/empty.lproj \
- $(OSX_APP)/Contents/Resources/bitcoin.icns $(OSX_APP)/Contents/Info.plist \
- $(OSX_APP)/Contents/MacOS/DAPScoin-Qt $(OSX_APP)/Contents/Resources/Base.lproj/InfoPlist.strings
-
-APP_DIST_DIR = $(top_builddir)/dist
-APP_DIST_EXTRAS = $(APP_DIST_DIR)/.background/$(OSX_BACKGROUND_IMAGE) $(APP_DIST_DIR)/.DS_Store $(APP_DIST_DIR)/Applications
-OSX_BACKGROUND_IMAGE_DPIFILES := $(foreach dpi,$(OSX_BACKGROUND_IMAGE_DPIS),dpi$(dpi).$(OSX_BACKGROUND_IMAGE))
-dist_noinst_SCRIPTS = autogen.sh
-EXTRA_DIST = $(top_srcdir)/share/genbuild.sh qa/pull-tester/rpc-tests.sh qa/pull-tester/run-bitcoin-cli qa/rpc-tests $(DIST_DOCS) $(WINDOWS_PACKAGING) $(OSX_PACKAGING)
-CLEANFILES = $(OSX_DMG) $(BITCOIN_WIN_INSTALLER)
-all: all-recursive
-
-.SUFFIXES:
-am--refresh: Makefile
- @:
-$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
- @for dep in $?; do \
- case '$(am__configure_deps)' in \
- *$$dep*) \
- echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \
- $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \
- && exit 0; \
- exit 1;; \
- esac; \
- done; \
- echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \
- $(am__cd) $(top_srcdir) && \
- $(AUTOMAKE) --foreign Makefile
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
- @case '$?' in \
- *config.status*) \
- echo ' $(SHELL) ./config.status'; \
- $(SHELL) ./config.status;; \
- *) \
- echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \
- cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \
- esac;
-
-$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
- $(SHELL) ./config.status --recheck
-
-$(top_srcdir)/configure: $(am__configure_deps)
- $(am__cd) $(srcdir) && $(AUTOCONF)
-$(ACLOCAL_M4): $(am__aclocal_m4_deps)
- $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
-$(am__aclocal_m4_deps):
-
-src/config/dapscoin-config.h: src/config/stamp-h1
- @test -f $@ || rm -f src/config/stamp-h1
- @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) src/config/stamp-h1
-
-src/config/stamp-h1: $(top_srcdir)/src/config/dapscoin-config.h.in $(top_builddir)/config.status
- @rm -f src/config/stamp-h1
- cd $(top_builddir) && $(SHELL) ./config.status src/config/dapscoin-config.h
-$(top_srcdir)/src/config/dapscoin-config.h.in: $(am__configure_deps)
- ($(am__cd) $(top_srcdir) && $(AUTOHEADER))
- rm -f src/config/stamp-h1
- touch $@
-
-distclean-hdr:
- -rm -f src/config/dapscoin-config.h src/config/stamp-h1
-share/setup.nsi: $(top_builddir)/config.status $(top_srcdir)/share/setup.nsi.in
- cd $(top_builddir) && $(SHELL) ./config.status $@
-share/qt/Info.plist: $(top_builddir)/config.status $(top_srcdir)/share/qt/Info.plist.in
- cd $(top_builddir) && $(SHELL) ./config.status $@
-src/test/buildenv.py: $(top_builddir)/config.status $(top_srcdir)/src/test/buildenv.py.in
- cd $(top_builddir) && $(SHELL) ./config.status $@
-qa/pull-tester/run-bitcoind-for-test.sh: $(top_builddir)/config.status $(top_srcdir)/qa/pull-tester/run-bitcoind-for-test.sh.in
- cd $(top_builddir) && $(SHELL) ./config.status $@
-qa/pull-tester/tests-config.sh: $(top_builddir)/config.status $(top_srcdir)/qa/pull-tester/tests-config.sh.in
- cd $(top_builddir) && $(SHELL) ./config.status $@
-contrib/devtools/split-debug.sh: $(top_builddir)/config.status $(top_srcdir)/contrib/devtools/split-debug.sh.in
- cd $(top_builddir) && $(SHELL) ./config.status $@
-
-mostlyclean-libtool:
- -rm -f *.lo
-
-clean-libtool:
- -rm -rf .libs _libs
-
-distclean-libtool:
- -rm -f libtool config.lt
-
-# This directory's subdirectories are mostly independent; you can cd
-# into them and run 'make' without going through this Makefile.
-# To change the values of 'make' variables: instead of editing Makefiles,
-# (1) if the variable is set in 'config.status', edit 'config.status'
-# (which will cause the Makefiles to be regenerated when you run 'make');
-# (2) otherwise, pass the desired values on the 'make' command line.
-$(am__recursive_targets):
- @fail=; \
- if $(am__make_keepgoing); then \
- failcom='fail=yes'; \
- else \
- failcom='exit 1'; \
- fi; \
- dot_seen=no; \
- target=`echo $@ | sed s/-recursive//`; \
- case "$@" in \
- distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
- *) list='$(SUBDIRS)' ;; \
- esac; \
- for subdir in $$list; do \
- echo "Making $$target in $$subdir"; \
- if test "$$subdir" = "."; then \
- dot_seen=yes; \
- local_target="$$target-am"; \
- else \
- local_target="$$target"; \
- fi; \
- ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
- || eval $$failcom; \
- done; \
- if test "$$dot_seen" = "no"; then \
- $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
- fi; test -z "$$fail"
-
-ID: $(am__tagged_files)
- $(am__define_uniq_tagged_files); mkid -fID $$unique
-tags: tags-recursive
-TAGS: tags
-
-tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
- set x; \
- here=`pwd`; \
- if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
- include_option=--etags-include; \
- empty_fix=.; \
- else \
- include_option=--include; \
- empty_fix=; \
- fi; \
- list='$(SUBDIRS)'; for subdir in $$list; do \
- if test "$$subdir" = .; then :; else \
- test ! -f $$subdir/TAGS || \
- set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
- fi; \
- done; \
- $(am__define_uniq_tagged_files); \
- shift; \
- if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
- test -n "$$unique" || unique=$$empty_fix; \
- if test $$# -gt 0; then \
- $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
- "$$@" $$unique; \
- else \
- $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
- $$unique; \
- fi; \
- fi
-ctags: ctags-recursive
-
-CTAGS: ctags
-ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
- $(am__define_uniq_tagged_files); \
- test -z "$(CTAGS_ARGS)$$unique" \
- || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
- $$unique
-
-GTAGS:
- here=`$(am__cd) $(top_builddir) && pwd` \
- && $(am__cd) $(top_srcdir) \
- && gtags -i $(GTAGS_ARGS) "$$here"
-cscope: cscope.files
- test ! -s cscope.files \
- || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS)
-clean-cscope:
- -rm -f cscope.files
-cscope.files: clean-cscope cscopelist
-cscopelist: cscopelist-recursive
-
-cscopelist-am: $(am__tagged_files)
- list='$(am__tagged_files)'; \
- case "$(srcdir)" in \
- [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
- *) sdir=$(subdir)/$(srcdir) ;; \
- esac; \
- for i in $$list; do \
- if test -f "$$i"; then \
- echo "$(subdir)/$$i"; \
- else \
- echo "$$sdir/$$i"; \
- fi; \
- done >> $(top_builddir)/cscope.files
-
-distclean-tags:
- -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
- -rm -f cscope.out cscope.in.out cscope.po.out cscope.files
-
-distdir: $(DISTFILES)
- $(am__remove_distdir)
- test -d "$(distdir)" || mkdir "$(distdir)"
- @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
- topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
- list='$(DISTFILES)'; \
- dist_files=`for file in $$list; do echo $$file; done | \
- sed -e "s|^$$srcdirstrip/||;t" \
- -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
- case $$dist_files in \
- */*) $(MKDIR_P) `echo "$$dist_files" | \
- sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
- sort -u` ;; \
- esac; \
- for file in $$dist_files; do \
- if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
- if test -d $$d/$$file; then \
- dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
- if test -d "$(distdir)/$$file"; then \
- find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
- fi; \
- if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
- cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
- find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
- fi; \
- cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
- else \
- test -f "$(distdir)/$$file" \
- || cp -p $$d/$$file "$(distdir)/$$file" \
- || exit 1; \
- fi; \
- done
- @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
- if test "$$subdir" = .; then :; else \
- $(am__make_dryrun) \
- || test -d "$(distdir)/$$subdir" \
- || $(MKDIR_P) "$(distdir)/$$subdir" \
- || exit 1; \
- dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
- $(am__relativize); \
- new_distdir=$$reldir; \
- dir1=$$subdir; dir2="$(top_distdir)"; \
- $(am__relativize); \
- new_top_distdir=$$reldir; \
- echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
- echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
- ($(am__cd) $$subdir && \
- $(MAKE) $(AM_MAKEFLAGS) \
- top_distdir="$$new_top_distdir" \
- distdir="$$new_distdir" \
- am__remove_distdir=: \
- am__skip_length_check=: \
- am__skip_mode_fix=: \
- distdir) \
- || exit 1; \
- fi; \
- done
- $(MAKE) $(AM_MAKEFLAGS) \
- top_distdir="$(top_distdir)" distdir="$(distdir)" \
- dist-hook
- -test -n "$(am__skip_mode_fix)" \
- || find "$(distdir)" -type d ! -perm -755 \
- -exec chmod u+rwx,go+rx {} \; -o \
- ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \
- ! -type d ! -perm -400 -exec chmod a+r {} \; -o \
- ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \
- || chmod -R a+r "$(distdir)"
-dist-gzip: distdir
- tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
- $(am__post_remove_distdir)
-
-dist-bzip2: distdir
- tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2
- $(am__post_remove_distdir)
-
-dist-lzip: distdir
- tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz
- $(am__post_remove_distdir)
-
-dist-xz: distdir
- tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz
- $(am__post_remove_distdir)
-
-dist-tarZ: distdir
- @echo WARNING: "Support for distribution archives compressed with" \
- "legacy program 'compress' is deprecated." >&2
- @echo WARNING: "It will be removed altogether in Automake 2.0" >&2
- tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
- $(am__post_remove_distdir)
-
-dist-shar: distdir
- @echo WARNING: "Support for shar distribution archives is" \
- "deprecated." >&2
- @echo WARNING: "It will be removed altogether in Automake 2.0" >&2
- shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz
- $(am__post_remove_distdir)
-
-dist-zip: distdir
- -rm -f $(distdir).zip
- zip -rq $(distdir).zip $(distdir)
- $(am__post_remove_distdir)
-
-dist dist-all:
- $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:'
- $(am__post_remove_distdir)
-
-# This target untars the dist file and tries a VPATH configuration. Then
-# it guarantees that the distribution is self-contained by making another
-# tarfile.
-distcheck: dist
- case '$(DIST_ARCHIVES)' in \
- *.tar.gz*) \
- GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\
- *.tar.bz2*) \
- bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\
- *.tar.lz*) \
- lzip -dc $(distdir).tar.lz | $(am__untar) ;;\
- *.tar.xz*) \
- xz -dc $(distdir).tar.xz | $(am__untar) ;;\
- *.tar.Z*) \
- uncompress -c $(distdir).tar.Z | $(am__untar) ;;\
- *.shar.gz*) \
- GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\
- *.zip*) \
- unzip $(distdir).zip ;;\
- esac
- chmod -R a-w $(distdir)
- chmod u+w $(distdir)
- mkdir $(distdir)/_build $(distdir)/_build/sub $(distdir)/_inst
- chmod a-w $(distdir)
- test -d $(distdir)/_build || exit 0; \
- dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \
- && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \
- && $(MAKE) $(AM_MAKEFLAGS) distcheck-hook \
- && am__cwd=`pwd` \
- && $(am__cd) $(distdir)/_build/sub \
- && ../../configure \
- $(AM_DISTCHECK_CONFIGURE_FLAGS) \
- $(DISTCHECK_CONFIGURE_FLAGS) \
- --srcdir=../.. --prefix="$$dc_install_base" \
- && $(MAKE) $(AM_MAKEFLAGS) \
- && $(MAKE) $(AM_MAKEFLAGS) dvi \
- && $(MAKE) $(AM_MAKEFLAGS) check \
- && $(MAKE) $(AM_MAKEFLAGS) install \
- && $(MAKE) $(AM_MAKEFLAGS) installcheck \
- && $(MAKE) $(AM_MAKEFLAGS) uninstall \
- && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \
- distuninstallcheck \
- && chmod -R a-w "$$dc_install_base" \
- && ({ \
- (cd ../.. && umask 077 && mkdir "$$dc_destdir") \
- && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \
- && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \
- && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \
- distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \
- } || { rm -rf "$$dc_destdir"; exit 1; }) \
- && rm -rf "$$dc_destdir" \
- && $(MAKE) $(AM_MAKEFLAGS) dist \
- && rm -rf $(DIST_ARCHIVES) \
- && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \
- && cd "$$am__cwd" \
- || exit 1
- $(am__post_remove_distdir)
- @(echo "$(distdir) archives ready for distribution: "; \
- list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \
- sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x'
-distuninstallcheck:
- @test -n '$(distuninstallcheck_dir)' || { \
- echo 'ERROR: trying to run $@ with an empty' \
- '$$(distuninstallcheck_dir)' >&2; \
- exit 1; \
- }; \
- $(am__cd) '$(distuninstallcheck_dir)' || { \
- echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \
- exit 1; \
- }; \
- test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \
- || { echo "ERROR: files left after uninstall:" ; \
- if test -n "$(DESTDIR)"; then \
- echo " (check DESTDIR support)"; \
- fi ; \
- $(distuninstallcheck_listfiles) ; \
- exit 1; } >&2
-check-am: all-am
-check: check-recursive
-all-am: Makefile $(SCRIPTS)
-installdirs: installdirs-recursive
-installdirs-am:
-install: install-recursive
-install-exec: install-exec-recursive
-install-data: install-data-recursive
-uninstall: uninstall-recursive
-
-install-am: all-am
- @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-
-installcheck: installcheck-recursive
-install-strip:
- if test -z '$(STRIP)'; then \
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
- install; \
- else \
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
- "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
- fi
-mostlyclean-generic:
-
-clean-generic:
- -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
-
-distclean-generic:
- -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
- -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
-
-maintainer-clean-generic:
- @echo "This command is intended for maintainers to use"
- @echo "it deletes files that may require special tools to rebuild."
-clean: clean-recursive
-
-clean-am: clean-generic clean-libtool clean-local mostlyclean-am
-
-distclean: distclean-recursive
- -rm -f $(am__CONFIG_DISTCLEAN_FILES)
- -rm -f Makefile
-distclean-am: clean-am distclean-generic distclean-hdr \
- distclean-libtool distclean-tags
-
-dvi: dvi-recursive
-
-dvi-am:
-
-html: html-recursive
-
-html-am:
-
-info: info-recursive
-
-info-am:
-
-install-data-am:
-
-install-dvi: install-dvi-recursive
-
-install-dvi-am:
-
-install-exec-am:
-
-install-html: install-html-recursive
-
-install-html-am:
-
-install-info: install-info-recursive
-
-install-info-am:
-
-install-man:
-
-install-pdf: install-pdf-recursive
-
-install-pdf-am:
-
-install-ps: install-ps-recursive
-
-install-ps-am:
-
-installcheck-am:
-
-maintainer-clean: maintainer-clean-recursive
- -rm -f $(am__CONFIG_DISTCLEAN_FILES)
- -rm -rf $(top_srcdir)/autom4te.cache
- -rm -f Makefile
-maintainer-clean-am: distclean-am maintainer-clean-generic
-
-mostlyclean: mostlyclean-recursive
-
-mostlyclean-am: mostlyclean-generic mostlyclean-libtool
-
-pdf: pdf-recursive
-
-pdf-am:
-
-ps: ps-recursive
-
-ps-am:
-
-uninstall-am:
-
-.MAKE: $(am__recursive_targets) install-am install-strip
-
-.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \
- am--refresh check check-am clean clean-cscope clean-generic \
- clean-libtool clean-local cscope cscopelist-am ctags ctags-am \
- dist dist-all dist-bzip2 dist-gzip dist-hook dist-lzip \
- dist-shar dist-tarZ dist-xz dist-zip distcheck distclean \
- distclean-generic distclean-hdr distclean-libtool \
- distclean-tags distcleancheck distdir distuninstallcheck dvi \
- dvi-am html html-am info info-am install install-am \
- install-data install-data-am install-dvi install-dvi-am \
- install-exec install-exec-am install-html install-html-am \
- install-info install-info-am install-man install-pdf \
- install-pdf-am install-ps install-ps-am install-strip \
- installcheck installcheck-am installdirs installdirs-am \
- maintainer-clean maintainer-clean-generic mostlyclean \
- mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
- tags tags-am uninstall uninstall-am
-
-.PRECIOUS: Makefile
-
-.PHONY: deploy FORCE
-export PYTHONPATH
-
-dist-hook:
- -$(MAKE) -C $(top_distdir)/src/leveldb clean
- -$(MAKE) -C $(top_distdir)/src/secp256k1 distclean
- -$(GIT) archive --format=tar HEAD -- src/clientversion.cpp | $(AMTAR) -C $(top_distdir) -xf -
-
-distcheck-hook:
- $(MKDIR_P) $(top_distdir)/_build/src/leveldb
- cp -rf $(top_srcdir)/src/leveldb/* $(top_distdir)/_build/src/leveldb/
- -$(MAKE) -C $(top_distdir)/_build/src/leveldb clean
-
-distcleancheck:
- @:
-
-$(BITCOIN_WIN_INSTALLER): all-recursive
- $(MKDIR_P) $(top_builddir)/release
- STRIPPROG="$(STRIP)" $(INSTALL_STRIP_PROGRAM) $(BITCOIND_BIN) $(top_builddir)/release
- STRIPPROG="$(STRIP)" $(INSTALL_STRIP_PROGRAM) $(BITCOIN_QT_BIN) $(top_builddir)/release
- STRIPPROG="$(STRIP)" $(INSTALL_STRIP_PROGRAM) $(BITCOIN_CLI_BIN) $(top_builddir)/release
- @test -f $(MAKENSIS) && $(MAKENSIS) -V2 $(top_builddir)/share/setup.nsi || \
- echo error: could not build $@
- @echo built $@
-
-$(OSX_APP)/Contents/PkgInfo:
- $(MKDIR_P) $(@D)
- @echo "APPL????" > $@
-
-$(OSX_APP)/Contents/Resources/empty.lproj:
- $(MKDIR_P) $(@D)
- @touch $@
-
-$(OSX_APP)/Contents/Info.plist: $(OSX_PLIST)
- $(MKDIR_P) $(@D)
- $(INSTALL_DATA) $< $@
-
-$(OSX_APP)/Contents/Resources/bitcoin.icns: $(OSX_INSTALLER_ICONS)
- $(MKDIR_P) $(@D)
- $(INSTALL_DATA) $< $@
-
-$(OSX_APP)/Contents/MacOS/DAPScoin-Qt: $(BITCOIN_QT_BIN)
- $(MKDIR_P) $(@D)
- STRIPPROG="$(STRIP)" $(INSTALL_STRIP_PROGRAM) $< $@
-
-$(OSX_APP)/Contents/Resources/Base.lproj/InfoPlist.strings:
- $(MKDIR_P) $(@D)
- echo '{ CFBundleDisplayName = "$(PACKAGE_NAME)"; CFBundleName = "$(PACKAGE_NAME)"; }' > $@
-
-osx_volname:
- echo $(OSX_VOLNAME) >$@
-
-#$(OSX_DMG): $(OSX_APP_BUILT) $(OSX_PACKAGING) $(OSX_BACKGROUND_IMAGE)
-# $(PYTHON) $(OSX_DEPLOY_SCRIPT) $(OSX_APP) -add-qt-tr $(OSX_QT_TRANSLATIONS) -translations-dir=$(QT_TRANSLATION_DIR) -dmg -fancy $(OSX_FANCY_PLIST) -verbose 2 -volname $(OSX_VOLNAME)
-
-#$(OSX_BACKGROUND_IMAGE).png: contrib/macdeploy/$(OSX_BACKGROUND_SVG)
-# sed 's/PACKAGE_NAME/$(PACKAGE_NAME)/' < "$<" | $(RSVG_CONVERT) -f png -d 36 -p 36 -o $@
-#$(OSX_BACKGROUND_IMAGE)@2x.png: contrib/macdeploy/$(OSX_BACKGROUND_SVG)
-# sed 's/PACKAGE_NAME/$(PACKAGE_NAME)/' < "$<" | $(RSVG_CONVERT) -f png -d 72 -p 72 -o $@
-#$(OSX_BACKGROUND_IMAGE): $(OSX_BACKGROUND_IMAGE).png $(OSX_BACKGROUND_IMAGE)@2x.png
-# tiffutil -cathidpicheck $^ -out $@
-
-#deploydir: $(OSX_DMG)
-
-$(APP_DIST_DIR)/Applications:
- @rm -f $@
- @cd $(@D); $(LN_S) /Applications $(@F)
-
-$(APP_DIST_EXTRAS): $(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/DAPScoin-Qt
-
-$(OSX_DMG): $(APP_DIST_EXTRAS)
- $(GENISOIMAGE) -no-cache-inodes -D -l -probe -V "$(OSX_VOLNAME)" -no-pad -r -dir-mode 0755 -apple -o $@ dist
-
-dpi%.$(OSX_BACKGROUND_IMAGE): contrib/macdeploy/$(OSX_BACKGROUND_SVG)
- sed 's/PACKAGE_NAME/$(PACKAGE_NAME)/' < "$<" | $(RSVG_CONVERT) -f png -d $* -p $* | $(IMAGEMAGICK_CONVERT) - $@
-$(APP_DIST_DIR)/.background/$(OSX_BACKGROUND_IMAGE): $(OSX_BACKGROUND_IMAGE_DPIFILES)
- $(MKDIR_P) $(@D)
- $(TIFFCP) -c none $(OSX_BACKGROUND_IMAGE_DPIFILES) $@
-
-$(APP_DIST_DIR)/.DS_Store: $(OSX_DSSTORE_GEN)
- $(PYTHON) $< "$@" "$(OSX_VOLNAME)"
-
-$(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/DAPScoin-Qt: $(OSX_APP_BUILT) $(OSX_PACKAGING)
- INSTALLNAMETOOL=$(INSTALLNAMETOOL) OTOOL=$(OTOOL) STRIP=$(STRIP) $(PYTHON) $(OSX_DEPLOY_SCRIPT) $(OSX_APP) -translations-dir=$(QT_TRANSLATION_DIR) -add-qt-tr $(OSX_QT_TRANSLATIONS) -verbose 2
-
-deploydir: $(APP_DIST_EXTRAS)
-
-#appbundle: $(OSX_APP_BUILT)
-#deploy: $(OSX_DMG)
-#deploy: $(BITCOIN_WIN_INSTALLER)
-
-$(BITCOIN_QT_BIN): FORCE
- $(MAKE) -C src qt/$(@F)
-
-$(BITCOIND_BIN): FORCE
- $(MAKE) -C src $(@F)
-
-$(BITCOIN_CLI_BIN): FORCE
- $(MAKE) -C src $(@F)
-
-#baseline.info:
-# $(LCOV) -c -i -d $(abs_builddir)/src -o $@
-
-#baseline_filtered.info: baseline.info
-# $(LCOV) -r $< "/usr/include/*" -o $@
-
-#leveldb_baseline.info: baseline_filtered.info
-# $(LCOV) -c -i -d $(abs_builddir)/src/leveldb -b $(abs_builddir)/src/leveldb -o $@
-
-#leveldb_baseline_filtered.info: leveldb_baseline.info
-# $(LCOV) -r $< "/usr/include/*" -o $@
-
-#baseline_filtered_combined.info: leveldb_baseline_filtered.info baseline_filtered.info
-# $(LCOV) -a leveldb_baseline_filtered.info -a baseline_filtered.info -o $@
-
-#test_dapscoin.info: baseline_filtered_combined.info
-# $(MAKE) -C src/ check
-# $(LCOV) -c -d $(abs_builddir)/src -t test_dapscoin -o $@
-# $(LCOV) -z -d $(abs_builddir)/src
-# $(LCOV) -z -d $(abs_builddir)/src/leveldb
-
-#test_dapscoin_filtered.info: test_dapscoin.info
-# $(LCOV) -r $< "/usr/include/*" -o $@
-
-#block_test.info: test_dapscoin_filtered.info
-# $(MKDIR_P) qa/tmp
-# -@TIMEOUT=15 qa/pull-tester/run-bitcoind-for-test.sh $(JAVA) -jar $(JAVA_COMPARISON_TOOL) qa/tmp/compTool 0
-# $(LCOV) -c -d $(abs_builddir)/src --t BitcoinJBlockTest -o $@
-# $(LCOV) -z -d $(abs_builddir)/src
-# $(LCOV) -z -d $(abs_builddir)/src/leveldb
-
-#block_test_filtered.info: block_test.info
-# $(LCOV) -r $< "/usr/include/*" -o $@
-
-#test_dapscoin_coverage.info: baseline_filtered_combined.info test_dapscoin_filtered.info
-# $(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_dapscoin_filtered.info -o $@
-
-#total_coverage.info: baseline_filtered_combined.info test_dapscoin_filtered.info block_test_filtered.info
-# $(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_dapscoin_filtered.info -a block_test_filtered.info -o $@ | $(GREP) "\%" | $(AWK) '{ print substr($$3,2,50) "/" $$5 }' > coverage_percent.txt
-
-#test_dapscoin.coverage/.dirstamp: test_dapscoin_coverage.info
-# $(GENHTML) -s $< -o $(@D)
-# @touch $@
-
-#total.coverage/.dirstamp: total_coverage.info
-# $(GENHTML) -s $< -o $(@D)
-# @touch $@
-
-#cov: test_dapscoin.coverage/.dirstamp total.coverage/.dirstamp
-
-.INTERMEDIATE: $(COVERAGE_INFO)
-
-clean-local:
- rm -rf test_dapscoin.coverage/ total.coverage/ $(OSX_APP)
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
diff --git a/README.md b/README.md
index 54dd54d273..358645d24f 100644
--- a/README.md
+++ b/README.md
@@ -1,17 +1,63 @@
-DAPS integration/staging repository
+
+
+Welcome to PRCY
=====================================
-DAPScoin is a cutting edge cryptocurrency, with many features not available in most other cryptocurrencies.
+
+## Introduction
+
+PRCYcoin is a cutting edge cryptocurrency, with many features not available in most other cryptocurrencies.
- Anonymized transactions using Stealth addresses, RingCT and Bulletproofs.
-- Masternode is secured with a collateral of 1,000,000 DAPS.
+- Masternode is secured with a collateral of 5,000 PRCY
+- Minimum Staking Amount is 2,500 PRCY
+PRCY is a cryptocurrency designed for corporate entities, traders, and individuals to have the autonomy to transactions business freely around the world safely and securely without the exposure to malicious actors that threaten financial transactions through traceability.
+
+PRCY is a privacy coin that aims to be the most private and secure privacy coin on the market in a hybrid chain of PoW, PoSv3 and PoA. We aim to set our protocol to become the new standard of privacy coins.
+
+The team of PRCY solves the trust issue of privacy coins and their management as follows:
+- The community will get access to view the number of the PRCY project coins and their actions
+- Each quarter the team explains their actions and displays their project balance of coins
+- Upfront the allocation is published as a starting point
+
+## About this Project
+
+PRCY is a non-ICO community driven project. The project has funded itself to deliver ground-breaking technology in the privacy coin industry.
+
+PRCY Team
+The team consists of a total of 10 members located worldwide.
+
+## How to Contribute to PRCY
+
+We have an extensive [Contributing.md](https://github.com/PRCYCoin/PRCYCoin/blob/master/CONTRIBUTING.md) guide on how to contribute to PRCY source code.
+Please have a look at this first before deciding to contribute to our codebase.
+
+We welcome developers from all backgrounds to take a look at our code and welcome all suggestions and changes.
+
+## Social
+
+Facebook - (https://www.facebook.com/Prcycoin-101534778505838)
+
+Twitter - (https://twitter.com/PRCYcoin)
+
+Reddit - (https://www.reddit.com/r/PRCYCoin/)
+
+Telegram - (https://t.me/prcycoinofficial)
+
+Telegram - Tech Support - (https://t.me/prycSupport)
+
+Medium - (https://prcycoin.medium.com/)
+
+Bitcointalk - (https://bitcointalk.org/index.php?topic=5301128)
+
+Instagram - (https://www.instagram.com/prcycoin/)
-More information at [officialdapscoin.com](https://officialdapscoin.com) Visit our ANN thread at [BitcoinTalk](https://bitcointalk.org/index.php?topic=5146718)
+More information at [prcycoin.com](https://prcycoin.com) Visit our ANN thread at [BitcoinTalk](https://bitcointalk.org/index.php?topic=5301128)
### Coin Specs
| Algo | PoW-PoA-PoS |
| Block Time | 60 Seconds |
| Difficulty Retargeting | Every Block |
-| Max Coin Supply | 60,000,000,000 DAPS |
-| Premine | 60 000 000 DAPS |
+| Max Coin Supply | 70,000,000 PRCY |
+| Premine | 60,000,000 PRCY |
diff --git a/_config.yml b/_config.yml
new file mode 100644
index 0000000000..c4192631f2
--- /dev/null
+++ b/_config.yml
@@ -0,0 +1 @@
+theme: jekyll-theme-cayman
\ No newline at end of file
diff --git a/autogen.sh b/autogen.sh
old mode 100644
new mode 100755
index 27417daf76..0c05626ccc
--- a/autogen.sh
+++ b/autogen.sh
@@ -3,6 +3,7 @@
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+export LC_ALL=C
set -e
srcdir="$(dirname $0)"
cd "$srcdir"
diff --git a/build-aux/m4/ax_boost_base.m4 b/build-aux/m4/ax_boost_base.m4
index 3f24d5ddc6..b1fed7a50a 100644
--- a/build-aux/m4/ax_boost_base.m4
+++ b/build-aux/m4/ax_boost_base.m4
@@ -1,5 +1,5 @@
# ===========================================================================
-# http://www.gnu.org/software/autoconf-archive/ax_boost_base.html
+# https://www.gnu.org/software/autoconf-archive/ax_boost_base.html
# ===========================================================================
#
# SYNOPSIS
@@ -11,9 +11,9 @@
# Test for the Boost C++ libraries of a particular version (or newer)
#
# If no path to the installed boost library is given the macro searchs
-# under /usr, /usr/local, /opt and /opt/local and evaluates the
-# $BOOST_ROOT environment variable. Further documentation is available at
-# .
+# under /usr, /usr/local, /opt, /opt/local and /opt/homebrew and evaluates
+# the $BOOST_ROOT environment variable. Further documentation is available
+# at .
#
# This macro calls:
#
@@ -33,7 +33,15 @@
# and this notice are preserved. This file is offered as-is, without any
# warranty.
-#serial 23
+#serial 52
+
+# example boost program (need to pass version)
+m4_define([_AX_BOOST_BASE_PROGRAM],
+ [AC_LANG_PROGRAM([[
+#include
+]],[[
+(void) ((void)sizeof(char[1 - 2*!!((BOOST_VERSION) < ($1))]));
+]])])
AC_DEFUN([AX_BOOST_BASE],
[
@@ -44,110 +52,123 @@ AC_ARG_WITH([boost],
or disable it (ARG=no)
@<:@ARG=yes@:>@ ])],
[
- if test "$withval" = "no"; then
- want_boost="no"
- elif test "$withval" = "yes"; then
- want_boost="yes"
- ac_boost_path=""
- else
- want_boost="yes"
- ac_boost_path="$withval"
- fi
+ AS_CASE([$withval],
+ [no],[want_boost="no";_AX_BOOST_BASE_boost_path=""],
+ [yes],[want_boost="yes";_AX_BOOST_BASE_boost_path=""],
+ [want_boost="yes";_AX_BOOST_BASE_boost_path="$withval"])
],
[want_boost="yes"])
AC_ARG_WITH([boost-libdir],
- AS_HELP_STRING([--with-boost-libdir=LIB_DIR],
- [Force given directory for boost libraries. Note that this will override library path detection, so use this parameter only if default library detection fails and you know exactly where your boost libraries are located.]),
- [
- if test -d "$withval"
- then
- ac_boost_lib_path="$withval"
- else
- AC_MSG_ERROR(--with-boost-libdir expected directory name)
- fi
- ],
- [ac_boost_lib_path=""]
-)
+ [AS_HELP_STRING([--with-boost-libdir=LIB_DIR],
+ [Force given directory for boost libraries.
+ Note that this will override library path detection,
+ so use this parameter only if default library detection fails
+ and you know exactly where your boost libraries are located.])],
+ [
+ AS_IF([test -d "$withval"],
+ [_AX_BOOST_BASE_boost_lib_path="$withval"],
+ [AC_MSG_ERROR([--with-boost-libdir expected directory name])])
+ ],
+ [_AX_BOOST_BASE_boost_lib_path=""])
-if test "x$want_boost" = "xyes"; then
- boost_lib_version_req=ifelse([$1], ,1.20.0,$1)
- boost_lib_version_req_shorten=`expr $boost_lib_version_req : '\([[0-9]]*\.[[0-9]]*\)'`
- boost_lib_version_req_major=`expr $boost_lib_version_req : '\([[0-9]]*\)'`
- boost_lib_version_req_minor=`expr $boost_lib_version_req : '[[0-9]]*\.\([[0-9]]*\)'`
- boost_lib_version_req_sub_minor=`expr $boost_lib_version_req : '[[0-9]]*\.[[0-9]]*\.\([[0-9]]*\)'`
- if test "x$boost_lib_version_req_sub_minor" = "x" ; then
- boost_lib_version_req_sub_minor="0"
- fi
- WANT_BOOST_VERSION=`expr $boost_lib_version_req_major \* 100000 \+ $boost_lib_version_req_minor \* 100 \+ $boost_lib_version_req_sub_minor`
- AC_MSG_CHECKING(for boostlib >= $boost_lib_version_req)
+BOOST_LDFLAGS=""
+BOOST_CPPFLAGS=""
+AS_IF([test "x$want_boost" = "xyes"],
+ [_AX_BOOST_BASE_RUNDETECT([$1],[$2],[$3])])
+AC_SUBST(BOOST_CPPFLAGS)
+AC_SUBST(BOOST_LDFLAGS)
+])
+
+
+# convert a version string in $2 to numeric and affect to polymorphic var $1
+AC_DEFUN([_AX_BOOST_BASE_TONUMERICVERSION],[
+ AS_IF([test "x$2" = "x"],[_AX_BOOST_BASE_TONUMERICVERSION_req="1.20.0"],[_AX_BOOST_BASE_TONUMERICVERSION_req="$2"])
+ _AX_BOOST_BASE_TONUMERICVERSION_req_shorten=`expr $_AX_BOOST_BASE_TONUMERICVERSION_req : '\([[0-9]]*\.[[0-9]]*\)'`
+ _AX_BOOST_BASE_TONUMERICVERSION_req_major=`expr $_AX_BOOST_BASE_TONUMERICVERSION_req : '\([[0-9]]*\)'`
+ AS_IF([test "x$_AX_BOOST_BASE_TONUMERICVERSION_req_major" = "x"],
+ [AC_MSG_ERROR([You should at least specify libboost major version])])
+ _AX_BOOST_BASE_TONUMERICVERSION_req_minor=`expr $_AX_BOOST_BASE_TONUMERICVERSION_req : '[[0-9]]*\.\([[0-9]]*\)'`
+ AS_IF([test "x$_AX_BOOST_BASE_TONUMERICVERSION_req_minor" = "x"],
+ [_AX_BOOST_BASE_TONUMERICVERSION_req_minor="0"])
+ _AX_BOOST_BASE_TONUMERICVERSION_req_sub_minor=`expr $_AX_BOOST_BASE_TONUMERICVERSION_req : '[[0-9]]*\.[[0-9]]*\.\([[0-9]]*\)'`
+ AS_IF([test "X$_AX_BOOST_BASE_TONUMERICVERSION_req_sub_minor" = "X"],
+ [_AX_BOOST_BASE_TONUMERICVERSION_req_sub_minor="0"])
+ _AX_BOOST_BASE_TONUMERICVERSION_RET=`expr $_AX_BOOST_BASE_TONUMERICVERSION_req_major \* 100000 \+ $_AX_BOOST_BASE_TONUMERICVERSION_req_minor \* 100 \+ $_AX_BOOST_BASE_TONUMERICVERSION_req_sub_minor`
+ AS_VAR_SET($1,$_AX_BOOST_BASE_TONUMERICVERSION_RET)
+])
+
+dnl Run the detection of boost should be run only if $want_boost
+AC_DEFUN([_AX_BOOST_BASE_RUNDETECT],[
+ _AX_BOOST_BASE_TONUMERICVERSION(WANT_BOOST_VERSION,[$1])
succeeded=no
+
+ AC_REQUIRE([AC_CANONICAL_HOST])
dnl On 64-bit systems check for system libraries in both lib64 and lib.
dnl The former is specified by FHS, but e.g. Debian does not adhere to
dnl this (as it rises problems for generic multi-arch support).
dnl The last entry in the list is chosen by default when no libraries
dnl are found, e.g. when only header-only libraries are installed!
- libsubdirs="lib"
- ax_arch=`uname -m`
- case $ax_arch in
- x86_64)
- libsubdirs="lib64 libx32 lib lib64"
- ;;
- ppc64|s390x|sparc64|aarch64)
- libsubdirs="lib64 lib lib64"
- ;;
- esac
+ AS_CASE([${host_cpu}],
+ [x86_64],[libsubdirs="lib64 libx32 lib lib64"],
+ [mips*64*],[libsubdirs="lib64 lib32 lib lib64"],
+ [ppc64|powerpc64|s390x|sparc64|aarch64|ppc64le|powerpc64le|riscv64|e2k|loongarch64],[libsubdirs="lib64 lib lib64"],
+ [libsubdirs="lib"]
+ )
dnl allow for real multi-arch paths e.g. /usr/lib/x86_64-linux-gnu. Give
dnl them priority over the other paths since, if libs are found there, they
dnl are almost assuredly the ones desired.
- AC_REQUIRE([AC_CANONICAL_HOST])
- libsubdirs="lib/${host_cpu}-${host_os} $libsubdirs"
-
- case ${host_cpu} in
- i?86)
- libsubdirs="lib/i386-${host_os} $libsubdirs"
- ;;
- esac
-
- dnl some arches may advertise a cpu type that doesn't line up with their
- dnl prefix's cpu type. For example, uname may report armv7l while libs are
- dnl installed to /usr/lib/arm-linux-gnueabihf. Try getting the compiler's
- dnl value for an extra chance of finding the correct path.
- libsubdirs="lib/`$CXX -dumpmachine 2>/dev/null` $libsubdirs"
+ AS_CASE([${host_cpu}],
+ [i?86],[multiarch_libsubdir="lib/i386-${host_os}"],
+ [armv7l],[multiarch_libsubdir="lib/arm-${host_os}"],
+ [multiarch_libsubdir="lib/${host_cpu}-${host_os}"]
+ )
dnl first we check the system location for boost libraries
- dnl this location ist chosen if boost libraries are installed with the --layout=system option
+ dnl this location is chosen if boost libraries are installed with the --layout=system option
dnl or if you install boost with RPM
- if test "$ac_boost_path" != ""; then
- BOOST_CPPFLAGS="-I$ac_boost_path/include"
- for ac_boost_path_tmp in $libsubdirs; do
- if test -d "$ac_boost_path"/"$ac_boost_path_tmp" ; then
- BOOST_LDFLAGS="-L$ac_boost_path/$ac_boost_path_tmp"
- break
- fi
- done
- elif test "$cross_compiling" != yes; then
- for ac_boost_path_tmp in /usr /usr/local /opt /opt/local ; do
- if test -d "$ac_boost_path_tmp/include/boost" && test -r "$ac_boost_path_tmp/include/boost"; then
- for libsubdir in $libsubdirs ; do
- if ls "$ac_boost_path_tmp/$libsubdir/libboost_"* >/dev/null 2>&1 ; then break; fi
+ AS_IF([test "x$_AX_BOOST_BASE_boost_path" != "x"],[
+ AC_MSG_CHECKING([for boostlib >= $1 ($WANT_BOOST_VERSION) includes in "$_AX_BOOST_BASE_boost_path/include"])
+ AS_IF([test -d "$_AX_BOOST_BASE_boost_path/include" && test -r "$_AX_BOOST_BASE_boost_path/include"],[
+ AC_MSG_RESULT([yes])
+ BOOST_CPPFLAGS="-I$_AX_BOOST_BASE_boost_path/include"
+ for _AX_BOOST_BASE_boost_path_tmp in $multiarch_libsubdir $libsubdirs; do
+ AC_MSG_CHECKING([for boostlib >= $1 ($WANT_BOOST_VERSION) lib path in "$_AX_BOOST_BASE_boost_path/$_AX_BOOST_BASE_boost_path_tmp"])
+ AS_IF([test -d "$_AX_BOOST_BASE_boost_path/$_AX_BOOST_BASE_boost_path_tmp" && test -r "$_AX_BOOST_BASE_boost_path/$_AX_BOOST_BASE_boost_path_tmp" ],[
+ AC_MSG_RESULT([yes])
+ BOOST_LDFLAGS="-L$_AX_BOOST_BASE_boost_path/$_AX_BOOST_BASE_boost_path_tmp";
+ break;
+ ],
+ [AC_MSG_RESULT([no])])
+ done],[
+ AC_MSG_RESULT([no])])
+ ],[
+ if test X"$cross_compiling" = Xyes; then
+ search_libsubdirs=$multiarch_libsubdir
+ else
+ search_libsubdirs="$multiarch_libsubdir $libsubdirs"
+ fi
+ for _AX_BOOST_BASE_boost_path_tmp in /usr /usr/local /opt /opt/local /opt/homebrew ; do
+ if test -d "$_AX_BOOST_BASE_boost_path_tmp/include/boost" && test -r "$_AX_BOOST_BASE_boost_path_tmp/include/boost" ; then
+ for libsubdir in $search_libsubdirs ; do
+ if ls "$_AX_BOOST_BASE_boost_path_tmp/$libsubdir/libboost_"* >/dev/null 2>&1 ; then break; fi
done
- BOOST_LDFLAGS="-L$ac_boost_path_tmp/$libsubdir"
- BOOST_CPPFLAGS="-I$ac_boost_path_tmp/include"
+ BOOST_LDFLAGS="-L$_AX_BOOST_BASE_boost_path_tmp/$libsubdir"
+ BOOST_CPPFLAGS="-I$_AX_BOOST_BASE_boost_path_tmp/include"
break;
fi
done
- fi
+ ])
dnl overwrite ld flags if we have required special directory with
dnl --with-boost-libdir parameter
- if test "$ac_boost_lib_path" != ""; then
- BOOST_LDFLAGS="-L$ac_boost_lib_path"
- fi
+ AS_IF([test "x$_AX_BOOST_BASE_boost_lib_path" != "x"],
+ [BOOST_LDFLAGS="-L$_AX_BOOST_BASE_boost_lib_path"])
+ AC_MSG_CHECKING([for boostlib >= $1 ($WANT_BOOST_VERSION)])
CPPFLAGS_SAVED="$CPPFLAGS"
CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS"
export CPPFLAGS
@@ -158,19 +179,11 @@ if test "x$want_boost" = "xyes"; then
AC_REQUIRE([AC_PROG_CXX])
AC_LANG_PUSH(C++)
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
- @%:@include
- ]], [[
- #if BOOST_VERSION >= $WANT_BOOST_VERSION
- // Everything is okay
- #else
- # error Boost version is too old
- #endif
- ]])],[
+ AC_COMPILE_IFELSE([_AX_BOOST_BASE_PROGRAM($WANT_BOOST_VERSION)],[
AC_MSG_RESULT(yes)
succeeded=yes
found_system=yes
- ],[:
+ ],[
])
AC_LANG_POP([C++])
@@ -178,30 +191,50 @@ if test "x$want_boost" = "xyes"; then
dnl if we found no boost with system layout we search for boost libraries
dnl built and installed without the --layout=system option or for a staged(not installed) version
- if test "x$succeeded" != "xyes"; then
+ if test "x$succeeded" != "xyes" ; then
+ CPPFLAGS="$CPPFLAGS_SAVED"
+ LDFLAGS="$LDFLAGS_SAVED"
+ BOOST_CPPFLAGS=
+ if test -z "$_AX_BOOST_BASE_boost_lib_path" ; then
+ BOOST_LDFLAGS=
+ fi
_version=0
- if test "$ac_boost_path" != ""; then
- if test -d "$ac_boost_path" && test -r "$ac_boost_path"; then
- for i in `ls -d $ac_boost_path/include/boost-* 2>/dev/null`; do
- _version_tmp=`echo $i | sed "s#$ac_boost_path##" | sed 's/\/include\/boost-//' | sed 's/_/./'`
+ if test -n "$_AX_BOOST_BASE_boost_path" ; then
+ if test -d "$_AX_BOOST_BASE_boost_path" && test -r "$_AX_BOOST_BASE_boost_path"; then
+ for i in `ls -d $_AX_BOOST_BASE_boost_path/include/boost-* 2>/dev/null`; do
+ _version_tmp=`echo $i | sed "s#$_AX_BOOST_BASE_boost_path##" | sed 's/\/include\/boost-//' | sed 's/_/./'`
V_CHECK=`expr $_version_tmp \> $_version`
- if test "$V_CHECK" = "1" ; then
+ if test "x$V_CHECK" = "x1" ; then
_version=$_version_tmp
fi
VERSION_UNDERSCORE=`echo $_version | sed 's/\./_/'`
- BOOST_CPPFLAGS="-I$ac_boost_path/include/boost-$VERSION_UNDERSCORE"
+ BOOST_CPPFLAGS="-I$_AX_BOOST_BASE_boost_path/include/boost-$VERSION_UNDERSCORE"
done
+ dnl if nothing found search for layout used in Windows distributions
+ if test -z "$BOOST_CPPFLAGS"; then
+ if test -d "$_AX_BOOST_BASE_boost_path/boost" && test -r "$_AX_BOOST_BASE_boost_path/boost"; then
+ BOOST_CPPFLAGS="-I$_AX_BOOST_BASE_boost_path"
+ fi
+ fi
+ dnl if we found something and BOOST_LDFLAGS was unset before
+ dnl (because "$_AX_BOOST_BASE_boost_lib_path" = ""), set it here.
+ if test -n "$BOOST_CPPFLAGS" && test -z "$BOOST_LDFLAGS"; then
+ for libsubdir in $libsubdirs ; do
+ if ls "$_AX_BOOST_BASE_boost_path/$libsubdir/libboost_"* >/dev/null 2>&1 ; then break; fi
+ done
+ BOOST_LDFLAGS="-L$_AX_BOOST_BASE_boost_path/$libsubdir"
+ fi
fi
else
- if test "$cross_compiling" != yes; then
- for ac_boost_path in /usr /usr/local /opt /opt/local ; do
- if test -d "$ac_boost_path" && test -r "$ac_boost_path"; then
- for i in `ls -d $ac_boost_path/include/boost-* 2>/dev/null`; do
- _version_tmp=`echo $i | sed "s#$ac_boost_path##" | sed 's/\/include\/boost-//' | sed 's/_/./'`
+ if test "x$cross_compiling" != "xyes" ; then
+ for _AX_BOOST_BASE_boost_path in /usr /usr/local /opt /opt/local /opt/homebrew ; do
+ if test -d "$_AX_BOOST_BASE_boost_path" && test -r "$_AX_BOOST_BASE_boost_path" ; then
+ for i in `ls -d $_AX_BOOST_BASE_boost_path/include/boost-* 2>/dev/null`; do
+ _version_tmp=`echo $i | sed "s#$_AX_BOOST_BASE_boost_path##" | sed 's/\/include\/boost-//' | sed 's/_/./'`
V_CHECK=`expr $_version_tmp \> $_version`
- if test "$V_CHECK" = "1" ; then
+ if test "x$V_CHECK" = "x1" ; then
_version=$_version_tmp
- best_path=$ac_boost_path
+ best_path=$_AX_BOOST_BASE_boost_path
fi
done
fi
@@ -209,7 +242,7 @@ if test "x$want_boost" = "xyes"; then
VERSION_UNDERSCORE=`echo $_version | sed 's/\./_/'`
BOOST_CPPFLAGS="-I$best_path/include/boost-$VERSION_UNDERSCORE"
- if test "$ac_boost_lib_path" = ""; then
+ if test -z "$_AX_BOOST_BASE_boost_lib_path" ; then
for libsubdir in $libsubdirs ; do
if ls "$best_path/$libsubdir/libboost_"* >/dev/null 2>&1 ; then break; fi
done
@@ -217,7 +250,7 @@ if test "x$want_boost" = "xyes"; then
fi
fi
- if test "x$BOOST_ROOT" != "x"; then
+ if test -n "$BOOST_ROOT" ; then
for libsubdir in $libsubdirs ; do
if ls "$BOOST_ROOT/stage/$libsubdir/libboost_"* >/dev/null 2>&1 ; then break; fi
done
@@ -226,7 +259,7 @@ if test "x$want_boost" = "xyes"; then
stage_version=`echo $version_dir | sed 's/boost_//' | sed 's/_/./g'`
stage_version_shorten=`expr $stage_version : '\([[0-9]]*\.[[0-9]]*\)'`
V_CHECK=`expr $stage_version_shorten \>\= $_version`
- if test "$V_CHECK" = "1" -a "$ac_boost_lib_path" = "" ; then
+ if test "x$V_CHECK" = "x1" && test -z "$_AX_BOOST_BASE_boost_lib_path" ; then
AC_MSG_NOTICE(We will use a staged boost library from $BOOST_ROOT)
BOOST_CPPFLAGS="-I$BOOST_ROOT"
BOOST_LDFLAGS="-L$BOOST_ROOT/stage/$libsubdir"
@@ -241,34 +274,24 @@ if test "x$want_boost" = "xyes"; then
export LDFLAGS
AC_LANG_PUSH(C++)
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
- @%:@include
- ]], [[
- #if BOOST_VERSION >= $WANT_BOOST_VERSION
- // Everything is okay
- #else
- # error Boost version is too old
- #endif
- ]])],[
+ AC_COMPILE_IFELSE([_AX_BOOST_BASE_PROGRAM($WANT_BOOST_VERSION)],[
AC_MSG_RESULT(yes)
succeeded=yes
found_system=yes
- ],[:
+ ],[
])
AC_LANG_POP([C++])
fi
- if test "$succeeded" != "yes" ; then
- if test "$_version" = "0" ; then
- AC_MSG_NOTICE([[We could not detect the boost libraries (version $boost_lib_version_req_shorten or higher). If you have a staged boost library (still not installed) please specify \$BOOST_ROOT in your environment and do not give a PATH to --with-boost option. If you are sure you have boost installed, then check your version number looking in . See http://randspringer.de/boost for more documentation.]])
+ if test "x$succeeded" != "xyes" ; then
+ if test "x$_version" = "x0" ; then
+ AC_MSG_NOTICE([[We could not detect the boost libraries (version $1 or higher). If you have a staged boost library (still not installed) please specify \$BOOST_ROOT in your environment and do not give a PATH to --with-boost option. If you are sure you have boost installed, then check your version number looking in . See http://randspringer.de/boost for more documentation.]])
else
AC_MSG_NOTICE([Your boost libraries seems to old (version $_version).])
fi
# execute ACTION-IF-NOT-FOUND (if present):
ifelse([$3], , :, [$3])
else
- AC_SUBST(BOOST_CPPFLAGS)
- AC_SUBST(BOOST_LDFLAGS)
AC_DEFINE(HAVE_BOOST,,[define if the Boost library is available])
# execute ACTION-IF-FOUND (if present):
ifelse([$2], , :, [$2])
@@ -276,6 +299,5 @@ if test "x$want_boost" = "xyes"; then
CPPFLAGS="$CPPFLAGS_SAVED"
LDFLAGS="$LDFLAGS_SAVED"
-fi
])
diff --git a/build-aux/m4/ax_boost_chrono.m4 b/build-aux/m4/ax_boost_chrono.m4
index 318ecea17f..4cd3b86041 100644
--- a/build-aux/m4/ax_boost_chrono.m4
+++ b/build-aux/m4/ax_boost_chrono.m4
@@ -1,5 +1,5 @@
# ===========================================================================
-# http://www.gnu.org/software/autoconf-archive/ax_boost_chrono.html
+# https://www.gnu.org/software/autoconf-archive/ax_boost_chrono.html
# ===========================================================================
#
# SYNOPSIS
@@ -8,7 +8,7 @@
#
# DESCRIPTION
#
-# Test for System library from the Boost C++ libraries. The macro requires
+# Test for Chrono library from the Boost C++ libraries. The macro requires
# a preceding call to AX_BOOST_BASE. Further documentation is available at
# .
#
@@ -29,7 +29,7 @@
# and this notice are preserved. This file is offered as-is, without any
# warranty.
-#serial 1
+#serial 5
AC_DEFUN([AX_BOOST_CHRONO],
[
@@ -68,7 +68,7 @@ AC_DEFUN([AX_BOOST_CHRONO],
CXXFLAGS_SAVE=$CXXFLAGS
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[@%:@include ]],
- [[boost::chrono::system_clock::time_point time;]])],
+ [[boost::chrono::system_clock::time_point* time = new boost::chrono::system_clock::time_point; delete time;]])],
ax_cv_boost_chrono=yes, ax_cv_boost_chrono=no)
CXXFLAGS=$CXXFLAGS_SAVE
AC_LANG_POP([C++])
@@ -81,7 +81,6 @@ AC_DEFUN([AX_BOOST_CHRONO],
LDFLAGS_SAVE=$LDFLAGS
if test "x$ax_boost_user_chrono_lib" = "x"; then
- ax_lib=
for libextension in `ls $BOOSTLIBDIR/libboost_chrono*.so* $BOOSTLIBDIR/libboost_chrono*.dylib* $BOOSTLIBDIR/libboost_chrono*.a* 2>/dev/null | sed 's,.*/,,' | sed -e 's;^lib\(boost_chrono.*\)\.so.*$;\1;' -e 's;^lib\(boost_chrono.*\)\.dylib.*$;\1;' -e 's;^lib\(boost_chrono.*\)\.a.*$;\1;'` ; do
ax_lib=${libextension}
AC_CHECK_LIB($ax_lib, exit,
@@ -106,7 +105,7 @@ AC_DEFUN([AX_BOOST_CHRONO],
fi
if test "x$ax_lib" = "x"; then
- AC_MSG_ERROR(Could not find a version of the boost_chrono library!)
+ AC_MSG_ERROR(Could not find a version of the Boost::Chrono library!)
fi
if test "x$link_chrono" = "xno"; then
AC_MSG_ERROR(Could not link against $ax_lib !)
diff --git a/build-aux/m4/ax_boost_filesystem.m4 b/build-aux/m4/ax_boost_filesystem.m4
index f5c9d56470..12f7bc5e2e 100644
--- a/build-aux/m4/ax_boost_filesystem.m4
+++ b/build-aux/m4/ax_boost_filesystem.m4
@@ -1,5 +1,5 @@
# ===========================================================================
-# http://www.gnu.org/software/autoconf-archive/ax_boost_filesystem.html
+# https://www.gnu.org/software/autoconf-archive/ax_boost_filesystem.html
# ===========================================================================
#
# SYNOPSIS
@@ -31,7 +31,7 @@
# and this notice are preserved. This file is offered as-is, without any
# warranty.
-#serial 26
+#serial 28
AC_DEFUN([AX_BOOST_FILESYSTEM],
[
@@ -80,7 +80,6 @@ AC_DEFUN([AX_BOOST_FILESYSTEM],
if test "x$ax_cv_boost_filesystem" = "xyes"; then
AC_DEFINE(HAVE_BOOST_FILESYSTEM,,[define if the Boost::Filesystem library is available])
BOOSTLIBDIR=`echo $BOOST_LDFLAGS | sed -e 's/@<:@^\/@:>@*//'`
- ax_lib=
if test "x$ax_boost_user_filesystem_lib" = "x"; then
for libextension in `ls -r $BOOSTLIBDIR/libboost_filesystem* 2>/dev/null | sed 's,.*/lib,,' | sed 's,\..*,,'` ; do
ax_lib=${libextension}
@@ -105,7 +104,7 @@ AC_DEFUN([AX_BOOST_FILESYSTEM],
fi
if test "x$ax_lib" = "x"; then
- AC_MSG_ERROR(Could not find a version of the boost_filesystem library!)
+ AC_MSG_ERROR(Could not find a version of the Boost::Filesystem library!)
fi
if test "x$link_filesystem" != "xyes"; then
AC_MSG_ERROR(Could not link against $ax_lib !)
diff --git a/build-aux/m4/ax_boost_program_options.m4 b/build-aux/m4/ax_boost_program_options.m4
index f591441854..7d23da4648 100644
--- a/build-aux/m4/ax_boost_program_options.m4
+++ b/build-aux/m4/ax_boost_program_options.m4
@@ -1,6 +1,6 @@
-# ============================================================================
-# http://www.gnu.org/software/autoconf-archive/ax_boost_program_options.html
-# ============================================================================
+# =============================================================================
+# https://www.gnu.org/software/autoconf-archive/ax_boost_program_options.html
+# =============================================================================
#
# SYNOPSIS
#
@@ -29,7 +29,7 @@
# and this notice are preserved. This file is offered as-is, without any
# warranty.
-#serial 22
+#serial 26
AC_DEFUN([AX_BOOST_PROGRAM_OPTIONS],
[
@@ -63,9 +63,9 @@ AC_DEFUN([AX_BOOST_PROGRAM_OPTIONS],
AC_CACHE_CHECK([whether the Boost::Program_Options library is available],
ax_cv_boost_program_options,
[AC_LANG_PUSH(C++)
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[@%:@include
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[@%:@include
]],
- [[boost::program_options::options_description generic("Generic options");
+ [[boost::program_options::error err("Error message");
return 0;]])],
ax_cv_boost_program_options=yes, ax_cv_boost_program_options=no)
AC_LANG_POP([C++])
@@ -74,7 +74,6 @@ AC_DEFUN([AX_BOOST_PROGRAM_OPTIONS],
AC_DEFINE(HAVE_BOOST_PROGRAM_OPTIONS,,[define if the Boost::PROGRAM_OPTIONS library is available])
BOOSTLIBDIR=`echo $BOOST_LDFLAGS | sed -e 's/@<:@^\/@:>@*//'`
if test "x$ax_boost_user_program_options_lib" = "x"; then
- ax_lib=
for libextension in `ls $BOOSTLIBDIR/libboost_program_options*.so* 2>/dev/null | sed 's,.*/,,' | sed -e 's;^lib\(boost_program_options.*\)\.so.*$;\1;'` `ls $BOOSTLIBDIR/libboost_program_options*.dylib* 2>/dev/null | sed 's,.*/,,' | sed -e 's;^lib\(boost_program_options.*\)\.dylib.*$;\1;'` `ls $BOOSTLIBDIR/libboost_program_options*.a* 2>/dev/null | sed 's,.*/,,' | sed -e 's;^lib\(boost_program_options.*\)\.a.*$;\1;'` ; do
ax_lib=${libextension}
AC_CHECK_LIB($ax_lib, exit,
@@ -97,7 +96,7 @@ AC_DEFUN([AX_BOOST_PROGRAM_OPTIONS],
done
fi
if test "x$ax_lib" = "x"; then
- AC_MSG_ERROR(Could not find a version of the boost_program_options library!)
+ AC_MSG_ERROR(Could not find a version of the Boost::Program_Options library!)
fi
if test "x$link_program_options" != "xyes"; then
AC_MSG_ERROR([Could not link against [$ax_lib] !])
diff --git a/build-aux/m4/ax_boost_system.m4 b/build-aux/m4/ax_boost_system.m4
index 9c78280fca..323e2a676a 100644
--- a/build-aux/m4/ax_boost_system.m4
+++ b/build-aux/m4/ax_boost_system.m4
@@ -1,5 +1,5 @@
# ===========================================================================
-# http://www.gnu.org/software/autoconf-archive/ax_boost_system.html
+# https://www.gnu.org/software/autoconf-archive/ax_boost_system.html
# ===========================================================================
#
# SYNOPSIS
@@ -31,7 +31,7 @@
# and this notice are preserved. This file is offered as-is, without any
# warranty.
-#serial 17
+#serial 20
AC_DEFUN([AX_BOOST_SYSTEM],
[
@@ -68,9 +68,10 @@ AC_DEFUN([AX_BOOST_SYSTEM],
ax_cv_boost_system,
[AC_LANG_PUSH([C++])
CXXFLAGS_SAVE=$CXXFLAGS
+ CXXFLAGS=
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[@%:@include ]],
- [[boost::system::system_category]])],
+ [[boost::system::error_category *a = 0;]])],
ax_cv_boost_system=yes, ax_cv_boost_system=no)
CXXFLAGS=$CXXFLAGS_SAVE
AC_LANG_POP([C++])
@@ -83,7 +84,6 @@ AC_DEFUN([AX_BOOST_SYSTEM],
LDFLAGS_SAVE=$LDFLAGS
if test "x$ax_boost_user_system_lib" = "x"; then
- ax_lib=
for libextension in `ls -r $BOOSTLIBDIR/libboost_system* 2>/dev/null | sed 's,.*/lib,,' | sed 's,\..*,,'` ; do
ax_lib=${libextension}
AC_CHECK_LIB($ax_lib, exit,
@@ -108,7 +108,7 @@ AC_DEFUN([AX_BOOST_SYSTEM],
fi
if test "x$ax_lib" = "x"; then
- AC_MSG_ERROR(Could not find a version of the boost_system library!)
+ AC_MSG_ERROR(Could not find a version of the Boost::System library!)
fi
if test "x$link_system" = "xno"; then
AC_MSG_ERROR(Could not link against $ax_lib !)
diff --git a/build-aux/m4/ax_boost_thread.m4 b/build-aux/m4/ax_boost_thread.m4
index 9f0bd0b23c..75e80e6e75 100644
--- a/build-aux/m4/ax_boost_thread.m4
+++ b/build-aux/m4/ax_boost_thread.m4
@@ -1,5 +1,5 @@
# ===========================================================================
-# http://www.gnu.org/software/autoconf-archive/ax_boost_thread.html
+# https://www.gnu.org/software/autoconf-archive/ax_boost_thread.html
# ===========================================================================
#
# SYNOPSIS
@@ -30,73 +30,96 @@
# and this notice are preserved. This file is offered as-is, without any
# warranty.
-#serial 27
+#serial 33
AC_DEFUN([AX_BOOST_THREAD],
[
- AC_ARG_WITH([boost-thread],
- AS_HELP_STRING([--with-boost-thread@<:@=special-lib@:>@],
- [use the Thread library from boost - it is possible to specify a certain library for the linker
- e.g. --with-boost-thread=boost_thread-gcc-mt ]),
+ AC_ARG_WITH([boost-thread],
+ AS_HELP_STRING([--with-boost-thread@<:@=special-lib@:>@],
+ [use the Thread library from boost -
+ it is possible to specify a certain library for the linker
+ e.g. --with-boost-thread=boost_thread-gcc-mt ]),
[
- if test "$withval" = "no"; then
- want_boost="no"
- elif test "$withval" = "yes"; then
+ if test "$withval" = "yes"; then
want_boost="yes"
ax_boost_user_thread_lib=""
else
- want_boost="yes"
- ax_boost_user_thread_lib="$withval"
- fi
+ want_boost="yes"
+ ax_boost_user_thread_lib="$withval"
+ fi
],
[want_boost="yes"]
- )
+ )
- if test "x$want_boost" = "xyes"; then
+ if test "x$want_boost" = "xyes"; then
AC_REQUIRE([AC_PROG_CC])
AC_REQUIRE([AC_CANONICAL_BUILD])
- CPPFLAGS_SAVED="$CPPFLAGS"
- CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS"
- export CPPFLAGS
+ CPPFLAGS_SAVED="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS"
+ export CPPFLAGS
- LDFLAGS_SAVED="$LDFLAGS"
- LDFLAGS="$LDFLAGS $BOOST_LDFLAGS"
- export LDFLAGS
+ LDFLAGS_SAVED="$LDFLAGS"
+ LDFLAGS="$LDFLAGS $BOOST_LDFLAGS"
+ export LDFLAGS
AC_CACHE_CHECK(whether the Boost::Thread library is available,
- ax_cv_boost_thread,
+ ax_cv_boost_thread,
[AC_LANG_PUSH([C++])
- CXXFLAGS_SAVE=$CXXFLAGS
+ CXXFLAGS_SAVE=$CXXFLAGS
+
+ case "x$host_os" in
+ xsolaris )
+ CXXFLAGS="-pthreads $CXXFLAGS"
+ break;
+ ;;
+ xmingw32 )
+ CXXFLAGS="-mthreads $CXXFLAGS"
+ break;
+ ;;
+ *android* )
+ break;
+ ;;
+ * )
+ CXXFLAGS="-pthread $CXXFLAGS"
+ break;
+ ;;
+ esac
- if test "x$host_os" = "xsolaris" ; then
- CXXFLAGS="-pthreads $CXXFLAGS"
- elif test "x$host_os" = "xmingw32" ; then
- CXXFLAGS="-mthreads $CXXFLAGS"
- else
- CXXFLAGS="-pthread $CXXFLAGS"
- fi
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[@%:@include ]],
- [[boost::thread_group thrds;
- return 0;]])],
- ax_cv_boost_thread=yes, ax_cv_boost_thread=no)
- CXXFLAGS=$CXXFLAGS_SAVE
+ AC_COMPILE_IFELSE([
+ AC_LANG_PROGRAM(
+ [[@%:@include ]],
+ [[boost::thread_group thrds;
+ return 0;]])],
+ ax_cv_boost_thread=yes, ax_cv_boost_thread=no)
+ CXXFLAGS=$CXXFLAGS_SAVE
AC_LANG_POP([C++])
- ])
- if test "x$ax_cv_boost_thread" = "xyes"; then
- if test "x$host_os" = "xsolaris" ; then
- BOOST_CPPFLAGS="-pthreads $BOOST_CPPFLAGS"
- elif test "x$host_os" = "xmingw32" ; then
- BOOST_CPPFLAGS="-mthreads $BOOST_CPPFLAGS"
- else
- BOOST_CPPFLAGS="-pthread $BOOST_CPPFLAGS"
- fi
+ ])
+ if test "x$ax_cv_boost_thread" = "xyes"; then
+ case "x$host_os" in
+ xsolaris )
+ BOOST_CPPFLAGS="-pthreads $BOOST_CPPFLAGS"
+ break;
+ ;;
+ xmingw32 )
+ BOOST_CPPFLAGS="-mthreads $BOOST_CPPFLAGS"
+ break;
+ ;;
+ *android* )
+ break;
+ ;;
+ * )
+ BOOST_CPPFLAGS="-pthread $BOOST_CPPFLAGS"
+ break;
+ ;;
+ esac
- AC_SUBST(BOOST_CPPFLAGS)
+ AC_SUBST(BOOST_CPPFLAGS)
- AC_DEFINE(HAVE_BOOST_THREAD,,[define if the Boost::Thread library is available])
+ AC_DEFINE(HAVE_BOOST_THREAD,,
+ [define if the Boost::Thread library is available])
BOOSTLIBDIR=`echo $BOOST_LDFLAGS | sed -e 's/@<:@^\/@:>@*//'`
- LDFLAGS_SAVE=$LDFLAGS
+ LDFLAGS_SAVE=$LDFLAGS
case "x$host_os" in
*bsd* )
LDFLAGS="-pthread $LDFLAGS"
@@ -104,47 +127,61 @@ AC_DEFUN([AX_BOOST_THREAD],
;;
esac
if test "x$ax_boost_user_thread_lib" = "x"; then
- ax_lib=
for libextension in `ls -r $BOOSTLIBDIR/libboost_thread* 2>/dev/null | sed 's,.*/lib,,' | sed 's,\..*,,'`; do
ax_lib=${libextension}
- AC_CHECK_LIB($ax_lib, exit,
- [BOOST_THREAD_LIB="-l$ax_lib"; AC_SUBST(BOOST_THREAD_LIB) link_thread="yes"; break],
+ AC_CHECK_LIB($ax_lib, exit,
+ [link_thread="yes"; break],
[link_thread="no"])
- done
+ done
if test "x$link_thread" != "xyes"; then
for libextension in `ls -r $BOOSTLIBDIR/boost_thread* 2>/dev/null | sed 's,.*/,,' | sed 's,\..*,,'`; do
ax_lib=${libextension}
- AC_CHECK_LIB($ax_lib, exit,
- [BOOST_THREAD_LIB="-l$ax_lib"; AC_SUBST(BOOST_THREAD_LIB) link_thread="yes"; break],
+ AC_CHECK_LIB($ax_lib, exit,
+ [link_thread="yes"; break],
[link_thread="no"])
- done
+ done
fi
else
for ax_lib in $ax_boost_user_thread_lib boost_thread-$ax_boost_user_thread_lib; do
- AC_CHECK_LIB($ax_lib, exit,
- [BOOST_THREAD_LIB="-l$ax_lib"; AC_SUBST(BOOST_THREAD_LIB) link_thread="yes"; break],
+ AC_CHECK_LIB($ax_lib, exit,
+ [link_thread="yes"; break],
[link_thread="no"])
done
fi
if test "x$ax_lib" = "x"; then
- AC_MSG_ERROR(Could not find a version of the boost_thread library!)
+ AC_MSG_ERROR(Could not find a version of the Boost::Thread library!)
fi
- if test "x$link_thread" = "xno"; then
- AC_MSG_ERROR(Could not link against $ax_lib !)
- else
- case "x$host_os" in
- *bsd* )
- BOOST_LDFLAGS="-pthread $BOOST_LDFLAGS"
- break;
- ;;
- esac
-
- fi
- fi
+ if test "x$link_thread" = "xno"; then
+ AC_MSG_ERROR(Could not link against $ax_lib !)
+ else
+ BOOST_THREAD_LIB="-l$ax_lib"
+ case "x$host_os" in
+ *bsd* )
+ BOOST_LDFLAGS="-pthread $BOOST_LDFLAGS"
+ break;
+ ;;
+ xsolaris )
+ BOOST_THREAD_LIB="$BOOST_THREAD_LIB -lpthread"
+ break;
+ ;;
+ xmingw32 )
+ break;
+ ;;
+ *android* )
+ break;
+ ;;
+ * )
+ BOOST_THREAD_LIB="$BOOST_THREAD_LIB -lpthread"
+ break;
+ ;;
+ esac
+ AC_SUBST(BOOST_THREAD_LIB)
+ fi
+ fi
- CPPFLAGS="$CPPFLAGS_SAVED"
- LDFLAGS="$LDFLAGS_SAVED"
- fi
+ CPPFLAGS="$CPPFLAGS_SAVED"
+ LDFLAGS="$LDFLAGS_SAVED"
+ fi
])
diff --git a/build-aux/m4/ax_boost_unit_test_framework.m4 b/build-aux/m4/ax_boost_unit_test_framework.m4
index 4efd1e2f18..4cca32fcfd 100644
--- a/build-aux/m4/ax_boost_unit_test_framework.m4
+++ b/build-aux/m4/ax_boost_unit_test_framework.m4
@@ -1,6 +1,6 @@
-# ================================================================================
-# http://www.gnu.org/software/autoconf-archive/ax_boost_unit_test_framework.html
-# ================================================================================
+# =================================================================================
+# https://www.gnu.org/software/autoconf-archive/ax_boost_unit_test_framework.html
+# =================================================================================
#
# SYNOPSIS
#
@@ -29,7 +29,7 @@
# and this notice are preserved. This file is offered as-is, without any
# warranty.
-#serial 19
+#serial 22
AC_DEFUN([AX_BOOST_UNIT_TEST_FRAMEWORK],
[
@@ -66,7 +66,7 @@ AC_DEFUN([AX_BOOST_UNIT_TEST_FRAMEWORK],
[AC_LANG_PUSH([C++])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[@%:@include ]],
[[using boost::unit_test::test_suite;
- test_suite* test= BOOST_TEST_SUITE( "Unit test example 1" ); return 0;]])],
+ test_suite* test= BOOST_TEST_SUITE( "Unit test example 1" ); if (test == NULL) { return 1; } else { return 0; }]])],
ax_cv_boost_unit_test_framework=yes, ax_cv_boost_unit_test_framework=no)
AC_LANG_POP([C++])
])
@@ -76,7 +76,6 @@ AC_DEFUN([AX_BOOST_UNIT_TEST_FRAMEWORK],
if test "x$ax_boost_user_unit_test_framework_lib" = "x"; then
saved_ldflags="${LDFLAGS}"
- ax_lib=
for monitor_library in `ls $BOOSTLIBDIR/libboost_unit_test_framework*.so* $BOOSTLIBDIR/libboost_unit_test_framework*.dylib* $BOOSTLIBDIR/libboost_unit_test_framework*.a* 2>/dev/null` ; do
if test -r $monitor_library ; then
libextension=`echo $monitor_library | sed 's,.*/,,' | sed -e 's;^lib\(boost_unit_test_framework.*\)\.so.*$;\1;' -e 's;^lib\(boost_unit_test_framework.*\)\.dylib.*$;\1;' -e 's;^lib\(boost_unit_test_framework.*\)\.a.*$;\1;'`
@@ -125,7 +124,7 @@ AC_DEFUN([AX_BOOST_UNIT_TEST_FRAMEWORK],
done
fi
if test "x$ax_lib" = "x"; then
- AC_MSG_ERROR(Could not find a version of the boost_unit_test_framework library!)
+ AC_MSG_ERROR(Could not find a version of the Boost::Unit_Test_Framework library!)
fi
if test "x$link_unit_test_framework" != "xyes"; then
AC_MSG_ERROR(Could not link against $ax_lib !)
diff --git a/build-aux/m4/ax_check_compile_flag.m4 b/build-aux/m4/ax_check_compile_flag.m4
index c3a8d695a1..ca3639715e 100644
--- a/build-aux/m4/ax_check_compile_flag.m4
+++ b/build-aux/m4/ax_check_compile_flag.m4
@@ -4,7 +4,7 @@
#
# SYNOPSIS
#
-# AX_CHECK_COMPILE_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS])
+# AX_CHECK_COMPILE_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS], [INPUT])
#
# DESCRIPTION
#
@@ -19,6 +19,8 @@
# the flags: "CFLAGS EXTRA-FLAGS FLAG". This can for example be used to
# force the compiler to issue an error when a bad flag is given.
#
+# INPUT gives an alternative input source to AC_COMPILE_IFELSE.
+#
# NOTE: Implementation based on AX_CFLAGS_GCC_OPTION. Please keep this
# macro in sync with AX_CHECK_{PREPROC,LINK}_FLAG.
#
@@ -53,19 +55,19 @@
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.
-#serial 2
+#serial 4
AC_DEFUN([AX_CHECK_COMPILE_FLAG],
-[AC_PREREQ(2.59)dnl for _AC_LANG_PREFIX
+[AC_PREREQ(2.64)dnl for _AC_LANG_PREFIX and AS_VAR_IF
AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_[]_AC_LANG_ABBREV[]flags_$4_$1])dnl
AC_CACHE_CHECK([whether _AC_LANG compiler accepts $1], CACHEVAR, [
ax_check_save_flags=$[]_AC_LANG_PREFIX[]FLAGS
_AC_LANG_PREFIX[]FLAGS="$[]_AC_LANG_PREFIX[]FLAGS $4 $1"
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
+ AC_COMPILE_IFELSE([m4_default([$5],[AC_LANG_PROGRAM()])],
[AS_VAR_SET(CACHEVAR,[yes])],
[AS_VAR_SET(CACHEVAR,[no])])
_AC_LANG_PREFIX[]FLAGS=$ax_check_save_flags])
-AS_IF([test x"AS_VAR_GET(CACHEVAR)" = xyes],
+AS_VAR_IF(CACHEVAR,yes,
[m4_default([$2], :)],
[m4_default([$3], :)])
AS_VAR_POPDEF([CACHEVAR])dnl
diff --git a/build-aux/m4/ax_check_link_flag.m4 b/build-aux/m4/ax_check_link_flag.m4
index e2d0d363e4..eb01a6ce13 100644
--- a/build-aux/m4/ax_check_link_flag.m4
+++ b/build-aux/m4/ax_check_link_flag.m4
@@ -4,7 +4,7 @@
#
# SYNOPSIS
#
-# AX_CHECK_LINK_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS])
+# AX_CHECK_LINK_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS], [INPUT])
#
# DESCRIPTION
#
@@ -19,6 +19,8 @@
# EXTRA-FLAGS FLAG". This can for example be used to force the linker to
# issue an error when a bad flag is given.
#
+# INPUT gives an alternative input source to AC_LINK_IFELSE.
+#
# NOTE: Implementation based on AX_CFLAGS_GCC_OPTION. Please keep this
# macro in sync with AX_CHECK_{PREPROC,COMPILE}_FLAG.
#
@@ -53,18 +55,19 @@
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.
-#serial 2
+#serial 4
AC_DEFUN([AX_CHECK_LINK_FLAG],
-[AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_ldflags_$4_$1])dnl
+[AC_PREREQ(2.64)dnl for _AC_LANG_PREFIX and AS_VAR_IF
+AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_ldflags_$4_$1])dnl
AC_CACHE_CHECK([whether the linker accepts $1], CACHEVAR, [
ax_check_save_flags=$LDFLAGS
LDFLAGS="$LDFLAGS $4 $1"
- AC_LINK_IFELSE([AC_LANG_PROGRAM()],
+ AC_LINK_IFELSE([m4_default([$5],[AC_LANG_PROGRAM()])],
[AS_VAR_SET(CACHEVAR,[yes])],
[AS_VAR_SET(CACHEVAR,[no])])
LDFLAGS=$ax_check_save_flags])
-AS_IF([test x"AS_VAR_GET(CACHEVAR)" = xyes],
+AS_VAR_IF(CACHEVAR,yes,
[m4_default([$2], :)],
[m4_default([$3], :)])
AS_VAR_POPDEF([CACHEVAR])dnl
diff --git a/build-aux/m4/ax_check_preproc_flag.m4 b/build-aux/m4/ax_check_preproc_flag.m4
index b1cfef6b86..ca1d5ee2b6 100644
--- a/build-aux/m4/ax_check_preproc_flag.m4
+++ b/build-aux/m4/ax_check_preproc_flag.m4
@@ -4,7 +4,7 @@
#
# SYNOPSIS
#
-# AX_CHECK_PREPROC_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS])
+# AX_CHECK_PREPROC_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS], [INPUT])
#
# DESCRIPTION
#
@@ -19,6 +19,8 @@
# "CPPFLAGS EXTRA-FLAGS FLAG". This can for example be used to force the
# preprocessor to issue an error when a bad flag is given.
#
+# INPUT gives an alternative input source to AC_PREPROC_IFELSE.
+#
# NOTE: Implementation based on AX_CFLAGS_GCC_OPTION. Please keep this
# macro in sync with AX_CHECK_{COMPILE,LINK}_FLAG.
#
@@ -53,19 +55,19 @@
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.
-#serial 2
+#serial 4
AC_DEFUN([AX_CHECK_PREPROC_FLAG],
-[AC_PREREQ(2.59)dnl for _AC_LANG_PREFIX
+[AC_PREREQ(2.64)dnl for _AC_LANG_PREFIX and AS_VAR_IF
AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_[]_AC_LANG_ABBREV[]cppflags_$4_$1])dnl
AC_CACHE_CHECK([whether _AC_LANG preprocessor accepts $1], CACHEVAR, [
ax_check_save_flags=$CPPFLAGS
CPPFLAGS="$CPPFLAGS $4 $1"
- AC_PREPROC_IFELSE([AC_LANG_PROGRAM()],
+ AC_PREPROC_IFELSE([m4_default([$5],[AC_LANG_PROGRAM()])],
[AS_VAR_SET(CACHEVAR,[yes])],
[AS_VAR_SET(CACHEVAR,[no])])
CPPFLAGS=$ax_check_save_flags])
-AS_IF([test x"AS_VAR_GET(CACHEVAR)" = xyes],
+AS_VAR_IF(CACHEVAR,yes,
[m4_default([$2], :)],
[m4_default([$3], :)])
AS_VAR_POPDEF([CACHEVAR])dnl
diff --git a/build-aux/m4/ax_cxx_compile_stdcxx.m4 b/build-aux/m4/ax_cxx_compile_stdcxx.m4
index 2c18e49c56..43087b2e68 100644
--- a/build-aux/m4/ax_cxx_compile_stdcxx.m4
+++ b/build-aux/m4/ax_cxx_compile_stdcxx.m4
@@ -1,5 +1,5 @@
# ===========================================================================
-# http://www.gnu.org/software/autoconf-archive/ax_cxx_compile_stdcxx.html
+# https://www.gnu.org/software/autoconf-archive/ax_cxx_compile_stdcxx.html
# ===========================================================================
#
# SYNOPSIS
@@ -33,21 +33,23 @@
# Copyright (c) 2014, 2015 Google Inc.; contributed by Alexey Sokolov
# Copyright (c) 2015 Paul Norman
# Copyright (c) 2015 Moritz Klammler
+# Copyright (c) 2016, 2018 Krzesimir Nowak
+# Copyright (c) 2019 Enji Cooper
#
# Copying and distribution of this file, with or without modification, are
# permitted in any medium without royalty provided the copyright notice
# and this notice are preserved. This file is offered as-is, without any
# warranty.
-#serial 4
+#serial 11
dnl This macro is based on the code from the AX_CXX_COMPILE_STDCXX_11 macro
dnl (serial version number 13).
AC_DEFUN([AX_CXX_COMPILE_STDCXX], [dnl
- m4_if([$1], [11], [],
- [$1], [14], [],
- [$1], [17], [m4_fatal([support for C++17 not yet implemented in AX_CXX_COMPILE_STDCXX])],
+ m4_if([$1], [11], [ax_cxx_compile_alternatives="11 0x"],
+ [$1], [14], [ax_cxx_compile_alternatives="14 1y"],
+ [$1], [17], [ax_cxx_compile_alternatives="17 1z"],
[m4_fatal([invalid first argument `$1' to AX_CXX_COMPILE_STDCXX])])dnl
m4_if([$2], [], [],
[$2], [ext], [],
@@ -59,18 +61,11 @@ AC_DEFUN([AX_CXX_COMPILE_STDCXX], [dnl
[m4_fatal([invalid third argument `$3' to AX_CXX_COMPILE_STDCXX])])
AC_LANG_PUSH([C++])dnl
ac_success=no
- AC_CACHE_CHECK(whether $CXX supports C++$1 features by default,
- ax_cv_cxx_compile_cxx$1,
- [AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_testbody_$1])],
- [ax_cv_cxx_compile_cxx$1=yes],
- [ax_cv_cxx_compile_cxx$1=no])])
- if test x$ax_cv_cxx_compile_cxx$1 = xyes; then
- ac_success=yes
- fi
m4_if([$2], [noext], [], [dnl
if test x$ac_success = xno; then
- for switch in -std=gnu++$1 -std=gnu++0x; do
+ for alternative in ${ax_cxx_compile_alternatives}; do
+ switch="-std=gnu++${alternative}"
cachevar=AS_TR_SH([ax_cv_cxx_compile_cxx$1_$switch])
AC_CACHE_CHECK(whether $CXX supports C++$1 features with $switch,
$cachevar,
@@ -96,22 +91,27 @@ AC_DEFUN([AX_CXX_COMPILE_STDCXX], [dnl
dnl HP's aCC needs +std=c++11 according to:
dnl http://h21007.www2.hp.com/portal/download/files/unprot/aCxx/PDF_Release_Notes/769149-001.pdf
dnl Cray's crayCC needs "-h std=c++11"
- for switch in -std=c++$1 -std=c++0x +std=c++$1 "-h std=c++$1"; do
- cachevar=AS_TR_SH([ax_cv_cxx_compile_cxx$1_$switch])
- AC_CACHE_CHECK(whether $CXX supports C++$1 features with $switch,
- $cachevar,
- [ac_save_CXX="$CXX"
- CXX="$CXX $switch"
- AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_testbody_$1])],
- [eval $cachevar=yes],
- [eval $cachevar=no])
- CXX="$ac_save_CXX"])
- if eval test x\$$cachevar = xyes; then
- CXX="$CXX $switch"
- if test -n "$CXXCPP" ; then
- CXXCPP="$CXXCPP $switch"
+ for alternative in ${ax_cxx_compile_alternatives}; do
+ for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
+ cachevar=AS_TR_SH([ax_cv_cxx_compile_cxx$1_$switch])
+ AC_CACHE_CHECK(whether $CXX supports C++$1 features with $switch,
+ $cachevar,
+ [ac_save_CXX="$CXX"
+ CXX="$CXX $switch"
+ AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_testbody_$1])],
+ [eval $cachevar=yes],
+ [eval $cachevar=no])
+ CXX="$ac_save_CXX"])
+ if eval test x\$$cachevar = xyes; then
+ CXX="$CXX $switch"
+ if test -n "$CXXCPP" ; then
+ CXXCPP="$CXXCPP $switch"
+ fi
+ ac_success=yes
+ break
fi
- ac_success=yes
+ done
+ if test x$ac_success = xyes; then
break
fi
done
@@ -148,6 +148,11 @@ m4_define([_AX_CXX_COMPILE_STDCXX_testbody_14],
_AX_CXX_COMPILE_STDCXX_testbody_new_in_14
)
+m4_define([_AX_CXX_COMPILE_STDCXX_testbody_17],
+ _AX_CXX_COMPILE_STDCXX_testbody_new_in_11
+ _AX_CXX_COMPILE_STDCXX_testbody_new_in_14
+ _AX_CXX_COMPILE_STDCXX_testbody_new_in_17
+)
dnl Tests for new features in C++11
@@ -185,11 +190,13 @@ namespace cxx11
struct Base
{
+ virtual ~Base() {}
virtual void f() {}
};
struct Derived : public Base
{
+ virtual ~Derived() override {}
virtual void f() override {}
};
@@ -518,7 +525,7 @@ namespace cxx14
}
- namespace test_digit_seperators
+ namespace test_digit_separators
{
constexpr auto ten_million = 100'000'000;
@@ -560,3 +567,385 @@ namespace cxx14
#endif // __cplusplus >= 201402L
]])
+
+
+dnl Tests for new features in C++17
+
+m4_define([_AX_CXX_COMPILE_STDCXX_testbody_new_in_17], [[
+
+// If the compiler admits that it is not ready for C++17, why torture it?
+// Hopefully, this will speed up the test.
+
+#ifndef __cplusplus
+
+#error "This is not a C++ compiler"
+
+#elif __cplusplus < 201703L
+
+#error "This is not a C++17 compiler"
+
+#else
+
+#include
+#include
+#include
+
+namespace cxx17
+{
+
+ namespace test_constexpr_lambdas
+ {
+
+ constexpr int foo = [](){return 42;}();
+
+ }
+
+ namespace test::nested_namespace::definitions
+ {
+
+ }
+
+ namespace test_fold_expression
+ {
+
+ template
+ int multiply(Args... args)
+ {
+ return (args * ... * 1);
+ }
+
+ template
+ bool all(Args... args)
+ {
+ return (args && ...);
+ }
+
+ }
+
+ namespace test_extended_static_assert
+ {
+
+ static_assert (true);
+
+ }
+
+ namespace test_auto_brace_init_list
+ {
+
+ auto foo = {5};
+ auto bar {5};
+
+ static_assert(std::is_same, decltype(foo)>::value);
+ static_assert(std::is_same::value);
+ }
+
+ namespace test_typename_in_template_template_parameter
+ {
+
+ template typename X> struct D;
+
+ }
+
+ namespace test_fallthrough_nodiscard_maybe_unused_attributes
+ {
+
+ int f1()
+ {
+ return 42;
+ }
+
+ [[nodiscard]] int f2()
+ {
+ [[maybe_unused]] auto unused = f1();
+
+ switch (f1())
+ {
+ case 17:
+ f1();
+ [[fallthrough]];
+ case 42:
+ f1();
+ }
+ return f1();
+ }
+
+ }
+
+ namespace test_extended_aggregate_initialization
+ {
+
+ struct base1
+ {
+ int b1, b2 = 42;
+ };
+
+ struct base2
+ {
+ base2() {
+ b3 = 42;
+ }
+ int b3;
+ };
+
+ struct derived : base1, base2
+ {
+ int d;
+ };
+
+ derived d1 {{1, 2}, {}, 4}; // full initialization
+ derived d2 {{}, {}, 4}; // value-initialized bases
+
+ }
+
+ namespace test_general_range_based_for_loop
+ {
+
+ struct iter
+ {
+ int i;
+
+ int& operator* ()
+ {
+ return i;
+ }
+
+ const int& operator* () const
+ {
+ return i;
+ }
+
+ iter& operator++()
+ {
+ ++i;
+ return *this;
+ }
+ };
+
+ struct sentinel
+ {
+ int i;
+ };
+
+ bool operator== (const iter& i, const sentinel& s)
+ {
+ return i.i == s.i;
+ }
+
+ bool operator!= (const iter& i, const sentinel& s)
+ {
+ return !(i == s);
+ }
+
+ struct range
+ {
+ iter begin() const
+ {
+ return {0};
+ }
+
+ sentinel end() const
+ {
+ return {5};
+ }
+ };
+
+ void f()
+ {
+ range r {};
+
+ for (auto i : r)
+ {
+ [[maybe_unused]] auto v = i;
+ }
+ }
+
+ }
+
+ namespace test_lambda_capture_asterisk_this_by_value
+ {
+
+ struct t
+ {
+ int i;
+ int foo()
+ {
+ return [*this]()
+ {
+ return i;
+ }();
+ }
+ };
+
+ }
+
+ namespace test_enum_class_construction
+ {
+
+ enum class byte : unsigned char
+ {};
+
+ byte foo {42};
+
+ }
+
+ namespace test_constexpr_if
+ {
+
+ template
+ int f ()
+ {
+ if constexpr(cond)
+ {
+ return 13;
+ }
+ else
+ {
+ return 42;
+ }
+ }
+
+ }
+
+ namespace test_selection_statement_with_initializer
+ {
+
+ int f()
+ {
+ return 13;
+ }
+
+ int f2()
+ {
+ if (auto i = f(); i > 0)
+ {
+ return 3;
+ }
+
+ switch (auto i = f(); i + 4)
+ {
+ case 17:
+ return 2;
+
+ default:
+ return 1;
+ }
+ }
+
+ }
+
+ namespace test_template_argument_deduction_for_class_templates
+ {
+
+ template
+ struct pair
+ {
+ pair (T1 p1, T2 p2)
+ : m1 {p1},
+ m2 {p2}
+ {}
+
+ T1 m1;
+ T2 m2;
+ };
+
+ void f()
+ {
+ [[maybe_unused]] auto p = pair{13, 42u};
+ }
+
+ }
+
+ namespace test_non_type_auto_template_parameters
+ {
+
+ template
+ struct B
+ {};
+
+ B<5> b1;
+ B<'a'> b2;
+
+ }
+
+ namespace test_structured_bindings
+ {
+
+ int arr[2] = { 1, 2 };
+ std::pair pr = { 1, 2 };
+
+ auto f1() -> int(&)[2]
+ {
+ return arr;
+ }
+
+ auto f2() -> std::pair&
+ {
+ return pr;
+ }
+
+ struct S
+ {
+ int x1 : 2;
+ volatile double y1;
+ };
+
+ S f3()
+ {
+ return {};
+ }
+
+ auto [ x1, y1 ] = f1();
+ auto& [ xr1, yr1 ] = f1();
+ auto [ x2, y2 ] = f2();
+ auto& [ xr2, yr2 ] = f2();
+ const auto [ x3, y3 ] = f3();
+
+ }
+
+ namespace test_exception_spec_type_system
+ {
+
+ struct Good {};
+ struct Bad {};
+
+ void g1() noexcept;
+ void g2();
+
+ template
+ Bad
+ f(T*, T*);
+
+ template
+ Good
+ f(T1*, T2*);
+
+ static_assert (std::is_same_v);
+
+ }
+
+ namespace test_inline_variables
+ {
+
+ template void f(T)
+ {}
+
+ template inline T g(T)
+ {
+ return T{};
+ }
+
+ template<> inline void f<>(int)
+ {}
+
+ template<> int g<>(int)
+ {
+ return 5;
+ }
+
+ }
+
+} // namespace cxx17
+
+#endif // __cplusplus < 201703L
+
+]])
diff --git a/build-aux/m4/ax_gcc_func_attribute.m4 b/build-aux/m4/ax_gcc_func_attribute.m4
index 275ca63a2c..c788ca9bd4 100644
--- a/build-aux/m4/ax_gcc_func_attribute.m4
+++ b/build-aux/m4/ax_gcc_func_attribute.m4
@@ -31,6 +31,7 @@
# cold
# const
# constructor
+# constructor_priority for constructor attribute with priority
# deprecated
# destructor
# dllexport
@@ -73,7 +74,7 @@
# and this notice are preserved. This file is offered as-is, without any
# warranty.
-#serial 2
+#serial 3
AC_DEFUN([AX_GCC_FUNC_ATTRIBUTE], [
AS_VAR_PUSHDEF([ac_var], [ax_cv_have_func_attribute_$1])
@@ -103,6 +104,9 @@ AC_DEFUN([AX_GCC_FUNC_ATTRIBUTE], [
[const], [
int foo( void ) __attribute__(($1));
],
+ [constructor_priority], [
+ int foo( void ) __attribute__((__constructor__(65535/2)));
+ ],
[constructor], [
int foo( void ) __attribute__(($1));
],
@@ -180,6 +184,8 @@ AC_DEFUN([AX_GCC_FUNC_ATTRIBUTE], [
[visibility], [
int foo_def( void ) __attribute__(($1("default")));
int foo_hid( void ) __attribute__(($1("hidden")));
+ int foo_int( void ) __attribute__(($1("internal")));
+ int foo_pro( void ) __attribute__(($1("protected")));
],
[warning], [
int foo( void ) __attribute__(($1("")));
diff --git a/build-aux/m4/ax_pthread.m4 b/build-aux/m4/ax_pthread.m4
index d383ad5c6d..4c4051ea37 100644
--- a/build-aux/m4/ax_pthread.m4
+++ b/build-aux/m4/ax_pthread.m4
@@ -19,10 +19,10 @@
# is necessary on AIX to use the special cc_r compiler alias.)
#
# NOTE: You are assumed to not only compile your program with these flags,
-# but also link it with them as well. e.g. you should link with
+# but also to link with them as well. For example, you might link with
# $PTHREAD_CC $CFLAGS $PTHREAD_CFLAGS $LDFLAGS ... $PTHREAD_LIBS $LIBS
#
-# If you are only building threads programs, you may wish to use these
+# If you are only building threaded programs, you may wish to use these
# variables in your default LIBS, CFLAGS, and CC:
#
# LIBS="$PTHREAD_LIBS $LIBS"
@@ -30,8 +30,8 @@
# CC="$PTHREAD_CC"
#
# In addition, if the PTHREAD_CREATE_JOINABLE thread-attribute constant
-# has a nonstandard name, defines PTHREAD_CREATE_JOINABLE to that name
-# (e.g. PTHREAD_CREATE_UNDETACHED on AIX).
+# has a nonstandard name, this macro defines PTHREAD_CREATE_JOINABLE to
+# that name (e.g. PTHREAD_CREATE_UNDETACHED on AIX).
#
# Also HAVE_PTHREAD_PRIO_INHERIT is defined if pthread is found and the
# PTHREAD_PRIO_INHERIT symbol is defined when compiling with
@@ -82,35 +82,40 @@
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.
-#serial 21
+#serial 23
AU_ALIAS([ACX_PTHREAD], [AX_PTHREAD])
AC_DEFUN([AX_PTHREAD], [
AC_REQUIRE([AC_CANONICAL_HOST])
+AC_REQUIRE([AC_PROG_CC])
+AC_REQUIRE([AC_PROG_SED])
AC_LANG_PUSH([C])
ax_pthread_ok=no
# We used to check for pthread.h first, but this fails if pthread.h
-# requires special compiler flags (e.g. on True64 or Sequent).
+# requires special compiler flags (e.g. on Tru64 or Sequent).
# It gets checked for in the link test anyway.
# First of all, check if the user has set any of the PTHREAD_LIBS,
# etcetera environment variables, and if threads linking works using
# them:
-if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
- save_CFLAGS="$CFLAGS"
+if test "x$PTHREAD_CFLAGS$PTHREAD_LIBS" != "x"; then
+ ax_pthread_save_CC="$CC"
+ ax_pthread_save_CFLAGS="$CFLAGS"
+ ax_pthread_save_LIBS="$LIBS"
+ AS_IF([test "x$PTHREAD_CC" != "x"], [CC="$PTHREAD_CC"])
CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
- save_LIBS="$LIBS"
LIBS="$PTHREAD_LIBS $LIBS"
- AC_MSG_CHECKING([for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS])
- AC_TRY_LINK_FUNC([pthread_join], [ax_pthread_ok=yes])
+ AC_MSG_CHECKING([for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS])
+ AC_LINK_IFELSE([AC_LANG_CALL([], [pthread_join])], [ax_pthread_ok=yes])
AC_MSG_RESULT([$ax_pthread_ok])
- if test x"$ax_pthread_ok" = xno; then
+ if test "x$ax_pthread_ok" = "xno"; then
PTHREAD_LIBS=""
PTHREAD_CFLAGS=""
fi
- LIBS="$save_LIBS"
- CFLAGS="$save_CFLAGS"
+ CC="$ax_pthread_save_CC"
+ CFLAGS="$ax_pthread_save_CFLAGS"
+ LIBS="$ax_pthread_save_LIBS"
fi
# We must check for the threads library under a number of different
@@ -123,7 +128,7 @@ fi
# which indicates that we try without any flags at all, and "pthread-config"
# which is a program returning the flags for the Pth emulation library.
-ax_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
+ax_pthread_flags="pthreads none -Kthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
# The ordering *is* (sometimes) important. Some notes on the
# individual items follow:
@@ -132,82 +137,225 @@ ax_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mt
# none: in case threads are in libc; should be tried before -Kthread and
# other compiler flags to prevent continual compiler warnings
# -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
-# -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
-# lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
-# -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
-# -pthreads: Solaris/gcc
-# -mthreads: Mingw32/gcc, Lynx/gcc
+# -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads), Tru64
+# (Note: HP C rejects this with "bad form for `-t' option")
+# -pthreads: Solaris/gcc (Note: HP C also rejects)
# -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
-# doesn't hurt to check since this sometimes defines pthreads too;
-# also defines -D_REENTRANT)
-# ... -mt is also the pthreads flag for HP/aCC
+# doesn't hurt to check since this sometimes defines pthreads and
+# -D_REENTRANT too), HP C (must be checked before -lpthread, which
+# is present but should not be used directly; and before -mthreads,
+# because the compiler interprets this as "-mt" + "-hreads")
+# -mthreads: Mingw32/gcc, Lynx/gcc
# pthread: Linux, etcetera
# --thread-safe: KAI C++
# pthread-config: use pthread-config program (for GNU Pth library)
-case ${host_os} in
+case $host_os in
+
+ freebsd*)
+
+ # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
+ # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
+
+ ax_pthread_flags="-kthread lthread $ax_pthread_flags"
+ ;;
+
+ hpux*)
+
+ # From the cc(1) man page: "[-mt] Sets various -D flags to enable
+ # multi-threading and also sets -lpthread."
+
+ ax_pthread_flags="-mt -pthread pthread $ax_pthread_flags"
+ ;;
+
+ openedition*)
+
+ # IBM z/OS requires a feature-test macro to be defined in order to
+ # enable POSIX threads at all, so give the user a hint if this is
+ # not set. (We don't define these ourselves, as they can affect
+ # other portions of the system API in unpredictable ways.)
+
+ AC_EGREP_CPP([AX_PTHREAD_ZOS_MISSING],
+ [
+# if !defined(_OPEN_THREADS) && !defined(_UNIX03_THREADS)
+ AX_PTHREAD_ZOS_MISSING
+# endif
+ ],
+ [AC_MSG_WARN([IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support.])])
+ ;;
+
solaris*)
# On Solaris (at least, for some versions), libc contains stubbed
# (non-functional) versions of the pthreads routines, so link-based
- # tests will erroneously succeed. (We need to link with -pthreads/-mt/
- # -lpthread.) (The stubs are missing pthread_cleanup_push, or rather
- # a function called by this macro, so we could check for that, but
- # who knows whether they'll stub that too in a future libc.) So,
- # we'll just look for -pthreads and -lpthread first:
+ # tests will erroneously succeed. (N.B.: The stubs are missing
+ # pthread_cleanup_push, or rather a function called by this macro,
+ # so we could check for that, but who knows whether they'll stub
+ # that too in a future libc.) So we'll check first for the
+ # standard Solaris way of linking pthreads (-mt -lpthread).
+
+ ax_pthread_flags="-mt,pthread pthread $ax_pthread_flags"
+ ;;
+esac
+
+# GCC generally uses -pthread, or -pthreads on some platforms (e.g. SPARC)
- ax_pthread_flags="-pthreads pthread -mt -pthread $ax_pthread_flags"
+AS_IF([test "x$GCC" = "xyes"],
+ [ax_pthread_flags="-pthread -pthreads $ax_pthread_flags"])
+
+# The presence of a feature test macro requesting re-entrant function
+# definitions is, on some systems, a strong hint that pthreads support is
+# correctly enabled
+
+case $host_os in
+ darwin* | hpux* | linux* | osf* | solaris*)
+ ax_pthread_check_macro="_REENTRANT"
;;
- darwin*)
- ax_pthread_flags="-pthread $ax_pthread_flags"
+ aix*)
+ ax_pthread_check_macro="_THREAD_SAFE"
+ ;;
+
+ *)
+ ax_pthread_check_macro="--"
;;
esac
+AS_IF([test "x$ax_pthread_check_macro" = "x--"],
+ [ax_pthread_check_cond=0],
+ [ax_pthread_check_cond="!defined($ax_pthread_check_macro)"])
+
+# Are we compiling with Clang?
+
+AC_CACHE_CHECK([whether $CC is Clang],
+ [ax_cv_PTHREAD_CLANG],
+ [ax_cv_PTHREAD_CLANG=no
+ # Note that Autoconf sets GCC=yes for Clang as well as GCC
+ if test "x$GCC" = "xyes"; then
+ AC_EGREP_CPP([AX_PTHREAD_CC_IS_CLANG],
+ [/* Note: Clang 2.7 lacks __clang_[a-z]+__ */
+# if defined(__clang__) && defined(__llvm__)
+ AX_PTHREAD_CC_IS_CLANG
+# endif
+ ],
+ [ax_cv_PTHREAD_CLANG=yes])
+ fi
+ ])
+ax_pthread_clang="$ax_cv_PTHREAD_CLANG"
+
+ax_pthread_clang_warning=no
+
+# Clang needs special handling, because older versions handle the -pthread
+# option in a rather... idiosyncratic way
+
+if test "x$ax_pthread_clang" = "xyes"; then
+
+ # Clang takes -pthread; it has never supported any other flag
+
+ # (Note 1: This will need to be revisited if a system that Clang
+ # supports has POSIX threads in a separate library. This tends not
+ # to be the way of modern systems, but it's conceivable.)
+
+ # (Note 2: On some systems, notably Darwin, -pthread is not needed
+ # to get POSIX threads support; the API is always present and
+ # active. We could reasonably leave PTHREAD_CFLAGS empty. But
+ # -pthread does define _REENTRANT, and while the Darwin headers
+ # ignore this macro, third-party headers might not.)
+
+ PTHREAD_CFLAGS="-pthread"
+ PTHREAD_LIBS=
+
+ ax_pthread_ok=yes
+
+ # However, older versions of Clang make a point of warning the user
+ # that, in an invocation where only linking and no compilation is
+ # taking place, the -pthread option has no effect ("argument unused
+ # during compilation"). They expect -pthread to be passed in only
+ # when source code is being compiled.
+ #
+ # Problem is, this is at odds with the way Automake and most other
+ # C build frameworks function, which is that the same flags used in
+ # compilation (CFLAGS) are also used in linking. Many systems
+ # supported by AX_PTHREAD require exactly this for POSIX threads
+ # support, and in fact it is often not straightforward to specify a
+ # flag that is used only in the compilation phase and not in
+ # linking. Such a scenario is extremely rare in practice.
+ #
+ # Even though use of the -pthread flag in linking would only print
+ # a warning, this can be a nuisance for well-run software projects
+ # that build with -Werror. So if the active version of Clang has
+ # this misfeature, we search for an option to squash it.
+
+ AC_CACHE_CHECK([whether Clang needs flag to prevent "argument unused" warning when linking with -pthread],
+ [ax_cv_PTHREAD_CLANG_NO_WARN_FLAG],
+ [ax_cv_PTHREAD_CLANG_NO_WARN_FLAG=unknown
+ # Create an alternate version of $ac_link that compiles and
+ # links in two steps (.c -> .o, .o -> exe) instead of one
+ # (.c -> exe), because the warning occurs only in the second
+ # step
+ ax_pthread_save_ac_link="$ac_link"
+ ax_pthread_sed='s/conftest\.\$ac_ext/conftest.$ac_objext/g'
+ ax_pthread_link_step=`$as_echo "$ac_link" | sed "$ax_pthread_sed"`
+ ax_pthread_2step_ac_link="($ac_compile) && (echo ==== >&5) && ($ax_pthread_link_step)"
+ ax_pthread_save_CFLAGS="$CFLAGS"
+ for ax_pthread_try in '' -Qunused-arguments -Wno-unused-command-line-argument unknown; do
+ AS_IF([test "x$ax_pthread_try" = "xunknown"], [break])
+ CFLAGS="-Werror -Wunknown-warning-option $ax_pthread_try -pthread $ax_pthread_save_CFLAGS"
+ ac_link="$ax_pthread_save_ac_link"
+ AC_LINK_IFELSE([AC_LANG_SOURCE([[int main(void){return 0;}]])],
+ [ac_link="$ax_pthread_2step_ac_link"
+ AC_LINK_IFELSE([AC_LANG_SOURCE([[int main(void){return 0;}]])],
+ [break])
+ ])
+ done
+ ac_link="$ax_pthread_save_ac_link"
+ CFLAGS="$ax_pthread_save_CFLAGS"
+ AS_IF([test "x$ax_pthread_try" = "x"], [ax_pthread_try=no])
+ ax_cv_PTHREAD_CLANG_NO_WARN_FLAG="$ax_pthread_try"
+ ])
-# Clang doesn't consider unrecognized options an error unless we specify
-# -Werror. We throw in some extra Clang-specific options to ensure that
-# this doesn't happen for GCC, which also accepts -Werror.
+ case "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" in
+ no | unknown) ;;
+ *) PTHREAD_CFLAGS="$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG $PTHREAD_CFLAGS" ;;
+ esac
-AC_MSG_CHECKING([if compiler needs -Werror to reject unknown flags])
-save_CFLAGS="$CFLAGS"
-ax_pthread_extra_flags="-Werror"
-CFLAGS="$CFLAGS $ax_pthread_extra_flags -Wunknown-warning-option -Wsizeof-array-argument"
-AC_COMPILE_IFELSE([AC_LANG_PROGRAM([int foo(void);],[foo()])],
- [AC_MSG_RESULT([yes])],
- [ax_pthread_extra_flags=
- AC_MSG_RESULT([no])])
-CFLAGS="$save_CFLAGS"
+fi # $ax_pthread_clang = yes
-if test x"$ax_pthread_ok" = xno; then
-for flag in $ax_pthread_flags; do
+if test "x$ax_pthread_ok" = "xno"; then
+for ax_pthread_try_flag in $ax_pthread_flags; do
- case $flag in
+ case $ax_pthread_try_flag in
none)
AC_MSG_CHECKING([whether pthreads work without any flags])
;;
+ -mt,pthread)
+ AC_MSG_CHECKING([whether pthreads work with -mt -lpthread])
+ PTHREAD_CFLAGS="-mt"
+ PTHREAD_LIBS="-lpthread"
+ ;;
+
-*)
- AC_MSG_CHECKING([whether pthreads work with $flag])
- PTHREAD_CFLAGS="$flag"
+ AC_MSG_CHECKING([whether pthreads work with $ax_pthread_try_flag])
+ PTHREAD_CFLAGS="$ax_pthread_try_flag"
;;
pthread-config)
AC_CHECK_PROG([ax_pthread_config], [pthread-config], [yes], [no])
- if test x"$ax_pthread_config" = xno; then continue; fi
+ AS_IF([test "x$ax_pthread_config" = "xno"], [continue])
PTHREAD_CFLAGS="`pthread-config --cflags`"
PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
;;
*)
- AC_MSG_CHECKING([for the pthreads library -l$flag])
- PTHREAD_LIBS="-l$flag"
+ AC_MSG_CHECKING([for the pthreads library -l$ax_pthread_try_flag])
+ PTHREAD_LIBS="-l$ax_pthread_try_flag"
;;
esac
- save_LIBS="$LIBS"
- save_CFLAGS="$CFLAGS"
+ ax_pthread_save_CFLAGS="$CFLAGS"
+ ax_pthread_save_LIBS="$LIBS"
+ CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
LIBS="$PTHREAD_LIBS $LIBS"
- CFLAGS="$CFLAGS $PTHREAD_CFLAGS $ax_pthread_extra_flags"
# Check for various functions. We must include pthread.h,
# since some functions may be macros. (On the Sequent, we
@@ -218,7 +366,11 @@ for flag in $ax_pthread_flags; do
# pthread_cleanup_push because it is one of the few pthread
# functions on Solaris that doesn't have a non-functional libc stub.
# We try pthread_create on general principles.
+
AC_LINK_IFELSE([AC_LANG_PROGRAM([#include
+# if $ax_pthread_check_cond
+# error "$ax_pthread_check_macro must be defined"
+# endif
static void routine(void *a) { a = 0; }
static void *start_routine(void *a) { return a; }],
[pthread_t th; pthread_attr_t attr;
@@ -227,16 +379,14 @@ for flag in $ax_pthread_flags; do
pthread_attr_init(&attr);
pthread_cleanup_push(routine, 0);
pthread_cleanup_pop(0) /* ; */])],
- [ax_pthread_ok=yes],
- [])
+ [ax_pthread_ok=yes],
+ [])
- LIBS="$save_LIBS"
- CFLAGS="$save_CFLAGS"
+ CFLAGS="$ax_pthread_save_CFLAGS"
+ LIBS="$ax_pthread_save_LIBS"
AC_MSG_RESULT([$ax_pthread_ok])
- if test "x$ax_pthread_ok" = xyes; then
- break;
- fi
+ AS_IF([test "x$ax_pthread_ok" = "xyes"], [break])
PTHREAD_LIBS=""
PTHREAD_CFLAGS=""
@@ -244,71 +394,74 @@ done
fi
# Various other checks:
-if test "x$ax_pthread_ok" = xyes; then
- save_LIBS="$LIBS"
- LIBS="$PTHREAD_LIBS $LIBS"
- save_CFLAGS="$CFLAGS"
+if test "x$ax_pthread_ok" = "xyes"; then
+ ax_pthread_save_CFLAGS="$CFLAGS"
+ ax_pthread_save_LIBS="$LIBS"
CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
+ LIBS="$PTHREAD_LIBS $LIBS"
# Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
- AC_MSG_CHECKING([for joinable pthread attribute])
- attr_name=unknown
- for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
- AC_LINK_IFELSE([AC_LANG_PROGRAM([#include ],
- [int attr = $attr; return attr /* ; */])],
- [attr_name=$attr; break],
- [])
- done
- AC_MSG_RESULT([$attr_name])
- if test "$attr_name" != PTHREAD_CREATE_JOINABLE; then
- AC_DEFINE_UNQUOTED([PTHREAD_CREATE_JOINABLE], [$attr_name],
- [Define to necessary symbol if this constant
- uses a non-standard name on your system.])
- fi
-
- AC_MSG_CHECKING([if more special flags are required for pthreads])
- flag=no
- case ${host_os} in
- aix* | freebsd* | darwin*) flag="-D_THREAD_SAFE";;
- osf* | hpux*) flag="-D_REENTRANT";;
- solaris*)
- if test "$GCC" = "yes"; then
- flag="-D_REENTRANT"
- else
- # TODO: What about Clang on Solaris?
- flag="-mt -D_REENTRANT"
- fi
- ;;
- esac
- AC_MSG_RESULT([$flag])
- if test "x$flag" != xno; then
- PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
- fi
+ AC_CACHE_CHECK([for joinable pthread attribute],
+ [ax_cv_PTHREAD_JOINABLE_ATTR],
+ [ax_cv_PTHREAD_JOINABLE_ATTR=unknown
+ for ax_pthread_attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
+ AC_LINK_IFELSE([AC_LANG_PROGRAM([#include ],
+ [int attr = $ax_pthread_attr; return attr /* ; */])],
+ [ax_cv_PTHREAD_JOINABLE_ATTR=$ax_pthread_attr; break],
+ [])
+ done
+ ])
+ AS_IF([test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xunknown" && \
+ test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xPTHREAD_CREATE_JOINABLE" && \
+ test "x$ax_pthread_joinable_attr_defined" != "xyes"],
+ [AC_DEFINE_UNQUOTED([PTHREAD_CREATE_JOINABLE],
+ [$ax_cv_PTHREAD_JOINABLE_ATTR],
+ [Define to necessary symbol if this constant
+ uses a non-standard name on your system.])
+ ax_pthread_joinable_attr_defined=yes
+ ])
+
+ AC_CACHE_CHECK([whether more special flags are required for pthreads],
+ [ax_cv_PTHREAD_SPECIAL_FLAGS],
+ [ax_cv_PTHREAD_SPECIAL_FLAGS=no
+ case $host_os in
+ solaris*)
+ ax_cv_PTHREAD_SPECIAL_FLAGS="-D_POSIX_PTHREAD_SEMANTICS"
+ ;;
+ esac
+ ])
+ AS_IF([test "x$ax_cv_PTHREAD_SPECIAL_FLAGS" != "xno" && \
+ test "x$ax_pthread_special_flags_added" != "xyes"],
+ [PTHREAD_CFLAGS="$ax_cv_PTHREAD_SPECIAL_FLAGS $PTHREAD_CFLAGS"
+ ax_pthread_special_flags_added=yes])
AC_CACHE_CHECK([for PTHREAD_PRIO_INHERIT],
- [ax_cv_PTHREAD_PRIO_INHERIT], [
- AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include ]],
- [[int i = PTHREAD_PRIO_INHERIT;]])],
- [ax_cv_PTHREAD_PRIO_INHERIT=yes],
- [ax_cv_PTHREAD_PRIO_INHERIT=no])
+ [ax_cv_PTHREAD_PRIO_INHERIT],
+ [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include ]],
+ [[int i = PTHREAD_PRIO_INHERIT;]])],
+ [ax_cv_PTHREAD_PRIO_INHERIT=yes],
+ [ax_cv_PTHREAD_PRIO_INHERIT=no])
])
- AS_IF([test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes"],
- [AC_DEFINE([HAVE_PTHREAD_PRIO_INHERIT], [1], [Have PTHREAD_PRIO_INHERIT.])])
+ AS_IF([test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes" && \
+ test "x$ax_pthread_prio_inherit_defined" != "xyes"],
+ [AC_DEFINE([HAVE_PTHREAD_PRIO_INHERIT], [1], [Have PTHREAD_PRIO_INHERIT.])
+ ax_pthread_prio_inherit_defined=yes
+ ])
- LIBS="$save_LIBS"
- CFLAGS="$save_CFLAGS"
+ CFLAGS="$ax_pthread_save_CFLAGS"
+ LIBS="$ax_pthread_save_LIBS"
# More AIX lossage: compile with *_r variant
- if test "x$GCC" != xyes; then
+ if test "x$GCC" != "xyes"; then
case $host_os in
aix*)
AS_CASE(["x/$CC"],
- [x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6],
- [#handle absolute path differently from PATH based program lookup
- AS_CASE(["x$CC"],
- [x/*],
- [AS_IF([AS_EXECUTABLE_P([${CC}_r])],[PTHREAD_CC="${CC}_r"])],
- [AC_CHECK_PROGS([PTHREAD_CC],[${CC}_r],[$CC])])])
+ [x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6],
+ [#handle absolute path differently from PATH based program lookup
+ AS_CASE(["x$CC"],
+ [x/*],
+ [AS_IF([AS_EXECUTABLE_P([${CC}_r])],[PTHREAD_CC="${CC}_r"])],
+ [AC_CHECK_PROGS([PTHREAD_CC],[${CC}_r],[$CC])])])
;;
esac
fi
@@ -321,7 +474,7 @@ AC_SUBST([PTHREAD_CFLAGS])
AC_SUBST([PTHREAD_CC])
# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
-if test x"$ax_pthread_ok" = xyes; then
+if test "x$ax_pthread_ok" = "xyes"; then
ifelse([$1],,[AC_DEFINE([HAVE_PTHREAD],[1],[Define if you have POSIX threads libraries and header files.])],[$1])
:
else
diff --git a/build-aux/m4/bitcoin_find_bdb48.m4 b/build-aux/m4/bitcoin_find_bdb48.m4
index f3b14461eb..2dbf0ea099 100644
--- a/build-aux/m4/bitcoin_find_bdb48.m4
+++ b/build-aux/m4/bitcoin_find_bdb48.m4
@@ -1,66 +1,77 @@
+dnl Copyright (c) 2013-2015 The Bitcoin Core developers
+dnl Distributed under the MIT software license, see the accompanying
+dnl file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
AC_DEFUN([BITCOIN_FIND_BDB48],[
- AC_MSG_CHECKING([for Berkeley DB C++ headers])
- BDB_CPPFLAGS=
- BDB_LIBS=
- bdbpath=X
- bdb48path=X
- bdbdirlist=
- for _vn in 4.8 48 4 5 ''; do
- for _pfx in b lib ''; do
- bdbdirlist="$bdbdirlist ${_pfx}db${_vn}"
+ AC_ARG_VAR(BDB_CFLAGS, [C compiler flags for BerkeleyDB, bypasses autodetection])
+ AC_ARG_VAR(BDB_LIBS, [Linker flags for BerkeleyDB, bypasses autodetection])
+
+ if test "x$BDB_CFLAGS" = "x"; then
+ AC_MSG_CHECKING([for Berkeley DB C++ headers])
+ BDB_CPPFLAGS=
+ bdbpath=X
+ bdb48path=X
+ bdbdirlist=
+ for _vn in 4.8 48 4 5 5.3 ''; do
+ for _pfx in b lib ''; do
+ bdbdirlist="$bdbdirlist ${_pfx}db${_vn}"
+ done
done
- done
- for searchpath in $bdbdirlist ''; do
- test -n "${searchpath}" && searchpath="${searchpath}/"
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
- #include <${searchpath}db_cxx.h>
- ]],[[
- #if !((DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR >= 8) || DB_VERSION_MAJOR > 4)
- #error "failed to find bdb 4.8+"
- #endif
- ]])],[
- if test "x$bdbpath" = "xX"; then
- bdbpath="${searchpath}"
- fi
- ],[
- continue
- ])
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
- #include <${searchpath}db_cxx.h>
- ]],[[
- #if !(DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR == 8)
- #error "failed to find bdb 4.8"
- #endif
- ]])],[
- bdb48path="${searchpath}"
- break
- ],[])
- done
- if test "x$bdbpath" = "xX"; then
- AC_MSG_RESULT([no])
- AC_MSG_ERROR(libdb_cxx headers missing)
- elif test "x$bdb48path" = "xX"; then
- BITCOIN_SUBDIR_TO_INCLUDE(BDB_CPPFLAGS,[${bdbpath}],db_cxx)
- AC_ARG_WITH([incompatible-bdb],[AS_HELP_STRING([--with-incompatible-bdb], [allow using a bdb version other than 4.8])],[
- AC_MSG_WARN([Found Berkeley DB other than 4.8; wallets opened by this build will not be portable!])
- ],[
- AC_MSG_ERROR([Found Berkeley DB other than 4.8, required for portable wallets (--with-incompatible-bdb to ignore or --disable-wallet to disable wallet functionality)])
- ])
+ for searchpath in $bdbdirlist ''; do
+ test -n "${searchpath}" && searchpath="${searchpath}/"
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+ #include <${searchpath}db_cxx.h>
+ ]],[[
+ #if !((DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR >= 8) || DB_VERSION_MAJOR > 4)
+ #error "failed to find bdb 4.8+"
+ #endif
+ ]])],[
+ if test "x$bdbpath" = "xX"; then
+ bdbpath="${searchpath}"
+ fi
+ ],[
+ continue
+ ])
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+ #include <${searchpath}db_cxx.h>
+ ]],[[
+ #if !(DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR == 8)
+ #error "failed to find bdb 4.8"
+ #endif
+ ]])],[
+ bdb48path="${searchpath}"
+ break
+ ],[])
+ done
+ if test "x$bdbpath" = "xX"; then
+ AC_MSG_RESULT([no])
+ AC_MSG_ERROR([libdb_cxx headers missing, ]AC_PACKAGE_NAME[ requires this library for wallet functionality (--disable-wallet to disable wallet functionality)])
+ elif test "x$bdb48path" = "xX"; then
+ BITCOIN_SUBDIR_TO_INCLUDE(BDB_CPPFLAGS,[${bdbpath}],db_cxx)
+ AC_ARG_WITH([incompatible-bdb],[AS_HELP_STRING([--with-incompatible-bdb], [allow using a bdb version other than 4.8])],[
+ AC_MSG_WARN([Found Berkeley DB other than 4.8; wallets opened by this build will not be portable!])
+ ],[
+ AC_MSG_ERROR([Found Berkeley DB other than 4.8, required for portable wallets (--with-incompatible-bdb to ignore or --disable-wallet to disable wallet functionality)])
+ ])
+ else
+ BITCOIN_SUBDIR_TO_INCLUDE(BDB_CPPFLAGS,[${bdb48path}],db_cxx)
+ bdbpath="${bdb48path}"
+ fi
else
- BITCOIN_SUBDIR_TO_INCLUDE(BDB_CPPFLAGS,[${bdb48path}],db_cxx)
- bdbpath="${bdb48path}"
+ BDB_CPPFLAGS=${BDB_CFLAGS}
fi
AC_SUBST(BDB_CPPFLAGS)
- # TODO: Ideally this could find the library version and make sure it matches the headers being used
- for searchlib in db_cxx-4.8 db_cxx; do
- AC_CHECK_LIB([$searchlib],[main],[
- BDB_LIBS="-l${searchlib}"
- break
- ])
- done
if test "x$BDB_LIBS" = "x"; then
- AC_MSG_ERROR([libdb_cxx missing, Bitcoin Core requires this library for wallet functionality (--disable-wallet to disable wallet functionality)])
+ # TODO: Ideally this could find the library version and make sure it matches the headers being used
+ for searchlib in db_cxx-4.8 db_cxx db4_cxx; do
+ AC_CHECK_LIB([$searchlib],[main],[
+ BDB_LIBS="-l${searchlib}"
+ break
+ ])
+ done
+ if test "x$BDB_LIBS" = "x"; then
+ AC_MSG_ERROR([libdb_cxx missing, ]AC_PACKAGE_NAME[ requires this library for wallet functionality (--disable-wallet to disable wallet functionality)])
+ fi
fi
- AC_SUBST(BDB_LIBS)
])
diff --git a/build-aux/m4/bitcoin_qt.m4 b/build-aux/m4/bitcoin_qt.m4
index c828cc09d0..5cc6c78552 100644
--- a/build-aux/m4/bitcoin_qt.m4
+++ b/build-aux/m4/bitcoin_qt.m4
@@ -7,7 +7,7 @@ dnl Output: If qt version is auto, set bitcoin_enable_qt to false. Else, exit.
AC_DEFUN([BITCOIN_QT_FAIL],[
if test "x$bitcoin_qt_want_version" = xauto && test "x$bitcoin_qt_force" != xyes; then
if test "x$bitcoin_enable_qt" != xno; then
- AC_MSG_WARN([$1; dapscoin-qt frontend will not be built])
+ AC_MSG_WARN([$1; prcycoin-qt frontend will not be built])
fi
bitcoin_enable_qt=no
bitcoin_enable_qt_test=no
@@ -54,7 +54,7 @@ AC_DEFUN([BITCOIN_QT_INIT],[
dnl enable qt support
AC_ARG_WITH([gui],
[AS_HELP_STRING([--with-gui@<:@=no|qt5|auto@:>@],
- [build dapscoin-qt GUI (default=auto)])],
+ [build prcycoin-qt GUI (default=auto)])],
[
bitcoin_qt_want_version=$withval
if test "x$bitcoin_qt_want_version" = xyes; then
@@ -64,6 +64,13 @@ AC_DEFUN([BITCOIN_QT_INIT],[
],
[bitcoin_qt_want_version=auto])
+ AS_IF([test "x$with_gui" = xqt5_debug],
+ [AS_CASE([$host],
+ [*darwin*], [qt_lib_suffix=_debug],
+ [*mingw*], [qt_lib_suffix=d],
+ [qt_lib_suffix= ]); bitcoin_qt_want_version=qt5],
+ [qt_lib_suffix= ])
+
AC_ARG_WITH([qt-incdir],[AS_HELP_STRING([--with-qt-incdir=INC_DIR],[specify qt include path (overridden by pkgconfig)])], [qt_include_path=$withval], [])
AC_ARG_WITH([qt-libdir],[AS_HELP_STRING([--with-qt-libdir=LIB_DIR],[specify qt lib path (overridden by pkgconfig)])], [qt_lib_path=$withval], [])
AC_ARG_WITH([qt-plugindir],[AS_HELP_STRING([--with-qt-plugindir=PLUGIN_DIR],[specify qt plugin path (overridden by pkgconfig)])], [qt_plugin_path=$withval], [])
@@ -72,41 +79,38 @@ AC_DEFUN([BITCOIN_QT_INIT],[
AC_ARG_WITH([qtdbus],
[AS_HELP_STRING([--with-qtdbus],
- [enable DBus support (default is yes if qt is enabled and QtDBus is found)])],
+ [enable DBus support (default is yes if qt is enabled and QtDBus is found, except on Android)])],
[use_dbus=$withval],
[use_dbus=auto])
+ dnl Android doesn't support D-Bus and certainly doesn't use it for notifications
+ case $host in
+ *android*)
+ if test "x$use_dbus" != xyes; then
+ use_dbus=no
+ fi
+ ;;
+ esac
+
AC_SUBST(QT_TRANSLATION_DIR,$qt_translation_path)
])
-dnl Find the appropriate version of Qt libraries and includes.
-dnl Inputs: $1: Whether or not pkg-config should be used. yes|no. Default: yes.
-dnl Inputs: $2: If $1 is "yes" and --with-gui=auto, which qt version should be
-dnl tried first.
-dnl Outputs: See _BITCOIN_QT_FIND_LIBS_*
+dnl Find Qt libraries and includes.
+dnl
+dnl BITCOIN_QT_CONFIGURE([MINIMUM-VERSION])
+dnl
+dnl Outputs: See _BITCOIN_QT_FIND_LIBS
dnl Outputs: Sets variables for all qt-related tools.
dnl Outputs: bitcoin_enable_qt, bitcoin_enable_qt_dbus, bitcoin_enable_qt_test
AC_DEFUN([BITCOIN_QT_CONFIGURE],[
- use_pkgconfig=$1
-
- if test "x$use_pkgconfig" = x; then
- use_pkgconfig=yes
- fi
-
- if test "x$use_pkgconfig" = xyes; then
- BITCOIN_QT_CHECK([_BITCOIN_QT_FIND_LIBS_WITH_PKGCONFIG])
- else
- BITCOIN_QT_CHECK([_BITCOIN_QT_FIND_LIBS_WITHOUT_PKGCONFIG])
- fi
-
- dnl This is ugly and complicated. Yuck. Works as follows:
- dnl For Qt5, we can check a header to find out whether Qt is build
- dnl statically. When Qt is built statically, some plugins must be linked into
- dnl the final binary as well.
- dnl With Qt5, languages moved into core and the WindowsIntegration plugin was
- dnl added.
- dnl _BITCOIN_QT_CHECK_STATIC_PLUGINS does a quick link-check and appends the
- dnl results to QT_LIBS.
+ qt_version=">= $1"
+ qt_lib_prefix="Qt5"
+ BITCOIN_QT_CHECK([_BITCOIN_QT_FIND_LIBS])
+
+ dnl We check a header to find out whether Qt is built statically.
+ dnl When Qt is built statically, some plugins must be linked into
+ dnl the final binary as well. _BITCOIN_QT_CHECK_STATIC_PLUGIN does
+ dnl a quick link-check and appends the results to QT_LIBS.
BITCOIN_QT_CHECK([
TEMP_CPPFLAGS=$CPPFLAGS
TEMP_CXXFLAGS=$CXXFLAGS
@@ -114,46 +118,59 @@ AC_DEFUN([BITCOIN_QT_CONFIGURE],[
CXXFLAGS="$PIC_FLAGS $CXXFLAGS"
_BITCOIN_QT_IS_STATIC
if test "x$bitcoin_cv_static_qt" = xyes; then
- _BITCOIN_QT_FIND_STATIC_PLUGINS
+ _BITCOIN_QT_CHECK_STATIC_LIBS
+
+ if test "x$qt_plugin_path" != x; then
+ if test -d "$qt_plugin_path/platforms"; then
+ QT_LIBS="$QT_LIBS -L$qt_plugin_path/platforms"
+ fi
+ if test -d "$qt_plugin_path/styles"; then
+ QT_LIBS="$QT_LIBS -L$qt_plugin_path/styles"
+ fi
+ if test -d "$qt_plugin_path/accessible"; then
+ QT_LIBS="$QT_LIBS -L$qt_plugin_path/accessible"
+ fi
+ if test -d "$qt_plugin_path/platforms/android"; then
+ QT_LIBS="$QT_LIBS -L$qt_plugin_path/platforms/android -lqtfreetype -lEGL"
+ fi
+ fi
+
AC_DEFINE(QT_STATICPLUGIN, 1, [Define this symbol if qt plugins are static])
- AC_CACHE_CHECK(for Qt < 5.4, bitcoin_cv_need_acc_widget,[
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
- #include
- #ifndef QT_VERSION
- # include
- #endif
- ]],
- [[
- #if QT_VERSION >= 0x050400
- choke
- #endif
- ]])],
- [bitcoin_cv_need_acc_widget=yes],
- [bitcoin_cv_need_acc_widget=no])
- ])
- if test "x$bitcoin_cv_need_acc_widget" = xyes; then
- _BITCOIN_QT_CHECK_STATIC_PLUGINS([Q_IMPORT_PLUGIN(AccessibleFactory)], [-lqtaccessiblewidgets])
+ if test "x$TARGET_OS" != xandroid; then
+ _BITCOIN_QT_CHECK_STATIC_PLUGIN([QMinimalIntegrationPlugin], [-lqminimal])
+ AC_DEFINE(QT_QPA_PLATFORM_MINIMAL, 1, [Define this symbol if the minimal qt platform exists])
fi
- _BITCOIN_QT_CHECK_STATIC_PLUGINS([Q_IMPORT_PLUGIN(QMinimalIntegrationPlugin)],[-lqminimal])
- AC_DEFINE(QT_QPA_PLATFORM_MINIMAL, 1, [Define this symbol if the minimal qt platform exists])
if test "x$TARGET_OS" = xwindows; then
- _BITCOIN_QT_CHECK_STATIC_PLUGINS([Q_IMPORT_PLUGIN(QWindowsIntegrationPlugin)],[-lqwindows])
+ dnl Linking against wtsapi32 is required. See #17749 and
+ dnl https://bugreports.qt.io/browse/QTBUG-27097.
+ AX_CHECK_LINK_FLAG([-lwtsapi32], [QT_LIBS="$QT_LIBS -lwtsapi32"], [AC_MSG_ERROR([could not link against -lwtsapi32])])
+ _BITCOIN_QT_CHECK_STATIC_PLUGIN([QWindowsIntegrationPlugin], [-lqwindows])
+ _BITCOIN_QT_CHECK_STATIC_PLUGIN([QWindowsVistaStylePlugin], [-lqwindowsvistastyle])
AC_DEFINE(QT_QPA_PLATFORM_WINDOWS, 1, [Define this symbol if the qt platform is windows])
elif test "x$TARGET_OS" = xlinux; then
- _BITCOIN_QT_CHECK_STATIC_PLUGINS([Q_IMPORT_PLUGIN(QXcbIntegrationPlugin)],[-lqxcb -lxcb-static])
+ dnl workaround for https://bugreports.qt.io/browse/QTBUG-74874
+ AX_CHECK_LINK_FLAG([-lxcb-shm], [QT_LIBS="$QT_LIBS -lxcb-shm"], [AC_MSG_ERROR([could not link against -lxcb-shm])])
+ _BITCOIN_QT_CHECK_STATIC_PLUGIN([QXcbIntegrationPlugin], [-lqxcb])
AC_DEFINE(QT_QPA_PLATFORM_XCB, 1, [Define this symbol if the qt platform is xcb])
elif test "x$TARGET_OS" = xdarwin; then
- AX_CHECK_LINK_FLAG([[-framework IOKit]],[QT_LIBS="$QT_LIBS -framework IOKit"],[AC_MSG_ERROR(could not iokit framework)])
- _BITCOIN_QT_CHECK_STATIC_PLUGINS([Q_IMPORT_PLUGIN(QCocoaIntegrationPlugin)],[-lqcocoa])
+ AX_CHECK_LINK_FLAG([[-framework Carbon]],[QT_LIBS="$QT_LIBS -framework Carbon"],[AC_MSG_ERROR(could not link against Carbon framework)])
+ AX_CHECK_LINK_FLAG([[-framework IOSurface]],[QT_LIBS="$QT_LIBS -framework IOSurface"],[AC_MSG_ERROR(could not link against IOSurface framework)])
+ AX_CHECK_LINK_FLAG([[-framework Metal]],[QT_LIBS="$QT_LIBS -framework Metal"],[AC_MSG_ERROR(could not link against Metal framework)])
+ AX_CHECK_LINK_FLAG([[-framework QuartzCore]],[QT_LIBS="$QT_LIBS -framework QuartzCore"],[AC_MSG_ERROR(could not link against QuartzCore framework)])
+ _BITCOIN_QT_CHECK_STATIC_PLUGIN([QCocoaIntegrationPlugin], [-lqcocoa])
+ _BITCOIN_QT_CHECK_STATIC_PLUGIN([QMacStylePlugin], [-lqmacstyle])
AC_DEFINE(QT_QPA_PLATFORM_COCOA, 1, [Define this symbol if the qt platform is cocoa])
+ elif test "x$TARGET_OS" = xandroid; then
+ QT_LIBS="-Wl,--export-dynamic,--undefined=JNI_OnLoad -lqtforandroid -ljnigraphics -landroid -lqtfreetype $QT_LIBS"
+ AC_DEFINE(QT_QPA_PLATFORM_ANDROID, 1, [Define this symbol if the qt platform is android])
fi
fi
CPPFLAGS=$TEMP_CPPFLAGS
CXXFLAGS=$TEMP_CXXFLAGS
])
- if test "x$use_pkgconfig$qt_bin_path" = xyes; then
- qt_bin_path="`$PKG_CONFIG --variable=host_bins Qt5Core 2>/dev/null`"
+ if test "x$qt_bin_path" = x; then
+ qt_bin_path="`$PKG_CONFIG --variable=host_bins ${qt_lib_prefix}Core 2>/dev/null`"
fi
if test "x$use_hardening" != xno; then
@@ -208,13 +225,14 @@ AC_DEFUN([BITCOIN_QT_CONFIGURE],[
BITCOIN_QT_PATH_PROGS([RCC], [rcc-qt5 rcc5 rcc], $qt_bin_path)
BITCOIN_QT_PATH_PROGS([LRELEASE], [lrelease-qt5 lrelease5 lrelease], $qt_bin_path)
BITCOIN_QT_PATH_PROGS([LUPDATE], [lupdate-qt5 lupdate5 lupdate],$qt_bin_path, yes)
+ BITCOIN_QT_PATH_PROGS([LCONVERT], [lconvert-qt5 lconvert5 lconvert], $qt_bin_path, yes)
MOC_DEFS='-DHAVE_CONFIG_H -I$(srcdir)'
case $host in
*darwin*)
BITCOIN_QT_CHECK([
MOC_DEFS="${MOC_DEFS} -DQ_OS_MAC"
- base_frameworks="-framework Foundation -framework ApplicationServices -framework AppKit"
+ base_frameworks="-framework Foundation -framework AppKit"
AX_CHECK_LINK_FLAG([[$base_frameworks]],[QT_LIBS="$QT_LIBS $base_frameworks"],[AC_MSG_ERROR(could not find base frameworks)])
])
;;
@@ -226,7 +244,7 @@ AC_DEFUN([BITCOIN_QT_CONFIGURE],[
dnl enable qt support
- AC_MSG_CHECKING(whether to build ]AC_PACKAGE_NAME[ GUI)
+ AC_MSG_CHECKING([whether to build ]AC_PACKAGE_NAME[ GUI])
BITCOIN_QT_CHECK([
bitcoin_enable_qt=yes
bitcoin_enable_qt_test=yes
@@ -241,80 +259,44 @@ AC_DEFUN([BITCOIN_QT_CONFIGURE],[
AC_MSG_ERROR([libQtDBus not found. Install libQtDBus or remove --with-qtdbus.])
fi
if test "x$LUPDATE" = x; then
- AC_MSG_WARN([lupdate is required to update qt translations])
+ AC_MSG_WARN([lupdate tool is required to update Qt translations.])
+ fi
+ if test "x$LCONVERT" = x; then
+ AC_MSG_WARN([lconvert tool is required to update Qt translations.])
fi
],[
bitcoin_enable_qt=no
])
- AC_MSG_RESULT([$bitcoin_enable_qt (Qt5)])
+ if test x$bitcoin_enable_qt = xyes; then
+ AC_MSG_RESULT([$bitcoin_enable_qt ($qt_lib_prefix)])
+ else
+ AC_MSG_RESULT([$bitcoin_enable_qt])
+ fi
AC_SUBST(QT_PIE_FLAGS)
AC_SUBST(QT_INCLUDES)
AC_SUBST(QT_LIBS)
AC_SUBST(QT_LDFLAGS)
AC_SUBST(QT_DBUS_INCLUDES)
- AC_SUBST(QT_DBUS_LIBS)
AC_SUBST(QT_TEST_INCLUDES)
- AC_SUBST(QT_TEST_LIBS)
AC_SUBST(QT_SELECT, qt5)
AC_SUBST(MOC_DEFS)
])
-dnl All macros below are internal and should _not_ be used from the main
-dnl configure.ac.
-dnl ----
-
-dnl Internal. Check if the included version of Qt is Qt5.
-dnl Requires: INCLUDES must be populated as necessary.
-dnl Output: bitcoin_cv_qt5=yes|no
-AC_DEFUN([_BITCOIN_QT_CHECK_QT5],[
- AC_CACHE_CHECK(for Qt 5, bitcoin_cv_qt5,[
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
- #include
- #ifndef QT_VERSION
- # include
- #endif
- ]],
- [[
- #if QT_VERSION < 0x050000 || QT_VERSION_MAJOR < 5
- choke
- #endif
- ]])],
- [bitcoin_cv_qt5=yes],
- [bitcoin_cv_qt5=no])
-])])
-
-dnl Internal. Check if the included version of Qt is greater than Qt58.
-dnl Requires: INCLUDES must be populated as necessary.
-dnl Output: bitcoin_cv_qt5=yes|no
-AC_DEFUN([_BITCOIN_QT_CHECK_QT58],[
- AC_CACHE_CHECK(for > Qt 5.7, bitcoin_cv_qt58,[
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
- #include
- #ifndef QT_VERSION
- # include
- #endif
- ]],
- [[
- #if QT_VERSION_MINOR < 8
- choke
- #endif
- ]])],
- [bitcoin_cv_qt58=yes],
- [bitcoin_cv_qt58=no])
-])])
+dnl All macros below are internal and should _not_ be used from configure.ac.
-
-dnl Internal. Check if the linked version of Qt was built as static libs.
-dnl Requires: Qt5.
+dnl Internal. Check if the linked version of Qt was built statically.
+dnl
+dnl _BITCOIN_QT_IS_STATIC
+dnl ---------------------
+dnl
dnl Requires: INCLUDES and LIBS must be populated as necessary.
dnl Output: bitcoin_cv_static_qt=yes|no
-dnl Output: Defines QT_STATICPLUGIN if plugins are static.
AC_DEFUN([_BITCOIN_QT_IS_STATIC],[
AC_CACHE_CHECK(for static Qt, bitcoin_cv_static_qt,[
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
#include
- #ifndef QT_VERSION OR QT_VERSION_STR
+ #ifndef QT_VERSION
# include
#endif
]],
@@ -326,205 +308,92 @@ AC_DEFUN([_BITCOIN_QT_IS_STATIC],[
[bitcoin_cv_static_qt=yes],
[bitcoin_cv_static_qt=no])
])
- if test "x$bitcoin_cv_static_qt" = xyes; then
- AC_DEFINE(QT_STATICPLUGIN, 1, [Define this symbol for static Qt plugins])
- fi
])
-dnl Internal. Check if the link-requirements for static plugins are met.
+dnl Internal. Check if the link-requirements for a static plugin are met.
+dnl
+dnl _BITCOIN_QT_CHECK_STATIC_PLUGIN(PLUGIN, LIBRARIES)
+dnl --------------------------------------------------
+dnl
dnl Requires: INCLUDES and LIBS must be populated as necessary.
-dnl Inputs: $1: A series of Q_IMPORT_PLUGIN().
+dnl Inputs: $1: A static plugin name.
dnl Inputs: $2: The libraries that resolve $1.
dnl Output: QT_LIBS is prepended or configure exits.
-AC_DEFUN([_BITCOIN_QT_CHECK_STATIC_PLUGINS],[
- AC_MSG_CHECKING(for static Qt plugins: $2)
+AC_DEFUN([_BITCOIN_QT_CHECK_STATIC_PLUGIN], [
+ AC_MSG_CHECKING([for $1 ($2)])
CHECK_STATIC_PLUGINS_TEMP_LIBS="$LIBS"
- LIBS="$2 $QT_LIBS $LIBS"
+ LIBS="$2${qt_lib_suffix} $QT_LIBS $LIBS"
AC_LINK_IFELSE([AC_LANG_PROGRAM([[
- #define QT_STATICPLUGIN
- #include
- $1]],
- [[return 0;]])],
- [AC_MSG_RESULT(yes); QT_LIBS="$2 $QT_LIBS"],
- [AC_MSG_RESULT(no); BITCOIN_QT_FAIL(Could not resolve: $2)])
+ #include
+ Q_IMPORT_PLUGIN($1)
+ ]])],
+ [AC_MSG_RESULT([yes]); QT_LIBS="$2${qt_lib_suffix} $QT_LIBS"],
+ [AC_MSG_RESULT([no]); BITCOIN_QT_FAIL([$1 not found.])])
LIBS="$CHECK_STATIC_PLUGINS_TEMP_LIBS"
])
-dnl Internal. Find paths necessary for linking qt static plugins
-dnl Inputs: qt_plugin_path. optional.
-dnl Outputs: QT_LIBS is appended
-AC_DEFUN([_BITCOIN_QT_FIND_STATIC_PLUGINS],[
- if test "x$qt_plugin_path" != x; then
- QT_LIBS="$QT_LIBS -L$qt_plugin_path/platforms"
- if test -d "$qt_plugin_path/accessible"; then
- QT_LIBS="$QT_LIBS -L$qt_plugin_path/accessible"
- fi
- if test "x$use_pkgconfig" = xyes; then
- : dnl
- m4_ifdef([PKG_CHECK_MODULES],[
- if test x$bitcoin_cv_qt58 = xno; then
- PKG_CHECK_MODULES([QTPLATFORM], [Qt5PlatformSupport], [QT_LIBS="$QTPLATFORM_LIBS $QT_LIBS"])
- else
- PKG_CHECK_MODULES([QTFONTDATABASE], [Qt5FontDatabaseSupport], [QT_LIBS="-lQt5FontDatabaseSupport $QT_LIBS"])
- PKG_CHECK_MODULES([QTEVENTDISPATCHER], [Qt5EventDispatcherSupport], [QT_LIBS="-lQt5EventDispatcherSupport $QT_LIBS"])
- PKG_CHECK_MODULES([QTTHEME], [Qt5ThemeSupport], [QT_LIBS="-lQt5ThemeSupport $QT_LIBS"])
- PKG_CHECK_MODULES([QTDEVICEDISCOVERY], [Qt5DeviceDiscoverySupport], [QT_LIBS="-lQt5DeviceDiscoverySupport $QT_LIBS"])
- PKG_CHECK_MODULES([QTACCESSIBILITY], [Qt5AccessibilitySupport], [QT_LIBS="-lQt5AccessibilitySupport $QT_LIBS"])
- PKG_CHECK_MODULES([QTFB], [Qt5FbSupport], [QT_LIBS="-lQt5FbSupport $QT_LIBS"])
- fi
- if test "x$TARGET_OS" = xlinux; then
- PKG_CHECK_MODULES([X11XCB], [x11-xcb], [QT_LIBS="$X11XCB_LIBS $QT_LIBS"])
- if ${PKG_CONFIG} --exists "Qt5Core >= 5.5" 2>/dev/null; then
- PKG_CHECK_MODULES([QTXCBQPA], [Qt5XcbQpa], [QT_LIBS="$QTXCBQPA_LIBS $QT_LIBS"])
- fi
- elif test "x$TARGET_OS" = xdarwin; then
- PKG_CHECK_MODULES([QTCLIPBOARD], [Qt5ClipboardSupport], [QT_LIBS="-lQt5ClipboardSupport $QT_LIBS"])
- PKG_CHECK_MODULES([QTGRAPHICS], [Qt5GraphicsSupport], [QT_LIBS="-lQt5GraphicsSupport $QT_LIBS"])
- PKG_CHECK_MODULES([QTCGL], [Qt5CglSupport], [QT_LIBS="-lQt5CglSupport $QT_LIBS"])
- fi
- ])
- else
- if test "x$TARGET_OS" = xwindows; then
- AC_CACHE_CHECK(for Qt >= 5.6, bitcoin_cv_need_platformsupport,[
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
- #include
- #ifndef QT_VERSION
- # include
- #endif
- ]],
- [[
- #if QT_VERSION < 0x050600 || QT_VERSION_MINOR < 6
- choke
- #endif
- ]])],
- [bitcoin_cv_need_platformsupport=yes],
- [bitcoin_cv_need_platformsupport=no])
- ])
- if test "x$bitcoin_cv_need_platformsupport" = xyes; then
- if test x$bitcoin_cv_qt58 = xno; then
- BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}PlatformSupport],[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXPlatformSupport not found)))
- else
- BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}FontDatabaseSupport],[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXFontDatabaseSupport not found)))
- BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}EventDispatcherSupport],[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXEventDispatcherSupport not found)))
- BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}ThemeSupport],[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXThemeSupport not found)))
- BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}FbSupport],[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXFbSupport not found)))
- BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}DeviceDiscoverySupport],[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXDeviceDiscoverySupport not found)))
- BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}AccessibilitySupport],[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXAccessibilitySupport not found)))
- QT_LIBS="$QT_LIBS -lversion -ldwmapi -luxtheme"
- fi
- fi
- fi
- fi
- fi
+dnl Internal. Check Qt static libs with PKG_CHECK_MODULES.
+dnl
+dnl _BITCOIN_QT_CHECK_STATIC_LIBS
+dnl -----------------------------
+dnl
+dnl Outputs: QT_LIBS is prepended.
+AC_DEFUN([_BITCOIN_QT_CHECK_STATIC_LIBS], [
+ PKG_CHECK_MODULES([QT_ACCESSIBILITY], [${qt_lib_prefix}AccessibilitySupport${qt_lib_suffix}], [QT_LIBS="$QT_ACCESSIBILITY_LIBS $QT_LIBS"])
+ PKG_CHECK_MODULES([QT_DEVICEDISCOVERY], [${qt_lib_prefix}DeviceDiscoverySupport${qt_lib_suffix}], [QT_LIBS="$QT_DEVICEDISCOVERY_LIBS $QT_LIBS"])
+ PKG_CHECK_MODULES([QT_EDID], [${qt_lib_prefix}EdidSupport${qt_lib_suffix}], [QT_LIBS="$QT_EDID_LIBS $QT_LIBS"])
+ PKG_CHECK_MODULES([QT_EVENTDISPATCHER], [${qt_lib_prefix}EventDispatcherSupport${qt_lib_suffix}], [QT_LIBS="$QT_EVENTDISPATCHER_LIBS $QT_LIBS"])
+ PKG_CHECK_MODULES([QT_FB], [${qt_lib_prefix}FbSupport${qt_lib_suffix}], [QT_LIBS="$QT_FB_LIBS $QT_LIBS"])
+ PKG_CHECK_MODULES([QT_FONTDATABASE], [${qt_lib_prefix}FontDatabaseSupport${qt_lib_suffix}], [QT_LIBS="$QT_FONTDATABASE_LIBS $QT_LIBS"])
+ PKG_CHECK_MODULES([QT_THEME], [${qt_lib_prefix}ThemeSupport${qt_lib_suffix}], [QT_LIBS="$QT_THEME_LIBS $QT_LIBS"])
+ if test "x$TARGET_OS" = xlinux; then
+ PKG_CHECK_MODULES([QT_INPUT], [${qt_lib_prefix}InputSupport], [QT_LIBS="$QT_INPUT_LIBS $QT_LIBS"])
+ PKG_CHECK_MODULES([QT_SERVICE], [${qt_lib_prefix}ServiceSupport], [QT_LIBS="$QT_SERVICE_LIBS $QT_LIBS"])
+ PKG_CHECK_MODULES([QT_XCBQPA], [${qt_lib_prefix}XcbQpa], [QT_LIBS="$QT_XCBQPA_LIBS $QT_LIBS"])
+ elif test "x$TARGET_OS" = xdarwin; then
+ PKG_CHECK_MODULES([QT_CLIPBOARD], [${qt_lib_prefix}ClipboardSupport${qt_lib_suffix}], [QT_LIBS="$QT_CLIPBOARD_LIBS $QT_LIBS"])
+ PKG_CHECK_MODULES([QT_GRAPHICS], [${qt_lib_prefix}GraphicsSupport${qt_lib_suffix}], [QT_LIBS="$QT_GRAPHICS_LIBS $QT_LIBS"])
+ PKG_CHECK_MODULES([QT_SERVICE], [${qt_lib_prefix}ServiceSupport${qt_lib_suffix}], [QT_LIBS="$QT_SERVICE_LIBS $QT_LIBS"])
+ elif test "x$TARGET_OS" = xwindows; then
+ PKG_CHECK_MODULES([QT_WINDOWSUIAUTOMATION], [${qt_lib_prefix}WindowsUIAutomationSupport${qt_lib_suffix}], [QT_LIBS="$QT_WINDOWSUIAUTOMATION_LIBS $QT_LIBS"])
+ elif test "x$TARGET_OS" = xandroid; then
+ PKG_CHECK_MODULES([QT_EGL], [${qt_lib_prefix}EglSupport], [QT_LIBS="$QT_EGL_LIBS $QT_LIBS"])
+ fi
])
dnl Internal. Find Qt libraries using pkg-config.
-dnl Inputs: bitcoin_qt_want_version (from --with-gui=). The version to check
-dnl first.
-dnl Inputs: $1: If bitcoin_qt_want_version is "auto", check for this version
-dnl first.
+dnl
+dnl _BITCOIN_QT_FIND_LIBS
+dnl ---------------------
+dnl
dnl Outputs: All necessary QT_* variables are set.
dnl Outputs: have_qt_test and have_qt_dbus are set (if applicable) to yes|no.
-AC_DEFUN([_BITCOIN_QT_FIND_LIBS_WITH_PKGCONFIG],[
- m4_ifdef([PKG_CHECK_MODULES],[
- QT_LIB_PREFIX=Qt5
- qt5_modules="Qt5Core Qt5Gui Qt5Network Qt5Widgets"
- BITCOIN_QT_CHECK([
- PKG_CHECK_MODULES([QT5], [$qt5_modules], [QT_INCLUDES="$QT5_CFLAGS"; QT_LIBS="$QT5_LIBS" have_qt=yes],[have_qt=no])
-
- if test "x$have_qt" != xyes; then
- have_qt=no
- BITCOIN_QT_FAIL([Qt dependencies not found])
- fi
- ])
- BITCOIN_QT_CHECK([
- PKG_CHECK_MODULES([QT_TEST], [${QT_LIB_PREFIX}Test], [QT_TEST_INCLUDES="$QT_TEST_CFLAGS"; have_qt_test=yes], [have_qt_test=no])
- if test "x$use_dbus" != xno; then
- PKG_CHECK_MODULES([QT_DBUS], [${QT_LIB_PREFIX}DBus], [QT_DBUS_INCLUDES="$QT_DBUS_CFLAGS"; have_qt_dbus=yes], [have_qt_dbus=no])
- fi
- ])
+AC_DEFUN([_BITCOIN_QT_FIND_LIBS],[
+ BITCOIN_QT_CHECK([
+ PKG_CHECK_MODULES([QT_CORE], [${qt_lib_prefix}Core${qt_lib_suffix} $qt_version], [QT_INCLUDES="$QT_CORE_CFLAGS $QT_INCLUDES" QT_LIBS="$QT_CORE_LIBS $QT_LIBS"],
+ [BITCOIN_QT_FAIL([${qt_lib_prefix}Core${qt_lib_suffix} $qt_version not found])])
])
- true; dnl
-])
-
-dnl Internal. Find Qt libraries without using pkg-config. Version is deduced
-dnl from the discovered headers.
-dnl Inputs: bitcoin_qt_want_version (from --with-gui=). The version to use.
-dnl If "auto", the version will be discovered by _BITCOIN_QT_CHECK_QT5.
-dnl Outputs: All necessary QT_* variables are set.
-dnl Outputs: have_qt_test and have_qt_dbus are set (if applicable) to yes|no.
-AC_DEFUN([_BITCOIN_QT_FIND_LIBS_WITHOUT_PKGCONFIG],[
- TEMP_CPPFLAGS="$CPPFLAGS"
- TEMP_CXXFLAGS="$CXXFLAGS"
- CXXFLAGS="$PIC_FLAGS $CXXFLAGS"
- TEMP_LIBS="$LIBS"
BITCOIN_QT_CHECK([
- if test "x$qt_include_path" != x; then
- QT_INCLUDES="-I$qt_include_path -I$qt_include_path/QtCore -I$qt_include_path/QtGui -I$qt_include_path/QtWidgets -I$qt_include_path/QtNetwork -I$qt_include_path/QtTest -I$qt_include_path/QtDBus"
- CPPFLAGS="$QT_INCLUDES $CPPFLAGS"
- fi
+ PKG_CHECK_MODULES([QT_GUI], [${qt_lib_prefix}Gui${qt_lib_suffix} $qt_version], [QT_INCLUDES="$QT_GUI_CFLAGS $QT_INCLUDES" QT_LIBS="$QT_GUI_LIBS $QT_LIBS"],
+ [BITCOIN_QT_FAIL([${qt_lib_prefix}Gui${qt_lib_suffix} $qt_version not found])])
])
-
- BITCOIN_QT_CHECK([AC_CHECK_HEADER([QtPlugin],,BITCOIN_QT_FAIL(QtCore headers missing))])
- BITCOIN_QT_CHECK([AC_CHECK_HEADER([QApplication],, BITCOIN_QT_FAIL(QtGui headers missing))])
- BITCOIN_QT_CHECK([AC_CHECK_HEADER([QLocalSocket],, BITCOIN_QT_FAIL(QtNetwork headers missing))])
-
BITCOIN_QT_CHECK([
- if test "x$bitcoin_qt_want_version" = xauto; then
- _BITCOIN_QT_CHECK_QT5
- _BITCOIN_QT_CHECK_QT58
- fi
- QT_LIB_PREFIX=Qt5
+ PKG_CHECK_MODULES([QT_WIDGETS], [${qt_lib_prefix}Widgets${qt_lib_suffix} $qt_version], [QT_INCLUDES="$QT_WIDGETS_CFLAGS $QT_INCLUDES" QT_LIBS="$QT_WIDGETS_LIBS $QT_LIBS"],
+ [BITCOIN_QT_FAIL([${qt_lib_prefix}Widgets${qt_lib_suffix} $qt_version not found])])
])
-
BITCOIN_QT_CHECK([
- LIBS=
- if test "x$qt_lib_path" != x; then
- LIBS="$LIBS -L$qt_lib_path"
- fi
-
- if test "x$TARGET_OS" = xwindows; then
- AC_CHECK_LIB([imm32], [main],, BITCOIN_QT_FAIL(libimm32 not found))
- fi
+ PKG_CHECK_MODULES([QT_NETWORK], [${qt_lib_prefix}Network${qt_lib_suffix} $qt_version], [QT_INCLUDES="$QT_NETWORK_CFLAGS $QT_INCLUDES" QT_LIBS="$QT_NETWORK_LIBS $QT_LIBS"],
+ [BITCOIN_QT_FAIL([${qt_lib_prefix}Network${qt_lib_suffix} $qt_version not found])])
+ ])
+ BITCOIN_QT_CHECK([
+ PKG_CHECK_MODULES([QT_CONCURRENT], [${qt_lib_prefix}Concurrent${qt_lib_suffix} $qt_version], [QT_INCLUDES="$QT_CONCURRENT_CFLAGS $QT_INCLUDES" QT_LIBS="$QT_CONCURRENT_LIBS $QT_LIBS"],
+ [BITCOIN_QT_FAIL([${qt_lib_prefix}Concurrent${qt_lib_suffix} $qt_version not found])])
])
-
- BITCOIN_QT_CHECK(AC_CHECK_LIB([z] ,[main],,AC_MSG_WARN([zlib not found. Assuming qt has it built-in])))
- BITCOIN_QT_CHECK(AC_SEARCH_LIBS([jpeg_create_decompress] ,[qtjpeg jpeg],,AC_MSG_WARN([libjpeg not found. Assuming qt has it built-in])))
- if test x$bitcoin_cv_qt58 = xno; then
- BITCOIN_QT_CHECK(AC_SEARCH_LIBS([png_error] ,[qtpng png],,AC_MSG_WARN([libpng not found. Assuming qt has it built-in])))
- BITCOIN_QT_CHECK(AC_SEARCH_LIBS([pcre16_exec], [qtpcre pcre16],,AC_MSG_WARN([libpcre16 not found. Assuming qt has it built-in])))
- else
- BITCOIN_QT_CHECK(AC_SEARCH_LIBS([png_error] ,[qtlibpng png],,AC_MSG_WARN([libpng not found. Assuming qt has it built-in])))
- BITCOIN_QT_CHECK(AC_SEARCH_LIBS([pcre2_match_16], [qtpcre2 libqtpcre2],,AC_MSG_WARN([libqtpcre2 not found. Assuming qt has it built-in])))
- fi
- BITCOIN_QT_CHECK(AC_SEARCH_LIBS([hb_ot_tags_from_script] ,[qtharfbuzzng qtharfbuzz harfbuzz],,AC_MSG_WARN([libharfbuzz not found. Assuming qt has it built-in or support is disabled])))
- BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}Core] ,[main],,BITCOIN_QT_FAIL(lib${QT_LIB_PREFIX}Core not found)))
- BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}Gui] ,[main],,BITCOIN_QT_FAIL(lib${QT_LIB_PREFIX}Gui not found)))
- BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}Network],[main],,BITCOIN_QT_FAIL(lib${QT_LIB_PREFIX}Network not found)))
- BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}Widgets],[main],,BITCOIN_QT_FAIL(lib${QT_LIB_PREFIX}Widgets not found)))
- QT_LIBS="$LIBS"
- LIBS="$TEMP_LIBS"
BITCOIN_QT_CHECK([
- LIBS=
- if test "x$qt_lib_path" != x; then
- LIBS="-L$qt_lib_path"
- fi
- AC_CHECK_LIB([${QT_LIB_PREFIX}Test], [main],, have_qt_test=no)
- AC_CHECK_HEADER([QTest],, have_qt_test=no)
- QT_TEST_LIBS="$LIBS"
+ PKG_CHECK_MODULES([QT_TEST], [${qt_lib_prefix}Test${qt_lib_suffix} $qt_version], [QT_TEST_INCLUDES="$QT_TEST_CFLAGS"; have_qt_test=yes], [have_qt_test=no])
if test "x$use_dbus" != xno; then
- LIBS=
- if test "x$qt_lib_path" != x; then
- LIBS="-L$qt_lib_path"
- fi
- AC_CHECK_LIB([${QT_LIB_PREFIX}DBus], [main],, have_qt_dbus=no)
- AC_CHECK_HEADER([QtDBus],, have_qt_dbus=no)
- QT_DBUS_LIBS="$LIBS"
+ PKG_CHECK_MODULES([QT_DBUS], [${qt_lib_prefix}DBus $qt_version], [QT_DBUS_INCLUDES="$QT_DBUS_CFLAGS"; have_qt_dbus=yes], [have_qt_dbus=no])
fi
])
- CPPFLAGS="$TEMP_CPPFLAGS"
- CXXFLAGS="$TEMP_CXXFLAGS"
- LIBS="$TEMP_LIBS"
])
-
diff --git a/build-aux/m4/bitcoin_subdir_to_include.m4 b/build-aux/m4/bitcoin_subdir_to_include.m4
index 66f106c7d4..7841042ac8 100644
--- a/build-aux/m4/bitcoin_subdir_to_include.m4
+++ b/build-aux/m4/bitcoin_subdir_to_include.m4
@@ -1,3 +1,7 @@
+dnl Copyright (c) 2013-2014 The Bitcoin Core developers
+dnl Distributed under the MIT software license, see the accompanying
+dnl file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
dnl BITCOIN_SUBDIR_TO_INCLUDE([CPPFLAGS-VARIABLE-NAME],[SUBDIRECTORY-NAME],[HEADER-FILE])
dnl SUBDIRECTORY-NAME must end with a path separator
AC_DEFUN([BITCOIN_SUBDIR_TO_INCLUDE],[
diff --git a/configure.ac b/configure.ac
index 9acedc672c..af2b9bcbff 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,40 +1,53 @@
dnl require autoconf 2.60 (AS_ECHO/AS_ECHO_N)
AC_PREREQ([2.60])
-define(_CLIENT_VERSION_MAJOR, 1)
+define(_CLIENT_VERSION_MAJOR, 2)
define(_CLIENT_VERSION_MINOR, 0)
-define(_CLIENT_VERSION_REVISION, 4)
-define(_CLIENT_VERSION_BUILD, 6)
-define(_CLIENT_VERSION_IS_RELEASE, true)
-define(_COPYRIGHT_YEAR, 2019)
-AC_INIT([DAPScoin],[_CLIENT_VERSION_MAJOR._CLIENT_VERSION_MINOR._CLIENT_VERSION_REVISION],[https://officialdapscoin.com],[dapscoin])
+define(_CLIENT_VERSION_REVISION, 0)
+define(_CLIENT_VERSION_BUILD, 7)
+define(_CLIENT_VERSION_RC, 5)
+define(_CLIENT_VERSION_IS_RELEASE, false)
+define(_COPYRIGHT_YEAR, 2023)
+AC_INIT([PRCYcoin],m4_join([.], _CLIENT_VERSION_MAJOR, _CLIENT_VERSION_MINOR, _CLIENT_VERSION_REVISION, m4_if(_CLIENT_VERSION_BUILD, [0], [], _CLIENT_VERSION_BUILD))m4_if(_CLIENT_VERSION_RC, [0], [], [rc]_CLIENT_VERSION_RC),[https://github.com/PRCYCoin/PRCYCoin/issues],[prcycoin],[https://www.prcycoin.com])
AC_CONFIG_SRCDIR([src/main.cpp])
-AC_CONFIG_HEADERS([src/config/dapscoin-config.h])
+AC_CONFIG_HEADERS([src/config/prcycoin-config.h])
AC_CONFIG_AUX_DIR([build-aux])
AC_CONFIG_MACRO_DIR([build-aux/m4])
-BITCOIN_DAEMON_NAME=dapscoind
-BITCOIN_GUI_NAME=dapscoin-qt
-BITCOIN_CLI_NAME=dapscoin-cli
-BITCOIN_TX_NAME=dapscoin-tx
+m4_ifndef([PKG_PROG_PKG_CONFIG], [m4_fatal([PKG_PROG_PKG_CONFIG macro not found. Please install pkg-config and re-run autogen.sh])])
+PKG_PROG_PKG_CONFIG
+if test "x$PKG_CONFIG" = x; then
+ AC_MSG_ERROR([pkg-config not found])
+fi
+
+BITCOIN_DAEMON_NAME=prcycoind
+BITCOIN_GUI_NAME=prcycoin-qt
+BITCOIN_CLI_NAME=prcycoin-cli
+BITCOIN_TX_NAME=prcycoin-tx
+
+dnl Unless the user specified ARFLAGS, force it to be cr
+AC_ARG_VAR(ARFLAGS, [Flags for the archiver, defaults to if not set])
+if test "x${ARFLAGS+set}" != "xset"; then
+ ARFLAGS="cr"
+fi
AC_CANONICAL_HOST
-AH_TOP([#ifndef DAPS_CONFIG_H])
-AH_TOP([#define DAPS_CONFIG_H])
-AH_BOTTOM([#endif //DAPS_CONFIG_H])
+AH_TOP([#ifndef PRCY_CONFIG_H])
+AH_TOP([#define PRCY_CONFIG_H])
+AH_BOTTOM([#endif //PRCY_CONFIG_H])
dnl faketime breaks configure and is only needed for make. Disable it here.
unset FAKETIME
dnl Automake init set-up and checks
-AM_INIT_AUTOMAKE([no-define subdir-objects foreign])
+AM_INIT_AUTOMAKE([1.13 no-define subdir-objects foreign])
dnl faketime messes with timestamps and causes configure to be re-run.
dnl --disable-maintainer-mode can be used to bypass this.
AM_MAINTAINER_MODE([enable])
dnl make the compilation flags quiet unless V=1 is used
-m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
+AM_SILENT_RULES([yes])
dnl Compiler checks (here before libtool).
if test "x${CXXFLAGS+set}" = "xset"; then
@@ -43,7 +56,6 @@ else
CXXFLAGS_overridden=no
fi
AC_PROG_CXX
-dnl ifdef([AC_PROG_OBJCXX],[AC_PROG_OBJCXX])
dnl By default, libtool for mingw refuses to link static libs into a dll for
dnl fear of mixing pic/non-pic objects, and import/export complications. Since
@@ -53,8 +65,12 @@ case $host in
lt_cv_deplibs_check_method="pass_all"
;;
esac
-dnl Require C++14 compiler (no GNU extensions)
-AX_CXX_COMPILE_STDCXX([14], [noext], [mandatory])
+
+dnl Require C++17 compiler (no GNU extensions)
+AX_CXX_COMPILE_STDCXX([17], [noext], [mandatory])
+
+dnl Check if -latomic is required for
+CHECK_ATOMIC
dnl Unless the user specified OBJCXX, force it to be the same as CXX. This ensures
dnl that we get the same -std flags for both.
@@ -70,12 +86,10 @@ LT_INIT([pic-only])
dnl Check/return PATH for base programs.
AC_PATH_TOOL(AR, ar)
-AC_PATH_TOOL(RANLIB, ranlib)
-AC_PATH_TOOL(STRIP, strip)
AC_PATH_TOOL(GCOV, gcov)
AC_PATH_PROG(LCOV, lcov)
-AC_PATH_PROG(JAVA, java)
-AC_PATH_PROGS([PYTHON], [python3 python2.7 python2 python])
+dnl Python 3.6 is specified in .python-version and should be used if available, see doc/dependencies.md
+AC_PATH_PROGS([PYTHON], [python3.6 python3.7 python3.8 python3.9 python3 python])
AC_PATH_PROG(GENHTML, genhtml)
AC_PATH_PROG([GIT], [git])
AC_PATH_PROG(CCACHE,ccache)
@@ -84,13 +98,18 @@ AC_PATH_PROG(HEXDUMP,hexdump)
AC_PATH_TOOL(READELF, readelf)
AC_PATH_TOOL(CPPFILT, c++filt)
AC_PATH_TOOL(OBJCOPY, objcopy)
+AC_PATH_PROG(DOXYGEN, doxygen)
+if test -z "$DOXYGEN"; then
+ AC_MSG_WARN([Doxygen not found])
+fi
+AM_CONDITIONAL([HAVE_DOXYGEN], [test -n "$DOXYGEN"])
AC_ARG_VAR(PYTHONPATH, Augments the default search path for python module files)
# Enable wallet
AC_ARG_ENABLE([wallet],
- [AS_HELP_STRING([--enable-wallet],
- [enable wallet (default is yes)])],
+ [AS_HELP_STRING([--disable-wallet],
+ [disable wallet (enabled by default)])],
[enable_wallet=$enableval],
[enable_wallet=yes])
@@ -107,19 +126,24 @@ AC_ARG_ENABLE([upnp-default],
[use_upnp_default=no])
AC_ARG_ENABLE(tests,
- AS_HELP_STRING([--enable-tests],[compile tests (default is yes)]),
+ AS_HELP_STRING([--disable-tests],[do not compile tests (default is to compile)]),
[use_tests=$enableval],
[use_tests=yes])
-AC_ARG_WITH([comparison-tool],
- AS_HELP_STRING([--with-comparison-tool],[path to java comparison tool (requires --enable-tests)]),
- [use_comparison_tool=$withval],
- [use_comparison_tool=no])
+AC_ARG_ENABLE(gui-tests,
+ AS_HELP_STRING([--disable-gui-tests],[do not compile GUI tests (default is to compile if GUI and tests enabled)]),
+ [use_gui_tests=$enableval],
+ [use_gui_tests=$use_tests])
-AC_ARG_ENABLE([comparison-tool-reorg-tests],
- AS_HELP_STRING([--enable-comparison-tool-reorg-tests],[enable expensive reorg tests in the comparison tool (default no)]),
- [use_comparison_tool_reorg_tests=$enableval],
- [use_comparison_tool_reorg_tests=no])
+AC_ARG_ENABLE(bench,
+ AS_HELP_STRING([--disable-bench],[do not compile benchmarks (default is to compile)]),
+ [use_bench=$enableval],
+ [use_bench=no])
+
+AC_ARG_ENABLE([extended-functional-tests],
+ AS_HELP_STRING([--enable-extended-functional-tests],[enable expensive functional tests when using lcov (default no)]),
+ [use_extended_functional_tests=$enableval],
+ [use_extended_functional_tests=no])
AC_ARG_WITH([qrencode],
[AS_HELP_STRING([--with-qrencode],
@@ -128,49 +152,68 @@ AC_ARG_WITH([qrencode],
[use_qr=auto])
AC_ARG_ENABLE([hardening],
- [AS_HELP_STRING([--enable-hardening],
- [attempt to harden the resulting executables (default is yes)])],
+ [AS_HELP_STRING([--disable-hardening],
+ [do not attempt to harden the resulting executables (default is to harden when possible)])],
[use_hardening=$enableval],
- [use_hardening=yes])
+ [use_hardening=auto])
AC_ARG_ENABLE([reduce-exports],
[AS_HELP_STRING([--enable-reduce-exports],
- [attempt to reduce exported symbols in the resulting executables (default is yes)])],
+ [attempt to reduce exported symbols in the resulting executables (default is no)])],
[use_reduce_exports=$enableval],
- [use_reduce_exports=auto])
+ [use_reduce_exports=no])
AC_ARG_ENABLE([ccache],
- [AS_HELP_STRING([--enable-ccache],
- [use ccache for building (default is yes if ccache is found)])],
+ [AS_HELP_STRING([--disable-ccache],
+ [do not use ccache for building (default is to use if found)])],
[use_ccache=$enableval],
[use_ccache=auto])
AC_ARG_ENABLE([lcov],
[AS_HELP_STRING([--enable-lcov],
[enable lcov testing (default is no)])],
- [use_lcov=yes],
+ [use_lcov=$enableval],
[use_lcov=no])
+AC_ARG_ENABLE([lcov-branch-coverage],
+ [AS_HELP_STRING([--enable-lcov-branch-coverage],
+ [enable lcov testing branch coverage (default is no)])],
+ [use_lcov_branch=yes],
+ [use_lcov_branch=no])
+
AC_ARG_ENABLE([glibc-back-compat],
[AS_HELP_STRING([--enable-glibc-back-compat],
- [enable backwards compatibility with glibc and libstdc++])],
+ [enable backwards compatibility with glibc])],
[use_glibc_compat=$enableval],
[use_glibc_compat=no])
+AC_ARG_ENABLE([threadlocal],
+ [AS_HELP_STRING([--enable-threadlocal],
+ [enable features that depend on the c++ thread_local keyword (currently just thread names in debug logs). (default is to enabled if there is platform support and glibc-back-compat is not enabled)])],
+ [use_thread_local=$enableval],
+ [use_thread_local=auto])
+
+AC_ARG_ENABLE([asm],
+ [AS_HELP_STRING([--enable-asm],
+ [Enable assembly routines (default is yes)])],
+ [use_asm=$enableval],
+ [use_asm=yes])
+
+if test "x$use_asm" = xyes; then
+ AC_DEFINE(USE_ASM, 1, [Define this symbol to build in assembly routines])
+fi
+
AC_ARG_ENABLE([zmq],
[AS_HELP_STRING([--disable-zmq],
[disable ZMQ notifications])],
[use_zmq=$enableval],
[use_zmq=yes])
-AC_ARG_WITH([system-univalue],
- [AS_HELP_STRING([--with-system-univalue],
- [Build with system UniValue (default is no)])],
- [system_univalue=$withval],
- [system_univalue=no]
-)
-
-AC_ARG_WITH([protoc-bindir],[AS_HELP_STRING([--with-protoc-bindir=BIN_DIR],[specify protoc bin path])], [protoc_bin_path=$withval], [])
+AC_ARG_ENABLE(man,
+ [AS_HELP_STRING([--disable-man],
+ [do not install man pages (default is to install)])],,
+ enable_man=yes)
+AM_CONDITIONAL(ENABLE_MAN, test "$enable_man" != no)
# Enable debug
AC_ARG_ENABLE([debug],
@@ -179,73 +222,256 @@ AC_ARG_ENABLE([debug],
[enable_debug=$enableval],
[enable_debug=no])
+# Enable different -fsanitize options
+AC_ARG_WITH([sanitizers],
+ [AS_HELP_STRING([--with-sanitizers],
+ [comma separated list of extra sanitizers to build with (default is none enabled)])],
+ [use_sanitizers=$withval])
+
+# Enable gprof profiling
+AC_ARG_ENABLE([gprof],
+ [AS_HELP_STRING([--enable-gprof],
+ [use gprof profiling compiler flags (default is no)])],
+ [enable_gprof=$enableval],
+ [enable_gprof=no])
+
+# Turn warnings into errors
+AC_ARG_ENABLE([werror],
+ [AS_HELP_STRING([--enable-werror],
+ [Treat certain compiler warnings as errors (default is no)])],
+ [enable_werror=$enableval],
+ [enable_werror=no])
+
+AC_ARG_ENABLE([lto],
+ [AS_HELP_STRING([--enable-lto],[build using LTO (default is no)])],
+ [enable_lto=$enableval],
+ [enable_lto=no])
+
+AC_LANG_PUSH([C++])
+AX_CHECK_COMPILE_FLAG([-Werror],[CXXFLAG_WERROR="-Werror"],[CXXFLAG_WERROR=""])
+
if test "x$enable_debug" = xyes; then
- if test "x$GCC" = xyes; then
- CFLAGS="-g3 -O0 -DDEBUG"
- fi
+ # Clear default -g -O2 flags
+ if test "x$CXXFLAGS_overridden" = xno; then
+ CXXFLAGS=""
+ fi
+ # Prefer -Og, fall back to -O0 if that is unavailable.
+ AX_CHECK_COMPILE_FLAG(
+ [-Og],
+ [[DEBUG_CXXFLAGS="$DEBUG_CXXFLAGS -Og"]],
+ [AX_CHECK_COMPILE_FLAG([-O0],[[DEBUG_CXXFLAGS="$DEBUG_CXXFLAGS -O0"]],,[[$CXXFLAG_WERROR]])],
+ [[$CXXFLAG_WERROR]])
+
+ # Prefer -g3, fall back to -g if that is unavailable.
+ AX_CHECK_COMPILE_FLAG(
+ [-g3],
+ [[DEBUG_CXXFLAGS="$DEBUG_CXXFLAGS -g3"]],
+ [AX_CHECK_COMPILE_FLAG([-g],[[DEBUG_CXXFLAGS="$DEBUG_CXXFLAGS -g"]],,[[$CXXFLAG_WERROR]])],
+ [[$CXXFLAG_WERROR]])
+
+ AX_CHECK_PREPROC_FLAG([-DDEBUG],[[DEBUG_CPPFLAGS="$DEBUG_CPPFLAGS -DDEBUG"]],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_PREPROC_FLAG([-DDEBUG_LOCKORDER],[[DEBUG_CPPFLAGS="$DEBUG_CPPFLAGS -DDEBUG_LOCKORDER"]],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-ftrapv],[DEBUG_CXXFLAGS="$DEBUG_CXXFLAGS -ftrapv"],,[[$CXXFLAG_WERROR]])
+fi
- if test "x$GXX" = xyes; then
- CXXFLAGS="-g3 -O0 -DDEBUG"
- fi
+if test "x$enable_lto" = "xyes"; then
+ AX_CHECK_COMPILE_FLAG([-flto], [LTO_CXXFLAGS="$LTO_CXXFLAGS -flto"], [AC_MSG_ERROR([compile failed with -flto])], [$CXXFLAG_WERROR])
+ AX_CHECK_LINK_FLAG([-flto], [LTO_LDFLAGS="$LTO_LDFLAGS -flto"], [AC_MSG_ERROR([link failed with -flto])], [$CXXFLAG_WERROR])
+fi
+
+if test x$use_sanitizers != x; then
+ # First check if the compiler accepts flags. If an incompatible pair like
+ # -fsanitize=address,thread is used here, this check will fail. This will also
+ # fail if a bad argument is passed, e.g. -fsanitize=undfeined
+ AX_CHECK_COMPILE_FLAG(
+ [[-fsanitize=$use_sanitizers]],
+ [[SANITIZER_CXXFLAGS=-fsanitize=$use_sanitizers]],
+ [AC_MSG_ERROR([compiler did not accept requested flags])])
+
+ # Some compilers (e.g. GCC) require additional libraries like libasan,
+ # libtsan, libubsan, etc. Make sure linking still works with the sanitize
+ # flag. This is a separate check so we can give a better error message when
+ # the sanitize flags are supported by the compiler but the actual sanitizer
+ # libs are missing.
+ AX_CHECK_LINK_FLAG(
+ [[-fsanitize=$use_sanitizers]],
+ [[SANITIZER_LDFLAGS=-fsanitize=$use_sanitizers]],
+ [AC_MSG_ERROR([linker did not accept requested flags, you are missing required libraries])])
+fi
+
+ERROR_CXXFLAGS=
+if test "x$enable_werror" = "xyes"; then
+ if test "x$CXXFLAG_WERROR" = "x"; then
+ AC_MSG_ERROR("enable-werror set but -Werror is not usable")
+ fi
+ AX_CHECK_COMPILE_FLAG([-Werror=vla],[ERROR_CXXFLAGS="$ERROR_CXXFLAGS -Werror=vla"],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-Werror=thread-safety-analysis],[ERROR_CXXFLAGS="$ERROR_CXXFLAGS -Werror=thread-safety-analysis"],,[[$CXXFLAG_WERROR]])
fi
-## TODO: Remove these hard-coded paths and flags. They are here for the sake of
-## compatibility with the legacy buildsystem.
-##
if test "x$CXXFLAGS_overridden" = "xno"; then
- CXXFLAGS="$CXXFLAGS -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameter"
+ AX_CHECK_COMPILE_FLAG([-Wall],[WARN_CXXFLAGS="$WARN_CXXFLAGS -Wall"],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-Wextra],[WARN_CXXFLAGS="$WARN_CXXFLAGS -Wextra"],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-Wformat],[WARN_CXXFLAGS="$WARN_CXXFLAGS -Wformat"],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-Wvla],[WARN_CXXFLAGS="$WARN_CXXFLAGS -Wvla"],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-Wformat-security],[WARN_CXXFLAGS="$WARN_CXXFLAGS -Wformat-security"],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-Wthread-safety-analysis],[WARN_CXXFLAGS="$WARN_CXXFLAGS -Wthread-safety-analysis"],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-Wrange-loop-analysis],[WARN_CXXFLAGS="$WARN_CXXFLAGS -Wrange-loop-analysis"],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-Wredundant-decls],[WARN_CXXFLAGS="$WARN_CXXFLAGS -Wredundant-decls"],,[[$CXXFLAG_WERROR]])
+
+ ## Some compilers (gcc) ignore unknown -Wno-* options, but warn about all
+ ## unknown options if any other warning is produced. Test the -Wfoo case, and
+ ## set the -Wno-foo case if it works.
+ AX_CHECK_COMPILE_FLAG([-Wunused-parameter],[NOWARN_CXXFLAGS="$NOWARN_CXXFLAGS -Wno-unused-parameter"],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-Wself-assign],[NOWARN_CXXFLAGS="$NOWARN_CXXFLAGS -Wno-self-assign"],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-Wunused-local-typedef],[NOWARN_CXXFLAGS="$NOWARN_CXXFLAGS -Wno-unused-local-typedef"],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-Wdeprecated-register],[NOWARN_CXXFLAGS="$NOWARN_CXXFLAGS -Wno-deprecated-register"],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-Wimplicit-fallthrough],[NOWARN_CXXFLAGS="$NOWARN_CXXFLAGS -Wno-implicit-fallthrough"],,[[$CXXFLAG_WERROR]])
+ AX_CHECK_COMPILE_FLAG([-Wdeprecated-copy],[NOWARN_CXXFLAGS="$NOWARN_CXXFLAGS -Wno-deprecated-copy"],,[[$CXXFLAG_WERROR]])
fi
-CPPFLAGS="$CPPFLAGS -DBOOST_SPIRIT_THREADSAFE -DHAVE_BUILD_INFO -D__STDC_FORMAT_MACROS"
+
+enable_sse42=no
+enable_sse41=no
+enable_avx2=no
+enable_shani=no
+
+if test "x$use_asm" = "xyes"; then
+
+dnl Check for optional instruction set support. Enabling these does _not_ imply that all code will
+dnl be compiled with them, rather that specific objects/libs may use them after checking for runtime
+dnl compatibility.
+
+dnl x86
+AX_CHECK_COMPILE_FLAG([-msse4.2],[[SSE42_CXXFLAGS="-msse4.2"]],,[[$CXXFLAG_WERROR]])
+AX_CHECK_COMPILE_FLAG([-msse4.1],[[SSE41_CXXFLAGS="-msse4.1"]],,[[$CXXFLAG_WERROR]])
+AX_CHECK_COMPILE_FLAG([-mavx -mavx2],[[AVX2_CXXFLAGS="-mavx -mavx2"]],,[[$CXXFLAG_WERROR]])
+AX_CHECK_COMPILE_FLAG([-msse4 -msha],[[SHANI_CXXFLAGS="-msse4 -msha"]],,[[$CXXFLAG_WERROR]])
+
+TEMP_CXXFLAGS="$CXXFLAGS"
+CXXFLAGS="$CXXFLAGS $SSE42_CXXFLAGS"
+AC_MSG_CHECKING(for SSE4.2 intrinsics)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+ #include
+ #if defined(_MSC_VER)
+ #include
+ #elif defined(__GNUC__) && defined(__SSE4_2__)
+ #include
+ #endif
+ ]],[[
+ uint64_t l = 0;
+ l = _mm_crc32_u8(l, 0);
+ l = _mm_crc32_u32(l, 0);
+ l = _mm_crc32_u64(l, 0);
+ return l;
+ ]])],
+ [ AC_MSG_RESULT(yes); enable_sse42=yes],
+ [ AC_MSG_RESULT(no)]
+)
+CXXFLAGS="$TEMP_CXXFLAGS"
+
+TEMP_CXXFLAGS="$CXXFLAGS"
+CXXFLAGS="$CXXFLAGS $SSE41_CXXFLAGS"
+AC_MSG_CHECKING(for SSE4.1 intrinsics)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+ #include
+ #include
+ ]],[[
+ __m128i l = _mm_set1_epi32(0);
+ return _mm_extract_epi32(l, 3);
+ ]])],
+ [ AC_MSG_RESULT(yes); enable_sse41=yes; AC_DEFINE(ENABLE_SSE41, 1, [Define this symbol to build code that uses SSE4.1 intrinsics]) ],
+ [ AC_MSG_RESULT(no)]
+)
+CXXFLAGS="$TEMP_CXXFLAGS"
+
+TEMP_CXXFLAGS="$CXXFLAGS"
+CXXFLAGS="$CXXFLAGS $AVX2_CXXFLAGS"
+AC_MSG_CHECKING(for AVX2 intrinsics)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+ #include
+ #include
+ ]],[[
+ __m256i l = _mm256_set1_epi32(0);
+ return _mm256_extract_epi32(l, 7);
+ ]])],
+ [ AC_MSG_RESULT(yes); enable_avx2=yes; AC_DEFINE(ENABLE_AVX2, 1, [Define this symbol to build code that uses AVX2 intrinsics]) ],
+ [ AC_MSG_RESULT(no)]
+)
+CXXFLAGS="$TEMP_CXXFLAGS"
+
+TEMP_CXXFLAGS="$CXXFLAGS"
+CXXFLAGS="$CXXFLAGS $SHANI_CXXFLAGS"
+AC_MSG_CHECKING(for SHA-NI intrinsics)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+ #include
+ #include
+ ]],[[
+ __m128i i = _mm_set1_epi32(0);
+ __m128i j = _mm_set1_epi32(1);
+ __m128i k = _mm_set1_epi32(2);
+ return _mm_extract_epi32(_mm_sha256rnds2_epu32(i, i, k), 0);
+ ]])],
+ [ AC_MSG_RESULT(yes); enable_shani=yes; AC_DEFINE(ENABLE_SHANI, 1, [Define this symbol to build code that uses SHA-NI intrinsics]) ],
+ [ AC_MSG_RESULT(no)]
+)
+CXXFLAGS="$TEMP_CXXFLAGS"
+
+# ARM
+AX_CHECK_COMPILE_FLAG([-march=armv8-a+crc+crypto],[[ARM_CRC_CXXFLAGS="-march=armv8-a+crc+crypto"]],,[[$CXXFLAG_WERROR]])
+
+TEMP_CXXFLAGS="$CXXFLAGS"
+CXXFLAGS="$CXXFLAGS $ARM_CRC_CXXFLAGS"
+AC_MSG_CHECKING(for ARM CRC32 intrinsics)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+ #include
+ #include
+ ]],[[
+ __crc32cb(0, 0); __crc32ch(0, 0); __crc32cw(0, 0); __crc32cd(0, 0);
+ vmull_p64(0, 0);
+ ]])],
+ [ AC_MSG_RESULT(yes); enable_arm_crc=yes; ],
+ [ AC_MSG_RESULT(no)]
+)
+CXXFLAGS="$TEMP_CXXFLAGS"
+
+fi
+
+CPPFLAGS="$CPPFLAGS -DHAVE_BUILD_INFO -D__STDC_FORMAT_MACROS"
AC_ARG_WITH([utils],
[AS_HELP_STRING([--with-utils],
- [build dapscoin-cli dapscoin-tx (default=yes)])],
+ [build prcycoin-cli prcycoin-tx (default=yes)])],
[build_bitcoin_utils=$withval],
[build_bitcoin_utils=yes])
AC_ARG_WITH([libs],
[AS_HELP_STRING([--with-libs],
- [build libraries (default=yes)])],
+ [build libraries (default=no)])],
[build_bitcoin_libs=$withval],
[build_bitcoin_libs=no])
AC_ARG_WITH([daemon],
[AS_HELP_STRING([--with-daemon],
- [build dapscoind daemon (default=yes)])],
+ [build prcycoind daemon (default=yes)])],
[build_bitcoind=$withval],
[build_bitcoind=yes])
-AC_LANG_PUSH([C++])
-
-#AX_CXX_CHECK_LIB([boost_regex-mt],[boost::regex::generic_category()],[BOOST_LIB_SUFFIX="-mt"],[BOOST_LIB_SUFFIX=""])
-
-use_pkgconfig=yes
case $host in
*mingw*)
-
- #pkgconfig does more harm than good with MinGW
- use_pkgconfig=no
-
TARGET_OS=windows
- AC_CHECK_LIB([mingwthrd], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([kernel32], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([user32], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([gdi32], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([comdlg32], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([winspool], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([winmm], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([shell32], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([comctl32], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([ole32], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([oleaut32], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([uuid], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([rpcrt4], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([advapi32], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([ws2_32], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([mswsock], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([shlwapi], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([iphlpapi], [main],, AC_MSG_ERROR(lib missing))
- AC_CHECK_LIB([crypt32], [main],, AC_MSG_ERROR(lib missing))
+ AC_CHECK_LIB([kernel32], [GetModuleFileNameA],, AC_MSG_ERROR(libkernel32 missing))
+ AC_CHECK_LIB([user32], [main],, AC_MSG_ERROR(libuser32 missing))
+ AC_CHECK_LIB([gdi32], [main],, AC_MSG_ERROR(libgdi32 missing))
+ AC_CHECK_LIB([comdlg32], [main],, AC_MSG_ERROR(libcomdlg32 missing))
+ AC_CHECK_LIB([winmm], [main],, AC_MSG_ERROR(libwinmm missing))
+ AC_CHECK_LIB([shell32], [SHGetSpecialFolderPathW],, AC_MSG_ERROR(libshell32 missing))
+ AC_CHECK_LIB([comctl32], [main],, AC_MSG_ERROR(libcomctl32 missing))
+ AC_CHECK_LIB([ole32], [CoCreateInstance],, AC_MSG_ERROR(libole32 missing))
+ AC_CHECK_LIB([oleaut32], [main],, AC_MSG_ERROR(liboleaut32 missing))
+ AC_CHECK_LIB([uuid], [main],, AC_MSG_ERROR(libuuid missing))
+ AC_CHECK_LIB([advapi32], [CryptAcquireContextW],, AC_MSG_ERROR(libadvapi32 missing))
+ AC_CHECK_LIB([ws2_32], [WSAStartup],, AC_MSG_ERROR(libws2_32 missing))
+ AC_CHECK_LIB([shlwapi], [PathRemoveFileSpecW],, AC_MSG_ERROR(libshlwapi missing))
+ AC_CHECK_LIB([iphlpapi], [GetAdaptersAddresses],, AC_MSG_ERROR(libiphlpapi missing))
# -static is interpreted by libtool, where it has a different meaning.
# In libtool-speak, it's -all-static.
@@ -261,17 +487,11 @@ case $host in
AC_MSG_ERROR("windres not found")
fi
- CPPFLAGS="$CPPFLAGS -D_MT -DWIN32 -D_WINDOWS -DBOOST_THREAD_USE_LIB"
- LEVELDB_TARGET_FLAGS="TARGET_OS=OS_WINDOWS_CROSSCOMPILE"
+ CPPFLAGS="$CPPFLAGS -D_MT -DWIN32 -D_WINDOWS -DBOOST_THREAD_USE_LIB -D_WIN32_WINNT=0x0601 -D_WIN32_IE=0x0501 -DWIN32_LEAN_AND_MEAN"
+ LEVELDB_TARGET_FLAGS="-DOS_WINDOWS"
if test "x$CXXFLAGS_overridden" = "xno"; then
CXXFLAGS="$CXXFLAGS -w"
fi
- case $host in
- i?86-*) WINDOWS_BITS=32 ;;
- x86_64-*) WINDOWS_BITS=64 ;;
- *) AC_MSG_ERROR("Could not determine win32/win64 for installer") ;;
- esac
- AC_SUBST(WINDOWS_BITS)
dnl libtool insists upon adding -nostdlib and a list of objects/libs to link against.
dnl That breaks our ability to build dll's with static libgcc/libstdc++/libssp. Override
@@ -284,21 +504,9 @@ case $host in
;;
*darwin*)
TARGET_OS=darwin
- LEVELDB_TARGET_FLAGS="TARGET_OS=Darwin"
+ LEVELDB_TARGET_FLAGS="-DOS_MACOSX"
if test x$cross_compiling != xyes; then
BUILD_OS=darwin
- AC_CHECK_PROG([PORT],port, port)
- if test x$PORT = xport; then
- dnl add default macports paths
- CPPFLAGS="$CPPFLAGS -isystem /opt/local/include"
- LIBS="$LIBS -L/opt/local/lib"
- if test -d /opt/local/include/db48; then
- CPPFLAGS="$CPPFLAGS -I/opt/local/include/db48"
- LIBS="$LIBS -L/opt/local/lib/db48"
- fi
- fi
-
- AC_PATH_PROGS([RSVG_CONVERT], [rsvg-convert rsvg],rsvg-convert)
AC_CHECK_PROG([BREW],brew, brew)
if test x$BREW = xbrew; then
dnl These Homebrew packages may be keg-only, meaning that they won't be found
@@ -329,12 +537,9 @@ case $host in
BUILD_OS=darwin
;;
*)
- AC_PATH_TOOL([INSTALLNAMETOOL], [install_name_tool], install_name_tool)
+ AC_PATH_TOOL([INSTALL_NAME_TOOL], [install_name_tool], install_name_tool)
AC_PATH_TOOL([OTOOL], [otool], otool)
- AC_PATH_PROGS([GENISOIMAGE], [genisoimage mkisofs],genisoimage)
- AC_PATH_PROGS([RSVG_CONVERT], [rsvg-convert rsvg],rsvg-convert)
- AC_PATH_PROGS([IMAGEMAGICK_CONVERT], [convert],convert)
- AC_PATH_PROGS([TIFFCP], [tiffcp],tiffcp)
+ AC_PATH_PROGS([XORRISOFS], [xorrisofs], xorrisofs)
dnl libtool will try to strip the static lib, which is a problem for
dnl cross-builds because strip attempts to call a hard-coded ld,
@@ -346,36 +551,35 @@ case $host in
fi
AX_CHECK_LINK_FLAG([[-Wl,-headerpad_max_install_names]], [LDFLAGS="$LDFLAGS -Wl,-headerpad_max_install_names"])
- CPPFLAGS="$CPPFLAGS -DMAC_OSX"
+ CPPFLAGS="$CPPFLAGS -DMAC_OSX -DOBJC_OLD_DISPATCH_PROTOTYPES=0"
+ OBJCXXFLAGS="$CXXFLAGS"
+ ;;
+ *android*)
+ dnl make sure android stays above linux for hosts like *linux-android*
+ TARGET_OS=android
+ case $host in
+ *x86_64*)
+ ANDROID_ARCH=x86_64
+ ;;
+ *aarch64*)
+ ANDROID_ARCH=arm64-v8a
+ ;;
+ *armv7a*)
+ ANDROID_ARCH=armeabi-v7a
+ ;;
+ *i686*)
+ ANDROID_ARCH=i686
+ ;;
+ *) AC_MSG_ERROR("Could not determine Android arch") ;;
+ esac
;;
*linux*)
TARGET_OS=linux
;;
- *)
- ;;
esac
-if test x$use_pkgconfig = xyes; then
- m4_ifndef([PKG_PROG_PKG_CONFIG], [AC_MSG_ERROR(PKG_PROG_PKG_CONFIG macro not found. Please install pkg-config and re-run autogen.sh.)])
- m4_ifdef([PKG_PROG_PKG_CONFIG], [
- PKG_PROG_PKG_CONFIG
- if test x"$PKG_CONFIG" = "x"; then
- AC_MSG_ERROR(pkg-config not found.)
- fi
- ])
-fi
-
-if test x$use_comparison_tool != xno; then
- AC_SUBST(JAVA_COMPARISON_TOOL, $use_comparison_tool)
-fi
-
-if test x$use_comparison_tool_reorg_tests != xno; then
- if test x$use_comparison_tool = x; then
- AC_MSG_ERROR("comparison tool reorg tests but comparison tool was not specified")
- fi
- AC_SUBST(COMPARISON_TOOL_REORG_TESTS, 1)
-else
- AC_SUBST(COMPARISON_TOOL_REORG_TESTS, 0)
+if test x$use_extended_functional_tests != xno; then
+ AC_SUBST(EXTENDED_FUNCTIONAL_TESTS, --extended)
fi
if test x$use_lcov = xyes; then
@@ -385,27 +589,32 @@ if test x$use_lcov = xyes; then
if test x$GCOV = x; then
AC_MSG_ERROR("lcov testing requested but gcov not found")
fi
- if test x$JAVA = x; then
- AC_MSG_ERROR("lcov testing requested but java not found")
+ if test x$PYTHON = x; then
+ AC_MSG_ERROR("lcov testing requested but python not found")
fi
if test x$GENHTML = x; then
AC_MSG_ERROR("lcov testing requested but genhtml not found")
fi
- if test x$use_comparison_tool = x; then
- AC_MSG_ERROR("lcov testing requested but comparison tool was not specified")
- fi
LCOV="$LCOV --gcov-tool=$GCOV"
+ AX_CHECK_LINK_FLAG([[--coverage]], [LDFLAGS="$LDFLAGS --coverage"],
+ [AC_MSG_ERROR("lcov testing requested but --coverage linker flag does not work")])
AX_CHECK_COMPILE_FLAG([--coverage],[CXXFLAGS="$CXXFLAGS --coverage"],
[AC_MSG_ERROR("lcov testing requested but --coverage flag does not work")])
+ AC_DEFINE(USE_COVERAGE, 1, [Define this symbol if coverage is enabled])
+ CXXFLAGS="$CXXFLAGS -Og"
fi
-dnl Require little endian
-AC_C_BIGENDIAN([AC_MSG_ERROR("Big Endian not supported")])
+if test x$use_lcov_branch != xno; then
+ AC_SUBST(LCOV_OPTS, "$LCOV_OPTS --rc lcov_branch_coverage=1")
+fi
+
+dnl Check for endianness
+AC_C_BIGENDIAN
dnl Check for pthread compile/link requirements
AX_PTHREAD
-# The following macro will add the necessary defines to dapscoin-config.h, but
+# The following macro will add the necessary defines to prcycoin-config.h, but
# they also need to be passed down to any subprojects. Pull the results out of
# the cache and add them to CPPFLAGS.
AC_SYS_LARGEFILE
@@ -431,24 +640,36 @@ AX_GCC_FUNC_ATTRIBUTE([dllexport])
AX_GCC_FUNC_ATTRIBUTE([dllimport])
if test x$use_glibc_compat != xno; then
+ AX_CHECK_LINK_FLAG([[-Wl,--wrap=__divmoddi4]], [COMPAT_LDFLAGS="$COMPAT_LDFLAGS -Wl,--wrap=__divmoddi4"])
+ AX_CHECK_LINK_FLAG([[-Wl,--wrap=log2f]], [COMPAT_LDFLAGS="$COMPAT_LDFLAGS -Wl,--wrap=log2f"])
+else
+ AC_SEARCH_LIBS([clock_gettime],[rt])
+fi
+
+if test "x$enable_gprof" = xyes; then
+ dnl -pg is incompatible with -pie. Since hardening and profiling together doesn't make sense,
+ dnl we simply make them mutually exclusive here. Additionally, hardened toolchains may force
+ dnl -pie by default, in which case it needs to be turned off with -no-pie.
+
+ if test x$use_hardening = xyes; then
+ AC_MSG_ERROR(gprof profiling is not compatible with hardening. Reconfigure with --disable-hardening or --disable-gprof)
+ fi
+ use_hardening=no
+ AX_CHECK_COMPILE_FLAG([-pg],[GPROF_CXXFLAGS="-pg"],
+ [AC_MSG_ERROR(gprof profiling requested but not available)], [[$CXXFLAG_WERROR]])
- #__fdelt_chk's params and return type have changed from long unsigned int to long int.
- # See which one is present here.
- AC_MSG_CHECKING(__fdelt_chk type)
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#ifdef _FORTIFY_SOURCE
- #undef _FORTIFY_SOURCE
- #endif
- #define _FORTIFY_SOURCE 2
- #include
- extern "C" long unsigned int __fdelt_warn(long unsigned int);]],[[]])],
- [ fdelt_type="long unsigned int"],
- [ fdelt_type="long int"])
- AC_MSG_RESULT($fdelt_type)
- AC_DEFINE_UNQUOTED(FDELT_TYPE, $fdelt_type,[parameter and return value type for __fdelt_chk])
+ AX_CHECK_LINK_FLAG([[-no-pie]], [GPROF_LDFLAGS="-no-pie"])
+ AX_CHECK_LINK_FLAG([[-pg]],[GPROF_LDFLAGS="$GPROF_LDFLAGS -pg"],
+ [AC_MSG_ERROR(gprof profiling requested but not available)], [[$GPROF_LDFLAGS]])
+fi
+if test x$TARGET_OS != xwindows; then
+ # All windows code is PIC, forcing it on just adds useless compile warnings
+ AX_CHECK_COMPILE_FLAG([-fPIC],[PIC_FLAGS="-fPIC"])
fi
if test x$use_hardening != xno; then
+ use_hardening=yes
AX_CHECK_COMPILE_FLAG([-Wstack-protector],[HARDENED_CXXFLAGS="$HARDENED_CXXFLAGS -Wstack-protector"])
AX_CHECK_COMPILE_FLAG([-fstack-protector-all],[HARDENED_CXXFLAGS="$HARDENED_CXXFLAGS -fstack-protector-all"])
@@ -461,52 +682,60 @@ if test x$use_hardening != xno; then
AX_CHECK_LINK_FLAG([[-Wl,--dynamicbase]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,--dynamicbase"])
AX_CHECK_LINK_FLAG([[-Wl,--nxcompat]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,--nxcompat"])
+ AX_CHECK_LINK_FLAG([[-Wl,--high-entropy-va]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,--high-entropy-va"])
AX_CHECK_LINK_FLAG([[-Wl,-z,relro]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,-z,relro"])
AX_CHECK_LINK_FLAG([[-Wl,-z,now]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,-z,now"])
-
- if test x$TARGET_OS != xwindows; then
- # All windows code is PIC, forcing it on just adds useless compile warnings
- AX_CHECK_COMPILE_FLAG([-fPIC],[HARDENED_CXXFLAGS="$HARDENED_CXXFLAGS -fPIC"])
- AX_CHECK_LINK_FLAG([[-pic]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -pic"])
- fi
+ AX_CHECK_LINK_FLAG([[-fPIE -pie]], [PIE_FLAGS="-fPIE"; HARDENED_LDFLAGS="$HARDENED_LDFLAGS -pie"],, [[$CXXFLAG_WERROR]])
case $host in
*mingw*)
- AC_CHECK_LIB([ssp], [main],, AC_MSG_ERROR(lib missing))
+ AC_CHECK_LIB([ssp], [main],, AC_MSG_ERROR(libssp missing))
;;
esac
-
- CXXFLAGS="$CXXFLAGS $HARDENED_CXXFLAGS"
- CPPFLAGS="$CPPFLAGS $HARDENED_CPPFLAGS"
- LDFLAGS="$LDFLAGS $HARDENED_LDFLAGS"
- OBJCXXFLAGS="$CXXFLAGS"
fi
dnl this flag screws up non-darwin gcc even when the check fails. special-case it.
if test x$TARGET_OS = xdarwin; then
AX_CHECK_LINK_FLAG([[-Wl,-dead_strip]], [LDFLAGS="$LDFLAGS -Wl,-dead_strip"])
+ AX_CHECK_LINK_FLAG([[-Wl,-dead_strip_dylibs]], [LDFLAGS="$LDFLAGS -Wl,-dead_strip_dylibs"])
fi
-AC_CHECK_HEADERS([endian.h stdio.h stdlib.h unistd.h strings.h sys/types.h sys/stat.h sys/select.h sys/prctl.h])
-AC_SEARCH_LIBS([getaddrinfo_a], [anl], [AC_DEFINE(HAVE_GETADDRINFO_A, 1, [Define this symbol if you have getaddrinfo_a])])
-AC_SEARCH_LIBS([inet_pton], [nsl resolv], [AC_DEFINE(HAVE_INET_PTON, 1, [Define this symbol if you have inet_pton])])
+AC_CHECK_HEADERS([endian.h sys/endian.h byteswap.h stdio.h stdlib.h unistd.h strings.h sys/types.h sys/stat.h sys/select.h sys/prctl.h])
AC_CHECK_DECLS([strnlen])
-AC_CHECK_DECLS([le32toh, le64toh, htole32, htole64, be32toh, be64toh, htobe32, htobe64],,,
+# Check for daemon(3), unrelated to --with-daemon (although used by it)
+AC_CHECK_DECLS([daemon])
+
+AC_CHECK_DECLS([le16toh, le32toh, le64toh, htole16, htole32, htole64, be16toh, be32toh, be64toh, htobe16, htobe32, htobe64],,,
[#if HAVE_ENDIAN_H
#include
+ #elif HAVE_SYS_ENDIAN_H
+ #include
#endif])
-dnl Check for MSG_NOSIGNAL
-AC_MSG_CHECKING(for MSG_NOSIGNAL)
-AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]],
- [[ int f = MSG_NOSIGNAL; ]])],
- [ AC_MSG_RESULT(yes); AC_DEFINE(HAVE_MSG_NOSIGNAL, 1,[Define this symbol if you have MSG_NOSIGNAL]) ],
+AC_CHECK_DECLS([bswap_16, bswap_32, bswap_64],,,
+ [#if HAVE_BYTESWAP_H
+ #include
+ #endif])
+
+AC_CHECK_DECLS([__builtin_clz, __builtin_clzl, __builtin_clzll])
+
+dnl Check for malloc_info (for memory statistics information in getmemoryinfo)
+AC_MSG_CHECKING(for getmemoryinfo)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]],
+ [[ int f = malloc_info(0, NULL); ]])],
+ [ AC_MSG_RESULT(yes); AC_DEFINE(HAVE_MALLOC_INFO, 1,[Define this symbol if you have malloc_info]) ],
[ AC_MSG_RESULT(no)]
)
-AC_SEARCH_LIBS([clock_gettime],[rt])
+dnl Check for mallopt(M_ARENA_MAX) (to set glibc arenas)
+AC_MSG_CHECKING(for mallopt M_ARENA_MAX)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]],
+ [[ mallopt(M_ARENA_MAX, 1); ]])],
+ [ AC_MSG_RESULT(yes); AC_DEFINE(HAVE_MALLOPT_ARENA_MAX, 1,[Define this symbol if you have mallopt with M_ARENA_MAX]) ],
+ [ AC_MSG_RESULT(no)]
+)
AC_MSG_CHECKING([for visibility attribute])
AC_LINK_IFELSE([AC_LANG_SOURCE([
@@ -520,31 +749,160 @@ AC_LINK_IFELSE([AC_LANG_SOURCE([
[
AC_MSG_RESULT(no)
if test x$use_reduce_exports = xyes; then
- AC_MSG_ERROR([Cannot find a working visibility attribute. Use --disable-reduced-exports.])
+ AC_MSG_ERROR([Cannot find a working visibility attribute. Use --disable-reduce-exports.])
fi
- AC_MSG_WARN([Cannot find a working visibility attribute. Disabling reduced exports.])
- use_reduce_exports=no
]
)
-if test x$use_reduce_exports != xno; then
- AX_CHECK_COMPILE_FLAG([-fvisibility=hidden],[RE_CXXFLAGS="-fvisibility=hidden"],
- [
- if test x$use_reduce_exports = xyes; then
- AC_MSG_ERROR([Cannot set default symbol visibility. Use --disable-reduced-exports.])
- fi
- AC_MSG_WARN([Cannot set default symbol visibility. Disabling reduced exports.])
- use_reduce_exports=no
- ])
+if test "x$use_thread_local" = xyes || { test "x$use_thread_local" = xauto && test "x$use_glibc_compat" = xno; }; then
+ TEMP_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$TEMP_LDFLAGS $PTHREAD_CFLAGS"
+ AC_MSG_CHECKING([for thread_local support])
+ AC_LINK_IFELSE([AC_LANG_SOURCE([
+ #include
+ static thread_local int foo = 0;
+ static void run_thread() { foo++;}
+ int main(){
+ for(int i = 0; i < 10; i++) { std::thread(run_thread).detach();}
+ return foo;
+ }
+ ])],
+ [
+ case $host in
+ *mingw*)
+ dnl mingw32's implementation of thread_local has also been shown to behave
+ dnl erroneously under concurrent usage; see:
+ dnl https://gist.github.com/jamesob/fe9a872051a88b2025b1aa37bfa98605
+ AC_MSG_RESULT(no)
+ ;;
+ *darwin*)
+ dnl TODO enable thread_local on later versions of Darwin where it is
+ dnl supported (per https://stackoverflow.com/a/29929949)
+ AC_MSG_RESULT(no)
+ ;;
+ *freebsd*)
+ dnl FreeBSD's implementation of thread_local is also buggy (per
+ dnl https://groups.google.com/d/msg/bsdmailinglist/22ncTZAbDp4/Dii_pII5AwAJ)
+ AC_MSG_RESULT(no)
+ ;;
+ *)
+ AC_DEFINE(HAVE_THREAD_LOCAL,1,[Define if thread_local is supported.])
+ AC_MSG_RESULT(yes)
+ ;;
+ esac
+ ],
+ [
+ AC_MSG_RESULT(no)
+ ]
+ )
+ LDFLAGS="$TEMP_LDFLAGS"
fi
-LEVELDB_CPPFLAGS=
-LIBLEVELDB=
-LIBMEMENV=
-AM_CONDITIONAL([EMBEDDED_LEVELDB],[true])
-AC_SUBST(LEVELDB_CPPFLAGS)
-AC_SUBST(LIBLEVELDB)
-AC_SUBST(LIBMEMENV)
+# Check for different ways of gathering OS randomness
+AC_MSG_CHECKING(for Linux getrandom syscall)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include
+ #include
+ #include ]],
+ [[ syscall(SYS_getrandom, nullptr, 32, 0); ]])],
+ [ AC_MSG_RESULT(yes); AC_DEFINE(HAVE_SYS_GETRANDOM, 1,[Define this symbol if the Linux getrandom system call is available]) ],
+ [ AC_MSG_RESULT(no)]
+)
+
+AC_MSG_CHECKING(for getentropy)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]],
+ [[ getentropy(nullptr, 32) ]])],
+ [ AC_MSG_RESULT(yes); AC_DEFINE(HAVE_GETENTROPY, 1,[Define this symbol if the BSD getentropy system call is available]) ],
+ [ AC_MSG_RESULT(no)]
+)
+
+AC_MSG_CHECKING(for getentropy via random.h)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include
+ #include ]],
+ [[ getentropy(nullptr, 32) ]])],
+ [ AC_MSG_RESULT(yes); AC_DEFINE(HAVE_GETENTROPY_RAND, 1,[Define this symbol if the BSD getentropy system call is available with sys/random.h]) ],
+ [ AC_MSG_RESULT(no)]
+)
+
+AC_MSG_CHECKING(for sysctl KERN_ARND)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include
+ #include ]],
+ [[ static const int name[2] = {CTL_KERN, KERN_ARND};
+ sysctl(name, 2, nullptr, nullptr, nullptr, 0); ]])],
+ [ AC_MSG_RESULT(yes); AC_DEFINE(HAVE_SYSCTL_ARND, 1,[Define this symbol if the BSD sysctl(KERN_ARND) is available]) ],
+ [ AC_MSG_RESULT(no)]
+)
+
+dnl LevelDB platform checks
+AC_MSG_CHECKING(for fdatasync)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]],
+ [[ fdatasync(0); ]])],
+ [ AC_MSG_RESULT(yes); HAVE_FDATASYNC=1 ],
+ [ AC_MSG_RESULT(no); HAVE_FDATASYNC=0 ]
+)
+
+AC_MSG_CHECKING(for F_FULLFSYNC)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]],
+ [[ fcntl(0, F_FULLFSYNC, 0); ]])],
+ [ AC_MSG_RESULT(yes); HAVE_FULLFSYNC=1 ],
+ [ AC_MSG_RESULT(no); HAVE_FULLFSYNC=0 ]
+)
+
+AC_MSG_CHECKING(for O_CLOEXEC)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]],
+ [[ open("", O_CLOEXEC); ]])],
+ [ AC_MSG_RESULT(yes); HAVE_O_CLOEXEC=1 ],
+ [ AC_MSG_RESULT(no); HAVE_O_CLOEXEC=0 ]
+)
+
+dnl crc32c platform checks
+AC_MSG_CHECKING(for __builtin_prefetch)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ ]], [[
+ char data = 0;
+ const char* address = &data;
+ __builtin_prefetch(address, 0, 0);
+ ]])],
+ [ AC_MSG_RESULT(yes); HAVE_BUILTIN_PREFETCH=1 ],
+ [ AC_MSG_RESULT(no); HAVE_BUILTIN_PREFETCH=0 ]
+)
+
+AC_MSG_CHECKING(for _mm_prefetch)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]], [[
+ char data = 0;
+ const char* address = &data;
+ _mm_prefetch(address, _MM_HINT_NTA);
+ ]])],
+ [ AC_MSG_RESULT(yes); HAVE_MM_PREFETCH=1 ],
+ [ AC_MSG_RESULT(no); HAVE_MM_PREFETCH=0 ]
+)
+
+AC_MSG_CHECKING(for strong getauxval support in the system headers)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+ #include
+ #include
+ #include
+ ]], [[
+ getauxval(AT_HWCAP);
+ ]])],
+ [ AC_MSG_RESULT(yes); HAVE_STRONG_GETAUXVAL=1 ],
+ [ AC_MSG_RESULT(no); HAVE_STRONG_GETAUXVAL=0 ]
+)
+
+AC_MSG_CHECKING(for weak getauxval support in the compiler)
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+ unsigned long getauxval(unsigned long type) __attribute__((weak));
+ #define AT_HWCAP 16
+ ]], [[
+ getauxval(AT_HWCAP);
+ ]])],
+ [ AC_MSG_RESULT(yes); HAVE_WEAK_GETAUXVAL=1 ],
+ [ AC_MSG_RESULT(no); HAVE_WEAK_GETAUXVAL=0 ]
+)
+
+dnl Check for reduced exports
+if test x$use_reduce_exports = xyes; then
+ AX_CHECK_COMPILE_FLAG([-fvisibility=hidden],[RE_CXXFLAGS="-fvisibility=hidden"],
+ [AC_MSG_ERROR([Cannot set default symbol visibility. Use --disable-reduce-exports.])])
+fi
if test x$enable_wallet != xno; then
dnl Check for libdb_cxx only if wallet enabled
@@ -555,7 +913,7 @@ dnl Check for libminiupnpc (optional)
if test x$use_upnp != xno; then
AC_CHECK_HEADERS(
[miniupnpc/miniwget.h miniupnpc/miniupnpc.h miniupnpc/upnpcommands.h miniupnpc/upnperrors.h],
- [AC_CHECK_LIB([miniupnpc], [main],[MINIUPNPC_LIBS=-lminiupnpc], [have_miniupnpc=no])],
+ [AC_CHECK_LIB([miniupnpc], [upnpDiscover], [MINIUPNPC_LIBS=-lminiupnpc], [have_miniupnpc=no])],
[have_miniupnpc=no]
)
fi
@@ -563,71 +921,29 @@ fi
BITCOIN_QT_INIT
dnl sets $bitcoin_enable_qt, $bitcoin_enable_qt_test, $bitcoin_enable_qt_dbus
-BITCOIN_QT_CONFIGURE([$use_pkgconfig], [qt5])
+BITCOIN_QT_CONFIGURE([5.5.1])
-if test x$build_bitcoin_utils$build_bitcoind$bitcoin_enable_qt$use_tests = xnononono; then
+if test x$build_bitcoin_utils$build_bitcoind$bitcoin_enable_qt$use_tests$use_bench = xnonononono; then
use_boost=no
else
use_boost=yes
fi
-if test x$bitcoin_enable_qt = xyes; then
-dnl enable tradingdialog
- AC_MSG_CHECKING([if the trading dialog should be enabled])
- if test x$bitcoin_qt_got_major_vers = x5; then
- AC_MSG_RESULT(yes)
- AC_DEFINE_UNQUOTED([HAVE_QT5],[1],[Define to 1 to enable trading dialog])
-
- else
- AC_MSG_RESULT(no)
- fi
-fi
-
if test x$use_boost = xyes; then
-dnl Check for boost libs
-AX_BOOST_BASE
+dnl Check for Boost headers
+AX_BOOST_BASE([1.64.0],[],[AC_MSG_ERROR([Boost is not available!])])
+if test x$want_boost = xno; then
+ AC_MSG_ERROR([[only libbitcoinconsensus can be built without boost]])
+fi
AX_BOOST_SYSTEM
AX_BOOST_FILESYSTEM
AX_BOOST_PROGRAM_OPTIONS
AX_BOOST_THREAD
AX_BOOST_CHRONO
-AX_BOOST_REGEX
-
-
-if test x$use_reduce_exports != xno; then
- AC_MSG_CHECKING([for working boost reduced exports])
- TEMP_CPPFLAGS="$CPPFLAGS"
- CPPFLAGS="$BOOST_CPPFLAGS $CPPFLAGS"
- AC_PREPROC_IFELSE([AC_LANG_PROGRAM([[
- @%:@include
- ]], [[
- #if BOOST_VERSION >= 104900
- // Everything is okay
- #else
- # error Boost version is too old
- #endif
- ]])],[
- AC_MSG_RESULT(yes)
- ],[:
- if test x$use_reduce_exports = xauto; then
- use_reduce_exports=no
- else
- if test x$use_reduce_exports = xyes; then
- AC_MSG_ERROR([boost versions < 1.49 are known to be broken with reduced exports. Use --disable-reduced-exports.])
- fi
- fi
- AC_MSG_RESULT(no)
- AC_MSG_WARN([boost versions < 1.49 are known to have symbol visibility issues. Disabling reduced exports.])
- ])
- CPPFLAGS="$TEMP_CPPFLAGS"
fi
-elif test x$use_reduce_exports = xauto; then
- use_reduce_exports=yes
-fi
-
-if test x$use_reduce_exports != xno; then
+if test x$use_reduce_exports = xyes; then
CXXFLAGS="$CXXFLAGS $RE_CXXFLAGS"
AX_CHECK_LINK_FLAG([[-Wl,--exclude-libs,ALL]], [RELDFLAGS="-Wl,--exclude-libs,ALL"])
fi
@@ -665,200 +981,75 @@ if test x$use_tests = xyes; then
fi
if test x$use_boost = xyes; then
-
-BOOST_LIBS="$BOOST_LDFLAGS $BOOST_SYSTEM_LIB $BOOST_REGEX_LIB $BOOST_FILESYSTEM_LIB $BOOST_PROGRAM_OPTIONS_LIB $BOOST_THREAD_LIB"
-
-dnl Boost >= 1.50 uses sleep_for rather than the now-deprecated sleep, however
-dnl it was broken from 1.50 to 1.52 when backed by nanosleep. Use sleep_for if
-dnl a working version is available, else fall back to sleep. sleep was removed
-dnl after 1.56.
-dnl If neither is available, abort.
-dnl If sleep_for is used, boost_chrono becomes a requirement.
-if test x$ax_cv_boost_chrono = xyes; then
-TEMP_LIBS="$LIBS"
-LIBS="$BOOST_LIBS $BOOST_CHRONO_LIB $LIBS"
-TEMP_CPPFLAGS="$CPPFLAGS"
-CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS"
-AC_LINK_IFELSE([AC_LANG_PROGRAM([[
- #include
- #include
- ]],[[
- #if BOOST_VERSION >= 105000 && (!defined(BOOST_HAS_NANOSLEEP) || BOOST_VERSION >= 105200)
- boost::this_thread::sleep_for(boost::chrono::milliseconds(0));
- #else
- choke me
- #endif
- ]])],
- [boost_sleep=yes; BOOST_LIBS="$BOOST_LIBS $BOOST_CHRONO_LIB";
- AC_DEFINE(HAVE_WORKING_BOOST_SLEEP_FOR, 1, [Define this symbol if boost sleep_for works])],
- [boost_sleep=no])
-LIBS="$TEMP_LIBS"
-CPPFLAGS="$TEMP_CPPFLAGS"
+BOOST_LIBS="$BOOST_LDFLAGS $BOOST_SYSTEM_LIB $BOOST_FILESYSTEM_LIB $BOOST_PROGRAM_OPTIONS_LIB $BOOST_THREAD_LIB $BOOST_CHRONO_LIB"
fi
-if test x$boost_sleep != xyes; then
-TEMP_LIBS="$LIBS"
-LIBS="$BOOST_LIBS $LIBS"
-TEMP_CPPFLAGS="$CPPFLAGS"
-CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS"
-AC_LINK_IFELSE([AC_LANG_PROGRAM([[
- #include
- #include
- #include
- ]],[[
- #if BOOST_VERSION <= 105600
- boost::this_thread::sleep(boost::posix_time::milliseconds(0));
- #else
- choke me
- #endif
- ]])],
- [boost_sleep=yes; AC_DEFINE(HAVE_WORKING_BOOST_SLEEP, 1, [Define this symbol if boost sleep works])],
- [boost_sleep=no])
-LIBS="$TEMP_LIBS"
-CPPFLAGS="$TEMP_CPPFLAGS"
-fi
+AC_CHECK_HEADER([openssl/crypto.h],,AC_MSG_ERROR(libcrypto headers missing))
+AC_CHECK_LIB([crypto], [main],CRYPTO_LIBS=-lcrypto, AC_MSG_ERROR(libcrypto missing))
-if test x$boost_sleep != xyes; then
- AC_MSG_ERROR(No working boost sleep implementation found.)
-fi
+AC_CHECK_HEADER([openssl/ssl.h],, AC_MSG_ERROR(libssl headers missing),)
+AC_CHECK_LIB([ssl], [main],SSL_LIBS=-lssl, AC_MSG_ERROR(libssl missing))
+dnl libevent check
+if test x$build_bitcoin_cli$build_bitcoind$bitcoin_enable_qt$use_tests$use_bench != xnonononono; then
+ PKG_CHECK_MODULES([EVENT], [libevent >= 2.0.21], [use_libevent=yes], [AC_MSG_ERROR([libevent version 2.0.21 or greater not found.])])
+ if test x$TARGET_OS != xwindows; then
+ PKG_CHECK_MODULES([EVENT_PTHREADS], [libevent_pthreads >= 2.0.21],, [AC_MSG_ERROR([libevent_pthreads version 2.0.21 or greater not found.])])
+ fi
fi
-if test x$use_pkgconfig = xyes; then
- : dnl
- m4_ifdef(
- [PKG_CHECK_MODULES],
- [
- PKG_CHECK_MODULES([SSL], [libssl],, [AC_MSG_ERROR(openssl not found.)])
- PKG_CHECK_MODULES([CRYPTO], [libcrypto],,[AC_MSG_ERROR(libcrypto not found.)])
- BITCOIN_QT_CHECK([PKG_CHECK_MODULES([PROTOBUF], [protobuf], [have_protobuf=yes], [BITCOIN_QT_FAIL(libprotobuf not found)])])
- if test x$use_qr != xno; then
- BITCOIN_QT_CHECK([PKG_CHECK_MODULES([QR], [libqrencode], [have_qrencode=yes], [have_qrencode=no])])
- fi
- if test x$build_bitcoin_utils$build_bitcoind$bitcoin_enable_qt$use_tests != xnononono; then
- PKG_CHECK_MODULES([EVENT], [libevent],, [AC_MSG_ERROR(libevent not found.)])
- if test x$TARGET_OS != xwindows; then
- PKG_CHECK_MODULES([EVENT_PTHREADS], [libevent_pthreads],, [AC_MSG_ERROR(libevent_pthreads not found.)])
- fi
- fi
- if test "x$use_zmq" = "xyes"; then
- PKG_CHECK_MODULES([ZMQ],[libzmq >= 4],
- [AC_DEFINE([ENABLE_ZMQ],[1],[Define to 1 to enable ZMQ functions])],
- [AC_DEFINE([ENABLE_ZMQ],[0],[Define to 1 to enable ZMQ functions])
- AC_MSG_WARN([libzmq version 4.x or greater not found, disabling])
- use_zmq=no])
- else
- AC_DEFINE_UNQUOTED([ENABLE_ZMQ],[0],[Define to 1 to enable ZMQ functions])
- fi
-
- ]
- )
-else
- AC_CHECK_HEADER([openssl/crypto.h],,AC_MSG_ERROR(libcrypto headers missing))
- AC_CHECK_LIB([crypto], [main],CRYPTO_LIBS=-lcrypto, AC_MSG_ERROR(libcrypto missing))
-
- AC_CHECK_HEADER([openssl/ssl.h],, AC_MSG_ERROR(libssl headers missing),)
- AC_CHECK_LIB([ssl], [main],SSL_LIBS=-lssl, AC_MSG_ERROR(libssl missing))
-
- if test x$build_bitcoin_utils$build_bitcoind$bitcoin_enable_qt$use_tests != xnononono; then
- AC_CHECK_HEADER([event2/event.h],, AC_MSG_ERROR(libevent headers missing),)
- AC_CHECK_LIB([event],[main],EVENT_LIBS=-levent,AC_MSG_ERROR(libevent missing))
- if test x$TARGET_OS != xwindows; then
- AC_CHECK_LIB([event_pthreads],[main],EVENT_PTHREADS_LIBS=-levent_pthreads,AC_MSG_ERROR(libevent_pthreads missing))
- fi
- fi
+dnl QR Code encoding library check
- if test "x$use_zmq" = "xyes"; then
- AC_CHECK_HEADER([zmq.h],
- [AC_DEFINE([ENABLE_ZMQ],[1],[Define to 1 to enable ZMQ functions])],
- [AC_MSG_WARN([zmq.h not found, disabling zmq support])
- use_zmq=no
- AC_DEFINE([ENABLE_ZMQ],[0],[Define to 1 to enable ZMQ functions])])
- AC_CHECK_LIB([zmq],[zmq_ctx_shutdown],ZMQ_LIBS=-lzmq,
- [AC_MSG_WARN([libzmq >= 4.0 not found, disabling zmq support])
- use_zmq=no
- AC_DEFINE([ENABLE_ZMQ],[0],[Define to 1 to enable ZMQ functions])])
- else
- AC_DEFINE_UNQUOTED([ENABLE_ZMQ],[0],[Define to 1 to enable ZMQ functions])
- fi
+if test "x$use_qr" != xno; then
+ BITCOIN_QT_CHECK([PKG_CHECK_MODULES([QR], [libqrencode], [have_qrencode=yes], [have_qrencode=no])])
+fi
- if test "x$use_zmq" = "xyes"; then
- dnl Assume libzmq was built for static linking
- case $host in
- *mingw*)
- ZMQ_CFLAGS="$ZMQ_CFLAGS -DZMQ_STATIC"
- ;;
- esac
- fi
+dnl curl check
+PKG_CHECK_MODULES([CURL], [libcurl],, [AC_MSG_ERROR([libcurl not found.])])
+AC_CHECK_HEADER([curl/curl.h],, [AC_MSG_ERROR([libcurl header not found.])])
+AC_CHECK_LIB([curl], [main],CURL_LIBS=-lcurl, AC_MSG_ERROR(libcurl missing))
- BITCOIN_QT_CHECK(AC_CHECK_LIB([protobuf] ,[main],[PROTOBUF_LIBS=-lprotobuf], BITCOIN_QT_FAIL(libprotobuf not found)))
- if test x$use_qr != xno; then
- BITCOIN_QT_CHECK([AC_CHECK_LIB([qrencode], [main],[QR_LIBS=-lqrencode], [have_qrencode=no])])
- BITCOIN_QT_CHECK([AC_CHECK_HEADER([qrencode.h],, have_qrencode=no)])
- fi
-fi
+save_CXXFLAGS="${CXXFLAGS}"
+CXXFLAGS="${CXXFLAGS} ${CRYPTO_CFLAGS} ${SSL_CFLAGS}"
+AC_CHECK_DECLS([EVP_MD_CTX_new],,,[AC_INCLUDES_DEFAULT
+#include
+])
+CXXFLAGS="${save_CXXFLAGS}"
AC_CHECK_LIB([crypto],[RAND_egd],[],[
- AC_ARG_WITH([libressl],
- [AS_HELP_STRING([--with-libressl],[Build with system LibreSSL (default is no; DANGEROUS; NOT SUPPORTED)])],
- [AC_MSG_WARN([Detected LibreSSL: This is NOT supported, and may break consensus compatibility!])],
- [AC_MSG_ERROR([Detected LibreSSL: This is NOT supported, and may break consensus compatibility!])]
+ AC_ARG_WITH([unsupported-ssl],
+ [AS_HELP_STRING([--with-unsupported-ssl],[Build with system SSL (default is no; DANGEROUS; NOT SUPPORTED; You should use OpenSSL 1.0)])],
+ [AC_MSG_WARN([Detected unsupported SSL version: This is NOT supported, and may break consensus compatibility!])],
+ [AC_MSG_ERROR([Detected unsupported SSL version: This is NOT supported, and may break consensus compatibility!])]
)
])
-dnl univalue check
-
-if test x$system_univalue != xno ; then
- found_univalue=no
- if test x$use_pkgconfig = xyes; then
- : #NOP
- m4_ifdef(
- [PKG_CHECK_MODULES],
- [
- PKG_CHECK_MODULES([UNIVALUE],[libunivalue],[found_univalue=yes],[true])
- ]
- )
- else
- AC_CHECK_HEADER([univalue.h],[
- AC_CHECK_LIB([univalue], [main],[
- UNIVALUE_LIBS=-lunivalue
- found_univalue=yes
- ],[true])
- ],[true])
- fi
+dnl ZMQ check
- if test x$found_univalue = xyes ; then
- system_univalue=yes
- elif test x$system_univalue = xyes ; then
- AC_MSG_ERROR([univalue not found])
- else
- system_univalue=no
- fi
+if test "x$use_zmq" = xyes; then
+ PKG_CHECK_MODULES([ZMQ], [libzmq >= 4],
+ AC_DEFINE([ENABLE_ZMQ], [1], [Define to 1 to enable ZMQ functions]),
+ [AC_DEFINE([ENABLE_ZMQ], [0], [Define to 1 to enable ZMQ functions])
+ AC_MSG_WARN([libzmq version 4.x or greater not found, disabling])
+ use_zmq=no])
+else
+ AC_DEFINE_UNQUOTED([ENABLE_ZMQ], [0], [Define to 1 to enable ZMQ functions])
fi
-if test x$system_univalue = xno ; then
- UNIVALUE_CFLAGS='-I$(srcdir)/univalue/include'
- UNIVALUE_LIBS='univalue/libunivalue.la'
+if test "x$use_zmq" = xyes; then
+ dnl Assume libzmq was built for static linking
+ case $host in
+ *mingw*)
+ ZMQ_CFLAGS="$ZMQ_CFLAGS -DZMQ_STATIC"
+ ;;
+ esac
fi
-AM_CONDITIONAL([EMBEDDED_UNIVALUE],[test x$system_univalue = xno])
-AC_SUBST(UNIVALUE_CFLAGS)
-AC_SUBST(UNIVALUE_LIBS)
-
-CFLAGS_TEMP="$CFLAGS"
-LIBS_TEMP="$LIBS"
-CFLAGS="$CFLAGS $SSL_CFLAGS $CRYPTO_CFLAGS"
-LIBS="$LIBS $SSL_LIBS $CRYPTO_LIBS"
-AC_CHECK_HEADER([openssl/ec.h],, AC_MSG_ERROR(OpenSSL ec header missing),)
-CFLAGS="$CFLAGS_TEMP"
-LIBS="$LIBS_TEMP"
-BITCOIN_QT_PATH_PROGS([PROTOC], [protoc],$protoc_bin_path)
-
-AC_MSG_CHECKING([whether to build dapscoind])
+AC_MSG_CHECKING([whether to build prcycoind])
AM_CONDITIONAL([BUILD_BITCOIND], [test x$build_bitcoind = xyes])
AC_MSG_RESULT($build_bitcoind)
-AC_MSG_CHECKING([whether to build utils (dapscoin-cli dapscoin-tx)])
+AC_MSG_CHECKING([whether to build utils (prcycoin-cli prcycoin-tx)])
AM_CONDITIONAL([BUILD_BITCOIN_UTILS], [test x$build_bitcoin_utils = xyes])
AC_MSG_RESULT($build_bitcoin_utils)
@@ -866,6 +1057,7 @@ AC_MSG_CHECKING([whether to build libraries])
AM_CONDITIONAL([BUILD_BITCOIN_LIBS], [test x$build_bitcoin_libs = xyes])
if test x$build_bitcoin_libs = xyes; then
AC_DEFINE(HAVE_CONSENSUS_LIB, 1, [Define this symbol if the consensus lib has been built])
+ AC_CONFIG_FILES([libbitcoinconsensus.pc:libbitcoinconsensus.pc.in])
fi
AC_MSG_RESULT($build_bitcoin_libs)
@@ -928,8 +1120,8 @@ else
fi
dnl these are only used when qt is enabled
+BUILD_TEST_QT=""
if test x$bitcoin_enable_qt != xno; then
- BUILD_QT=qt
dnl enable dbus support
AC_MSG_CHECKING([whether to build GUI with support for D-Bus])
if test x$bitcoin_enable_qt_dbus != xno; then
@@ -958,10 +1150,10 @@ if test x$bitcoin_enable_qt != xno; then
AC_MSG_WARN("xgettext is required to update qt translations")
fi
- AC_MSG_CHECKING([whether to build test_dapscoin-qt])
- if test x$use_tests$bitcoin_enable_qt_test = xyesyes; then
+ AC_MSG_CHECKING([whether to build test_prcycoin-qt])
+ if test x$use_gui_tests$bitcoin_enable_qt_test = xyesyes; then
AC_MSG_RESULT([yes])
- BUILD_TEST_QT="test"
+ BUILD_TEST_QT="yes"
else
AC_MSG_RESULT([no])
fi
@@ -969,39 +1161,45 @@ fi
AM_CONDITIONAL([ENABLE_ZMQ], [test "x$use_zmq" = "xyes"])
-AC_MSG_CHECKING([whether to build test_dapscoin])
+AC_MSG_CHECKING([whether to build test_prcycoin])
if test x$use_tests = xyes; then
AC_MSG_RESULT([yes])
- BUILD_TEST="test"
+ BUILD_TEST="yes"
else
AC_MSG_RESULT([no])
+ BUILD_TEST=""
fi
AC_MSG_CHECKING([whether to reduce exports])
-if test x$use_reduce_exports != xno; then
+if test x$use_reduce_exports = xyes; then
AC_MSG_RESULT([yes])
else
AC_MSG_RESULT([no])
fi
-if test x$build_bitcoin_utils$build_bitcoin_libs$build_bitcoind$bitcoin_enable_qt$use_tests = xnonononono; then
- AC_MSG_ERROR([No targets! Please specify at least one of: --with-utils --with-libs --with-daemon --with-gui or --enable-tests])
+if test x$build_bitcoin_utils$build_bitcoin_libs$build_bitcoind$bitcoin_enable_qt$use_bench$use_tests = xnononononono; then
+ AC_MSG_ERROR([No targets! Please specify at least one of: --with-utils --with-libs --with-daemon --with-gui --enable-bench or --enable-tests])
fi
AM_CONDITIONAL([TARGET_DARWIN], [test x$TARGET_OS = xdarwin])
AM_CONDITIONAL([BUILD_DARWIN], [test x$BUILD_OS = xdarwin])
AM_CONDITIONAL([TARGET_WINDOWS], [test x$TARGET_OS = xwindows])
AM_CONDITIONAL([ENABLE_WALLET],[test x$enable_wallet = xyes])
-AM_CONDITIONAL([ENABLE_TESTS],[test x$use_tests = xyes])
+AM_CONDITIONAL([ENABLE_TESTS],[test x$BUILD_TEST = xyes])
AM_CONDITIONAL([ENABLE_QT],[test x$bitcoin_enable_qt = xyes])
-AM_CONDITIONAL([HAVE_QT5], [test x$bitcoin_qt_got_major_vers = x5])
-AM_CONDITIONAL([ENABLE_QT_TESTS],[test x$use_tests$bitcoin_enable_qt_test = xyesyes])
+AM_CONDITIONAL([ENABLE_QT_TESTS],[test x$BUILD_TEST_QT = xyes])
+AM_CONDITIONAL([ENABLE_BENCH],[test x$use_bench = xyes])
AM_CONDITIONAL([USE_QRCODE], [test x$use_qr = xyes])
AM_CONDITIONAL([USE_LCOV],[test x$use_lcov = xyes])
-AM_CONDITIONAL([USE_COMPARISON_TOOL],[test x$use_comparison_tool != xno])
-AM_CONDITIONAL([USE_COMPARISON_TOOL_REORG_TESTS],[test x$use_comparison_tool_reorg_test != xno])
AM_CONDITIONAL([GLIBC_BACK_COMPAT],[test x$use_glibc_compat = xyes])
-AM_CONDITIONAL([USE_LIBSECP256K1],[test x$use_libsecp256k1 = xyes])
+AM_CONDITIONAL([HARDEN],[test x$use_hardening = xyes])
+AM_CONDITIONAL([ENABLE_SSE42],[test x$enable_sse42 = xyes])
+AM_CONDITIONAL([ENABLE_SSE41],[test x$enable_sse41 = xyes])
+AM_CONDITIONAL([ENABLE_AVX2],[test x$enable_avx2 = xyes])
+AM_CONDITIONAL([ENABLE_SHANI],[test x$enable_shani = xyes])
+AM_CONDITIONAL([ENABLE_ARM_CRC],[test x$enable_arm_crc = xyes])
+AM_CONDITIONAL([USE_ASM],[test x$use_asm = xyes])
+AM_CONDITIONAL([WORDS_BIGENDIAN],[test x$ac_cv_c_bigendian = xyes])
AC_DEFINE(CLIENT_VERSION_MAJOR, _CLIENT_VERSION_MAJOR, [Major version])
AC_DEFINE(CLIENT_VERSION_MINOR, _CLIENT_VERSION_MINOR, [Minor version])
@@ -1021,28 +1219,55 @@ AC_SUBST(BITCOIN_CLI_NAME)
AC_SUBST(BITCOIN_TX_NAME)
AC_SUBST(RELDFLAGS)
+AC_SUBST(DEBUG_CPPFLAGS)
+AC_SUBST(WARN_CXXFLAGS)
+AC_SUBST(NOWARN_CXXFLAGS)
+AC_SUBST(DEBUG_CXXFLAGS)
+AC_SUBST(COMPAT_LDFLAGS)
+AC_SUBST(ERROR_CXXFLAGS)
+AC_SUBST(GPROF_CXXFLAGS)
+AC_SUBST(GPROF_LDFLAGS)
+AC_SUBST(HARDENED_CXXFLAGS)
+AC_SUBST(HARDENED_CPPFLAGS)
+AC_SUBST(HARDENED_LDFLAGS)
+AC_SUBST(LTO_CXXFLAGS)
+AC_SUBST(LTO_LDFLAGS)
+AC_SUBST(PIC_FLAGS)
+AC_SUBST(PIE_FLAGS)
+AC_SUBST(SANITIZER_CXXFLAGS)
+AC_SUBST(SANITIZER_LDFLAGS)
+AC_SUBST(SSE42_CXXFLAGS)
+AC_SUBST(SSE41_CXXFLAGS)
+AC_SUBST(AVX2_CXXFLAGS)
+AC_SUBST(SHANI_CXXFLAGS)
+AC_SUBST(ARM_CRC_CXXFLAGS)
AC_SUBST(LIBTOOL_APP_LDFLAGS)
AC_SUBST(USE_UPNP)
AC_SUBST(USE_QRCODE)
AC_SUBST(BOOST_LIBS)
AC_SUBST(TESTDEFS)
-AC_SUBST(LEVELDB_TARGET_FLAGS)
-AC_SUBST(BUILD_TEST)
-AC_SUBST(BUILD_QT)
-AC_SUBST(BUILD_TEST_QT)
AC_SUBST(MINIUPNPC_CPPFLAGS)
AC_SUBST(MINIUPNPC_LIBS)
AC_SUBST(CRYPTO_LIBS)
AC_SUBST(SSL_LIBS)
-AC_SUBST(EVENT_LIBS)
-AC_SUBST(EVENT_PTHREADS_LIBS)
-AC_SUBST(ZMQ_LIBS)
-AC_SUBST(PROTOBUF_LIBS)
-AC_SUBST(QR_LIBS)
-AC_CONFIG_FILES([Makefile src/Makefile share/setup.nsi share/qt/Info.plist src/test/buildenv.py])
-AC_CONFIG_FILES([qa/pull-tester/run-bitcoind-for-test.sh],[chmod +x qa/pull-tester/run-bitcoind-for-test.sh])
-AC_CONFIG_FILES([qa/pull-tester/tests-config.sh],[chmod +x qa/pull-tester/tests-config.sh])
+AC_SUBST(CURL_CFLAGS)
+AC_SUBST(CURL_LIBS)
+AC_SUBST(USE_NUM_OPENSSL)
+AC_SUBST(HAVE_FDATASYNC)
+AC_SUBST(HAVE_FULLFSYNC)
+AC_SUBST(HAVE_O_CLOEXEC)
+AC_SUBST(HAVE_BUILTIN_PREFETCH)
+AC_SUBST(HAVE_MM_PREFETCH)
+AC_SUBST(HAVE_STRONG_GETAUXVAL)
+AC_SUBST(HAVE_WEAK_GETAUXVAL)
+AC_CONFIG_FILES([Makefile src/Makefile doc/man/Makefile share/setup.nsi share/qt/Info.plist test/config.ini])
AC_CONFIG_FILES([contrib/devtools/split-debug.sh],[chmod +x contrib/devtools/split-debug.sh])
+AM_COND_IF([HAVE_DOXYGEN], [AC_CONFIG_FILES([doc/Doxyfile])])
+AC_CONFIG_LINKS([contrib/filter-lcov.py:contrib/filter-lcov.py])
+AC_CONFIG_LINKS([contrib/macdeploy/background.tiff:contrib/macdeploy/background.tiff])
+AC_CONFIG_LINKS([test/functional/test_runner.py:test/functional/test_runner.py])
+AC_CONFIG_LINKS([test/util/bitcoin-util-test.py:test/util/bitcoin-util-test.py])
+AC_CONFIG_LINKS([test/util/rpcauth-test.py:test/util/rpcauth-test.py])
dnl boost's m4 checks do something really nasty: they export these vars. As a
dnl result, they leak into secp256k1's configure and crazy things happen.
@@ -1067,11 +1292,7 @@ PKGCONFIG_LIBDIR_TEMP="$PKG_CONFIG_LIBDIR"
unset PKG_CONFIG_LIBDIR
PKG_CONFIG_LIBDIR="$PKGCONFIG_LIBDIR_TEMP"
-if test x$system_univalue = xno; then
- AC_CONFIG_SUBDIRS([src/univalue])
-fi
-
-ac_configure_args="${ac_configure_args} --enable-module-bulletproof --enable-experimental --enable-module-generator --enable-module-commitment --disable-shared --with-pic"
+ac_configure_args="${ac_configure_args} --enable-module-bulletproof --enable-experimental --enable-module-generator --enable-module-commitment --disable-shared --with-pic --disable-jni"
AC_CONFIG_SUBDIRS([src/secp256k1])
AC_CONFIG_SUBDIRS([src/secp256k1-mw])
@@ -1089,27 +1310,43 @@ case $host in
;;
esac
+dnl Replace the BUILDDIR path with the correct Windows path if compiling on Native Windows
+case ${OS} in
+ *Windows*)
+ sed 's/BUILDDIR="\/\([[a-z]]\)/BUILDDIR="\1:/' test/config.ini > test/config-2.ini
+ mv test/config-2.ini test/config.ini
+ ;;
+esac
+
echo
echo "Options used to compile and link:"
echo " with wallet = $enable_wallet"
echo " with gui / qt = $bitcoin_enable_qt"
if test x$bitcoin_enable_qt != xno; then
- echo " qt version = $bitcoin_qt_got_major_vers"
echo " with qr = $use_qr"
fi
echo " with zmq = $use_zmq"
echo " with test = $use_tests"
-dnl echo " with bench = $use_bench"
+echo " with bench = $use_bench"
echo " with upnp = $use_upnp"
+echo " use asm = $use_asm"
+echo " sanitizers = $use_sanitizers"
echo " debug enabled = $enable_debug"
+echo " gprof enabled = $enable_gprof"
+echo " werror = $enable_werror"
+echo " LTO = $enable_lto"
echo
echo " target os = $TARGET_OS"
echo " build os = $BUILD_OS"
echo
echo " CC = $CC"
echo " CFLAGS = $CFLAGS"
-echo " CPPFLAGS = $CPPFLAGS"
+echo " CPPFLAGS = $DEBUG_CPPFLAGS $HARDENED_CPPFLAGS $CPPFLAGS"
echo " CXX = $CXX"
-echo " CXXFLAGS = $CXXFLAGS"
-echo " LDFLAGS = $LDFLAGS"
+echo " CXXFLAGS = $LTO_CXXFLAGS $DEBUG_CXXFLAGS $HARDENED_CXXFLAGS $WARN_CXXFLAGS $NOWARN_CXXFLAGS $ERROR_CXXFLAGS $GPROF_CXXFLAGS $CXXFLAGS"
+echo " LDFLAGS = $LTO_LDFLAGS $PTHREAD_CFLAGS $HARDENED_LDFLAGS $GPROF_LDFLAGS $LDFLAGS"
+echo " AR = $AR"
+echo " ARFLAGS = $ARFLAGS"
+echo " PIC_FLAGS = $PIC_FLAGS"
+echo " QT_PIE_FLAGS = $QT_PIE_FLAGS"
echo
diff --git a/contrib/bitrpc/bitrpc.py b/contrib/bitrpc/bitrpc.py
index 6facb48581..1a1cbe6c89 100644
--- a/contrib/bitrpc/bitrpc.py
+++ b/contrib/bitrpc/bitrpc.py
@@ -11,9 +11,9 @@
if rpcpass == "":
- access = ServiceProxy("http://127.0.0.1:53573")
+ access = ServiceProxy("http://127.0.0.1:59683")
else:
- access = ServiceProxy("http://"+rpcuser+":"+rpcpass+"@127.0.0.1:53573")
+ access = ServiceProxy("http://"+rpcuser+":"+rpcpass+"@127.0.0.1:59683")
cmd = sys.argv[1].lower()
if cmd == "backupwallet":
diff --git a/contrib/debian/README.md b/contrib/debian/README.md
index e7ab96061c..bba1be289a 100644
--- a/contrib/debian/README.md
+++ b/contrib/debian/README.md
@@ -1,21 +1,20 @@
Debian
====================
-This directory contains files used to package dapscoind/dapscoin-qt
-for Debian-based Linux systems. If you compile dapscoind/dapscoin-qt yourself, there are some useful files here.
+This directory contains files used to package prcycoind/prcycoin-qt
+for Debian-based Linux systems. If you compile prcycoind/prcycoin-qt yourself, there are some useful files here.
-## dapscoin: URI support ##
+## prcycoin: URI support ##
-dapscoin-qt.desktop (Gnome / Open Desktop)
+prcycoin-qt.desktop (Gnome / Open Desktop)
To install:
- sudo desktop-file-install dapscoin-qt.desktop
+ sudo desktop-file-install prcycoin-qt.desktop
sudo update-desktop-database
If you build yourself, you will either need to modify the paths in
-the .desktop file or copy or symlink your dapscoinqt binary to `/usr/bin`
-and the `../../share/pixmaps/dapscoin128.png` to `/usr/share/pixmaps`
-
-dapscoin-qt.protocol (KDE)
+the .desktop file or copy or symlink your prcycoin-qt binary to `/usr/bin`
+and the `../../share/pixmaps/prcycoin128.png` to `/usr/share/pixmaps`
+prcycoin-qt.protocol (KDE)
diff --git a/contrib/debian/changelog b/contrib/debian/changelog
index a9a00c27f5..1e12862c90 100644
--- a/contrib/debian/changelog
+++ b/contrib/debian/changelog
@@ -1,417 +1,5 @@
-bitcoin (0.9.3-precise1) precise; urgency=medium
+prcycoin (1.0.0.8-trusty1) trusty; urgency=medium
- * New upstream releases.
+ * PRCY Coin v1.0.0.8 (trusty).
- -- Matt Corallo (BlueMatt) Fri, 26 Sep 2014 12:01:00 -0700
-
-bitcoin (0.9.1-precise1) precise; urgency=medium
-
- * New upstream release.
- * Backport pull #4019
-
- -- Matt Corallo Sat, 19 Apr 2014 17:29:00 -0400
-
-bitcoin (0.9.0-precise1) precise; urgency=medium
-
- * New upstream release.
-
- -- Matt Corallo Thu, 20 Mar 2014 13:10:00 -0400
-
-bitcoin (0.8.6-precise1) precise; urgency=medium
-
- * New upstream release.
- * Make .desktop paths non-fixed (suggested by prusnak@github)
-
- -- Matt Corallo Fri, 13 Dec 2013 13:31:00 -0400
-
-bitcoin (0.8.5-precise1) precise; urgency=medium
-
- * New upstream release.
-
- -- Matt Corallo Sun, 15 Sep 2013 14:02:00 -0400
-
-bitcoin (0.8.4-precise1) precise; urgency=medium
-
- * New upstream release.
-
- -- Matt Corallo Wed, 4 Sep 2013 10:25:00 -0400
-
-bitcoin (0.8.3-natty1) natty; urgency=low
-
- * New upstream release.
-
- -- Matt Corallo Wed, 26 Jun 2013 00:18:00 +0100
-
-bitcoin (0.8.2-natty1) natty; urgency=low
-
- * New upstream release.
-
- -- Matt Corallo Wed, 29 Mar 2013 23:23:00 +0100
-
-bitcoin (0.8.1-natty3) natty; urgency=low
-
- * New pixmaps
-
- -- Jonas Schnelli Mon, 13 May 2013 16:14:00 +0100
-
-bitcoin (0.8.1-natty2) natty; urgency=low
-
- * Remove dumb broken launcher script
-
- -- Matt Corallo Sun, 24 Mar 2013 20:01:00 -0400
-
-bitcoin (0.8.1-natty1) natty; urgency=low
-
- * New upstream release.
-
- -- Matt Corallo Tue, 19 Mar 2013 13:03:00 -0400
-
-bitcoin (0.8.0-natty1) natty; urgency=low
-
- * New upstream release.
-
- -- Matt Corallo Sat, 23 Feb 2013 16:01:00 -0500
-
-bitcoin (0.7.2-natty1) natty; urgency=low
-
- * New upstream release.
-
- -- Matt Corallo Sat, 15 Dec 2012 10:59:00 -0400
-
-bitcoin (0.7.1-natty1) natty; urgency=low
-
- * New upstream release.
-
- -- Matt Corallo Wed, 24 Oct 2012 15:06:00 -0400
-
-bitcoin (0.7.0-natty1) natty; urgency=low
-
- * New upstream release.
-
- -- Matt Corallo Mon, 17 Sep 2012 13:45:00 +0200
-
-bitcoin (0.6.3-natty1) natty; urgency=low
-
- * New upstream release.
-
- -- Matt Corallo Mon, 25 Jun 2012 23:47:00 +0200
-
-bitcoin (0.6.2-natty1) natty; urgency=low
-
- * Update package description and launch scripts.
-
- -- Matt Corallo Sat, 2 Jun 2012 16:41:00 +0200
-
-bitcoin (0.6.2-natty0) natty; urgency=low
-
- * New upstream release.
-
- -- Matt Corallo Tue, 8 May 2012 16:27:00 -0500
-
-bitcoin (0.6.1-natty0) natty; urgency=low
-
- * New upstream release.
-
- -- Matt Corallo Sun, 6 May 2012 20:09:00 -0500
-
-bitcoin (0.6.0-natty0) natty; urgency=low
-
- * New upstream release.
- * Add GNOME/KDE support for bitcoin-qt's bitcoin: URI support.
- Thanks to luke-jr for the KDE .protocol file.
-
- -- Matt Corallo Sat, 31 Mar 2012 15:35:00 -0500
-
-bitcoin (0.5.3-natty1) natty; urgency=low
-
- * Mark for upload to PPA.
-
- -- Matt Corallo Wed, 14 Mar 2012 23:06:00 -0400
-
-bitcoin (0.5.3-natty0) natty; urgency=low
-
- * New upstream release.
-
- -- Luke Dashjr Tue, 10 Jan 2012 15:57:00 -0500
-
-bitcoin (0.5.2-natty1) natty; urgency=low
-
- * Remove mentions on anonymity in package descriptions and manpage.
- These should never have been there, bitcoin isnt anonymous without
- a ton of work that virtually no users will ever be willing and
- capable of doing
-
- -- Matt Corallo Sat, 7 Jan 2012 13:37:00 -0500
-
-bitcoin (0.5.2-natty0) natty; urgency=low
-
- * New upstream release.
-
- -- Luke Dashjr Fri, 16 Dec 2011 17:57:00 -0500
-
-bitcoin (0.5.1-natty0) natty; urgency=low
-
- * New upstream release.
-
- -- Matt Corallo Fri, 16 Dec 2011 13:27:00 -0500
-
-bitcoin (0.5.0-natty0) natty; urgency=low
-
- * New upstream release.
-
- -- Matt Corallo Mon, 21 Nov 2011 11:32:00 -0500
-
-bitcoin (0.5.0~rc7-natty0) natty; urgency=low
-
- * New upstream release candidate.
-
- -- Matt Corallo Sun, 20 Nov 2011 17:08:00 -0500
-
-bitcoin (0.5.0~rc3-natty0) natty; urgency=low
-
- * New upstream release candidate.
- * Don't set rpcpassword for bitcoin-qt.
-
- -- Matt Corallo Tue, 8 Nov 2011 11:56:00 -0400
-
-bitcoin (0.5.0~rc1-natty1) natty; urgency=low
-
- * Add test_bitcoin to build test
- * Fix clean
- * Remove uneccessary build-dependancies
-
- -- Matt Corallo Wed, 26 Oct 2011 14:37:18 -0400
-
-bitcoin (0.5.0~rc1-natty0) natty; urgency=low
-
- * Mark for natty
- * Fix broken build
- * Fix copyright listing
- * Remove bitcoin: URL handler until bitcoin actually has support for it (Oops)
-
- -- Matt Corallo Wed, 26 Oct 2011 14:37:18 -0400
-
-bitcoin (0.5.0~rc1-2) experimental; urgency=low
-
- * Add bitcoin-qt
-
- -- Matt Corallo Tue, 25 Oct 2011 15:24:18 -0400
-
-bitcoin (0.5.0~rc1-1) experimental; urgency=low
-
- * New upstream prerelease.
- * Add Github as alternate upstream source in watch file.
- * Stop build-depending on libcrypto++-dev, and drop patch 1000:
- Upstream no longer use crypto++.
- * Drop patch 1003: Upstream builds dynamic by default now.
- * Update copyright file: Drop notes on longer included sources.
-
- -- Jonas Smedegaard Fri, 14 Oct 2011 00:16:18 +0200
-
-bitcoin (0.4.0-1) unstable; urgency=low
-
- * New upstream release.
- * Stop repackaging source tarballs: No DFSG-violating stripping left.
- * Update copyright file:
- + Add Github URL to Source.
- * Drop dpkg-source local-options hint: Declared options are default
- since dpkg-source 1.16.1.
- + Add irc URL to Upstream-Contact.
- + Add comment on Bitcoin Developers to catch-all Files section.
- + Add Files sections for newly readded src/cryptopp/* (new custom
- BSD-like license), and newly added doc/build-osx.txt and
- src/makefile.osx (Expat).
- * Bump debhelper compatibility level to 7.
- * Suppress binary icns and gpg files.
- * Enable regression tests:
- + Build-depend on libboost-test-dev.
- + Extend patch 1003 to also dynamically link test binary.
- + Build and invoke test binary unless tests are disabled.
- * Tighten build-dependency on cdbs: Recent version needed to support
- debhelper 7.
- * Relax build-depend unversioned on debhelper: needed version
- satisfied even in oldstable.
- * Stop suppress optional build-dependencies: Satisfied in stable.
- Build-depend on devscripts (enabling copyright-check).
-
- -- Jonas Smedegaard Wed, 05 Oct 2011 01:48:53 +0200
-
-bitcoin (0.3.24~dfsg-1) unstable; urgency=low
-
- * New upstream release.
-
- [ Jonas Smedegaard ]
- * Improve various usage hints:
- + Explicitly mention in long description that bitcoind contains
- daemon and command-line interface.
- + Extend README.Debian with section on lack of GUI, and add primary
- headline.
- + Avoid installing upstream README: contains no parts relevant for
- Debian usage.
- Thanks to richard for suggestions (see bug#629443).
- * Favor final releases over prereleases in rules and watch file.
- Thanks to Jan Dittberner.
- * Track -src (not -linux) tarballs in rules and watch file.
- Thanks to Jan Dittberner.
- * Drop patches 1004 and 1005 (integrated upstream) and simplify
- CXXFLAGS in rules file.
- * Stop stripping no longer included source-less binaries from upstream
- tarballs.
-
- [ Jan Dittberner ]
- * refresh debian/patches/1000_use_system_crypto++.patch
-
- -- Jonas Smedegaard Tue, 19 Jul 2011 15:08:54 +0200
-
-bitcoin (0.3.21~dfsg-2) unstable; urgency=low
-
- * Enable UPNP support:
- + Drop patch 1006.
- + Build-depend on libminiupnpc-dev.
- Thanks to Matt Corallo.
-
- -- Jonas Smedegaard Sat, 28 May 2011 15:52:44 +0200
-
-bitcoin (0.3.21~dfsg-1) unstable; urgency=low
-
- * New upstream release.
- * Refresh patches.
- * Drop patch 1002: no longer needed, as upstream use pkgconfig now.
- * Add patch 1006 to really unset USE_UPNP as aparently intended.
- * Adjust cleanup rule to preserve .gitignore files.
- * Update copyright file:
- + Bump format to draft 174 of DEP-5.
- + Shorten comments.
- * Bump policy compliance to standards-version 3.9.2.
- * Shorten Vcs-Browser paragraph in control file.
- * Fix mention daemon (not CLI tools) in short description.
- * Stop conflicting with or replace bitcoin-cli: Only transitional, no
- longer needed.
- * Link against unversioned berkeleydb. Update NEWS and README.Debian
- accordingly (and improve wording while at it).
- Closes: Bug#621425. Thanks to Ondřej Surý.
- * This release also implicitly updates linkage against libcrypto++,
- which closes: bug#626953, #627024.
- * Disable linkage against not yet Debian packaged MiniUPnP.
- * Silence seemingly harmless noise about unused variables.
-
- -- Jonas Smedegaard Tue, 17 May 2011 15:31:24 +0200
-
-bitcoin (0.3.20.2~dfsg-2) unstable; urgency=medium
-
- * Fix have wrapper script execute real binary (not loop executing
- itself).
- Closes: bug#617290. Thanks to Philippe Gauthier and Etienne Laurin.
- * Set urgency=medium as the only (user-exposed) binary is useless
- without this fix and has been for some time.
-
- -- Jonas Smedegaard Wed, 16 Mar 2011 09:11:06 +0100
-
-bitcoin (0.3.20.2~dfsg-1) unstable; urgency=low
-
- * New upstream release.
- * Fix provide and replace former package name bitcoin-cli.
- Closes: bug#618439. Thanks to Shane Wegner.
-
- -- Jonas Smedegaard Tue, 15 Mar 2011 11:41:43 +0100
-
-bitcoin (0.3.20.01~dfsg-1) unstable; urgency=low
-
- * New upstream release.
-
- [ Micah Anderson ]
- * Add myself as uploader.
-
- [ Jonas Smedegaard ]
- * Add wrapper for bitcoind to ease initial startup.
- * Update patches:
- + Drop patch 2002: Applied upstream.
- + Add patch 1005 to add phtread linker option.
- Closes: bug#615619. Thanks to Shane Wegner.
- + Refresh patches.
- * Extend copyright years in rules file header.
- * Rewrite copyright file using draft svn166 of DEP5 format.
- * Rename binary package to bitcoind (from bincoin-cli).
- Closes: bug#614025. Thanks to Luke-Jr.
-
- -- Jonas Smedegaard Tue, 01 Mar 2011 15:55:04 +0100
-
-bitcoin (0.3.19~dfsg-6) unstable; urgency=low
-
- * Fix override agressive optimizations.
- * Fix tighten build-dependencies to really fit backporting to Lenny:
- + Add fallback build-dependency on libdb4.6++-dev.
- + Tighten unversioned Boost build-dependencies to recent versions,
- To force use of versioned Boost when backporting to Lenny.
- ...needs more love, though: actual build fails.
-
- -- Jonas Smedegaard Mon, 17 Jan 2011 19:48:35 +0100
-
-bitcoin (0.3.19~dfsg-5) unstable; urgency=low
-
- * Fix lower Boost fallback-build-dependencies to 1.35, really
- available in Lenny.
- * Correct comment in rules file regarding reason for versioned Boost
- fallback-build-dependency.
- * Add patch 2002 adding -mt decoration to Boost flags, to ease
- backporting to Lenny.
- * Respect DEB_BUILD_OPTIONS, and suppress arch-specific optimizations:
- + Add patch 1004 to allow overriding optimization flags.
- + Set optimization flags conditionally at build time.
- + Drop patch 2002 unconditionally suppressing arch-optimizations.
-
- -- Jonas Smedegaard Mon, 17 Jan 2011 16:04:48 +0100
-
-bitcoin (0.3.19~dfsg-4) unstable; urgency=low
-
- [ Micah Anderson ]
- * Provide example dapscoin.conf.
- * Add bitcoind(1) and dapscoin.conf(5) man pages.
-
- [ Jonas Smedegaard ]
- * Ease backporting:
- + Suppress optional build-dependencies.
- + Add fallback build-dependencies on the most recent Boost libs
- available in Lenny (where unversioned Boost libs are missing).
- * Add Micah as copyright holder for manpages, licensed as GPL-3+.
- * Bump copyright format to Subversion candidate draft 162 of DEP5.
-
- -- Jonas Smedegaard Mon, 17 Jan 2011 14:00:48 +0100
-
-bitcoin (0.3.19~dfsg-3) unstable; urgency=low
-
- * Document in copyright file files excluded from repackaged source.
- * Update copyright file:
- + Bump DEP5 format hint to Subversion draft rev. 153.
- + Consistently wrap at 72 chars.
- + Refer to GPL-2 file (not GPL symlink).
- * Link against Berkeley DB 4.8 (not 4.7):
- + Build-depend on libdb4.8++-dev (and on on libdb4.7++-dev).
- + Suggest libdb4.8-util and db4.7-util.
- + Add README.Debian note on (untested) upgrade routine.
- + Add NEWS entry on changed db version, referring to README.Debian.
-
- -- Jonas Smedegaard Fri, 07 Jan 2011 22:50:57 +0100
-
-bitcoin (0.3.19~dfsg-2) unstable; urgency=low
-
- * Adjust build options to use optimized miner only for amd64. Fixes
- FTBFS on i386 (and other archs, if compiling anywhere else at all).
- * Avoid static linking.
- * Adjust patch 2001 to avoid only arch-specific optimizations (keep
- -O3).
- * Extend long description to mention disk consumption and initial use
- of IRC.
- All of above changes thanks to Helmuth Grohne.
- * Add lintian override regarding OpenSSL and GPL: Linked code is Expat
- - only Debian packaging is GPL-2+.
-
- -- Jonas Smedegaard Wed, 29 Dec 2010 00:27:54 +0100
-
-bitcoin (0.3.19~dfsg-1) unstable; urgency=low
-
- [ Jonas Smedegaard ]
- * Initial release.
- Closes: bug#578157.
-
- -- Jonas Smedegaard Tue, 28 Dec 2010 15:49:22 +0100
+ -- lyricidal Mon, 13 Sept 2021 12:01:00 -0700
diff --git a/contrib/debian/control b/contrib/debian/control
index 5e444a92e9..9714245c5d 100644
--- a/contrib/debian/control
+++ b/contrib/debian/control
@@ -1,36 +1,41 @@
-Source: dapscoin
+Source: prcycoin
Section: utils
Priority: optional
-Maintainer: Jonas Smedegaard ***TODO***
-Uploaders: Micah Anderson ***TODO***
+Maintainer: lyricidal
+Uploaders: lyricidal
Build-Depends: debhelper,
devscripts,
automake,
libtool,
bash-completion,
- libboost-system-dev (>> 1.35) | libboost-system1.35-dev,
libdb4.8++-dev,
- libssl-dev,
+ libssl1.0-dev | libssl-dev,
pkg-config,
- libminiupnpc8-dev,
- libboost-filesystem-dev (>> 1.35) | libboost-filesystem1.35-dev,
- libboost-program-options-dev (>> 1.35) | libboost-program-options1.35-dev,
- libboost-thread-dev (>> 1.35) | libboost-thread1.35-dev,
- libboost-test-dev (>> 1.35) | libboost-test1.35-dev,
- qt4-qmake,
- libqt4-dev,
+ libevent-dev,
+ libboost-system1.48-dev | libboost-system-dev (>> 1.47),
+ libboost-filesystem1.48-dev | libboost-filesystem-dev (>> 1.47),
+ libboost-program-options1.48-dev | libboost-program-options-dev (>> 1.47),
+ libboost-thread1.48-dev | libboost-thread-dev (>> 1.47),
+ libboost-test1.48-dev | libboost-test-dev (>> 1.47),
+ libboost-chrono1.48-dev | libboost-chrono-dev (>> 1.47),
+ libminiupnpc8-dev | libminiupnpc-dev,
+ xvfb,
+ qtbase5-dev, qttools5-dev-tools, qttools5-dev,
libqrencode-dev,
- libprotobuf-dev, protobuf-compiler
+ libprotobuf-dev, protobuf-compiler,
+ python,
+ libzmq3-dev,
+ dh-systemd
Standards-Version: 3.9.2
-Homepage: http://www.dapscoin.org
-Vcs-Git: git://github.com/DAPScoin-Project/DAPScoin.git
-Vcs-Browser: http://github.com/DAPScoin-Project/DAPScoin
+Homepage: http://www.prcycoin.com
+Vcs-Git: git://github.com/PRCYCoin/PRCYCoin.git
+Vcs-Browser: http://github.com/PRCYCoin/PRCYCoin
-Package: dapscoind
+Package: prcycoind
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: peer-to-peer network based digital currency - daemon
- Dapscoin is a free open source peer-to-peer electronic cash system that
+ PRCY Coin is a free open source peer-to-peer electronic cash system that
is completely decentralized, without the need for a central server or
trusted parties. Users hold the crypto keys to their own money and
transact directly with each other, with the help of a P2P network to
@@ -39,14 +44,14 @@ Description: peer-to-peer network based digital currency - daemon
Full transaction history is stored locally at each client. This
requires 1+ GB of space, slowly growing.
.
- This package provides the daemon, dapscoind, and the CLI tool
- dapscoin-cli to interact with the daemon.
+ This package provides the daemon, prcycoind, and the CLI tool
+ prcycoin-cli to interact with the daemon.
-Package: dapscoin-qt
+Package: prcycoin-qt
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: peer-to-peer network based digital currency - Qt GUI
- Dapscoin is a free open source peer-to-peer electronic cash system that
+ PRCY Coin is a free open source peer-to-peer electronic cash system that
is completely decentralized, without the need for a central server or
trusted parties. Users hold the crypto keys to their own money and
transact directly with each other, with the help of a P2P network to
@@ -55,4 +60,4 @@ Description: peer-to-peer network based digital currency - Qt GUI
Full transaction history is stored locally at each client. This
requires 1+ GB of space, slowly growing.
.
- This package provides Dapscoin-Qt, a GUI for Dapscoin based on Qt.
+ This package provides PRCYCoin-Qt, a GUI for PRCY Coin based on Qt.
diff --git a/contrib/debian/dapscoin-qt.desktop b/contrib/debian/dapscoin-qt.desktop
deleted file mode 100644
index 3e9ac22d91..0000000000
--- a/contrib/debian/dapscoin-qt.desktop
+++ /dev/null
@@ -1,12 +0,0 @@
-[Desktop Entry]
-Encoding=UTF-8
-Name=Dapscoin
-Comment=Dapscoin P2P Cryptocurrency
-Comment[fr]=Dapscoin, monnaie virtuelle cryptographique pair à pair
-Comment[tr]=Dapscoin, eşten eşe kriptografik sanal para birimi
-Exec=dapscoin-qt %u
-Terminal=false
-Type=Application
-Icon=dapscoin128
-MimeType=x-scheme-handler/dapscoin;
-Categories=Office;Finance;
diff --git a/contrib/debian/dapscoin-qt.install b/contrib/debian/dapscoin-qt.install
deleted file mode 100644
index 9dba1727a4..0000000000
--- a/contrib/debian/dapscoin-qt.install
+++ /dev/null
@@ -1,6 +0,0 @@
-usr/local/bin/dapscoin-qt usr/bin
-share/pixmaps/bitcoin32.xpm usr/share/pixmaps
-share/pixmaps/bitcoin16.xpm usr/share/pixmaps
-share/pixmaps/bitcoin128.png usr/share/pixmaps
-debian/dapscoin-qt.desktop usr/share/applications
-debian/dapscoin-qt.protocol usr/share/kde4/services/
diff --git a/contrib/debian/dapscoind.bash-completion b/contrib/debian/dapscoind.bash-completion
deleted file mode 100644
index 035fa21083..0000000000
--- a/contrib/debian/dapscoind.bash-completion
+++ /dev/null
@@ -1 +0,0 @@
-contrib/dapscoind.bash-completion dapscoind
diff --git a/contrib/debian/dapscoind.examples b/contrib/debian/dapscoind.examples
deleted file mode 100644
index dde3213db0..0000000000
--- a/contrib/debian/dapscoind.examples
+++ /dev/null
@@ -1 +0,0 @@
-debian/examples/dapscoin.conf
diff --git a/contrib/debian/dapscoind.install b/contrib/debian/dapscoind.install
deleted file mode 100644
index 719be311b9..0000000000
--- a/contrib/debian/dapscoind.install
+++ /dev/null
@@ -1,2 +0,0 @@
-usr/local/bin/dapscoind usr/bin
-usr/local/bin/dapscoin-cli usr/bin
diff --git a/contrib/debian/dapscoind.manpages b/contrib/debian/dapscoind.manpages
deleted file mode 100644
index fdd50a6e5c..0000000000
--- a/contrib/debian/dapscoind.manpages
+++ /dev/null
@@ -1,2 +0,0 @@
-debian/manpages/dapscoind.1
-debian/manpages/dapscoin.conf.5
diff --git a/contrib/debian/examples/dapscoin.conf b/contrib/debian/examples/prcycoin.conf
similarity index 82%
rename from contrib/debian/examples/dapscoin.conf
rename to contrib/debian/examples/prcycoin.conf
index 4a26ffb9b7..22bbfa7bc6 100644
--- a/contrib/debian/examples/dapscoin.conf
+++ b/contrib/debian/examples/prcycoin.conf
@@ -1,10 +1,10 @@
##
-## dapscoin.conf configuration file. Lines beginning with # are comments.
+## prcycoin.conf configuration file. Lines beginning with # are comments.
##
# Network-related settings:
-# Run on the test network instead of the real dapscoin network.
+# Run on the test network instead of the real prcycoin network.
#testnet=0
# Run a regression test network
@@ -38,11 +38,11 @@
# Use as many addnode= settings as you like to connect to specific peers
#addnode=69.164.218.197
-#addnode=10.0.0.2:53572
+#addnode=10.0.0.2:59682
# Alternatively use as many connect= settings as you like to connect ONLY to specific peers
#connect=69.164.218.197
-#connect=10.0.0.1:53572
+#connect=10.0.0.1:59682
# Listening mode, enabled by default except when 'connect' is being used
#listen=1
@@ -51,17 +51,17 @@
#maxconnections=
#
-# JSON-RPC options (for controlling a running Dapscoin/dapscoind process)
+# JSON-RPC options (for controlling a running Prcycoin/prcycoind process)
#
-# server=1 tells Dapscoin-QT and dapscoind to accept JSON-RPC commands
+# server=1 tells Prcycoin-QT and prcycoind to accept JSON-RPC commands
#server=0
# You must set rpcuser and rpcpassword to secure the JSON-RPC api
#rpcuser=Ulysseys
#rpcpassword=YourSuperGreatPasswordNumber_DO_NOT_USE_THIS_OR_YOU_WILL_GET_ROBBED_385593
-# How many seconds dapscoin will wait for a complete RPC HTTP request.
+# How many seconds prcycoin will wait for a complete RPC HTTP request.
# after the HTTP connection is established.
#rpcclienttimeout=30
@@ -72,16 +72,16 @@
# NOTE: opening up the RPC port to hosts outside your local trusted network is NOT RECOMMENDED,
# because the rpcpassword is transmitted over the network unencrypted.
-# server=1 tells Dapscoin-QT to accept JSON-RPC commands.
-# it is also read by dapscoind to determine if RPC should be enabled
+# server=1 tells Prcycoin-QT to accept JSON-RPC commands.
+# it is also read by prcycoind to determine if RPC should be enabled
#rpcallowip=10.1.1.34/255.255.255.0
#rpcallowip=1.2.3.4/24
#rpcallowip=2001:db8:85a3:0:0:8a2e:370:7334/96
# Listen for RPC connections on this TCP port:
-#rpcport=53573
+#rpcport=59683
-# You can use Dapscoin or dapscoind to send commands to Dapscoin/dapscoind
+# You can use Prcycoin or prcycoind to send commands to Prcycoin/prcycoind
# running on another host using this option:
#rpcconnect=127.0.0.1
@@ -91,14 +91,14 @@
# both prior transactions and several dozen future transactions.
#keypool=100
-# Pay an optional transaction fee every time you send DAPSs. Transactions with fees
+# Pay an optional transaction fee every time you send PRCYs. Transactions with fees
# are more likely than free transactions to be included in generated blocks, so may
# be validated sooner.
#paytxfee=0.00
# User interface options
-# Start Dapscoin minimized
+# Start Prcycoin minimized
#min=1
# Minimize to the system tray
diff --git a/contrib/debian/manpages/dapscoin-qt.1 b/contrib/debian/manpages/dapscoin-qt.1
deleted file mode 100644
index 9d40e331f4..0000000000
--- a/contrib/debian/manpages/dapscoin-qt.1
+++ /dev/null
@@ -1,190 +0,0 @@
-.TH DAPS-QT "1" "February 2017" "dapscoin-qt 1"
-.SH NAME
-dapscoin-qt \- peer-to-peer network based digital currency
-.SH DESCRIPTION
-.SS "Usage:"
-.IP
-dapscoin\-qt [command\-line options]
-.SH OPTIONS
-.TP
-\-?
-This help message
-.TP
-\fB\-conf=\fR
-Specify configuration file (default: dapscoin.conf)
-.TP
-\fB\-pid=\fR
-Specify pid file (default: dapscoind.pid)
-.TP
-\fB\-gen\fR
-Generate coins
-.TP
-\fB\-gen\fR=\fI0\fR
-Don't generate coins
-.TP
-\fB\-datadir=\fR
-Specify data directory
-.TP
-\fB\-dbcache=\fR
-Set database cache size in megabytes (default: 25)
-.TP
-\fB\-timeout=\fR
-Specify connection timeout in milliseconds (default: 5000)
-.TP
-\fB\-proxy=\fR
-Connect through SOCKS5 proxy
-.TP
-\fB\-tor=\fR
-Use proxy to reach tor hidden services (default: same as \fB\-proxy\fR)
-.TP
-\fB\-dns\fR
-Allow DNS lookups for \fB\-addnode\fR, \fB\-seednode\fR and \fB\-connect\fR
-.TP
-\fB\-port=\fR
-Listen for connections on (default: 53572 or testnet: 53574)
-.TP
-\fB\-maxconnections=\fR
-Maintain at most connections to peers (default: 125)
-.TP
-\fB\-addnode=\fR
-Add a node to connect to and attempt to keep the connection open
-.TP
-\fB\-connect=\fR
-Connect only to the specified node(s)
-.TP
-\fB\-seednode=\fR
-Connect to a node to retrieve peer addresses, and disconnect
-.TP
-\fB\-externalip=\fR
-Specify your own public address
-.TP
-\fB\-onlynet=\fR
-Only connect to nodes in network (IPv4, IPv6 or Tor)
-.TP
-\fB\-discover\fR
-Discover own IP address (default: 1 when listening and no \fB\-externalip\fR)
-.TP
-\fB\-checkpoints\fR
-Only accept block chain matching built\-in checkpoints (default: 1)
-.TP
-\fB\-listen\fR
-Accept connections from outside (default: 1 if no \fB\-proxy\fR or \fB\-connect\fR)
-.TP
-\fB\-bind=\fR
-Bind to given address and always listen on it. Use [host]:port notation for IPv6
-.TP
-\fB\-dnsseed\fR
-Find peers using DNS lookup (default: 1 unless \fB\-connect\fR)
-.TP
-\fB\-banscore=\fR
-Threshold for disconnecting misbehaving peers (default: 100)
-.TP
-\fB\-bantime=\fR
-Number of seconds to keep misbehaving peers from reconnecting (default: 86400)
-.TP
-\fB\-maxreceivebuffer=\fR
-Maximum per\-connection receive buffer, *1000 bytes (default: 5000)
-.TP
-\fB\-maxsendbuffer=\fR
-Maximum per\-connection send buffer, *1000 bytes (default: 1000)
-.TP
-\fB\-upnp\fR
-Use UPnP to map the listening port (default: 1 when listening)
-.TP
-\fB\-paytxfee=\fR
-Fee per KB to add to transactions you send
-.TP
-\fB\-server\fR
-Accept command line and JSON\-RPC commands
-.TP
-\fB\-testnet\fR
-Use the test network
-.TP
-\fB\-debug\fR
-Output extra debugging information. Implies all other \fB\-debug\fR* options
-.TP
-\fB\-debugnet\fR
-Output extra network debugging information
-.TP
-\fB\-logtimestamps\fR
-Prepend debug output with timestamp
-.TP
-\fB\-shrinkdebugfile\fR
-Shrink debug.log file on client startup (default: 1 when no \fB\-debug\fR)
-.TP
-\fB\-printtoconsole\fR
-Send trace/debug info to console instead of debug.log file
-.TP
-\fB\-rpcuser=\fR
-Username for JSON\-RPC connections
-.TP
-\fB\-rpcpassword=\fR
-Password for JSON\-RPC connections
-.TP
-\fB\-rpcport=\fR
-Listen for JSON\-RPC connections on (default: 53573 or testnet: 53575)
-.TP
-\fB\-rpcallowip=\fR
-Allow JSON\-RPC connections from specified IP address
-.TP
-\fB\-rpcthreads=\fR
-Set the number of threads to service RPC calls (default: 4)
-.TP
-\fB\-blocknotify=\fR
-Execute command when the best block changes (%s in cmd is replaced by block hash)
-.TP
-\fB\-walletnotify=\fR
-Execute command when a wallet transaction changes (%s in cmd is replaced by TxID)
-.TP
-\fB\-alertnotify=\fR
-Execute command when a relevant alert is received (%s in cmd is replaced by message)
-.TP
-\fB\-upgradewallet\fR
-Upgrade wallet to latest format
-.TP
-\fB\-keypool=\fR
-Set key pool size to (default: 100)
-.TP
-\fB\-rescan\fR
-Rescan the block chain for missing wallet transactions
-.TP
-\fB\-salvagewallet\fR
-Attempt to recover private keys from a corrupt wallet.dat
-.TP
-\fB\-checkblocks=\fR
-How many blocks to check at startup (default: 288, 0 = all)
-.TP
-\fB\-checklevel=\fR
-How thorough the block verification is (0\-4, default: 3)
-.TP
-\fB\-txindex\fR
-Maintain a full transaction index (default: 0)
-.TP
-\fB\-loadblock=\fR
-Imports blocks from external blk000??.dat file
-.TP
-\fB\-reindex\fR
-Rebuild block chain index from current blk000??.dat files
-.TP
-\fB\-par=\fR
-Set the number of script verification threads (1\-16, 0=auto, default: 0)
-.SS "Block creation options:"
-.TP
-\fB\-blockminsize=\fR
-Set minimum block size in bytes (default: 0)
-.TP
-\fB\-blockmaxsize=\fR
-Set maximum block size in bytes (default: 250000)
-.HP
-\fB\-blockprioritysize=\fR Set maximum size of high\-priority/low\-fee transactions in bytes (default: 27000)
-.PP
-.SS "UI options:"
-.TP
-\fB\-lang=\fR
-Set language, for example "de_DE" (default: system locale)
-.TP
-\fB\-min\fR
-Start minimized
-.TP
-\fB\-splash\fR
-Show splash screen on startup (default: 1)
diff --git a/contrib/debian/manpages/dapscoin.conf.5 b/contrib/debian/manpages/dapscoin.conf.5
deleted file mode 100644
index d7d297656b..0000000000
--- a/contrib/debian/manpages/dapscoin.conf.5
+++ /dev/null
@@ -1,79 +0,0 @@
-.TH DAPS.CONF "5" "January 2011" "dapscoin.conf 3.19"
-.SH NAME
-dapscoin.conf \- dapscoin configuration file
-.SH SYNOPSIS
-All command-line options (except for '\-conf') may be specified in a configuration file, and all configuration file options may also be specified on the command line. Command-line options override values set in the configuration file.
-.TP
-The configuration file is a list of 'setting=value' pairs, one per line, with optional comments starting with the '#' character.
-.TP
-The configuration file is not automatically created; you can create it using your favorite plain-text editor. By default, dapscoind(1) will look for a file named dapscoin.conf(5) in the dapscoin data directory, but both the data directory and the configuration file path may be changed using the '\-datadir' and '\-conf' command-line arguments.
-.SH LOCATION
-dapscoin.conf should be located in $HOME/.dapscoin
-.SH NETWORK-RELATED SETTINGS
-.TP
-.TP
-\fBtestnet=\fR[\fI'1'\fR|\fI'0'\fR]
-Enable or disable run on the test network instead of the real *dapscoin* network.
-.TP
-\fBproxy=\fR\fI'127.0.0.1:9050'\fR
-Connect via a socks4 proxy.
-.TP
-\fBaddnode=\fR\fI'10.0.0.2:53572'\fR
-Use as many *addnode=* settings as you like to connect to specific peers.
-.TP
-\fBconnect=\fR\fI'10.0.0.1:53572'\fR
-Use as many *connect=* settings as you like to connect ONLY to specific peers.
-.TP
-\fRmaxconnections=\fR\fI'value'\fR
-Maximum number of inbound+outbound connections.
-.SH JSON-RPC OPTIONS
-.TP
-\fBserver=\fR[\fI'1'\fR|\fI'0'\fR]
-Tells *dapscoin* to accept or not accept JSON-RPC commands.
-.TP
-\fBrpcuser=\fR\fI'username'\fR
-You must set *rpcuser* to secure the JSON-RPC api.
-.TP
-\fBrpcpassword=\fR\fI'password'\fR
-You must set *rpcpassword* to secure the JSON-RPC api.
-.TP
-\fBrpcallowip=\fR\fI'192.168.1.*'\fR
-By default, only RPC connections from localhost are allowed. Specify as many *rpcallowip=* settings as you like to allow connections from other hosts (and you may use * as a wildcard character).
-.TP
-\fBrpcport=\fR\fI'53573'\fR
-Listen for RPC connections on this TCP port.
-.TP
-\fBrpcconnect=\fR\fI'127.0.0.1'\fR
-You can use *dapscoin* or *dapscoind(1)* to send commands to *dapscoin*/*dapscoind(1)* running on another host using this option.
-.TP
-.SH MISCELLANEOUS OPTIONS
-.TP
-\fBgen=\fR[\fI'0'\fR|\fI'1'\fR]
-Enable or disable attempt to generate DAPSs.
-.TP
-\fB4way=\fR[\fI'0'\fR|\fI'1'\fR]
-Enable or disable use SSE instructions to try to generate DAPSs faster.
-.TP
-\fBkeypool=\fR\fI'100'\fR
-Pre-generate this many public/private key pairs, so wallet backups will be valid for both prior transactions and several dozen future transactions.
-.TP
-\fBpaytxfee=\fR\fI'0.00'\fR
-Pay an optional transaction fee every time you send DAPSs. Transactions with fees are more likely than free transactions to be included in generated blocks, so may be validated sooner.
-.TP
-\fBallowreceivebyip=\fR\fI'1'\fR
-Allow direct connections for the 'pay via IP address' feature.
-.TP
-.SH USER INTERFACE OPTIONS
-.TP
-\fBmin=\fR[\fI'0'\fR|\fI'1'\fR]
-Enable or disable start dapscoind minimized.
-.TP
-\fBminimizetotray=\fR[\fI'0'\fR|\fI'1'\fR]
-Enable or disable minimize to the system tray.
-.SH "SEE ALSO"
-dapscoind(1)
-.SH AUTHOR
-This manual page was written by Micah Anderson for the Debian system (but may be used by others). Permission is granted to copy, distribute and/or modify this document under the terms of the GNU General Public License, Version 3 or any later version published by the Free Software Foundation.
-
-On Debian systems, the complete text of the GNU General Public License can be found in /usr/share/common-licenses/GPL.
-
diff --git a/contrib/debian/manpages/dapscoind.1 b/contrib/debian/manpages/dapscoind.1
deleted file mode 100644
index d09c7ff5c2..0000000000
--- a/contrib/debian/manpages/dapscoind.1
+++ /dev/null
@@ -1,195 +0,0 @@
-.TH DAPSD "1" "February 2017" "dapscoind 2.1.4.1"
-.SH NAME
-Dapscoin \- peer-to-peer network based digital currency
-.SH SYNOPSIS
-dapscoind [options] [params]
-.TP
-dapscoind [options] help \- Get help for a command
-.SH DESCRIPTION
-This manual page documents the dapscoind program. Dapscoin is a peer-to-peer digital currency. Peer-to-peer (P2P) means that there is no central authority to issue new money or keep track of transactions. Instead, these tasks are managed collectively by the nodes of the network. Advantages:
-
-Dapscoin can be sent easily through the Internet, without having to trust middlemen. Transactions are designed to be irreversible. Be safe from instability caused by fractional reserve banking and central banks. The limited inflation of the Dapscoin system’s money supply is distributed evenly (by CPU power) throughout the network, not monopolized by banks.
-
-.SH OPTIONS
-.TP
-\fB\-conf=\fR
-Specify configuration file (default: dapscoin.conf)
-.TP
-\fB\-gen\fR
-Generate coins
-.TP
-\fB\-gen\fR=\fI0\fR
-Don't generate coins
-.TP
-\fB\-min\fR
-Start minimized
-.TP
-\fB\-datadir=\fR
-Specify data directory
-.TP
-\fB\-proxy=\fR
-Connect through SOCKS5 proxy
-.TP
-\fB\-addnode=\fR
-Add a node to connect to
-.TP
-\fB\-connect=\fR
-Connect only to the specified node
-.TP
-\fB\-paytxfee=\fR
-Fee per KB to add to transactions you send
-.TP
-\fB\-server\fR
-Accept command line and JSON\-RPC commands
-.TP
-\fB\-daemon\fR
-Run in the background as a daemon and accept commands
-.TP
-\fB\-testnet\fR
-Use the test network
-.TP
-\fB\-rpcuser=\fR
-Username for JSON\-RPC connections
-.TP
-\fB\-rpcpassword=\fR
-Password for JSON\-RPC connections
-.TP
-\fB\-rpcport=\fR
-Listen for JSON\-RPC connections on
-.TP
-\fB\-rpcallowip=\fR
-Allow JSON\-RPC connections from specified IP address
-.TP
-\fB\-rpcconnect=\fR
-Send commands to node running on
-.TP
-\-?
-This help message
-.SH COMMANDS
-.TP
-\fBbackupwallet 'destination'\fR
-Safely copies *wallet.dat* to 'destination', which can be a directory or a path with filename.
-.TP
-\fBgetaccount 'dapscoinaddress'\fR
-Returns the account associated with the given address.
-.TP
-\fBsetaccount 'dapscoinaddress' ['account']\fR
-Sets the ['account'] associated with the given address. ['account'] may be omitted to remove an address from ['account'].
-.TP
-\fBgetaccountaddress 'account'\fR
-Returns a new dapscoin address for 'account'.
-.TP
-\fBgetaddressesbyaccount 'account'\fR
-Returns the list of addresses associated with the given 'account'.
-.TP
-\fBgetbalance 'account'\fR
-Returns the server's available balance, or the balance for 'account'.
-.TP
-\fBgetblockcount\fR
-Returns the number of blocks in the longest block chain.
-.TP
-\fBgetblocknumber\fR
-Returns the block number of the latest block in the longest block chain.
-.TP
-\fBgetconnectioncount\fR
-Returns the number of connections to other nodes.
-.TP
-\fBgetdifficulty\fR
-Returns the proof-of-work difficulty as a multiple of the minimum difficulty.
-.TP
-\fBgetgenerate\fR
-Returns boolean true if server is trying to generate DAPS, false otherwise.
-.TP
-\fBsetgenerate 'generate' ['genproclimit']\fR
-Generation is limited to ['genproclimit'] processors, \-1 is unlimited.
-.TP
-\fBgethashespersec\fR
-Returns a recent hashes per second performance measurement while generating.
-.TP
-\fBgetinfo\fR
-Returns an object containing server information.
-.TP
-\fBgetnewaddress 'account'\fR
-Returns a new dapscoin address for receiving payments. If 'account' is specified (recommended), it is added to the address book so payments received with the address will be credited to 'account'.
-.TP
-\fBgetreceivedbyaccount 'account' ['minconf=1']\fR
-Returns the total amount received by addresses associated with 'account' in transactions with at least ['minconf'] confirmations.
-.TP
-\fBgetreceivedbyaddress 'dapscoinaddress' ['minconf=1']\fR
-Returns the total amount received by 'dapscoinaddress' in transactions with at least ['minconf'] confirmations.
-.TP
-\fBgettransaction 'txid'\fR
-Returns information about a specific transaction, given hexadecimal transaction ID.
-.TP
-\fBgetwork 'data'\fR
-If 'data' is specified, tries to solve the block and returns true if it was successful. If 'data' is not specified, returns formatted hash 'data' to work on:
-
- "midstate" : precomputed hash state after hashing the first half of the data.
- "data" : block data.
- "hash1" : formatted hash buffer for second hash.
- "target" : little endian hash target.
-.TP
-\fBhelp 'command'\fR
-List commands, or get help for a command.
-.TP
-\fBlistaccounts ['minconf=1']\fR
-List accounts and their current balances.
- *note: requires dapscoin 1.0.2.1 or later.
-.TP
-\fBlistreceivedbyaccount ['minconf=1'] ['includeempty=false']\fR
-['minconf'] is the minimum number of confirmations before payments are included. ['includeempty'] whether to include addresses that haven't received any payments. Returns an array of objects containing:
-
- "account" : the account of the receiving address.
- "amount" : total amount received by the address.
- "confirmations" : number of confirmations of the most recent transaction included.
-.TP
-\fBlistreceivedbyaddress ['minconf=1'] ['includeempty=false']\fR
-['minconf'] is the minimum number of confirmations before payments are included. ['includeempty'] whether to include addresses that haven't received any payments. Returns an array of objects containing:
-
- "address" : receiving address.
- "account" : the account of the receiving address.
- "amount" : total amount received by the address.
- "confirmations" : number of confirmations of the most recent transaction included.
-.TP
-\fBlisttransactions 'account' ['count=10']\fR
-Returns a list of the last ['count'] transactions for 'account' \- for all accounts if 'account' is not specified or is "*". Each entry in the list may contain:
-
- "category" : will be generate, send, receive, or move.
- "amount" : amount of transaction.
- "fee" : Fee (if any) paid (only for send transactions).
- "confirmations" : number of confirmations (only for generate/send/receive).
- "txid" : transaction ID (only for generate/send/receive).
- "otheraccount" : account funds were moved to or from (only for move).
- "message" : message associated with transaction (only for send).
- "to" : message-to associated with transaction (only for send).
-
- *note: requires dapscoin 1.0.2.1 or later.
-.TP
-\fBmove <'fromaccount'> <'toaccount'> <'amount'> ['minconf=1'] ['comment']\fR
-Moves funds between accounts.
-.TP
-\fBsendfrom* <'account'> <'dapscoinaddress'> <'amount'> ['minconf=1'] ['comment'] ['comment-to']\fR
-Sends amount from account's balance to 'dapscoinaddress'. This method will fail if there is less than amount DAPS with ['minconf'] confirmations in the account's balance (unless account is the empty-string-named default account; it behaves like the *sendtoaddress* method). Returns transaction ID on success.
-.TP
-\fBsendtoaddress 'dapscoinaddress' 'amount' ['comment'] ['comment-to']\fR
-Sends amount from the server's available balance to 'dapscoinaddress'. amount is a real and is rounded to the nearest 0.01. Returns transaction id on success.
-.TP
-\fBstop\fR
-Stops the dapscoin server.
-.TP
-\fBvalidateaddress 'dapscoinaddress'\fR
-Checks that 'dapscoinaddress' looks like a proper Dapscoin address. Returns an object containing:
-
- "isvalid" : true or false.
- "ismine" : true if the address is in the server's wallet.
- "address" : dapscoinaddress.
-
- *note: ismine and address are only returned if the address is valid.
-
-.SH "SEE ALSO"
-dapscoin.conf(5)
-.SH AUTHOR
-This manual page was written by Micah Anderson for the Debian system (but may be used by others). Permission is granted to copy, distribute and/or modify this document under the terms of the GNU General Public License, Version 3 or any later version published by the Free Software Foundation.
-
-On Debian systems, the complete text of the GNU General Public License can be found in /usr/share/common-licenses/GPL.
-
diff --git a/contrib/debian/prcycoin-qt.desktop b/contrib/debian/prcycoin-qt.desktop
new file mode 100644
index 0000000000..92c99130f2
--- /dev/null
+++ b/contrib/debian/prcycoin-qt.desktop
@@ -0,0 +1,13 @@
+[Desktop Entry]
+Version=1.0
+Name=PRCYCoin Core
+Comment=PRivaCY Coin, P2P Cryptocurrency
+Comment[fr]=PRivaCY Coin, monnaie virtuelle cryptographique pair à pair
+Comment[tr]=PRivaCY Coin, eşten eşe kriptografik sanal para birimi
+Exec=prcycoin-qt %u
+Terminal=false
+Type=Application
+Icon=prcycoin128
+MimeType=x-scheme-handler/prcycoin;
+Categories=Office;Finance;
+StartupWMClass=Prcycoin-qt
diff --git a/contrib/debian/prcycoin-qt.install b/contrib/debian/prcycoin-qt.install
new file mode 100644
index 0000000000..28b8d7fe75
--- /dev/null
+++ b/contrib/debian/prcycoin-qt.install
@@ -0,0 +1,6 @@
+usr/local/bin/prcycoin-qt usr/bin
+share/pixmaps/prcycoin32.xpm usr/share/pixmaps
+share/pixmaps/prcycoin16.xpm usr/share/pixmaps
+share/pixmaps/prcycoin128.png usr/share/pixmaps
+debian/prcycoin-qt.desktop usr/share/applications
+debian/prcycoin-qt.protocol usr/share/kde4/services/
diff --git a/contrib/debian/dapscoin-qt.lintian-overrides b/contrib/debian/prcycoin-qt.lintian-overrides
similarity index 52%
rename from contrib/debian/dapscoin-qt.lintian-overrides
rename to contrib/debian/prcycoin-qt.lintian-overrides
index 777ee89790..f0bf230053 100644
--- a/contrib/debian/dapscoin-qt.lintian-overrides
+++ b/contrib/debian/prcycoin-qt.lintian-overrides
@@ -1,2 +1,2 @@
# Linked code is Expat - only Debian packaging is GPL-2+
-dapscoin-qt: possible-gpl-code-linked-with-openssl
+prcycoin-qt: possible-gpl-code-linked-with-openssl
diff --git a/contrib/debian/prcycoin-qt.manpages b/contrib/debian/prcycoin-qt.manpages
new file mode 100644
index 0000000000..f29151c97a
--- /dev/null
+++ b/contrib/debian/prcycoin-qt.manpages
@@ -0,0 +1 @@
+doc/man/prcycoin-qt.1
diff --git a/contrib/debian/dapscoin-qt.protocol b/contrib/debian/prcycoin-qt.protocol
similarity index 73%
rename from contrib/debian/dapscoin-qt.protocol
rename to contrib/debian/prcycoin-qt.protocol
index 0543f911b7..1cf82a5582 100644
--- a/contrib/debian/dapscoin-qt.protocol
+++ b/contrib/debian/prcycoin-qt.protocol
@@ -1,6 +1,6 @@
[Protocol]
-exec=dapscoin-qt '%u'
-protocol=dapscoin
+exec=prcycoin-qt '%u'
+protocol=prcycoin
input=none
output=none
helper=true
diff --git a/contrib/debian/prcycoind.bash-completion b/contrib/debian/prcycoind.bash-completion
new file mode 100644
index 0000000000..fb4efabbd4
--- /dev/null
+++ b/contrib/debian/prcycoind.bash-completion
@@ -0,0 +1,2 @@
+contrib/prcycoind.bash-completion prcycoind
+contrib/prcycoin-cli.bash-completion prcycoin-cli
diff --git a/contrib/debian/prcycoind.examples b/contrib/debian/prcycoind.examples
new file mode 100644
index 0000000000..8f9fcffba0
--- /dev/null
+++ b/contrib/debian/prcycoind.examples
@@ -0,0 +1 @@
+debian/examples/prcycoin.conf
diff --git a/contrib/debian/prcycoind.install b/contrib/debian/prcycoind.install
new file mode 100644
index 0000000000..8e765d4a68
--- /dev/null
+++ b/contrib/debian/prcycoind.install
@@ -0,0 +1,3 @@
+usr/local/bin/prcycoind usr/bin
+usr/local/bin/prcycoin-cli usr/bin
+debian/examples/prcycoin.conf etc/prcycoin
diff --git a/contrib/debian/dapscoind.lintian-overrides b/contrib/debian/prcycoind.lintian-overrides
similarity index 53%
rename from contrib/debian/dapscoind.lintian-overrides
rename to contrib/debian/prcycoind.lintian-overrides
index 4b0508d59b..3fa6c545e6 100644
--- a/contrib/debian/dapscoind.lintian-overrides
+++ b/contrib/debian/prcycoind.lintian-overrides
@@ -1,2 +1,2 @@
# Linked code is Expat - only Debian packaging is GPL-2+
-dapscoind: possible-gpl-code-linked-with-openssl
+prcycoind: possible-gpl-code-linked-with-openssl
diff --git a/contrib/debian/prcycoind.manpages b/contrib/debian/prcycoind.manpages
new file mode 100644
index 0000000000..153f1ddbc2
--- /dev/null
+++ b/contrib/debian/prcycoind.manpages
@@ -0,0 +1,2 @@
+doc/man/prcycoind.1
+doc/man/prcycoin-cli.1
diff --git a/contrib/debian/prcycoind.postinst b/contrib/debian/prcycoind.postinst
new file mode 100644
index 0000000000..343c48e526
--- /dev/null
+++ b/contrib/debian/prcycoind.postinst
@@ -0,0 +1,28 @@
+
+#!/bin/sh
+
+# setup prcycoin account, homedir etc
+
+set -e
+
+BCUSER="prcycoin"
+BCHOME="/var/lib/prcycoin"
+
+if [ "$1" = "configure" ]; then
+ # Add prcycoin user/group - this will gracefully abort if the user already exists.
+ # A homedir is never created.
+ set +e
+ adduser --system --home "${BCHOME}" --no-create-home --group "${BCUSER}" 2>/dev/null
+ set -e
+
+ # If the homedir does not already exist, create it with proper
+ # ownership and permissions.
+ if [ ! -d "${BCHOME}" ]; then
+ mkdir -m 0750 -p "${BCHOME}"
+ chown "${BCUSER}:${BCUSER}" "${BCHOME}"
+ fi
+fi
+
+#DEBHELPER#
+
+exit 0
diff --git a/contrib/debian/prcycoind.postrm b/contrib/debian/prcycoind.postrm
new file mode 100644
index 0000000000..143394d7ad
--- /dev/null
+++ b/contrib/debian/prcycoind.postrm
@@ -0,0 +1,35 @@
+#!/bin/sh
+
+# setup prcycoin account, homedir etc
+
+set -e
+
+BCUSER="prcycoin"
+BCHOME="/var/lib/prcycoin"
+
+if [ "$1" = "purge" ]; then
+
+ # The prcycoin user is left in place for now - This is to ensure that a new user
+ # will not inherit the users UID/GID and inadvertently gain access to wallets etc
+
+ # The homedir is also left intact to ensure that we don't accidentally delete a
+ # wallet or something equally important
+
+ echo
+ echo "#"
+ echo "# The prcycoin user (${BCUSER}) and data dir (${BCHOME})"
+ echo "# were left intact."
+ echo "#"
+ echo "# Make sure to check \"${BCHOME}\" for wallets and other"
+ echo "# important bits."
+ echo "#"
+ echo "# After backing up all vital data, cleanup can be completed"
+ echo "# by running: sudo userdel -r ${BCUSER}"
+ echo "#"
+ echo
+
+fi
+
+#DEBHELPER#
+
+exit 0
diff --git a/contrib/debian/prcycoind.service b/contrib/debian/prcycoind.service
new file mode 100644
index 0000000000..6bfedff4a9
--- /dev/null
+++ b/contrib/debian/prcycoind.service
@@ -0,0 +1,45 @@
+# It is not recommended to modify this file in-place, because it will
+# be overwritten during package upgrades. If you want to add further
+# options or overwrite existing ones then use
+# $ systemctl edit prcycoind.service
+# See "man systemd.service" for details.
+
+# Note that almost all daemon options could be specified in
+# /etc/prcycoin/prcycoin.conf
+
+[Unit]
+Description=PRivaCY Coin daemon
+After=network.target
+
+[Service]
+ExecStart=/usr/bin/prcycoind -daemon -datadir=/var/lib/prcycoin -conf=/etc/prcycoin/prcycoin.conf -pid=/run/prcycoind/prcycoind.pid
+# Creates /run/prcycoind owned by prcycoin
+RuntimeDirectory=prcycoind
+User=prcycoin
+Type=forking
+PIDFile=/run/prcycoind/prcycoind.pid
+Restart=on-failure
+
+# Hardening measures
+####################
+
+# Provide a private /tmp and /var/tmp.
+PrivateTmp=true
+
+# Mount /usr, /boot/ and /etc read-only for the process.
+ProtectSystem=full
+
+# Disallow the process and all of its children to gain
+# new privileges through execve().
+NoNewPrivileges=true
+
+# Use a new /dev namespace only populated with API pseudo devices
+# such as /dev/null, /dev/zero and /dev/random.
+PrivateDevices=true
+
+# Deny the creation of writable and executable memory mappings.
+# Commented out as it's not supported on Debian 8 or Ubuntu 16.04 LTS
+#MemoryDenyWriteExecute=true
+
+[Install]
+WantedBy=multi-user.target
diff --git a/contrib/debian/rules b/contrib/debian/rules
index 27b46bae3d..0bd3840bcd 100644
--- a/contrib/debian/rules
+++ b/contrib/debian/rules
@@ -1,9 +1,9 @@
#!/usr/bin/make -f
# -*- mode: makefile; coding: utf-8 -*-
-#DEB_MAKE_CHECK_TARGET = test_dapscoin
+#DEB_MAKE_CHECK_TARGET = test_prcycoin
#build/bitcoind::
-# $(if $(filter nocheck,$(DEB_BUILD_OPTIONS)),,src/test_dapscoin)
+# $(if $(filter nocheck,$(DEB_BUILD_OPTIONS)),,src/test_prcycoin)
DEB_INSTALL_EXAMPLES_bitcoind += debian/examples/*
DEB_INSTALL_MANPAGES_bitcoind += debian/manpages/*
@@ -13,12 +13,26 @@ DEB_INSTALL_MANPAGES_bitcoind += debian/manpages/*
override_dh_auto_clean:
if [ -f Makefile ]; then $(MAKE) distclean; fi
- rm -rf Makefile.in aclocal.m4 configure src/Makefile.in src/dapscoin-config.h.in src/build-aux src/qt/Makefile.in src/qt/test/Makefile.in src/test/Makefile.in
+ rm -rf Makefile.in aclocal.m4 configure src/Makefile.in src/prcycoin-config.h.in src/build-aux src/qt/Makefile.in src/qt/test/Makefile.in src/test/Makefile.in
# Yea, autogen should be run on the source archive, but I like doing git archive
override_dh_auto_configure:
./autogen.sh
- ./configure
+ ./configure --with-gui=qt5
override_dh_auto_test:
make check
+
+# No SysV or Upstart init scripts included
+override_dh_installinit:
+ dh_installinit \
+ --noscripts
+
+# Don’t enable service by default
+override_dh_systemd_enable:
+ dh_systemd_enable \
+ --no-enable
+
+# Restart after upgrade
+override_dh_systemd_start:
+ dh_systemd_start \
diff --git a/contrib/debian/watch b/contrib/debian/watch
index c96d2f8e75..6ccc8a14d9 100644
--- a/contrib/debian/watch
+++ b/contrib/debian/watch
@@ -1,7 +1,5 @@
# Run the "uscan" command to check for upstream updates and more.
version=3
# use qa.debian.org redirector; see man uscan
-opts=uversionmangle=s/(\d)(alpha|beta|rc)/$1~$2/;s/\-src//,dversionmangle=s/~dfsg\d*// \
- http://sf.net/bitcoin/bitcoin-(\d.*)-linux\.tar\.gz debian
opts=uversionmangle=s/(\d)(alpha|beta|rc)/$1~$2/,dversionmangle=s/~dfsg\d*// \
- http://githubredir.debian.net/github/bitcoin/bitcoin v(.*).tar.gz
+ http://githubredir.debian.net/github/prcycoin/prcycoin v(.*).tar.gz
diff --git a/contrib/devtools/README.md b/contrib/devtools/README.md
index afa0a90fd3..eee44b650b 100644
--- a/contrib/devtools/README.md
+++ b/contrib/devtools/README.md
@@ -1,5 +1,5 @@
Contents
-===========
+========
This directory contains tools for developers working on this repository.
check-doc.py
@@ -8,6 +8,93 @@ check-doc.py
Check if all command line args are documented. The return value indicates the
number of undocumented args.
+clang-format-diff.py
+===================
+
+A script to format unified git diffs according to [.clang-format](../../src/.clang-format).
+
+Requires `clang-format`, installed e.g. via `brew install clang-format` on macOS.
+
+For instance, to format the last commit with 0 lines of context,
+the script should be called from the git root folder as follows.
+
+```
+git diff -U0 HEAD~1.. | ./contrib/devtools/clang-format-diff.py -p1 -i -v
+```
+
+copyright\_header.py
+====================
+
+Provides utilities for managing copyright headers of `The PRCYCoin
+developers` in repository source files. It has three subcommands:
+
+```
+$ ./copyright_header.py report [verbose]
+$ ./copyright_header.py update
+$ ./copyright_header.py insert
+```
+Running these subcommands without arguments displays a usage string.
+
+copyright\_header.py report \ [verbose]
+---------------------------------------------------------
+
+Produces a report of all copyright header notices found inside the source files
+of a repository. Useful to quickly visualize the state of the headers.
+Specifying `verbose` will list the full filenames of files of each category.
+
+copyright\_header.py update \ [verbose]
+---------------------------------------------------------
+Updates all the copyright headers of `The PRCYCoin developers` which were
+changed in a year more recent than is listed. For example:
+```
+// Copyright (c) - The PRCYCoin developers
+```
+will be updated to:
+```
+// Copyright (c) - The PRCYCoin developers
+```
+where `` is obtained from the `git log` history.
+
+This subcommand also handles copyright headers that have only a single year. In
+those cases:
+```
+// Copyright (c) The PRCYCoin developers
+```
+will be updated to:
+```
+// Copyright (c) - The PRCYCoin developers
+```
+where the update is appropriate.
+
+copyright\_header.py insert \
+------------------------------------
+Inserts a copyright header for `The PRCYCoin developers` at the top of the
+file in either Python or C++ style as determined by the file extension. If the
+file is a Python file and it has `#!` starting the first line, the header is
+inserted in the line below it.
+
+The copyright dates will be set to be `-` where
+`` is according to the `git log` history. If
+`` is equal to ``, it will be set as a single
+year rather than two hyphenated years.
+
+If the file already has a copyright for `The PRCYCoin developers`, the
+script will exit.
+
+gen-manpages.sh
+===============
+
+A small script to automatically create manpages in ../../doc/man by running the release binaries with the -help option.
+This requires help2man which can be found at: https://www.gnu.org/software/help2man/
+
+With in-tree builds this tool can be run from any directory within the
+repostitory. To use this tool with out-of-tree builds set `BUILDDIR`. For
+example:
+
+```bash
+BUILDDIR=$PWD/build contrib/devtools/gen-manpages.sh
+```
+
github-merge.py
===============
@@ -18,7 +105,7 @@ For example:
./github-merge.py 3077
(in any git repository) will help you merge pull request #3077 for the
-DAPScoin-Project/DAPS repository.
+PRCYCoin-Project/PRCYCoin repository.
What it does:
* Fetch master and the pull request.
@@ -36,47 +123,48 @@ couldn't mess with the sources.
Setup
---------
-Configuring the github-merge tool for the DAPS repository is done in the following way:
+Configuring the github-merge tool for the PRCYCoin repository is done in the following way:
- git config githubmerge.repository DAPScoin-Project/DAPScoin
+ git config githubmerge.repository PRCYCoin-Project/PRCYCoin
git config githubmerge.testcmd "make -j4 check" (adapt to whatever you want to use for testing)
- git config --global user.signingkey mykeyid (if you want to GPG sign)
-
-optimize-pngs.py
-================
+ git config --global user.signingkey mykeyid
-A script to optimize png files in the DAPScoin
-repository (requires pngcrush).
-
-fix-copyright-headers.py
-===========================
+Authentication (optional)
+--------------------------
-Every year newly updated files need to have its copyright headers updated to reflect the current year.
-If you run this script from src/ it will automatically update the year on the copyright header for all
-.cpp and .h files if these have a git commit from the current year.
+The API request limit for unauthenticated requests is quite low, but the
+limit for authenticated requests is much higher. If you start running
+into rate limiting errors it can be useful to set an authentication token
+so that the script can authenticate requests.
-For example a file changed in 2014 (with 2014 being the current year):
-```// Copyright (c) 2009-2013 The Bitcoin developers```
+- First, go to [Personal access tokens](https://github.com/settings/tokens).
+- Click 'Generate new token'.
+- Fill in an arbitrary token description. No further privileges are needed.
+- Click the `Generate token` button at the bottom of the form.
+- Copy the generated token (should be a hexadecimal string)
-would be changed to:
-```// Copyright (c) 2009-2014 The Bitcoin developers```
+Then do:
-logprint-scanner.py
-===================
-LogPrint and LogPrintf are known to throw exceptions when the number of arguments supplied to the
-LogPrint(f) function is not the same as the number of format specifiers.
+ git config --global user.ghtoken "pasted token"
-Ideally, the presentation of this mismatch would be at compile-time, but instead it is at run-time.
+Create and verify timestamps of merge commits
+---------------------------------------------
+To create or verify timestamps on the merge commits, install the OpenTimestamps
+client via `pip3 install opentimestamps-client`. Then, dowload the gpg wrapper
+`ots-git-gpg-wrapper.sh` and set it as git's `gpg.program`. See
+[the ots git integration documentation](https://github.com/opentimestamps/opentimestamps-client/blob/master/doc/git-integration.md#usage)
+for further details.
-This script scans the src/ directory recursively and looks in each .cpp/.h file and identifies all
-errorneous LogPrint(f) calls where the number of arguments do not match.
+optimize-pngs.py
+================
-The filename and line number of the errorneous occurence is given.
+A script to optimize png files in the PRCYCoin
+repository (requires pngcrush).
-The script returns with the number of erroneous occurences as an error code to help facilitate
-integration with a continuous integration system.
+security-check.py and test-security-check.py
+============================================
-The script can be ran from any working directory inside the git repository.
+Perform basic ELF security checks on a series of executables.
symbol-check.py
===============
@@ -87,16 +175,16 @@ still compatible with the minimum supported Linux distribution versions.
Example usage after a gitian build:
- find ../gitian-builder/build -type f -executable | xargs python contrib/devtools/symbol-check.py
+ find ../gitian-builder/build -type f -executable | xargs python3 contrib/devtools/symbol-check.py
If only supported symbols are used the return value will be 0 and the output will be empty.
If there are 'unsupported' symbols, the return value will be 1 a list like this will be printed:
- .../64/test_dapscoin: symbol memcpy from unsupported version GLIBC_2.14
- .../64/test_dapscoin: symbol __fdelt_chk from unsupported version GLIBC_2.15
- .../64/test_dapscoin: symbol std::out_of_range::~out_of_range() from unsupported version GLIBCXX_3.4.15
- .../64/test_dapscoin: symbol _ZNSt8__detail15_List_nod from unsupported version GLIBCXX_3.4.15
+ .../64/test_prcycoin: symbol memcpy from unsupported version GLIBC_2.14
+ .../64/test_prcycoin: symbol __fdelt_chk from unsupported version GLIBC_2.15
+ .../64/test_prcycoin: symbol std::out_of_range::~out_of_range() from unsupported version GLIBCXX_3.4.15
+ .../64/test_prcycoin: symbol _ZNSt8__detail15_List_nod from unsupported version GLIBCXX_3.4.15
update-translations.py
======================
@@ -109,3 +197,14 @@ It will do the following automatically:
- add missing translations to the build system (TODO)
See doc/translation-process.md for more information.
+
+circular-dependencies.py
+========================
+
+Run this script from the root of the source tree (`src/`) to find circular dependencies in the source code.
+This looks only at which files include other files, treating the `.cpp` and `.h` file as one unit.
+
+Example usage:
+
+ cd .../src
+ ../contrib/devtools/circular-dependencies.py {*,*/*,*/*/*}.{h,cpp}
diff --git a/contrib/devtools/check-doc.py b/contrib/devtools/check-doc.py
index 9f6e7c87ef..1245ee13a4 100644
--- a/contrib/devtools/check-doc.py
+++ b/contrib/devtools/check-doc.py
@@ -20,7 +20,7 @@
REGEX_ARG = re.compile(r'(?:map(?:Multi)?Args(?:\.count\(|\[)|Get(?:Bool)?Arg\()\"(\-[^\"]+?)\"')
REGEX_DOC = re.compile(r'HelpMessageOpt\(\"(\-[^\"=]+?)(?:=|\")')
# list unsupported, deprecated and duplicate args as they need no documentation
-SET_DOC_OPTIONAL = set(['-rpcssl', '-benchmark', '-h', '-help', '-socks', '-tor', '-debugnet', '-whitelistalwaysrelay', '-prematurewitness', '-walletprematurewitness', '-promiscuousmempoolflags', '-blockminsize', '-sendfreetransactions', '-checklevel', '-liquidityprovider', '-anonymizedapscoinamount'])
+SET_DOC_OPTIONAL = set(['-rpcssl', '-benchmark', '-h', '-help', '-socks', '-tor', '-debugnet', '-whitelistalwaysrelay', '-prematurewitness', '-walletprematurewitness', '-promiscuousmempoolflags', '-blockminsize', '-sendfreetransactions', '-checklevel', '-liquidityprovider'])
def main():
used = check_output(CMD_GREP_ARGS, shell=True)
diff --git a/contrib/devtools/circular-dependencies.py b/contrib/devtools/circular-dependencies.py
new file mode 100755
index 0000000000..ce70470ed8
--- /dev/null
+++ b/contrib/devtools/circular-dependencies.py
@@ -0,0 +1,92 @@
+#!/usr/bin/env python3
+# Copyright (c) 2018-2020 The Bitcoin Core developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+import sys
+import re
+from typing import Dict, List, Set
+
+MAPPING = {
+ 'core_read.cpp': 'core_io.cpp',
+ 'core_write.cpp': 'core_io.cpp',
+}
+
+# Directories with header-based modules, where the assumption that .cpp files
+# define functions and variables declared in corresponding .h files is
+# incorrect.
+HEADER_MODULE_PATHS = [
+ 'interfaces/'
+]
+
+def module_name(path):
+ if path in MAPPING:
+ path = MAPPING[path]
+ if any(path.startswith(dirpath) for dirpath in HEADER_MODULE_PATHS):
+ return path
+ if path.endswith(".h"):
+ return path[:-2]
+ if path.endswith(".c"):
+ return path[:-2]
+ if path.endswith(".cpp"):
+ return path[:-4]
+ return None
+
+files = dict()
+deps: Dict[str, Set[str]] = dict()
+
+RE = re.compile("^#include \"(.*)\"")
+
+# Iterate over files, and create list of modules
+for arg in sys.argv[1:]:
+ module = module_name(arg)
+ if module is None:
+ print("Ignoring file %s (does not constitute module)\n" % arg)
+ else:
+ files[arg] = module
+ deps[module] = set()
+
+# Iterate again, and build list of direct dependencies for each module
+# TODO: implement support for multiple include directories
+for arg in sorted(files.keys()):
+ module = files[arg]
+ with open(arg, 'r', encoding="utf8") as f:
+ for line in f:
+ match = RE.match(line)
+ if match:
+ include = match.group(1)
+ included_module = module_name(include)
+ if included_module is not None and included_module in deps and included_module != module:
+ deps[module].add(included_module)
+
+# Loop to find the shortest (remaining) circular dependency
+have_cycle: bool = False
+while True:
+ shortest_cycle = None
+ for module in sorted(deps.keys()):
+ # Build the transitive closure of dependencies of module
+ closure: Dict[str, List[str]] = dict()
+ for dep in deps[module]:
+ closure[dep] = []
+ while True:
+ old_size = len(closure)
+ old_closure_keys = sorted(closure.keys())
+ for src in old_closure_keys:
+ for dep in deps[src]:
+ if dep not in closure:
+ closure[dep] = closure[src] + [src]
+ if len(closure) == old_size:
+ break
+ # If module is in its own transitive closure, it's a circular dependency; check if it is the shortest
+ if module in closure and (shortest_cycle is None or len(closure[module]) + 1 < len(shortest_cycle)):
+ shortest_cycle = [module] + closure[module]
+ if shortest_cycle is None:
+ break
+ # We have the shortest circular dependency; report it
+ module = shortest_cycle[0]
+ print("Circular dependency: %s" % (" -> ".join(shortest_cycle + [module])))
+ # And then break the dependency to avoid repeating in other cycles
+ deps[shortest_cycle[-1]] = deps[shortest_cycle[-1]] - set([module])
+ have_cycle = True
+
+sys.exit(1 if have_cycle else 0)
diff --git a/contrib/devtools/clang-format-diff.py b/contrib/devtools/clang-format-diff.py
new file mode 100755
index 0000000000..f322b3a880
--- /dev/null
+++ b/contrib/devtools/clang-format-diff.py
@@ -0,0 +1,166 @@
+#!/usr/bin/env python3
+#
+#===- clang-format-diff.py - ClangFormat Diff Reformatter ----*- python -*--===#
+#
+# The LLVM Compiler Infrastructure
+#
+# This file is distributed under the University of Illinois Open Source
+# License.
+#
+# ============================================================
+#
+# University of Illinois/NCSA
+# Open Source License
+#
+# Copyright (c) 2007-2015 University of Illinois at Urbana-Champaign.
+# All rights reserved.
+#
+# Developed by:
+#
+# LLVM Team
+#
+# University of Illinois at Urbana-Champaign
+#
+# http://llvm.org
+#
+# Permission is hereby granted, free of charge, to any person obtaining a copy of
+# this software and associated documentation files (the "Software"), to deal with
+# the Software without restriction, including without limitation the rights to
+# use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
+# of the Software, and to permit persons to whom the Software is furnished to do
+# so, subject to the following conditions:
+#
+# * Redistributions of source code must retain the above copyright notice,
+# this list of conditions and the following disclaimers.
+#
+# * Redistributions in binary form must reproduce the above copyright notice,
+# this list of conditions and the following disclaimers in the
+# documentation and/or other materials provided with the distribution.
+#
+# * Neither the names of the LLVM Team, University of Illinois at
+# Urbana-Champaign, nor the names of its contributors may be used to
+# endorse or promote products derived from this Software without specific
+# prior written permission.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
+# FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+# CONTRIBUTORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS WITH THE
+# SOFTWARE.
+#
+# ============================================================
+#
+#===------------------------------------------------------------------------===#
+
+r"""
+ClangFormat Diff Reformatter
+============================
+
+This script reads input from a unified diff and reformats all the changed
+lines. This is useful to reformat all the lines touched by a specific patch.
+Example usage for git/svn users:
+
+ git diff -U0 HEAD^ | clang-format-diff.py -p1 -i
+ svn diff --diff-cmd=diff -x-U0 | clang-format-diff.py -i
+
+"""
+
+import argparse
+import difflib
+import io
+import re
+import subprocess
+import sys
+
+
+# Change this to the full path if clang-format is not on the path.
+binary = 'clang-format'
+
+
+def main():
+ parser = argparse.ArgumentParser(description=
+ 'Reformat changed lines in diff. Without -i '
+ 'option just output the diff that would be '
+ 'introduced.')
+ parser.add_argument('-i', action='store_true', default=False,
+ help='apply edits to files instead of displaying a diff')
+ parser.add_argument('-p', metavar='NUM', default=0,
+ help='strip the smallest prefix containing P slashes')
+ parser.add_argument('-regex', metavar='PATTERN', default=None,
+ help='custom pattern selecting file paths to reformat '
+ '(case sensitive, overrides -iregex)')
+ parser.add_argument('-iregex', metavar='PATTERN', default=
+ r'.*\.(cpp|cc|c\+\+|cxx|c|cl|h|hpp|m|mm|inc|js|ts|proto'
+ r'|protodevel|java)',
+ help='custom pattern selecting file paths to reformat '
+ '(case insensitive, overridden by -regex)')
+ parser.add_argument('-sort-includes', action='store_true', default=False,
+ help='let clang-format sort include blocks')
+ parser.add_argument('-v', '--verbose', action='store_true',
+ help='be more verbose, ineffective without -i')
+ args = parser.parse_args()
+
+ # Extract changed lines for each file.
+ filename = None
+ lines_by_file = {}
+ for line in sys.stdin:
+ match = re.search('^\+\+\+\ (.*?/){%s}(\S*)' % args.p, line)
+ if match:
+ filename = match.group(2)
+ if filename is None:
+ continue
+
+ if args.regex is not None:
+ if not re.match('^%s$' % args.regex, filename):
+ continue
+ else:
+ if not re.match('^%s$' % args.iregex, filename, re.IGNORECASE):
+ continue
+
+ match = re.search('^@@.*\+(\d+)(,(\d+))?', line)
+ if match:
+ start_line = int(match.group(1))
+ line_count = 1
+ if match.group(3):
+ line_count = int(match.group(3))
+ if line_count == 0:
+ continue
+ end_line = start_line + line_count - 1
+ lines_by_file.setdefault(filename, []).extend(
+ ['-lines', str(start_line) + ':' + str(end_line)])
+
+ # Reformat files containing changes in place.
+ for filename, lines in lines_by_file.items():
+ if args.i and args.verbose:
+ print('Formatting {}'.format(filename))
+ command = [binary, filename]
+ if args.i:
+ command.append('-i')
+ if args.sort_includes:
+ command.append('-sort-includes')
+ command.extend(lines)
+ command.extend(['-style=file', '-fallback-style=none'])
+ p = subprocess.Popen(command,
+ stdout=subprocess.PIPE,
+ stderr=None,
+ stdin=subprocess.PIPE,
+ universal_newlines=True)
+ stdout, stderr = p.communicate()
+ if p.returncode != 0:
+ sys.exit(p.returncode)
+
+ if not args.i:
+ with open(filename, encoding="utf8") as f:
+ code = f.readlines()
+ formatted_code = io.StringIO(stdout).readlines()
+ diff = difflib.unified_diff(code, formatted_code,
+ filename, filename,
+ '(before formatting)', '(after formatting)')
+ diff_string = ''.join(diff)
+ if len(diff_string) > 0:
+ sys.stdout.write(diff_string)
+
+if __name__ == '__main__':
+ main()
diff --git a/contrib/devtools/commit-script-check.sh b/contrib/devtools/commit-script-check.sh
new file mode 100755
index 0000000000..1c9dbc7f68
--- /dev/null
+++ b/contrib/devtools/commit-script-check.sh
@@ -0,0 +1,46 @@
+#!/bin/sh
+# Copyright (c) 2017 The Bitcoin Core developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+# This simple script checks for commits beginning with: scripted-diff:
+# If found, looks for a script between the lines -BEGIN VERIFY SCRIPT- and
+# -END VERIFY SCRIPT-. If no ending is found, it reads until the end of the
+# commit message.
+
+# The resulting script should exactly transform the previous commit into the current
+# one. Any remaining diff signals an error.
+
+if test "x$1" = "x"; then
+ echo "Usage: $0 ..."
+ exit 1
+fi
+
+RET=0
+PREV_BRANCH=`git name-rev --name-only HEAD`
+PREV_HEAD=`git rev-parse HEAD`
+for i in `git rev-list --reverse $1`; do
+ if git rev-list -n 1 --pretty="%s" $i | grep -q "^scripted-diff:"; then
+ git checkout --quiet $i^ || exit
+ SCRIPT="`git rev-list --format=%b -n1 $i | sed '/^-BEGIN VERIFY SCRIPT-$/,/^-END VERIFY SCRIPT-$/{//!b};d'`"
+ if test "x$SCRIPT" = "x"; then
+ echo "Error: missing script for: $i"
+ echo "Failed"
+ RET=1
+ else
+ echo "Running script for: $i"
+ echo "$SCRIPT"
+ eval "$SCRIPT"
+ git --no-pager diff --exit-code $i && echo "OK" || (echo "Failed"; false) || RET=1
+ fi
+ git reset --quiet --hard HEAD
+ else
+ if git rev-list "--format=%b" -n1 $i | grep -q '^-\(BEGIN\|END\)[ a-zA-Z]*-$'; then
+ echo "Error: script block marker but no scripted-diff in title"
+ echo "Failed"
+ RET=1
+ fi
+ fi
+done
+git checkout --quiet $PREV_BRANCH 2>/dev/null || git checkout --quiet $PREV_HEAD
+exit $RET
diff --git a/contrib/devtools/copyright_header.py b/contrib/devtools/copyright_header.py
new file mode 100755
index 0000000000..c45aa004d2
--- /dev/null
+++ b/contrib/devtools/copyright_header.py
@@ -0,0 +1,622 @@
+#!/usr/bin/env python3
+# Copyright (c) 2016-2018 The Bitcoin Core developers
+# Copyright (c) 2018 The PIVX developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+import re
+import fnmatch
+import sys
+import subprocess
+import datetime
+import os
+
+################################################################################
+# file filtering
+################################################################################
+
+EXCLUDE = [
+ # auto generated:
+ 'src/qt/prcycoinstrings.cpp',
+ 'src/chainparamsseeds.h',
+ # other external copyrights:
+ 'src/tinyformat.h',
+ 'src/crypto/scrypt.cpp',
+ 'test/functional/test_framework/bignum.py',
+ # python init:
+ '*__init__.py',
+]
+EXCLUDE_COMPILED = re.compile('|'.join([fnmatch.translate(m) for m in EXCLUDE]))
+
+EXCLUDE_DIRS = [
+ # git subtrees
+ "src/crypto/ctaes/",
+ "src/leveldb/",
+ "src/secp256k1/",
+ "src/univalue/",
+ "src/crc32c",
+]
+
+INCLUDE = ['*.h', '*.cpp', '*.cc', '*.c', '*.py']
+INCLUDE_COMPILED = re.compile('|'.join([fnmatch.translate(m) for m in INCLUDE]))
+
+def applies_to_file(filename):
+ for excluded_dir in EXCLUDE_DIRS:
+ if filename.startswith(excluded_dir):
+ return False
+ return ((EXCLUDE_COMPILED.match(filename) is None) and
+ (INCLUDE_COMPILED.match(filename) is not None))
+
+################################################################################
+# obtain list of files in repo according to INCLUDE and EXCLUDE
+################################################################################
+
+GIT_LS_CMD = 'git ls-files --full-name'.split(' ')
+GIT_TOPLEVEL_CMD = 'git rev-parse --show-toplevel'.split(' ')
+
+def call_git_ls(base_directory):
+ out = subprocess.check_output([*GIT_LS_CMD, base_directory])
+ return [f for f in out.decode("utf-8").split('\n') if f != '']
+
+def call_git_toplevel():
+ "Returns the absolute path to the project root"
+ return subprocess.check_output(GIT_TOPLEVEL_CMD).strip().decode("utf-8")
+
+def get_filenames_to_examine(base_directory):
+ "Returns an array of absolute paths to any project files in the base_directory that pass the include/exclude filters"
+ root = call_git_toplevel()
+ filenames = call_git_ls(base_directory)
+ return sorted([os.path.join(root, filename) for filename in filenames if
+ applies_to_file(filename)])
+
+################################################################################
+# define and compile regexes for the patterns we are looking for
+################################################################################
+
+
+COPYRIGHT_WITH_C = 'Copyright \(c\)'
+COPYRIGHT_WITHOUT_C = 'Copyright'
+ANY_COPYRIGHT_STYLE = '(%s|%s)' % (COPYRIGHT_WITH_C, COPYRIGHT_WITHOUT_C)
+
+YEAR = "20[0-9][0-9]"
+YEAR_RANGE = '(%s)(-%s)?' % (YEAR, YEAR)
+YEAR_LIST = '(%s)(, %s)+' % (YEAR, YEAR)
+ANY_YEAR_STYLE = '(%s|%s)' % (YEAR_RANGE, YEAR_LIST)
+ANY_COPYRIGHT_STYLE_OR_YEAR_STYLE = ("%s %s" % (ANY_COPYRIGHT_STYLE,
+ ANY_YEAR_STYLE))
+
+ANY_COPYRIGHT_COMPILED = re.compile(ANY_COPYRIGHT_STYLE_OR_YEAR_STYLE)
+
+def compile_copyright_regex(copyright_style, year_style, name):
+ return re.compile('%s %s,? %s' % (copyright_style, year_style, name))
+
+EXPECTED_HOLDER_NAMES = [
+ "Satoshi Nakamoto\n",
+ "The Bitcoin Core developers\n",
+ "The Bitcoin Core developers \n",
+ "Bitcoin Core Developers\n",
+ "the Bitcoin Core developers\n",
+ "The Bitcoin developers\n",
+ "The LevelDB Authors\. All rights reserved\.\n",
+ "BitPay Inc\.\n",
+ "BitPay, Inc\.\n",
+ "University of Illinois at Urbana-Champaign\.\n",
+ "MarcoFalke\n",
+ "Pieter Wuille\n",
+ "Pieter Wuille +\*\n",
+ "Pieter Wuille, Gregory Maxwell +\*\n",
+ "Pieter Wuille, Andrew Poelstra +\*\n",
+ "Ian Miers, Christina Garman and Matthew Green\n",
+ "Andrew Poelstra +\*\n",
+ "Wladimir J. van der Laan\n",
+ "Jeff Garzik\n",
+ "Diederik Huys, Pieter Wuille +\*\n",
+ "Thomas Daede, Cory Fields +\*\n",
+ "Jan-Klaas Kollhof\n",
+ "Sam Rushing\n",
+ "ArtForz -- public domain half-a-node\n",
+ " Projet RNRT SAPHIR\n",
+ "The Zcash developers\n",
+ "The Dash developers\n",
+ "The Dash Developers\n",
+ "The Dash Core developers\n",
+ "The PIVX developers\n",
+ "The PPCoin developers\n",
+ "The PRivaCY Coin Developers\n",
+]
+
+DOMINANT_STYLE_COMPILED = {}
+YEAR_LIST_STYLE_COMPILED = {}
+WITHOUT_C_STYLE_COMPILED = {}
+
+for holder_name in EXPECTED_HOLDER_NAMES:
+ DOMINANT_STYLE_COMPILED[holder_name] = (
+ compile_copyright_regex(COPYRIGHT_WITH_C, YEAR_RANGE, holder_name))
+ YEAR_LIST_STYLE_COMPILED[holder_name] = (
+ compile_copyright_regex(COPYRIGHT_WITH_C, YEAR_LIST, holder_name))
+ WITHOUT_C_STYLE_COMPILED[holder_name] = (
+ compile_copyright_regex(COPYRIGHT_WITHOUT_C, ANY_YEAR_STYLE,
+ holder_name))
+
+################################################################################
+# search file contents for copyright message of particular category
+################################################################################
+
+def get_count_of_copyrights_of_any_style_any_holder(contents):
+ return len(ANY_COPYRIGHT_COMPILED.findall(contents))
+
+def file_has_dominant_style_copyright_for_holder(contents, holder_name):
+ match = DOMINANT_STYLE_COMPILED[holder_name].search(contents)
+ return match is not None
+
+def file_has_year_list_style_copyright_for_holder(contents, holder_name):
+ match = YEAR_LIST_STYLE_COMPILED[holder_name].search(contents)
+ return match is not None
+
+def file_has_without_c_style_copyright_for_holder(contents, holder_name):
+ match = WITHOUT_C_STYLE_COMPILED[holder_name].search(contents)
+ return match is not None
+
+################################################################################
+# get file info
+################################################################################
+
+def read_file(filename):
+ return open(filename, 'r', encoding="utf8").read()
+
+def gather_file_info(filename):
+ info = {}
+ info['filename'] = filename
+ c = read_file(filename)
+ info['contents'] = c
+
+ info['all_copyrights'] = get_count_of_copyrights_of_any_style_any_holder(c)
+
+ info['classified_copyrights'] = 0
+ info['dominant_style'] = {}
+ info['year_list_style'] = {}
+ info['without_c_style'] = {}
+ for holder_name in EXPECTED_HOLDER_NAMES:
+ has_dominant_style = (
+ file_has_dominant_style_copyright_for_holder(c, holder_name))
+ has_year_list_style = (
+ file_has_year_list_style_copyright_for_holder(c, holder_name))
+ has_without_c_style = (
+ file_has_without_c_style_copyright_for_holder(c, holder_name))
+ info['dominant_style'][holder_name] = has_dominant_style
+ info['year_list_style'][holder_name] = has_year_list_style
+ info['without_c_style'][holder_name] = has_without_c_style
+ if has_dominant_style or has_year_list_style or has_without_c_style:
+ info['classified_copyrights'] = info['classified_copyrights'] + 1
+ return info
+
+################################################################################
+# report execution
+################################################################################
+
+SEPARATOR = '-'.join(['' for _ in range(80)])
+
+def print_filenames(filenames, verbose):
+ if not verbose:
+ return
+ for filename in filenames:
+ print("\t%s" % filename)
+
+def print_report(file_infos, verbose):
+ print(SEPARATOR)
+ examined = [i['filename'] for i in file_infos]
+ print("%d files examined according to INCLUDE and EXCLUDE fnmatch rules" %
+ len(examined))
+ print_filenames(examined, verbose)
+
+ print(SEPARATOR)
+ print('')
+ zero_copyrights = [i['filename'] for i in file_infos if
+ i['all_copyrights'] == 0]
+ print("%4d with zero copyrights" % len(zero_copyrights))
+ print_filenames(zero_copyrights, verbose)
+ one_copyright = [i['filename'] for i in file_infos if
+ i['all_copyrights'] == 1]
+ print("%4d with one copyright" % len(one_copyright))
+ print_filenames(one_copyright, verbose)
+ two_copyrights = [i['filename'] for i in file_infos if
+ i['all_copyrights'] == 2]
+ print("%4d with two copyrights" % len(two_copyrights))
+ print_filenames(two_copyrights, verbose)
+ three_copyrights = [i['filename'] for i in file_infos if
+ i['all_copyrights'] == 3]
+ print("%4d with three copyrights" % len(three_copyrights))
+ print_filenames(three_copyrights, verbose)
+ four_or_more_copyrights = [i['filename'] for i in file_infos if
+ i['all_copyrights'] >= 4]
+ print("%4d with four or more copyrights" % len(four_or_more_copyrights))
+ print_filenames(four_or_more_copyrights, verbose)
+ print('')
+ print(SEPARATOR)
+ print('Copyrights with dominant style:\ne.g. "Copyright (c)" and '
+ '"" or "-":\n')
+ for holder_name in EXPECTED_HOLDER_NAMES:
+ dominant_style = [i['filename'] for i in file_infos if
+ i['dominant_style'][holder_name]]
+ if len(dominant_style) > 0:
+ print("%4d with '%s'" % (len(dominant_style),
+ holder_name.replace('\n', '\\n')))
+ print_filenames(dominant_style, verbose)
+ print('')
+ print(SEPARATOR)
+ print('Copyrights with year list style:\ne.g. "Copyright (c)" and '
+ '", , ...":\n')
+ for holder_name in EXPECTED_HOLDER_NAMES:
+ year_list_style = [i['filename'] for i in file_infos if
+ i['year_list_style'][holder_name]]
+ if len(year_list_style) > 0:
+ print("%4d with '%s'" % (len(year_list_style),
+ holder_name.replace('\n', '\\n')))
+ print_filenames(year_list_style, verbose)
+ print('')
+ print(SEPARATOR)
+ print('Copyrights with no "(c)" style:\ne.g. "Copyright" and "" or '
+ '"-":\n')
+ for holder_name in EXPECTED_HOLDER_NAMES:
+ without_c_style = [i['filename'] for i in file_infos if
+ i['without_c_style'][holder_name]]
+ if len(without_c_style) > 0:
+ print("%4d with '%s'" % (len(without_c_style),
+ holder_name.replace('\n', '\\n')))
+ print_filenames(without_c_style, verbose)
+
+ print('')
+ print(SEPARATOR)
+
+ unclassified_copyrights = [i['filename'] for i in file_infos if
+ i['classified_copyrights'] < i['all_copyrights']]
+ print("%d with unexpected copyright holder names" %
+ len(unclassified_copyrights))
+ print_filenames(unclassified_copyrights, verbose)
+ print(SEPARATOR)
+
+def exec_report(base_directory, verbose):
+ filenames = get_filenames_to_examine(base_directory)
+ file_infos = [gather_file_info(f) for f in filenames]
+ print_report(file_infos, verbose)
+
+################################################################################
+# report cmd
+################################################################################
+
+REPORT_USAGE = """
+Produces a report of all copyright header notices found inside the source files
+of a repository.
+
+Usage:
+ $ ./copyright_header.py report [verbose]
+
+Arguments:
+ - The base directory of a bitcoin source code repository.
+ [verbose] - Includes a list of every file of each subcategory in the report.
+"""
+
+def report_cmd(argv):
+ if len(argv) == 2:
+ sys.exit(REPORT_USAGE)
+
+ base_directory = argv[2]
+ if not os.path.exists(base_directory):
+ sys.exit("*** bad : %s" % base_directory)
+
+ if len(argv) == 3:
+ verbose = False
+ elif argv[3] == 'verbose':
+ verbose = True
+ else:
+ sys.exit("*** unknown argument: %s" % argv[2])
+
+ exec_report(base_directory, verbose)
+
+################################################################################
+# query git for year of last change
+################################################################################
+
+GIT_LOG_CMD = "git log --pretty=format:%%ai %s"
+
+def call_git_log(filename):
+ out = subprocess.check_output((GIT_LOG_CMD % filename).split(' '))
+ return out.decode("utf-8").split('\n')
+
+def get_git_change_years(filename):
+ git_log_lines = call_git_log(filename)
+ if len(git_log_lines) == 0:
+ return [datetime.date.today().year]
+ # timestamp is in ISO 8601 format. e.g. "2016-09-05 14:25:32 -0600"
+ return [line.split(' ')[0].split('-')[0] for line in git_log_lines]
+
+def get_most_recent_git_change_year(filename):
+ return max(get_git_change_years(filename))
+
+################################################################################
+# read and write to file
+################################################################################
+
+def read_file_lines(filename):
+ f = open(filename, 'r', encoding="utf8")
+ file_lines = f.readlines()
+ f.close()
+ return file_lines
+
+def write_file_lines(filename, file_lines):
+ f = open(filename, 'w', encoding="utf8")
+ f.write(''.join(file_lines))
+ f.close()
+
+################################################################################
+# update header years execution
+################################################################################
+
+COPYRIGHT = 'Copyright \(c\)'
+YEAR = "20[0-9][0-9]"
+YEAR_RANGE = '(%s)(-%s)?' % (YEAR, YEAR)
+HOLDER = 'The PRivaCY Coin Developers'
+UPDATEABLE_LINE_COMPILED = re.compile(' '.join([COPYRIGHT, YEAR_RANGE, HOLDER]))
+
+def get_updatable_copyright_line(file_lines):
+ index = 0
+ for line in file_lines:
+ if UPDATEABLE_LINE_COMPILED.search(line) is not None:
+ return index, line
+ index = index + 1
+ return None, None
+
+def parse_year_range(year_range):
+ year_split = year_range.split('-')
+ start_year = year_split[0]
+ if len(year_split) == 1:
+ return start_year, start_year
+ return start_year, year_split[1]
+
+def year_range_to_str(start_year, end_year):
+ if start_year == end_year:
+ return start_year
+ return "%s-%s" % (start_year, end_year)
+
+def create_updated_copyright_line(line, last_git_change_year):
+ copyright_splitter = 'Copyright (c) '
+ copyright_split = line.split(copyright_splitter)
+ # Preserve characters on line that are ahead of the start of the copyright
+ # notice - they are part of the comment block and vary from file-to-file.
+ before_copyright = copyright_split[0]
+ after_copyright = copyright_split[1]
+
+ space_split = after_copyright.split(' ')
+ year_range = space_split[0]
+ start_year, end_year = parse_year_range(year_range)
+ if end_year == last_git_change_year:
+ return line
+ return (before_copyright + copyright_splitter +
+ year_range_to_str(start_year, last_git_change_year) + ' ' +
+ ' '.join(space_split[1:]))
+
+def update_updatable_copyright(filename):
+ file_lines = read_file_lines(filename)
+ index, line = get_updatable_copyright_line(file_lines)
+ if not line:
+ print_file_action_message(filename, "No updatable copyright.")
+ return
+ last_git_change_year = get_most_recent_git_change_year(filename)
+ new_line = create_updated_copyright_line(line, last_git_change_year)
+ if line == new_line:
+ print_file_action_message(filename, "Copyright up-to-date.")
+ return
+ file_lines[index] = new_line
+ write_file_lines(filename, file_lines)
+ print_file_action_message(filename,
+ "Copyright updated! -> %s" % last_git_change_year)
+
+def exec_update_header_year(base_directory):
+ for filename in get_filenames_to_examine(base_directory):
+ update_updatable_copyright(filename)
+
+################################################################################
+# update cmd
+################################################################################
+
+UPDATE_USAGE = """
+Updates all the copyright headers of "The PRivaCY Coin Developers" which were
+changed in a year more recent than is listed. For example:
+
+// Copyright (c) - The PRivaCY Coin Developers
+
+will be updated to:
+
+// Copyright (c) - The PRivaCY Coin Developers
+
+where is obtained from the 'git log' history.
+
+This subcommand also handles copyright headers that have only a single year. In those cases:
+
+// Copyright (c) The PRivaCY Coin Developers
+
+will be updated to:
+
+// Copyright (c) - The PRivaCY Coin Developers
+
+where the update is appropriate.
+
+Usage:
+ $ ./copyright_header.py update
+
+Arguments:
+ - The base directory of a prcycoin source code repository.
+"""
+
+def print_file_action_message(filename, action):
+ print("%-52s %s" % (filename, action))
+
+def update_cmd(argv):
+ if len(argv) != 3:
+ sys.exit(UPDATE_USAGE)
+
+ base_directory = argv[2]
+ if not os.path.exists(base_directory):
+ sys.exit("*** bad base_directory: %s" % base_directory)
+ exec_update_header_year(base_directory)
+
+################################################################################
+# inserted copyright header format
+################################################################################
+
+def get_header_lines(header, start_year, end_year):
+ lines = header.split('\n')[1:-1]
+ lines[0] = lines[0] % year_range_to_str(start_year, end_year)
+ return [line + '\n' for line in lines]
+
+CPP_HEADER = '''
+// Copyright (c) %s The PRivaCY Coin Developers
+// Distributed under the MIT software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+'''
+
+def get_cpp_header_lines_to_insert(start_year, end_year):
+ return reversed(get_header_lines(CPP_HEADER, start_year, end_year))
+
+PYTHON_HEADER = '''
+# Copyright (c) %s The PRivaCY Coin Developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or http://www.opensource.org/licenses/mit-license.php.
+'''
+
+def get_python_header_lines_to_insert(start_year, end_year):
+ return reversed(get_header_lines(PYTHON_HEADER, start_year, end_year))
+
+################################################################################
+# query git for year of last change
+################################################################################
+
+def get_git_change_year_range(filename):
+ years = get_git_change_years(filename)
+ return min(years), max(years)
+
+################################################################################
+# check for existing core copyright
+################################################################################
+
+def file_already_has_core_copyright(file_lines):
+ index, _ = get_updatable_copyright_line(file_lines)
+ return index is not None
+
+################################################################################
+# insert header execution
+################################################################################
+
+def file_has_hashbang(file_lines):
+ if len(file_lines) < 1:
+ return False
+ if len(file_lines[0]) <= 2:
+ return False
+ return file_lines[0][:2] == '#!'
+
+def insert_python_header(filename, file_lines, start_year, end_year):
+ if file_has_hashbang(file_lines):
+ insert_idx = 1
+ else:
+ insert_idx = 0
+ header_lines = get_python_header_lines_to_insert(start_year, end_year)
+ for line in header_lines:
+ file_lines.insert(insert_idx, line)
+ write_file_lines(filename, file_lines)
+
+def insert_cpp_header(filename, file_lines, start_year, end_year):
+ header_lines = get_cpp_header_lines_to_insert(start_year, end_year)
+ for line in header_lines:
+ file_lines.insert(0, line)
+ write_file_lines(filename, file_lines)
+
+def exec_insert_header(filename, style):
+ file_lines = read_file_lines(filename)
+ if file_already_has_core_copyright(file_lines):
+ sys.exit('*** %s already has a copyright by The PRivaCY Coin Developers'
+ % (filename))
+ start_year, end_year = get_git_change_year_range(filename)
+ if style == 'python':
+ insert_python_header(filename, file_lines, start_year, end_year)
+ else:
+ insert_cpp_header(filename, file_lines, start_year, end_year)
+
+################################################################################
+# insert cmd
+################################################################################
+
+INSERT_USAGE = """
+Inserts a copyright header for "The PRivaCY Coin Developers" at the top of the
+file in either Python or C++ style as determined by the file extension. If the
+file is a Python file and it has a '#!' starting the first line, the header is
+inserted in the line below it.
+
+The copyright dates will be set to be:
+
+"-"
+
+where is according to the 'git log' history. If
+ is equal to , the date will be set to be:
+
+""
+
+If the file already has a copyright for "The PRivaCY Coin Developers", the
+script will exit.
+
+Usage:
+ $ ./copyright_header.py insert