From 12ac47dfc57983d6383b87111a5d3d683681781a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Bylica?= Date: Sun, 23 Apr 2017 13:11:16 +0200 Subject: [PATCH 1/2] Travis CI --- .travis.yml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 000000000..c97fdb993 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,20 @@ +language: cpp +branches: + only: + - master +matrix: + include: + - os: linux + dist: trusty + sudo: required + - os: osx + osx_image: xcode8.3 +cache: + ccache: true +install: + - if [ "$TRAVIS_OS_NAME" = "linux" ]; then sudo add-apt-repository -y ppa:ethereum/ethereum; sudo apt-get update; sudo apt-get install -y --no-install-recommends --allow-unauthenticated libjson-rpc-cpp-dev libjsoncpp-dev libboost-all-dev libcurl4-openssl-dev libmicrohttpd-dev mesa-common-dev ocl-icd-libopencl1 opencl-headers; fi + - if [ "$TRAVIS_OS_NAME" = "osx" ]; then brew install libjson-rpc-cpp jsoncpp; fi +script: + - cmake -DETHASHCUDA=Off -DETHSTRATUM=On -DETHASHCL=On -H. -Bbuild + - cmake --build build + - build/ethminer/ethminer --list-devices -G \ No newline at end of file From 054981020ed2f4c187eb4b994963892989ad75a7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Bylica?= Date: Sun, 23 Apr 2017 16:03:15 +0200 Subject: [PATCH 2/2] Fix compilation with clang --- libethcore/BlockInfo.h | 2 -- libethcore/EthashGPUMiner.cpp | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/libethcore/BlockInfo.h b/libethcore/BlockInfo.h index adddf0f3c..93ffac14c 100644 --- a/libethcore/BlockInfo.h +++ b/libethcore/BlockInfo.h @@ -188,8 +188,6 @@ template class BlockHeaderPolished: public BlockInfoSub { public: - static const unsigned Fields = BlockInfoSub::BasicFields + BlockInfoSub::SealFields; - BlockHeaderPolished() {} BlockHeaderPolished(BlockInfo const& _bi): BlockInfoSub(_bi) {} explicit BlockHeaderPolished(bytes const& _data, Strictness _s = IgnoreSeal, h256 const& _h = h256(), BlockDataType _bdt = BlockData) { populate(&_data, _s, _h, _bdt); } diff --git a/libethcore/EthashGPUMiner.cpp b/libethcore/EthashGPUMiner.cpp index 9f2c7b2ba..aa6f4adda 100644 --- a/libethcore/EthashGPUMiner.cpp +++ b/libethcore/EthashGPUMiner.cpp @@ -183,7 +183,7 @@ void EthashGPUMiner::workLoop() } uint64_t upper64OfBoundary = (uint64_t)(u64)((u256)w.boundary >> 192); - uint64_t startN; + uint64_t startN = 0; if (w.exSizeBits >= 0) startN = w.startNonce | ((uint64_t)index() << (64 - 4 - w.exSizeBits)); // this can support up to 16 devices m_miner->search(w.headerHash.data(), upper64OfBoundary, *m_hook, (w.exSizeBits >= 0), startN);