93
Makefile.am
93
Makefile.am
@@ -39,11 +39,20 @@ OSX_PACKAGING = $(OSX_DEPLOY_SCRIPT) $(OSX_FANCY_PLIST) $(OSX_INSTALLER_ICONS) $
|
|||||||
$(top_srcdir)/contrib/macdeploy/detached-sig-apply.sh \
|
$(top_srcdir)/contrib/macdeploy/detached-sig-apply.sh \
|
||||||
$(top_srcdir)/contrib/macdeploy/detached-sig-create.sh
|
$(top_srcdir)/contrib/macdeploy/detached-sig-create.sh
|
||||||
|
|
||||||
|
|
||||||
|
if BUILD_DARWIN
|
||||||
|
COVERAGE_INFO = baseline_filtered_combined.info baseline.info block_test.info \
|
||||||
|
leveldb_baseline.info test_bitcoin_filtered.info total_coverage.info \
|
||||||
|
baseline_filtered.info block_test_filtered.info \
|
||||||
|
leveldb_baseline_filtered.info test_bitcoin_coverage.info test_bitcoin.info
|
||||||
|
# zcash-gtest.info zcash-gtest_filtered.info zcash-gtest_coverage.info
|
||||||
|
else
|
||||||
COVERAGE_INFO = baseline_filtered_combined.info baseline.info block_test.info \
|
COVERAGE_INFO = baseline_filtered_combined.info baseline.info block_test.info \
|
||||||
leveldb_baseline.info test_bitcoin_filtered.info total_coverage.info \
|
leveldb_baseline.info test_bitcoin_filtered.info total_coverage.info \
|
||||||
baseline_filtered.info block_test_filtered.info \
|
baseline_filtered.info block_test_filtered.info \
|
||||||
leveldb_baseline_filtered.info test_bitcoin_coverage.info test_bitcoin.info \
|
leveldb_baseline_filtered.info test_bitcoin_coverage.info test_bitcoin.info \
|
||||||
zcash-gtest.info zcash-gtest_filtered.info zcash-gtest_coverage.info
|
zcash-gtest.info zcash-gtest_filtered.info zcash-gtest_coverage.info
|
||||||
|
endif
|
||||||
|
|
||||||
dist-hook:
|
dist-hook:
|
||||||
-$(MAKE) -C $(top_distdir)/src/leveldb clean
|
-$(MAKE) -C $(top_distdir)/src/leveldb clean
|
||||||
@@ -150,6 +159,15 @@ if USE_LCOV
|
|||||||
baseline.info:
|
baseline.info:
|
||||||
$(LCOV) -c -i -d $(abs_builddir)/src -o $@
|
$(LCOV) -c -i -d $(abs_builddir)/src -o $@
|
||||||
|
|
||||||
|
if BUILD_DARWIN
|
||||||
|
baseline_filtered.info: baseline.info
|
||||||
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
|
||||||
|
"$(abs_builddir)/src/test/*" \
|
||||||
|
-o $@
|
||||||
|
else
|
||||||
baseline_filtered.info: baseline.info
|
baseline_filtered.info: baseline.info
|
||||||
$(LCOV) -r $< "/usr/include/*" \
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
@@ -159,10 +177,20 @@ baseline_filtered.info: baseline.info
|
|||||||
"$(abs_builddir)/src/gtest/*" \
|
"$(abs_builddir)/src/gtest/*" \
|
||||||
"$(abs_builddir)/src/test/*" \
|
"$(abs_builddir)/src/test/*" \
|
||||||
-o $@
|
-o $@
|
||||||
|
endif
|
||||||
|
|
||||||
leveldb_baseline.info: baseline_filtered.info
|
leveldb_baseline.info: baseline_filtered.info
|
||||||
$(LCOV) -c -i -d $(abs_builddir)/src/leveldb -b $(abs_builddir)/src/leveldb -o $@
|
$(LCOV) -c -i -d $(abs_builddir)/src/leveldb -b $(abs_builddir)/src/leveldb -o $@
|
||||||
|
|
||||||
|
if BUILD_DARWIN
|
||||||
|
leveldb_baseline_filtered.info: leveldb_baseline.info
|
||||||
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
|
||||||
|
"$(abs_builddir)/src/test/*" \
|
||||||
|
-o $@
|
||||||
|
else
|
||||||
leveldb_baseline_filtered.info: leveldb_baseline.info
|
leveldb_baseline_filtered.info: leveldb_baseline.info
|
||||||
$(LCOV) -r $< "/usr/include/*" \
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
@@ -172,6 +200,7 @@ leveldb_baseline_filtered.info: leveldb_baseline.info
|
|||||||
"$(abs_builddir)/src/gtest/*" \
|
"$(abs_builddir)/src/gtest/*" \
|
||||||
"$(abs_builddir)/src/test/*" \
|
"$(abs_builddir)/src/test/*" \
|
||||||
-o $@
|
-o $@
|
||||||
|
endif
|
||||||
|
|
||||||
baseline_filtered_combined.info: leveldb_baseline_filtered.info baseline_filtered.info
|
baseline_filtered_combined.info: leveldb_baseline_filtered.info baseline_filtered.info
|
||||||
$(LCOV) -a leveldb_baseline_filtered.info -a baseline_filtered.info -o $@
|
$(LCOV) -a leveldb_baseline_filtered.info -a baseline_filtered.info -o $@
|
||||||
@@ -182,6 +211,15 @@ test_bitcoin.info: baseline_filtered_combined.info
|
|||||||
$(LCOV) -z -d $(abs_builddir)/src
|
$(LCOV) -z -d $(abs_builddir)/src
|
||||||
$(LCOV) -z -d $(abs_builddir)/src/leveldb
|
$(LCOV) -z -d $(abs_builddir)/src/leveldb
|
||||||
|
|
||||||
|
if BUILD_DARWIN
|
||||||
|
test_bitcoin_filtered.info: test_bitcoin.info
|
||||||
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
|
||||||
|
"$(abs_builddir)/src/test/*" \
|
||||||
|
-o $@
|
||||||
|
else
|
||||||
test_bitcoin_filtered.info: test_bitcoin.info
|
test_bitcoin_filtered.info: test_bitcoin.info
|
||||||
$(LCOV) -r $< "/usr/include/*" \
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
@@ -191,22 +229,7 @@ test_bitcoin_filtered.info: test_bitcoin.info
|
|||||||
"$(abs_builddir)/src/gtest/*" \
|
"$(abs_builddir)/src/gtest/*" \
|
||||||
"$(abs_builddir)/src/test/*" \
|
"$(abs_builddir)/src/test/*" \
|
||||||
-o $@
|
-o $@
|
||||||
|
endif
|
||||||
zcash-gtest.info: baseline_filtered_combined.info
|
|
||||||
$(MAKE) -C src/ zcash-gtest_check
|
|
||||||
$(LCOV) -c -d $(abs_builddir)/src -t zcash-gtest -o $@
|
|
||||||
$(LCOV) -z -d $(abs_builddir)/src
|
|
||||||
$(LCOV) -z -d $(abs_builddir)/src/leveldb
|
|
||||||
|
|
||||||
zcash-gtest_filtered.info: zcash-gtest.info
|
|
||||||
$(LCOV) -r $< "/usr/include/*" \
|
|
||||||
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
|
||||||
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
|
|
||||||
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
|
|
||||||
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gtest/*" \
|
|
||||||
"$(abs_builddir)/src/gtest/*" \
|
|
||||||
"$(abs_builddir)/src/test/*" \
|
|
||||||
-o $@
|
|
||||||
|
|
||||||
block_test.info: test_bitcoin_filtered.info
|
block_test.info: test_bitcoin_filtered.info
|
||||||
$(MKDIR_P) qa/tmp
|
$(MKDIR_P) qa/tmp
|
||||||
@@ -215,6 +238,15 @@ block_test.info: test_bitcoin_filtered.info
|
|||||||
$(LCOV) -z -d $(abs_builddir)/src
|
$(LCOV) -z -d $(abs_builddir)/src
|
||||||
$(LCOV) -z -d $(abs_builddir)/src/leveldb
|
$(LCOV) -z -d $(abs_builddir)/src/leveldb
|
||||||
|
|
||||||
|
if BUILD_DARWIN
|
||||||
|
block_test_filtered.info: block_test.info
|
||||||
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
|
||||||
|
"$(abs_builddir)/src/test/*" \
|
||||||
|
-o $@
|
||||||
|
else
|
||||||
block_test_filtered.info: block_test.info
|
block_test_filtered.info: block_test.info
|
||||||
$(LCOV) -r $< "/usr/include/*" \
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
@@ -224,31 +256,38 @@ block_test_filtered.info: block_test.info
|
|||||||
"$(abs_builddir)/src/gtest/*" \
|
"$(abs_builddir)/src/gtest/*" \
|
||||||
"$(abs_builddir)/src/test/*" \
|
"$(abs_builddir)/src/test/*" \
|
||||||
-o $@
|
-o $@
|
||||||
|
endif
|
||||||
|
|
||||||
test_bitcoin_coverage.info: baseline_filtered_combined.info test_bitcoin_filtered.info
|
test_bitcoin_coverage.info: baseline_filtered_combined.info test_bitcoin_filtered.info
|
||||||
$(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_bitcoin_filtered.info -o $@
|
$(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_bitcoin_filtered.info -o $@
|
||||||
|
|
||||||
|
if ! BUILD_DARWIN
|
||||||
zcash-gtest_coverage.info: baseline_filtered_combined.info zcash-gtest_filtered.info
|
zcash-gtest_coverage.info: baseline_filtered_combined.info zcash-gtest_filtered.info
|
||||||
$(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a zcash-gtest_filtered.info -o $@
|
$(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a zcash-gtest_filtered.info -o $@
|
||||||
|
endif
|
||||||
|
|
||||||
|
if BUILD_DARWIN
|
||||||
|
total_coverage.info: baseline_filtered_combined.info test_bitcoin_filtered.info block_test_filtered.info
|
||||||
|
$(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_bitcoin_filtered.info -a block_test_filtered.info -o $@ | $(GREP) "\%" | $(AWK) '{ print substr($$3,2,50) "/" $$5 }' > coverage_percent.txt
|
||||||
|
else
|
||||||
total_coverage.info: baseline_filtered_combined.info test_bitcoin_filtered.info zcash-gtest_filtered.info block_test_filtered.info
|
total_coverage.info: baseline_filtered_combined.info test_bitcoin_filtered.info zcash-gtest_filtered.info block_test_filtered.info
|
||||||
$(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_bitcoin_filtered.info -a zcash-gtest_filtered.info -a block_test_filtered.info -o $@ | $(GREP) "\%" | $(AWK) '{ print substr($$3,2,50) "/" $$5 }' > coverage_percent.txt
|
$(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_bitcoin_filtered.info -a zcash-gtest_filtered.info -a block_test_filtered.info -o $@ | $(GREP) "\%" | $(AWK) '{ print substr($$3,2,50) "/" $$5 }' > coverage_percent.txt
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
test_bitcoin.coverage/.dirstamp: test_bitcoin_coverage.info
|
test_bitcoin.coverage/.dirstamp: test_bitcoin_coverage.info
|
||||||
$(GENHTML) -s $< -o $(@D)
|
$(GENHTML) -s $< -o $(@D)
|
||||||
@touch $@
|
@touch $@
|
||||||
|
|
||||||
zcash-gtest.coverage/.dirstamp: zcash-gtest_coverage.info
|
|
||||||
$(GENHTML) -s $< -o $(@D)
|
|
||||||
@touch $@
|
|
||||||
|
|
||||||
cov-zcash: zcash-gtest.coverage/.dirstamp
|
|
||||||
|
|
||||||
total.coverage/.dirstamp: total_coverage.info
|
total.coverage/.dirstamp: total_coverage.info
|
||||||
$(GENHTML) -s $< -o $(@D)
|
$(GENHTML) -s $< -o $(@D)
|
||||||
@touch $@
|
@touch $@
|
||||||
|
|
||||||
|
if BUILD_DARWIN
|
||||||
|
cov: test_bitcoin.coverage/.dirstamp total.coverage/.dirstamp
|
||||||
|
else
|
||||||
cov: test_bitcoin.coverage/.dirstamp cov-zcash total.coverage/.dirstamp
|
cov: test_bitcoin.coverage/.dirstamp cov-zcash total.coverage/.dirstamp
|
||||||
|
endif
|
||||||
|
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|||||||
218
Makefile.am.patch
Normal file
218
Makefile.am.patch
Normal file
@@ -0,0 +1,218 @@
|
|||||||
|
*** Makefile.am 2017-01-03 10:53:52.436371005 +0000
|
||||||
|
--- ../../komodo-jl777/Makefile.am 2017-01-03 09:49:08.848505929 +0000
|
||||||
|
***************
|
||||||
|
*** 39,58 ****
|
||||||
|
$(top_srcdir)/contrib/macdeploy/detached-sig-apply.sh \
|
||||||
|
$(top_srcdir)/contrib/macdeploy/detached-sig-create.sh
|
||||||
|
|
||||||
|
-
|
||||||
|
- if BUILD_DARWIN
|
||||||
|
- COVERAGE_INFO = baseline_filtered_combined.info baseline.info block_test.info \
|
||||||
|
- leveldb_baseline.info test_bitcoin_filtered.info total_coverage.info \
|
||||||
|
- baseline_filtered.info block_test_filtered.info \
|
||||||
|
- leveldb_baseline_filtered.info test_bitcoin_coverage.info test_bitcoin.info
|
||||||
|
- # zcash-gtest.info zcash-gtest_filtered.info zcash-gtest_coverage.info
|
||||||
|
- else
|
||||||
|
COVERAGE_INFO = baseline_filtered_combined.info baseline.info block_test.info \
|
||||||
|
leveldb_baseline.info test_bitcoin_filtered.info total_coverage.info \
|
||||||
|
baseline_filtered.info block_test_filtered.info \
|
||||||
|
leveldb_baseline_filtered.info test_bitcoin_coverage.info test_bitcoin.info \
|
||||||
|
zcash-gtest.info zcash-gtest_filtered.info zcash-gtest_coverage.info
|
||||||
|
- endif
|
||||||
|
|
||||||
|
dist-hook:
|
||||||
|
-$(MAKE) -C $(top_distdir)/src/leveldb clean
|
||||||
|
--- 39,49 ----
|
||||||
|
***************
|
||||||
|
*** 159,173 ****
|
||||||
|
baseline.info:
|
||||||
|
$(LCOV) -c -i -d $(abs_builddir)/src -o $@
|
||||||
|
|
||||||
|
- if BUILD_DARWIN
|
||||||
|
- baseline_filtered.info: baseline.info
|
||||||
|
- $(LCOV) -r $< "/usr/include/*" \
|
||||||
|
- "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
- "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
|
||||||
|
- "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
|
||||||
|
- "$(abs_builddir)/src/test/*" \
|
||||||
|
- -o $@
|
||||||
|
- else
|
||||||
|
baseline_filtered.info: baseline.info
|
||||||
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
--- 150,155 ----
|
||||||
|
***************
|
||||||
|
*** 177,196 ****
|
||||||
|
"$(abs_builddir)/src/gtest/*" \
|
||||||
|
"$(abs_builddir)/src/test/*" \
|
||||||
|
-o $@
|
||||||
|
- endif
|
||||||
|
|
||||||
|
leveldb_baseline.info: baseline_filtered.info
|
||||||
|
$(LCOV) -c -i -d $(abs_builddir)/src/leveldb -b $(abs_builddir)/src/leveldb -o $@
|
||||||
|
|
||||||
|
- if BUILD_DARWIN
|
||||||
|
- leveldb_baseline_filtered.info: leveldb_baseline.info
|
||||||
|
- $(LCOV) -r $< "/usr/include/*" \
|
||||||
|
- "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
- "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
|
||||||
|
- "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
|
||||||
|
- "$(abs_builddir)/src/test/*" \
|
||||||
|
- -o $@
|
||||||
|
- else
|
||||||
|
leveldb_baseline_filtered.info: leveldb_baseline.info
|
||||||
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
--- 159,168 ----
|
||||||
|
***************
|
||||||
|
*** 200,206 ****
|
||||||
|
"$(abs_builddir)/src/gtest/*" \
|
||||||
|
"$(abs_builddir)/src/test/*" \
|
||||||
|
-o $@
|
||||||
|
- endif
|
||||||
|
|
||||||
|
baseline_filtered_combined.info: leveldb_baseline_filtered.info baseline_filtered.info
|
||||||
|
$(LCOV) -a leveldb_baseline_filtered.info -a baseline_filtered.info -o $@
|
||||||
|
--- 172,177 ----
|
||||||
|
***************
|
||||||
|
*** 211,226 ****
|
||||||
|
$(LCOV) -z -d $(abs_builddir)/src
|
||||||
|
$(LCOV) -z -d $(abs_builddir)/src/leveldb
|
||||||
|
|
||||||
|
- if BUILD_DARWIN
|
||||||
|
test_bitcoin_filtered.info: test_bitcoin.info
|
||||||
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
|
||||||
|
"$(abs_builddir)/src/test/*" \
|
||||||
|
-o $@
|
||||||
|
! else
|
||||||
|
! test_bitcoin_filtered.info: test_bitcoin.info
|
||||||
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
|
||||||
|
--- 182,204 ----
|
||||||
|
$(LCOV) -z -d $(abs_builddir)/src
|
||||||
|
$(LCOV) -z -d $(abs_builddir)/src/leveldb
|
||||||
|
|
||||||
|
test_bitcoin_filtered.info: test_bitcoin.info
|
||||||
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
|
||||||
|
+ "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gtest/*" \
|
||||||
|
+ "$(abs_builddir)/src/gtest/*" \
|
||||||
|
"$(abs_builddir)/src/test/*" \
|
||||||
|
-o $@
|
||||||
|
!
|
||||||
|
! zcash-gtest.info: baseline_filtered_combined.info
|
||||||
|
! $(MAKE) -C src/ zcash-gtest_check
|
||||||
|
! $(LCOV) -c -d $(abs_builddir)/src -t zcash-gtest -o $@
|
||||||
|
! $(LCOV) -z -d $(abs_builddir)/src
|
||||||
|
! $(LCOV) -z -d $(abs_builddir)/src/leveldb
|
||||||
|
!
|
||||||
|
! zcash-gtest_filtered.info: zcash-gtest.info
|
||||||
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
|
||||||
|
***************
|
||||||
|
*** 229,235 ****
|
||||||
|
"$(abs_builddir)/src/gtest/*" \
|
||||||
|
"$(abs_builddir)/src/test/*" \
|
||||||
|
-o $@
|
||||||
|
- endif
|
||||||
|
|
||||||
|
block_test.info: test_bitcoin_filtered.info
|
||||||
|
$(MKDIR_P) qa/tmp
|
||||||
|
--- 207,212 ----
|
||||||
|
***************
|
||||||
|
*** 238,252 ****
|
||||||
|
$(LCOV) -z -d $(abs_builddir)/src
|
||||||
|
$(LCOV) -z -d $(abs_builddir)/src/leveldb
|
||||||
|
|
||||||
|
- if BUILD_DARWIN
|
||||||
|
- block_test_filtered.info: block_test.info
|
||||||
|
- $(LCOV) -r $< "/usr/include/*" \
|
||||||
|
- "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
- "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
|
||||||
|
- "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
|
||||||
|
- "$(abs_builddir)/src/test/*" \
|
||||||
|
- -o $@
|
||||||
|
- else
|
||||||
|
block_test_filtered.info: block_test.info
|
||||||
|
$(LCOV) -r $< "/usr/include/*" \
|
||||||
|
"$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
|
||||||
|
--- 215,220 ----
|
||||||
|
***************
|
||||||
|
*** 256,293 ****
|
||||||
|
"$(abs_builddir)/src/gtest/*" \
|
||||||
|
"$(abs_builddir)/src/test/*" \
|
||||||
|
-o $@
|
||||||
|
- endif
|
||||||
|
|
||||||
|
test_bitcoin_coverage.info: baseline_filtered_combined.info test_bitcoin_filtered.info
|
||||||
|
! $(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_bitcoin_filtered.info -o $@
|
||||||
|
|
||||||
|
- if ! BUILD_DARWIN
|
||||||
|
zcash-gtest_coverage.info: baseline_filtered_combined.info zcash-gtest_filtered.info
|
||||||
|
$(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a zcash-gtest_filtered.info -o $@
|
||||||
|
- endif
|
||||||
|
|
||||||
|
- if BUILD_DARWIN
|
||||||
|
- total_coverage.info: baseline_filtered_combined.info test_bitcoin_filtered.info block_test_filtered.info
|
||||||
|
- $(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_bitcoin_filtered.info -a block_test_filtered.info -o $@ | $(GREP) "\%" | $(AWK) '{ print substr($$3,2,50) "/" $$5 }' > coverage_percent.txt
|
||||||
|
- else
|
||||||
|
total_coverage.info: baseline_filtered_combined.info test_bitcoin_filtered.info zcash-gtest_filtered.info block_test_filtered.info
|
||||||
|
$(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_bitcoin_filtered.info -a zcash-gtest_filtered.info -a block_test_filtered.info -o $@ | $(GREP) "\%" | $(AWK) '{ print substr($$3,2,50) "/" $$5 }' > coverage_percent.txt
|
||||||
|
- endif
|
||||||
|
-
|
||||||
|
|
||||||
|
test_bitcoin.coverage/.dirstamp: test_bitcoin_coverage.info
|
||||||
|
! $(GENHTML) -s $< -o $(@D)
|
||||||
|
! @touch $@
|
||||||
|
|
||||||
|
total.coverage/.dirstamp: total_coverage.info
|
||||||
|
! $(GENHTML) -s $< -o $(@D)
|
||||||
|
! @touch $@
|
||||||
|
|
||||||
|
- if BUILD_DARWIN
|
||||||
|
- cov: test_bitcoin.coverage/.dirstamp total.coverage/.dirstamp
|
||||||
|
- else
|
||||||
|
cov: test_bitcoin.coverage/.dirstamp cov-zcash total.coverage/.dirstamp
|
||||||
|
- endif
|
||||||
|
|
||||||
|
endif
|
||||||
|
|
||||||
|
--- 224,254 ----
|
||||||
|
"$(abs_builddir)/src/gtest/*" \
|
||||||
|
"$(abs_builddir)/src/test/*" \
|
||||||
|
-o $@
|
||||||
|
|
||||||
|
test_bitcoin_coverage.info: baseline_filtered_combined.info test_bitcoin_filtered.info
|
||||||
|
! $(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_bitcoin_filtered.info -o $@
|
||||||
|
|
||||||
|
zcash-gtest_coverage.info: baseline_filtered_combined.info zcash-gtest_filtered.info
|
||||||
|
$(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a zcash-gtest_filtered.info -o $@
|
||||||
|
|
||||||
|
total_coverage.info: baseline_filtered_combined.info test_bitcoin_filtered.info zcash-gtest_filtered.info block_test_filtered.info
|
||||||
|
$(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_bitcoin_filtered.info -a zcash-gtest_filtered.info -a block_test_filtered.info -o $@ | $(GREP) "\%" | $(AWK) '{ print substr($$3,2,50) "/" $$5 }' > coverage_percent.txt
|
||||||
|
|
||||||
|
test_bitcoin.coverage/.dirstamp: test_bitcoin_coverage.info
|
||||||
|
! $(GENHTML) -s $< -o $(@D)
|
||||||
|
! @touch $@
|
||||||
|
!
|
||||||
|
! zcash-gtest.coverage/.dirstamp: zcash-gtest_coverage.info
|
||||||
|
! $(GENHTML) -s $< -o $(@D)
|
||||||
|
! @touch $@
|
||||||
|
!
|
||||||
|
! cov-zcash: zcash-gtest.coverage/.dirstamp
|
||||||
|
|
||||||
|
total.coverage/.dirstamp: total_coverage.info
|
||||||
|
! $(GENHTML) -s $< -o $(@D)
|
||||||
|
! @touch $@
|
||||||
|
|
||||||
|
cov: test_bitcoin.coverage/.dirstamp cov-zcash total.coverage/.dirstamp
|
||||||
|
|
||||||
|
endif
|
||||||
|
|
||||||
32
README-mac.md
Normal file
32
README-mac.md
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
First off you need Apple's Xcode (at least version 7, preferably 8.x) and the Xcode Command Line Tools:
|
||||||
|
|
||||||
|
https://itunes.apple.com/us/app/xcode/id497799835?mt=12
|
||||||
|
|
||||||
|
And Homebrew:
|
||||||
|
|
||||||
|
http://brew.sh/
|
||||||
|
|
||||||
|
And this is the list of brew packages you'll need installed:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
brew tap discoteq/discoteq; brew install flock
|
||||||
|
brew install autoconf autogen automake
|
||||||
|
brew tap homebrew/versions; brew install homebrew/versions/gcc5
|
||||||
|
brew install binutils
|
||||||
|
brew install protobuf
|
||||||
|
brew install coreutils
|
||||||
|
brew install wget
|
||||||
|
```
|
||||||
|
|
||||||
|
Get all that installed, then run:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
git clone https://github.com/j-cimb-barker/komodo.git
|
||||||
|
cd komodo
|
||||||
|
git checkout dev
|
||||||
|
./zcutil/build-mac.sh
|
||||||
|
```
|
||||||
|
When you are done building, you need to do a few things in the [Configuration](https://github.com/zcash/zcash/wiki/1.0-User-Guide#configuration) section of the Zcash User Guide differently because we are on the Mac. All instances of `~/.zcash` need to be replaced by `~/Library/Application\ Support/Zcash`
|
||||||
|
The fetch-params.sh script, however, has already been altered to fetch the proving keys into the correct directory to conform to Mac specific naming conventions.
|
||||||
|
|
||||||
|
Happy Building
|
||||||
55
boost.mk.patch
Normal file
55
boost.mk.patch
Normal file
@@ -0,0 +1,55 @@
|
|||||||
|
*** depends/packages/boost.mk 2017-01-03 10:53:52.440371182 +0000
|
||||||
|
--- ../../komodo-jl777/depends/packages/boost.mk 2017-01-03 09:48:21.650035146 +0000
|
||||||
|
***************
|
||||||
|
*** 11,24 ****
|
||||||
|
$(package)_config_opts=--layout=tagged --build-type=complete --user-config=user-config.jam
|
||||||
|
$(package)_config_opts+=threading=multi link=static -sNO_BZIP2=1 -sNO_ZLIB=1
|
||||||
|
$(package)_config_opts_linux=threadapi=pthread runtime-link=shared
|
||||||
|
! $(package)_config_opts_darwin=--toolset=gcc threadapi=pthread runtime-link=shared
|
||||||
|
$(package)_config_opts_mingw32=binary-format=pe target-os=windows threadapi=win32 runtime-link=static
|
||||||
|
$(package)_config_opts_x86_64_mingw32=address-model=64
|
||||||
|
$(package)_config_opts_i686_mingw32=address-model=32
|
||||||
|
$(package)_config_opts_i686_linux=address-model=32 architecture=x86
|
||||||
|
$(package)_toolset_$(host_os)=gcc
|
||||||
|
$(package)_archiver_$(host_os)=$($(package)_ar)
|
||||||
|
! $(package)_toolset_darwin=gcc
|
||||||
|
$(package)_config_libraries=chrono,filesystem,program_options,system,thread,test
|
||||||
|
$(package)_cxxflags=-fvisibility=hidden
|
||||||
|
$(package)_cxxflags_linux=-fPIC
|
||||||
|
--- 11,25 ----
|
||||||
|
$(package)_config_opts=--layout=tagged --build-type=complete --user-config=user-config.jam
|
||||||
|
$(package)_config_opts+=threading=multi link=static -sNO_BZIP2=1 -sNO_ZLIB=1
|
||||||
|
$(package)_config_opts_linux=threadapi=pthread runtime-link=shared
|
||||||
|
! $(package)_config_opts_darwin=--toolset=darwin-4.2.1 runtime-link=shared
|
||||||
|
$(package)_config_opts_mingw32=binary-format=pe target-os=windows threadapi=win32 runtime-link=static
|
||||||
|
$(package)_config_opts_x86_64_mingw32=address-model=64
|
||||||
|
$(package)_config_opts_i686_mingw32=address-model=32
|
||||||
|
$(package)_config_opts_i686_linux=address-model=32 architecture=x86
|
||||||
|
$(package)_toolset_$(host_os)=gcc
|
||||||
|
$(package)_archiver_$(host_os)=$($(package)_ar)
|
||||||
|
! $(package)_toolset_darwin=darwin
|
||||||
|
! $(package)_archiver_darwin=$($(package)_libtool)
|
||||||
|
$(package)_config_libraries=chrono,filesystem,program_options,system,thread,test
|
||||||
|
$(package)_cxxflags=-fvisibility=hidden
|
||||||
|
$(package)_cxxflags_linux=-fPIC
|
||||||
|
***************
|
||||||
|
*** 35,43 ****
|
||||||
|
endef
|
||||||
|
|
||||||
|
define $(package)_build_cmds
|
||||||
|
! ./b2 -d2 -j2 -d1 --prefix=$($(package)_staging_prefix_dir) $($(package)_config_opts) cxxflags=-std=c++11 stage
|
||||||
|
endef
|
||||||
|
|
||||||
|
define $(package)_stage_cmds
|
||||||
|
! ./b2 -d0 -j4 --prefix=$($(package)_staging_prefix_dir) $($(package)_config_opts) cxxflags=-std=c++11 install
|
||||||
|
endef
|
||||||
|
--- 36,44 ----
|
||||||
|
endef
|
||||||
|
|
||||||
|
define $(package)_build_cmds
|
||||||
|
! ./b2 -d2 -j2 -d1 --prefix=$($(package)_staging_prefix_dir) $($(package)_config_opts) stage
|
||||||
|
endef
|
||||||
|
|
||||||
|
define $(package)_stage_cmds
|
||||||
|
! ./b2 -d0 -j4 --prefix=$($(package)_staging_prefix_dir) $($(package)_config_opts) install
|
||||||
|
endef
|
||||||
40
configure.ac
40
configure.ac
@@ -124,7 +124,7 @@ AC_ARG_ENABLE([hardening],
|
|||||||
[AS_HELP_STRING([--enable-hardening],
|
[AS_HELP_STRING([--enable-hardening],
|
||||||
[attempt to harden the resulting executables (default is yes)])],
|
[attempt to harden the resulting executables (default is yes)])],
|
||||||
[use_hardening=$enableval],
|
[use_hardening=$enableval],
|
||||||
[use_hardening=yes])
|
[use_hardening=no])
|
||||||
|
|
||||||
AC_ARG_ENABLE([reduce-exports],
|
AC_ARG_ENABLE([reduce-exports],
|
||||||
[AS_HELP_STRING([--enable-reduce-exports],
|
[AS_HELP_STRING([--enable-reduce-exports],
|
||||||
@@ -276,30 +276,30 @@ case $host in
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
AC_CHECK_PROG([BREW],brew, brew)
|
dnl AC_CHECK_PROG([BREW],brew, brew)
|
||||||
if test x$BREW = xbrew; then
|
dnl if test x$BREW = xbrew; then
|
||||||
dnl These Homebrew packages may be keg-only, meaning that they won't be found
|
dnl These Homebrew packages may be keg-only, meaning that they won't be found
|
||||||
dnl in expected paths because they may conflict with system files. Ask
|
dnl in expected paths because they may conflict with system files. Ask
|
||||||
dnl Homebrew where each one is located, then adjust paths accordingly.
|
dnl Homebrew where each one is located, then adjust paths accordingly.
|
||||||
dnl It's safe to add these paths even if the functionality is disabled by
|
dnl It's safe to add these paths even if the functionality is disabled by
|
||||||
dnl the user (--without-wallet or --without-gui for example).
|
dnl the user (--without-wallet or --without-gui for example).
|
||||||
|
|
||||||
openssl_prefix=`$BREW --prefix openssl 2>/dev/null`
|
dnl openssl_prefix=`$BREW --prefix openssl 2>/dev/null`
|
||||||
bdb_prefix=`$BREW --prefix berkeley-db4 2>/dev/null`
|
dnl bdb_prefix=`$BREW --prefix berkeley-db4 2>/dev/null`
|
||||||
qt5_prefix=`$BREW --prefix qt5 2>/dev/null`
|
dnl qt5_prefix=`$BREW --prefix qt5 2>/dev/null`
|
||||||
if test x$openssl_prefix != x; then
|
dnl if test x$openssl_prefix != x; then
|
||||||
PKG_CONFIG_PATH="$openssl_prefix/lib/pkgconfig:$PKG_CONFIG_PATH"
|
dnl PKG_CONFIG_PATH="$PKG_CONFIG_PATH"
|
||||||
export PKG_CONFIG_PATH
|
dnl export PKG_CONFIG_PATH
|
||||||
fi
|
dnl fi
|
||||||
if test x$bdb_prefix != x; then
|
dnl if test x$bdb_prefix != x; then
|
||||||
CPPFLAGS="$CPPFLAGS -I$bdb_prefix/include"
|
dnl CPPFLAGS="$CPPFLAGS -I$bdb_prefix/include"
|
||||||
LIBS="$LIBS -L$bdb_prefix/lib"
|
dnl LIBS="$LIBS -L$bdb_prefix/lib"
|
||||||
fi
|
dnl fi
|
||||||
if test x$qt5_prefix != x; then
|
dnl if test x$qt5_prefix != x; then
|
||||||
PKG_CONFIG_PATH="$qt5_prefix/lib/pkgconfig:$PKG_CONFIG_PATH"
|
dnl PKG_CONFIG_PATH="$qt5_prefix/lib/pkgconfig:$PKG_CONFIG_PATH"
|
||||||
export PKG_CONFIG_PATH
|
dnl export PKG_CONFIG_PATH
|
||||||
fi
|
dnl fi
|
||||||
fi
|
dnl fi
|
||||||
else
|
else
|
||||||
case $build_os in
|
case $build_os in
|
||||||
*darwin*)
|
*darwin*)
|
||||||
@@ -730,7 +730,7 @@ CPPFLAGS="-I$LIBSNARK_INCDIR $CPPFLAGS"
|
|||||||
AC_CHECK_HEADER([libsnark/gadgetlib1/gadget.hpp],,AC_MSG_ERROR(libsnark headers missing))
|
AC_CHECK_HEADER([libsnark/gadgetlib1/gadget.hpp],,AC_MSG_ERROR(libsnark headers missing))
|
||||||
AC_CHECK_LIB([snark],[main],LIBSNARK_LIBS=-lsnark, [AC_MSG_ERROR(libsnark missing)], [-lgmpxx])
|
AC_CHECK_LIB([snark],[main],LIBSNARK_LIBS=-lsnark, [AC_MSG_ERROR(libsnark missing)], [-lgmpxx])
|
||||||
|
|
||||||
LIBZCASH_LIBS="-lsnark -lgmp -lgmpxx -lboost_system-mt -lcrypto -lsodium -fopenmp"
|
LIBZCASH_LIBS="-lsnark -lgmp -lgmpxx -lboost_system-mt -lcrypto -lsodium"
|
||||||
|
|
||||||
CXXFLAGS_TEMP="$CXXFLAGS"
|
CXXFLAGS_TEMP="$CXXFLAGS"
|
||||||
LIBS_TEMP="$LIBS"
|
LIBS_TEMP="$LIBS"
|
||||||
|
|||||||
99
configure.ac.patch
Normal file
99
configure.ac.patch
Normal file
@@ -0,0 +1,99 @@
|
|||||||
|
*** configure.ac 2017-01-03 10:53:52.436371005 +0000
|
||||||
|
--- ../../komodo-jl777/configure.ac 2017-01-03 09:49:08.848505929 +0000
|
||||||
|
***************
|
||||||
|
*** 124,130 ****
|
||||||
|
[AS_HELP_STRING([--enable-hardening],
|
||||||
|
[attempt to harden the resulting executables (default is yes)])],
|
||||||
|
[use_hardening=$enableval],
|
||||||
|
! [use_hardening=no])
|
||||||
|
|
||||||
|
AC_ARG_ENABLE([reduce-exports],
|
||||||
|
[AS_HELP_STRING([--enable-reduce-exports],
|
||||||
|
--- 124,130 ----
|
||||||
|
[AS_HELP_STRING([--enable-hardening],
|
||||||
|
[attempt to harden the resulting executables (default is yes)])],
|
||||||
|
[use_hardening=$enableval],
|
||||||
|
! [use_hardening=yes])
|
||||||
|
|
||||||
|
AC_ARG_ENABLE([reduce-exports],
|
||||||
|
[AS_HELP_STRING([--enable-reduce-exports],
|
||||||
|
***************
|
||||||
|
*** 276,305 ****
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
! dnl AC_CHECK_PROG([BREW],brew, brew)
|
||||||
|
! dnl if test x$BREW = xbrew; then
|
||||||
|
dnl These Homebrew packages may be keg-only, meaning that they won't be found
|
||||||
|
dnl in expected paths because they may conflict with system files. Ask
|
||||||
|
dnl Homebrew where each one is located, then adjust paths accordingly.
|
||||||
|
dnl It's safe to add these paths even if the functionality is disabled by
|
||||||
|
dnl the user (--without-wallet or --without-gui for example).
|
||||||
|
|
||||||
|
! dnl openssl_prefix=`$BREW --prefix openssl 2>/dev/null`
|
||||||
|
! dnl bdb_prefix=`$BREW --prefix berkeley-db4 2>/dev/null`
|
||||||
|
! dnl qt5_prefix=`$BREW --prefix qt5 2>/dev/null`
|
||||||
|
! dnl if test x$openssl_prefix != x; then
|
||||||
|
! dnl PKG_CONFIG_PATH="$PKG_CONFIG_PATH"
|
||||||
|
! dnl export PKG_CONFIG_PATH
|
||||||
|
! dnl fi
|
||||||
|
! dnl if test x$bdb_prefix != x; then
|
||||||
|
! dnl CPPFLAGS="$CPPFLAGS -I$bdb_prefix/include"
|
||||||
|
! dnl LIBS="$LIBS -L$bdb_prefix/lib"
|
||||||
|
! dnl fi
|
||||||
|
! dnl if test x$qt5_prefix != x; then
|
||||||
|
! dnl PKG_CONFIG_PATH="$qt5_prefix/lib/pkgconfig:$PKG_CONFIG_PATH"
|
||||||
|
! dnl export PKG_CONFIG_PATH
|
||||||
|
! dnl fi
|
||||||
|
! dnl fi
|
||||||
|
else
|
||||||
|
case $build_os in
|
||||||
|
*darwin*)
|
||||||
|
--- 276,305 ----
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
! 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
|
||||||
|
dnl in expected paths because they may conflict with system files. Ask
|
||||||
|
dnl Homebrew where each one is located, then adjust paths accordingly.
|
||||||
|
dnl It's safe to add these paths even if the functionality is disabled by
|
||||||
|
dnl the user (--without-wallet or --without-gui for example).
|
||||||
|
|
||||||
|
! openssl_prefix=`$BREW --prefix openssl 2>/dev/null`
|
||||||
|
! bdb_prefix=`$BREW --prefix berkeley-db4 2>/dev/null`
|
||||||
|
! qt5_prefix=`$BREW --prefix qt5 2>/dev/null`
|
||||||
|
! if test x$openssl_prefix != x; then
|
||||||
|
! PKG_CONFIG_PATH="$openssl_prefix/lib/pkgconfig:$PKG_CONFIG_PATH"
|
||||||
|
! export PKG_CONFIG_PATH
|
||||||
|
! fi
|
||||||
|
! if test x$bdb_prefix != x; then
|
||||||
|
! CPPFLAGS="$CPPFLAGS -I$bdb_prefix/include"
|
||||||
|
! LIBS="$LIBS -L$bdb_prefix/lib"
|
||||||
|
! fi
|
||||||
|
! if test x$qt5_prefix != x; then
|
||||||
|
! PKG_CONFIG_PATH="$qt5_prefix/lib/pkgconfig:$PKG_CONFIG_PATH"
|
||||||
|
! export PKG_CONFIG_PATH
|
||||||
|
! fi
|
||||||
|
! fi
|
||||||
|
else
|
||||||
|
case $build_os in
|
||||||
|
*darwin*)
|
||||||
|
***************
|
||||||
|
*** 730,736 ****
|
||||||
|
AC_CHECK_HEADER([libsnark/gadgetlib1/gadget.hpp],,AC_MSG_ERROR(libsnark headers missing))
|
||||||
|
AC_CHECK_LIB([snark],[main],LIBSNARK_LIBS=-lsnark, [AC_MSG_ERROR(libsnark missing)], [-lgmpxx])
|
||||||
|
|
||||||
|
! LIBZCASH_LIBS="-lsnark -lgmp -lgmpxx -lboost_system-mt -lcrypto -lsodium"
|
||||||
|
|
||||||
|
CXXFLAGS_TEMP="$CXXFLAGS"
|
||||||
|
LIBS_TEMP="$LIBS"
|
||||||
|
--- 730,736 ----
|
||||||
|
AC_CHECK_HEADER([libsnark/gadgetlib1/gadget.hpp],,AC_MSG_ERROR(libsnark headers missing))
|
||||||
|
AC_CHECK_LIB([snark],[main],LIBSNARK_LIBS=-lsnark, [AC_MSG_ERROR(libsnark missing)], [-lgmpxx])
|
||||||
|
|
||||||
|
! LIBZCASH_LIBS="-lsnark -lgmp -lgmpxx -lboost_system-mt -lcrypto -lsodium -fopenmp"
|
||||||
|
|
||||||
|
CXXFLAGS_TEMP="$CXXFLAGS"
|
||||||
|
LIBS_TEMP="$LIBS"
|
||||||
21
darwin.host.mk.patch
Normal file
21
darwin.host.mk.patch
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
*** depends/hosts/darwin.mk 2017-01-03 10:53:52.440371182 +0000
|
||||||
|
--- ../../komodo-jl777/depends/hosts/darwin.mk 2017-01-03 09:48:21.650035146 +0000
|
||||||
|
***************
|
||||||
|
*** 2,9 ****
|
||||||
|
OSX_SDK_VERSION=10.9
|
||||||
|
OSX_SDK=$(SDK_PATH)/MacOSX$(OSX_SDK_VERSION).sdk
|
||||||
|
LD64_VERSION=241.9
|
||||||
|
! darwin_CC=gcc-5 -target $(host) -mmacosx-version-min=$(OSX_MIN_VERSION) --sysroot $(OSX_SDK) -mlinker-version=$(LD64_VERSION)
|
||||||
|
! darwin_CXX=g++-5 -target $(host) -mmacosx-version-min=$(OSX_MIN_VERSION) --sysroot $(OSX_SDK) -mlinker-version=$(LD64_VERSION)
|
||||||
|
|
||||||
|
darwin_CFLAGS=-pipe
|
||||||
|
darwin_CXXFLAGS=$(darwin_CFLAGS)
|
||||||
|
--- 2,9 ----
|
||||||
|
OSX_SDK_VERSION=10.9
|
||||||
|
OSX_SDK=$(SDK_PATH)/MacOSX$(OSX_SDK_VERSION).sdk
|
||||||
|
LD64_VERSION=241.9
|
||||||
|
! darwin_CC=clang -target $(host) -mmacosx-version-min=$(OSX_MIN_VERSION) --sysroot $(OSX_SDK) -mlinker-version=$(LD64_VERSION)
|
||||||
|
! darwin_CXX=clang++ -target $(host) -mmacosx-version-min=$(OSX_MIN_VERSION) --sysroot $(OSX_SDK) -mlinker-version=$(LD64_VERSION)
|
||||||
|
|
||||||
|
darwin_CFLAGS=-pipe
|
||||||
|
darwin_CXXFLAGS=$(darwin_CFLAGS)
|
||||||
40
darwin.mk.patch
Normal file
40
darwin.mk.patch
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
*** depends/builders/darwin.mk 2017-01-03 10:53:52.440371182 +0000
|
||||||
|
--- ../../komodo-jl777/depends/builders/darwin.mk 2017-01-03 09:48:21.646034937 +0000
|
||||||
|
***************
|
||||||
|
*** 1,5 ****
|
||||||
|
! build_darwin_CC = gcc-5
|
||||||
|
! build_darwin_CXX = g++-5
|
||||||
|
build_darwin_AR: = $(shell xcrun -f ar)
|
||||||
|
build_darwin_RANLIB: = $(shell xcrun -f ranlib)
|
||||||
|
build_darwin_STRIP: = $(shell xcrun -f strip)
|
||||||
|
--- 1,5 ----
|
||||||
|
! build_darwin_CC: = $(shell xcrun -f clang)
|
||||||
|
! build_darwin_CXX: = $(shell xcrun -f clang++)
|
||||||
|
build_darwin_AR: = $(shell xcrun -f ar)
|
||||||
|
build_darwin_RANLIB: = $(shell xcrun -f ranlib)
|
||||||
|
build_darwin_STRIP: = $(shell xcrun -f strip)
|
||||||
|
***************
|
||||||
|
*** 7,17 ****
|
||||||
|
build_darwin_NM: = $(shell xcrun -f nm)
|
||||||
|
build_darwin_INSTALL_NAME_TOOL:=$(shell xcrun -f install_name_tool)
|
||||||
|
build_darwin_SHA256SUM = shasum -a 256
|
||||||
|
! build_darwin_DOWNLOAD = wget --timeout=$(DOWNLOAD_CONNECT_TIMEOUT) --tries=$(DOWNLOAD_RETRIES) -nv -O
|
||||||
|
|
||||||
|
#darwin host on darwin builder. overrides darwin host preferences.
|
||||||
|
! darwin_CC= gcc-5
|
||||||
|
! darwin_CXX= g++-5
|
||||||
|
darwin_AR:=$(shell xcrun -f ar)
|
||||||
|
darwin_RANLIB:=$(shell xcrun -f ranlib)
|
||||||
|
darwin_STRIP:=$(shell xcrun -f strip)
|
||||||
|
--- 7,17 ----
|
||||||
|
build_darwin_NM: = $(shell xcrun -f nm)
|
||||||
|
build_darwin_INSTALL_NAME_TOOL:=$(shell xcrun -f install_name_tool)
|
||||||
|
build_darwin_SHA256SUM = shasum -a 256
|
||||||
|
! build_darwin_DOWNLOAD = curl --connect-timeout $(DOWNLOAD_CONNECT_TIMEOUT) --retry $(DOWNLOAD_RETRIES) -L -o
|
||||||
|
|
||||||
|
#darwin host on darwin builder. overrides darwin host preferences.
|
||||||
|
! darwin_CC=$(shell xcrun -f clang) -mmacosx-version-min=$(OSX_MIN_VERSION)
|
||||||
|
! darwin_CXX:=$(shell xcrun -f clang++) -mmacosx-version-min=$(OSX_MIN_VERSION)
|
||||||
|
darwin_AR:=$(shell xcrun -f ar)
|
||||||
|
darwin_RANLIB:=$(shell xcrun -f ranlib)
|
||||||
|
darwin_STRIP:=$(shell xcrun -f strip)
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
build_darwin_CC: = $(shell xcrun -f clang)
|
build_darwin_CC = gcc-5
|
||||||
build_darwin_CXX: = $(shell xcrun -f clang++)
|
build_darwin_CXX = g++-5
|
||||||
build_darwin_AR: = $(shell xcrun -f ar)
|
build_darwin_AR: = $(shell xcrun -f ar)
|
||||||
build_darwin_RANLIB: = $(shell xcrun -f ranlib)
|
build_darwin_RANLIB: = $(shell xcrun -f ranlib)
|
||||||
build_darwin_STRIP: = $(shell xcrun -f strip)
|
build_darwin_STRIP: = $(shell xcrun -f strip)
|
||||||
@@ -7,11 +7,11 @@ build_darwin_OTOOL: = $(shell xcrun -f otool)
|
|||||||
build_darwin_NM: = $(shell xcrun -f nm)
|
build_darwin_NM: = $(shell xcrun -f nm)
|
||||||
build_darwin_INSTALL_NAME_TOOL:=$(shell xcrun -f install_name_tool)
|
build_darwin_INSTALL_NAME_TOOL:=$(shell xcrun -f install_name_tool)
|
||||||
build_darwin_SHA256SUM = shasum -a 256
|
build_darwin_SHA256SUM = shasum -a 256
|
||||||
build_darwin_DOWNLOAD = curl --connect-timeout $(DOWNLOAD_CONNECT_TIMEOUT) --retry $(DOWNLOAD_RETRIES) -L -o
|
build_darwin_DOWNLOAD = wget --timeout=$(DOWNLOAD_CONNECT_TIMEOUT) --tries=$(DOWNLOAD_RETRIES) -nv -O
|
||||||
|
|
||||||
#darwin host on darwin builder. overrides darwin host preferences.
|
#darwin host on darwin builder. overrides darwin host preferences.
|
||||||
darwin_CC=$(shell xcrun -f clang) -mmacosx-version-min=$(OSX_MIN_VERSION)
|
darwin_CC= gcc-5
|
||||||
darwin_CXX:=$(shell xcrun -f clang++) -mmacosx-version-min=$(OSX_MIN_VERSION)
|
darwin_CXX= g++-5
|
||||||
darwin_AR:=$(shell xcrun -f ar)
|
darwin_AR:=$(shell xcrun -f ar)
|
||||||
darwin_RANLIB:=$(shell xcrun -f ranlib)
|
darwin_RANLIB:=$(shell xcrun -f ranlib)
|
||||||
darwin_STRIP:=$(shell xcrun -f strip)
|
darwin_STRIP:=$(shell xcrun -f strip)
|
||||||
|
|||||||
@@ -2,8 +2,8 @@ OSX_MIN_VERSION=10.7
|
|||||||
OSX_SDK_VERSION=10.9
|
OSX_SDK_VERSION=10.9
|
||||||
OSX_SDK=$(SDK_PATH)/MacOSX$(OSX_SDK_VERSION).sdk
|
OSX_SDK=$(SDK_PATH)/MacOSX$(OSX_SDK_VERSION).sdk
|
||||||
LD64_VERSION=241.9
|
LD64_VERSION=241.9
|
||||||
darwin_CC=clang -target $(host) -mmacosx-version-min=$(OSX_MIN_VERSION) --sysroot $(OSX_SDK) -mlinker-version=$(LD64_VERSION)
|
darwin_CC=gcc-5 -target $(host) -mmacosx-version-min=$(OSX_MIN_VERSION) --sysroot $(OSX_SDK) -mlinker-version=$(LD64_VERSION)
|
||||||
darwin_CXX=clang++ -target $(host) -mmacosx-version-min=$(OSX_MIN_VERSION) --sysroot $(OSX_SDK) -mlinker-version=$(LD64_VERSION)
|
darwin_CXX=g++-5 -target $(host) -mmacosx-version-min=$(OSX_MIN_VERSION) --sysroot $(OSX_SDK) -mlinker-version=$(LD64_VERSION)
|
||||||
|
|
||||||
darwin_CFLAGS=-pipe
|
darwin_CFLAGS=-pipe
|
||||||
darwin_CXXFLAGS=$(darwin_CFLAGS)
|
darwin_CXXFLAGS=$(darwin_CFLAGS)
|
||||||
|
|||||||
@@ -11,15 +11,14 @@ $(package)_config_opts_debug=variant=debug
|
|||||||
$(package)_config_opts=--layout=tagged --build-type=complete --user-config=user-config.jam
|
$(package)_config_opts=--layout=tagged --build-type=complete --user-config=user-config.jam
|
||||||
$(package)_config_opts+=threading=multi link=static -sNO_BZIP2=1 -sNO_ZLIB=1
|
$(package)_config_opts+=threading=multi link=static -sNO_BZIP2=1 -sNO_ZLIB=1
|
||||||
$(package)_config_opts_linux=threadapi=pthread runtime-link=shared
|
$(package)_config_opts_linux=threadapi=pthread runtime-link=shared
|
||||||
$(package)_config_opts_darwin=--toolset=darwin-4.2.1 runtime-link=shared
|
$(package)_config_opts_darwin=--toolset=gcc threadapi=pthread runtime-link=shared
|
||||||
$(package)_config_opts_mingw32=binary-format=pe target-os=windows threadapi=win32 runtime-link=static
|
$(package)_config_opts_mingw32=binary-format=pe target-os=windows threadapi=win32 runtime-link=static
|
||||||
$(package)_config_opts_x86_64_mingw32=address-model=64
|
$(package)_config_opts_x86_64_mingw32=address-model=64
|
||||||
$(package)_config_opts_i686_mingw32=address-model=32
|
$(package)_config_opts_i686_mingw32=address-model=32
|
||||||
$(package)_config_opts_i686_linux=address-model=32 architecture=x86
|
$(package)_config_opts_i686_linux=address-model=32 architecture=x86
|
||||||
$(package)_toolset_$(host_os)=gcc
|
$(package)_toolset_$(host_os)=gcc
|
||||||
$(package)_archiver_$(host_os)=$($(package)_ar)
|
$(package)_archiver_$(host_os)=$($(package)_ar)
|
||||||
$(package)_toolset_darwin=darwin
|
$(package)_toolset_darwin=gcc
|
||||||
$(package)_archiver_darwin=$($(package)_libtool)
|
|
||||||
$(package)_config_libraries=chrono,filesystem,program_options,system,thread,test
|
$(package)_config_libraries=chrono,filesystem,program_options,system,thread,test
|
||||||
$(package)_cxxflags=-fvisibility=hidden
|
$(package)_cxxflags=-fvisibility=hidden
|
||||||
$(package)_cxxflags_linux=-fPIC
|
$(package)_cxxflags_linux=-fPIC
|
||||||
@@ -36,9 +35,9 @@ define $(package)_config_cmds
|
|||||||
endef
|
endef
|
||||||
|
|
||||||
define $(package)_build_cmds
|
define $(package)_build_cmds
|
||||||
./b2 -d2 -j2 -d1 --prefix=$($(package)_staging_prefix_dir) $($(package)_config_opts) stage
|
./b2 -d2 -j2 -d1 --prefix=$($(package)_staging_prefix_dir) $($(package)_config_opts) cxxflags=-std=c++11 stage
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define $(package)_stage_cmds
|
define $(package)_stage_cmds
|
||||||
./b2 -d0 -j4 --prefix=$($(package)_staging_prefix_dir) $($(package)_config_opts) install
|
./b2 -d0 -j4 --prefix=$($(package)_staging_prefix_dir) $($(package)_config_opts) cxxflags=-std=c++11 install
|
||||||
endef
|
endef
|
||||||
|
|||||||
@@ -1,17 +1,30 @@
|
|||||||
package=libsnark
|
package=libsnark
|
||||||
$(package)_version=0.1
|
$(package)_version=0.1
|
||||||
$(package)_download_path=https://github.com/zcash/$(package)/archive/
|
$(package)_download_path=https://github.com/radix42/$(package)/archive/
|
||||||
$(package)_file_name=$(package)-$($(package)_git_commit).tar.gz
|
$(package)_file_name=$(package)-$($(package)_git_commit).tar.gz
|
||||||
$(package)_download_file=$($(package)_git_commit).tar.gz
|
$(package)_download_file=$($(package)_git_commit).tar.gz
|
||||||
$(package)_sha256_hash=9422b1a2a94e6b8be61f07af7f146087c2a7d70b208d07ad076622225aa7f0e4
|
$(package)_sha256_hash=9dbd5b44d3443e86463e934bfe1023cab4ca5948f8d74c23a67d9535c28d2584
|
||||||
$(package)_git_commit=2e6314a9f7efcd9af1c77669d7d9a229df86a777
|
$(package)_git_commit=9be18569b8abcda1245c3912877075259599c0f1
|
||||||
|
|
||||||
$(package)_dependencies=libgmp libsodium
|
$(package)_dependencies=libgmp libsodium
|
||||||
|
|
||||||
|
ifeq ($(build_os),darwin)
|
||||||
|
define $(package)_build_cmds
|
||||||
|
CC=gcc-5 CXX=g++-5 CXXFLAGS="-arch x86_64 -DBINARY_OUTPUT -DNO_PT_COMPRESSION=1" $(MAKE) lib DEPINST=$(host_prefix) CURVE=ALT_BN128 MULTICORE=0 NO_PROCPS=1 NO_GTEST=1 NO_DOCS=1 STATIC=1 NO_SUPERCOP=1 FEATUREFLAGS=-DMONTGOMERY_OUTPUT
|
||||||
|
endef
|
||||||
|
else
|
||||||
define $(package)_build_cmds
|
define $(package)_build_cmds
|
||||||
CXXFLAGS="-fPIC -DBINARY_OUTPUT -DNO_PT_COMPRESSION=1" $(MAKE) lib DEPINST=$(host_prefix) CURVE=ALT_BN128 MULTICORE=1 NO_PROCPS=1 NO_GTEST=1 NO_DOCS=1 STATIC=1 NO_SUPERCOP=1 FEATUREFLAGS=-DMONTGOMERY_OUTPUT OPTFLAGS="-O2 -march=x86-64"
|
CXXFLAGS="-fPIC -DBINARY_OUTPUT -DNO_PT_COMPRESSION=1" $(MAKE) lib DEPINST=$(host_prefix) CURVE=ALT_BN128 MULTICORE=1 NO_PROCPS=1 NO_GTEST=1 NO_DOCS=1 STATIC=1 NO_SUPERCOP=1 FEATUREFLAGS=-DMONTGOMERY_OUTPUT OPTFLAGS="-O2 -march=x86-64"
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
define $(package)_stage_cmds
|
define $(package)_stage_cmds
|
||||||
$(MAKE) install STATIC=1 DEPINST=$(host_prefix) PREFIX=$($(package)_staging_dir)$(host_prefix) CURVE=ALT_BN128 NO_SUPERCOP=1
|
$(MAKE) install STATIC=1 DEPINST=$(host_prefix) PREFIX=$($(package)_staging_dir)$(host_prefix) CURVE=ALT_BN128 NO_SUPERCOP=1
|
||||||
endef
|
endef
|
||||||
|
|||||||
@@ -1,5 +1,12 @@
|
|||||||
zcash_packages := libsnark libgmp libsodium
|
zcash_packages := libsnark libgmp libsodium
|
||||||
|
|
||||||
|
ifeq ($(build_os),darwin)
|
||||||
|
packages := boost openssl $(zcash_packages)
|
||||||
|
else
|
||||||
packages := boost openssl $(zcash_packages) googletest googlemock
|
packages := boost openssl $(zcash_packages) googletest googlemock
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
native_packages := native_ccache
|
native_packages := native_ccache
|
||||||
|
|
||||||
wallet_packages=bdb
|
wallet_packages=bdb
|
||||||
|
|||||||
35
equihash.cpp.patch
Normal file
35
equihash.cpp.patch
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
*** src/crypto/equihash.cpp 2017-01-03 10:53:52.444371361 +0000
|
||||||
|
--- ../../komodo-jl777/src/crypto/equihash.cpp 2017-01-03 09:48:21.690037241 +0000
|
||||||
|
***************
|
||||||
|
*** 21,50 ****
|
||||||
|
|
||||||
|
#include <boost/optional.hpp>
|
||||||
|
|
||||||
|
- #ifdef __APPLE__
|
||||||
|
- #include <machine/endian.h>
|
||||||
|
- #include <libkern/OSByteOrder.h>
|
||||||
|
-
|
||||||
|
- #define htobe16(x) OSSwapHostToBigInt16(x)
|
||||||
|
- #define htole16(x) OSSwapHostToLittleInt16(x)
|
||||||
|
- #define be16toh(x) OSSwapBigToHostInt16(x)
|
||||||
|
- #define le16toh(x) OSSwapLittleToHostInt16(x)
|
||||||
|
-
|
||||||
|
- #define htobe32(x) OSSwapHostToBigInt32(x)
|
||||||
|
- #define htole32(x) OSSwapHostToLittleInt32(x)
|
||||||
|
- #define be32toh(x) OSSwapBigToHostInt32(x)
|
||||||
|
- #define le32toh(x) OSSwapLittleToHostInt32(x)
|
||||||
|
-
|
||||||
|
- #define htobe64(x) OSSwapHostToBigInt64(x)
|
||||||
|
- #define htole64(x) OSSwapHostToLittleInt64(x)
|
||||||
|
- #define be64toh(x) OSSwapBigToHostInt64(x)
|
||||||
|
- #define le64toh(x) OSSwapLittleToHostInt64(x)
|
||||||
|
-
|
||||||
|
- #define __BIG_ENDIAN BIG_ENDIAN
|
||||||
|
- #define __LITTLE_ENDIAN LITTLE_ENDIAN
|
||||||
|
- #define __BYTE_ORDER BYTE_ORDER
|
||||||
|
- #endif
|
||||||
|
-
|
||||||
|
EhSolverCancelledException solver_cancelled;
|
||||||
|
|
||||||
|
template<unsigned int N, unsigned int K>
|
||||||
|
--- 21,26 ----
|
||||||
52
libsnark.mk.patch
Normal file
52
libsnark.mk.patch
Normal file
@@ -0,0 +1,52 @@
|
|||||||
|
*** depends/packages/libsnark.mk 2017-01-03 10:53:52.440371182 +0000
|
||||||
|
--- ../../komodo-jl777/depends/packages/libsnark.mk 2017-01-03 09:48:21.650035146 +0000
|
||||||
|
***************
|
||||||
|
*** 1,30 ****
|
||||||
|
package=libsnark
|
||||||
|
$(package)_version=0.1
|
||||||
|
! $(package)_download_path=https://github.com/radix42/$(package)/archive/
|
||||||
|
$(package)_file_name=$(package)-$($(package)_git_commit).tar.gz
|
||||||
|
$(package)_download_file=$($(package)_git_commit).tar.gz
|
||||||
|
! $(package)_sha256_hash=9dbd5b44d3443e86463e934bfe1023cab4ca5948f8d74c23a67d9535c28d2584
|
||||||
|
! $(package)_git_commit=9be18569b8abcda1245c3912877075259599c0f1
|
||||||
|
|
||||||
|
$(package)_dependencies=libgmp libsodium
|
||||||
|
|
||||||
|
- ifeq ($(build_os),darwin)
|
||||||
|
- define $(package)_build_cmds
|
||||||
|
- CC=gcc-5 CXX=g++-5 CXXFLAGS="-arch x86_64 -DBINARY_OUTPUT -DNO_PT_COMPRESSION=1" $(MAKE) lib DEPINST=$(host_prefix) CURVE=ALT_BN128 MULTICORE=0 NO_PROCPS=1 NO_GTEST=1 NO_DOCS=1 STATIC=1 NO_SUPERCOP=1 FEATUREFLAGS=-DMONTGOMERY_OUTPUT
|
||||||
|
- endef
|
||||||
|
- else
|
||||||
|
define $(package)_build_cmds
|
||||||
|
CXXFLAGS="-fPIC -DBINARY_OUTPUT -DNO_PT_COMPRESSION=1" $(MAKE) lib DEPINST=$(host_prefix) CURVE=ALT_BN128 MULTICORE=1 NO_PROCPS=1 NO_GTEST=1 NO_DOCS=1 STATIC=1 NO_SUPERCOP=1 FEATUREFLAGS=-DMONTGOMERY_OUTPUT OPTFLAGS="-O2 -march=x86-64"
|
||||||
|
endef
|
||||||
|
|
||||||
|
-
|
||||||
|
-
|
||||||
|
-
|
||||||
|
- endif
|
||||||
|
-
|
||||||
|
-
|
||||||
|
-
|
||||||
|
-
|
||||||
|
define $(package)_stage_cmds
|
||||||
|
$(MAKE) install STATIC=1 DEPINST=$(host_prefix) PREFIX=$($(package)_staging_dir)$(host_prefix) CURVE=ALT_BN128 NO_SUPERCOP=1
|
||||||
|
endef
|
||||||
|
--- 1,17 ----
|
||||||
|
package=libsnark
|
||||||
|
$(package)_version=0.1
|
||||||
|
! $(package)_download_path=https://github.com/zcash/$(package)/archive/
|
||||||
|
$(package)_file_name=$(package)-$($(package)_git_commit).tar.gz
|
||||||
|
$(package)_download_file=$($(package)_git_commit).tar.gz
|
||||||
|
! $(package)_sha256_hash=9422b1a2a94e6b8be61f07af7f146087c2a7d70b208d07ad076622225aa7f0e4
|
||||||
|
! $(package)_git_commit=2e6314a9f7efcd9af1c77669d7d9a229df86a777
|
||||||
|
|
||||||
|
$(package)_dependencies=libgmp libsodium
|
||||||
|
|
||||||
|
define $(package)_build_cmds
|
||||||
|
CXXFLAGS="-fPIC -DBINARY_OUTPUT -DNO_PT_COMPRESSION=1" $(MAKE) lib DEPINST=$(host_prefix) CURVE=ALT_BN128 MULTICORE=1 NO_PROCPS=1 NO_GTEST=1 NO_DOCS=1 STATIC=1 NO_SUPERCOP=1 FEATUREFLAGS=-DMONTGOMERY_OUTPUT OPTFLAGS="-O2 -march=x86-64"
|
||||||
|
endef
|
||||||
|
|
||||||
|
define $(package)_stage_cmds
|
||||||
|
$(MAKE) install STATIC=1 DEPINST=$(host_prefix) PREFIX=$($(package)_staging_dir)$(host_prefix) CURVE=ALT_BN128 NO_SUPERCOP=1
|
||||||
|
endef
|
||||||
17
packages.mk.patch
Normal file
17
packages.mk.patch
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
*** depends/packages/packages.mk 2017-01-03 10:53:52.440371182 +0000
|
||||||
|
--- ../../komodo-jl777/depends/packages/packages.mk 2017-01-03 09:48:21.650035146 +0000
|
||||||
|
***************
|
||||||
|
*** 1,12 ****
|
||||||
|
zcash_packages := libsnark libgmp libsodium
|
||||||
|
-
|
||||||
|
- ifeq ($(build_os),darwin)
|
||||||
|
- packages := boost openssl $(zcash_packages)
|
||||||
|
- else
|
||||||
|
packages := boost openssl $(zcash_packages) googletest googlemock
|
||||||
|
- endif
|
||||||
|
-
|
||||||
|
-
|
||||||
|
native_packages := native_ccache
|
||||||
|
|
||||||
|
wallet_packages=bdb
|
||||||
|
--- 1,5 ----
|
||||||
@@ -14,6 +14,7 @@ echo $pubkey
|
|||||||
./komodod -pubkey=$pubkey -ac_name=SHARK -ac_supply=1401 -addnode=78.47.196.146 $1 -gen &
|
./komodod -pubkey=$pubkey -ac_name=SHARK -ac_supply=1401 -addnode=78.47.196.146 $1 -gen &
|
||||||
./komodod -pubkey=$pubkey -ac_name=BOTS -ac_supply=999999 -addnode=78.47.196.146 $1 -gen &
|
./komodod -pubkey=$pubkey -ac_name=BOTS -ac_supply=999999 -addnode=78.47.196.146 $1 -gen &
|
||||||
./komodod -pubkey=$pubkey -ac_name=MGW -ac_supply=999999 -addnode=78.47.196.146 $1 -gen &
|
./komodod -pubkey=$pubkey -ac_name=MGW -ac_supply=999999 -addnode=78.47.196.146 $1 -gen &
|
||||||
|
./komodod -pubkey=$pubkey -ac_name=MVP -ac_supply=1000000 -addnode=78.47.196.146 $1 -gen &
|
||||||
|
|
||||||
./komodod -pubkey=$pubkey -ac_name=USD -addnode=78.47.196.146 $1 -gen &
|
./komodod -pubkey=$pubkey -ac_name=USD -addnode=78.47.196.146 $1 -gen &
|
||||||
./komodod -pubkey=$pubkey -ac_name=EUR -addnode=78.47.196.146 $1 -gen &
|
./komodod -pubkey=$pubkey -ac_name=EUR -addnode=78.47.196.146 $1 -gen &
|
||||||
|
|||||||
@@ -634,7 +634,7 @@ void cJSON_Minify(char *json)
|
|||||||
|
|
||||||
// the following written by jl777
|
// the following written by jl777
|
||||||
/******************************************************************************
|
/******************************************************************************
|
||||||
* Copyright © 2014-2016 The SuperNET Developers. *
|
* Copyright © 2014-2017 The SuperNET Developers. *
|
||||||
* *
|
* *
|
||||||
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
||||||
* the top-level directory of this distribution for the individual copyright *
|
* the top-level directory of this distribution for the individual copyright *
|
||||||
|
|||||||
@@ -21,6 +21,30 @@
|
|||||||
|
|
||||||
#include <boost/optional.hpp>
|
#include <boost/optional.hpp>
|
||||||
|
|
||||||
|
#ifdef __APPLE__
|
||||||
|
#include <machine/endian.h>
|
||||||
|
#include <libkern/OSByteOrder.h>
|
||||||
|
|
||||||
|
#define htobe16(x) OSSwapHostToBigInt16(x)
|
||||||
|
#define htole16(x) OSSwapHostToLittleInt16(x)
|
||||||
|
#define be16toh(x) OSSwapBigToHostInt16(x)
|
||||||
|
#define le16toh(x) OSSwapLittleToHostInt16(x)
|
||||||
|
|
||||||
|
#define htobe32(x) OSSwapHostToBigInt32(x)
|
||||||
|
#define htole32(x) OSSwapHostToLittleInt32(x)
|
||||||
|
#define be32toh(x) OSSwapBigToHostInt32(x)
|
||||||
|
#define le32toh(x) OSSwapLittleToHostInt32(x)
|
||||||
|
|
||||||
|
#define htobe64(x) OSSwapHostToBigInt64(x)
|
||||||
|
#define htole64(x) OSSwapHostToLittleInt64(x)
|
||||||
|
#define be64toh(x) OSSwapBigToHostInt64(x)
|
||||||
|
#define le64toh(x) OSSwapLittleToHostInt64(x)
|
||||||
|
|
||||||
|
#define __BIG_ENDIAN BIG_ENDIAN
|
||||||
|
#define __LITTLE_ENDIAN LITTLE_ENDIAN
|
||||||
|
#define __BYTE_ORDER BYTE_ORDER
|
||||||
|
#endif
|
||||||
|
|
||||||
EhSolverCancelledException solver_cancelled;
|
EhSolverCancelledException solver_cancelled;
|
||||||
|
|
||||||
template<unsigned int N, unsigned int K>
|
template<unsigned int N, unsigned int K>
|
||||||
|
|||||||
@@ -16,6 +16,8 @@ curl --url "http://127.0.0.1:7776" --data "{\"agent\":\"iguana\",\"method\":\"dp
|
|||||||
curl --url "http://127.0.0.1:7776" --data "{\"agent\":\"iguana\",\"method\":\"dpow\",\"symbol\":\"SHARK\",\"pubkey\":\"$pubkey\"}"
|
curl --url "http://127.0.0.1:7776" --data "{\"agent\":\"iguana\",\"method\":\"dpow\",\"symbol\":\"SHARK\",\"pubkey\":\"$pubkey\"}"
|
||||||
curl --url "http://127.0.0.1:7776" --data "{\"agent\":\"iguana\",\"method\":\"dpow\",\"symbol\":\"BOTS\",\"pubkey\":\"$pubkey\"}"
|
curl --url "http://127.0.0.1:7776" --data "{\"agent\":\"iguana\",\"method\":\"dpow\",\"symbol\":\"BOTS\",\"pubkey\":\"$pubkey\"}"
|
||||||
curl --url "http://127.0.0.1:7776" --data "{\"agent\":\"iguana\",\"method\":\"dpow\",\"symbol\":\"MGW\",\"pubkey\":\"$pubkey\"}"
|
curl --url "http://127.0.0.1:7776" --data "{\"agent\":\"iguana\",\"method\":\"dpow\",\"symbol\":\"MGW\",\"pubkey\":\"$pubkey\"}"
|
||||||
|
curl --url "http://127.0.0.1:7776" --data "{\"agent\":\"iguana\",\"method\":\"dpow\",\"symbol\":\"MVP\",\"pubkey\":\"$pubkey\"}"
|
||||||
|
|
||||||
curl --url "http://127.0.0.1:7776" --data "{\"agent\":\"iguana\",\"method\":\"dpow\",\"symbol\":\"USD\",\"pubkey\":\"$pubkey\"}"
|
curl --url "http://127.0.0.1:7776" --data "{\"agent\":\"iguana\",\"method\":\"dpow\",\"symbol\":\"USD\",\"pubkey\":\"$pubkey\"}"
|
||||||
curl --url "http://127.0.0.1:7776" --data "{\"agent\":\"iguana\",\"method\":\"dpow\",\"symbol\":\"EUR\",\"pubkey\":\"$pubkey\"}"
|
curl --url "http://127.0.0.1:7776" --data "{\"agent\":\"iguana\",\"method\":\"dpow\",\"symbol\":\"EUR\",\"pubkey\":\"$pubkey\"}"
|
||||||
|
|
||||||
|
|||||||
@@ -43,3 +43,4 @@ echo hodl; fiat/hodl $1 $2 $3 $4
|
|||||||
echo shark; fiat/shark $1 $2 $3 $4
|
echo shark; fiat/shark $1 $2 $3 $4
|
||||||
echo bots; fiat/bots $1 $2 $3 $4
|
echo bots; fiat/bots $1 $2 $3 $4
|
||||||
echo mgw; fiat/mgw $1 $2 $3 $4
|
echo mgw; fiat/mgw $1 $2 $3 $4
|
||||||
|
echo mvp; fiat/mvp $1 $2 $3 $4
|
||||||
|
|||||||
2
src/fiat/mvp
Executable file
2
src/fiat/mvp
Executable file
@@ -0,0 +1,2 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
./komodo-cli -ac_name=MVP $1 $2 $3 $4
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
/******************************************************************************
|
/******************************************************************************
|
||||||
* Copyright © 2014-2016 The SuperNET Developers. *
|
* Copyright © 2014-2017 The SuperNET Developers. *
|
||||||
* *
|
* *
|
||||||
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
||||||
* the top-level directory of this distribution for the individual copyright *
|
* the top-level directory of this distribution for the individual copyright *
|
||||||
@@ -407,8 +407,10 @@ int32_t komodo_voutupdate(int32_t *isratificationp,int32_t notaryid,uint8_t *scr
|
|||||||
}
|
}
|
||||||
if ( opretlen > len && scriptbuf[len] == 'A' )
|
if ( opretlen > len && scriptbuf[len] == 'A' )
|
||||||
{
|
{
|
||||||
printf("Found extradata.[%d] %d - %d\n",opretlen-len,opretlen,len);
|
for (i=0; i<opretlen-len; i++)
|
||||||
komodo_stateupdate(height,0,0,0,txhash,0,0,0,0,0,0,value,&scriptbuf[len],opretlen-len,j);
|
printf("%02x",scriptbuf[len+i]);
|
||||||
|
printf(" Found extradata.[%d] %d - %d\n",opretlen-len,opretlen,len);
|
||||||
|
komodo_stateupdate(height,0,0,0,txhash,0,0,0,0,0,0,value,&scriptbuf[len],opretlen-len+4+3+(scriptbuf[1] == 0x4d),j);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else printf("notarized.%d %llx reject ht.%d NOTARIZED.%d %s.%s DESTTXID.%s (%s)\n",notarized,(long long)signedmask,height,*notarizedheightp,ASSETCHAINS_SYMBOL[0]==0?"KMD":ASSETCHAINS_SYMBOL,kmdtxid.ToString().c_str(),desttxid.ToString().c_str(),(char *)&scriptbuf[len]);
|
} else printf("notarized.%d %llx reject ht.%d NOTARIZED.%d %s.%s DESTTXID.%s (%s)\n",notarized,(long long)signedmask,height,*notarizedheightp,ASSETCHAINS_SYMBOL[0]==0?"KMD":ASSETCHAINS_SYMBOL,kmdtxid.ToString().c_str(),desttxid.ToString().c_str(),(char *)&scriptbuf[len]);
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/******************************************************************************
|
/******************************************************************************
|
||||||
* Copyright © 2014-2016 The SuperNET Developers. *
|
* Copyright © 2014-2017 The SuperNET Developers. *
|
||||||
* *
|
* *
|
||||||
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
||||||
* the top-level directory of this distribution for the individual copyright *
|
* the top-level directory of this distribution for the individual copyright *
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/******************************************************************************
|
/******************************************************************************
|
||||||
* Copyright © 2014-2016 The SuperNET Developers. *
|
* Copyright © 2014-2017 The SuperNET Developers. *
|
||||||
* *
|
* *
|
||||||
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
||||||
* the top-level directory of this distribution for the individual copyright *
|
* the top-level directory of this distribution for the individual copyright *
|
||||||
@@ -92,7 +92,7 @@ void komodo_event_undo(struct komodo_state *sp,struct komodo_event *ep)
|
|||||||
switch ( ep->type )
|
switch ( ep->type )
|
||||||
{
|
{
|
||||||
case KOMODO_EVENT_RATIFY: printf("rewind of ratify, needs to be coded.%d\n",ep->height); break;
|
case KOMODO_EVENT_RATIFY: printf("rewind of ratify, needs to be coded.%d\n",ep->height); break;
|
||||||
case KOMODO_EVENT_NOTARIZED: printf("unexpected rewind of notarization.%d\n",ep->height); break;
|
case KOMODO_EVENT_NOTARIZED: break;
|
||||||
case KOMODO_EVENT_KMDHEIGHT:
|
case KOMODO_EVENT_KMDHEIGHT:
|
||||||
if ( ep->height <= sp->SAVEDHEIGHT )
|
if ( ep->height <= sp->SAVEDHEIGHT )
|
||||||
sp->SAVEDHEIGHT = ep->height;
|
sp->SAVEDHEIGHT = ep->height;
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/******************************************************************************
|
/******************************************************************************
|
||||||
* Copyright © 2014-2016 The SuperNET Developers. *
|
* Copyright © 2014-2017 The SuperNET Developers. *
|
||||||
* *
|
* *
|
||||||
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
||||||
* the top-level directory of this distribution for the individual copyright *
|
* the top-level directory of this distribution for the individual copyright *
|
||||||
@@ -58,7 +58,7 @@ struct pax_transaction *komodo_paxfind(uint256 txid,uint16_t vout,uint8_t type)
|
|||||||
|
|
||||||
struct pax_transaction *komodo_paxfinds(uint256 txid,uint16_t vout)
|
struct pax_transaction *komodo_paxfinds(uint256 txid,uint16_t vout)
|
||||||
{
|
{
|
||||||
struct pax_transaction *pax; int32_t i; uint8_t types[] = { 'D', 'I', 'W', 'A', 'X' };
|
struct pax_transaction *pax; int32_t i; uint8_t types[] = { 'I', 'D', 'X', 'A', 'W' };
|
||||||
for (i=0; i<sizeof(types)/sizeof(*types); i++)
|
for (i=0; i<sizeof(types)/sizeof(*types); i++)
|
||||||
if ( (pax= komodo_paxfind(txid,vout,types[i])) != 0 )
|
if ( (pax= komodo_paxfind(txid,vout,types[i])) != 0 )
|
||||||
return(pax);
|
return(pax);
|
||||||
@@ -190,8 +190,11 @@ int32_t komodo_issued_opreturn(char *base,uint256 *txids,uint16_t *vouts,int64_t
|
|||||||
struct pax_transaction p,*pax; int32_t i,n=0,j,len=0,incr,height,otherheight; uint8_t type,rmd160[20]; uint64_t fiatoshis; char symbol[16];
|
struct pax_transaction p,*pax; int32_t i,n=0,j,len=0,incr,height,otherheight; uint8_t type,rmd160[20]; uint64_t fiatoshis; char symbol[16];
|
||||||
if ( KOMODO_PAX == 0 )
|
if ( KOMODO_PAX == 0 )
|
||||||
return(0);
|
return(0);
|
||||||
incr = 34 + (iskomodo * (2*sizeof(fiatoshis) + 2*sizeof(height) + 20));
|
incr = 34 + (iskomodo * (2*sizeof(fiatoshis) + 2*sizeof(height) + 20 + 4));
|
||||||
//41e77b91cb68dc2aa02fa88550eae6b6d44db676a7e935337b6d1392d9718f03cb0200305c90660400000000fbcbeb1f000000bde801006201000058e7945ad08ddba1eac9c9b6c8e1e97e8016a2d152
|
//41e77b91cb68dc2aa02fa88550eae6b6d44db676a7e935337b6d1392d9718f03cb0200305c90660400000000fbcbeb1f000000bde801006201000058e7945ad08ddba1eac9c9b6c8e1e97e8016a2d152
|
||||||
|
|
||||||
|
// 41e94d736ec69d88c08b5d238abeeca609c02357a8317e0d56c328bcb1c259be5d0200485bc80200000000404b4c000000000059470200b80b000061f22ba7d19fe29ac3baebd839af8b7127d1f9075553440046bb4cc7a3b5cd39dffe7206507a3482a00780e617f68b273cce9817ed69298d02001069ca1b0000000080f0fa02000000005b470200b90b000061f22ba7d19fe29ac3baebd839af8b7127d1f90755
|
||||||
|
|
||||||
//for (i=0; i<opretlen; i++)
|
//for (i=0; i<opretlen; i++)
|
||||||
// printf("%02x",opretbuf[i]);
|
// printf("%02x",opretbuf[i]);
|
||||||
//printf(" opretlen.%d (%s)\n",opretlen,base);
|
//printf(" opretlen.%d (%s)\n",opretlen,base);
|
||||||
@@ -362,7 +365,7 @@ uint64_t komodo_paxtotal()
|
|||||||
{
|
{
|
||||||
seed = 0;
|
seed = 0;
|
||||||
checktoshis = komodo_paxprice(&seed,pax->height,pax->source,(char *)"KMD",(uint64_t)pax->fiatoshis);
|
checktoshis = komodo_paxprice(&seed,pax->height,pax->source,(char *)"KMD",(uint64_t)pax->fiatoshis);
|
||||||
//printf("PAX_fiatdest ht.%d price %s %.8f -> KMD %.8f vs %.8f\n",pax->height,pax->symbol,(double)pax->fiatoshis/COIN,(double)pax->komodoshis/COIN,(double)checktoshis/COIN);
|
//printf("paxtotal PAX_fiatdest ht.%d price %s %.8f -> KMD %.8f vs %.8f\n",pax->height,pax->symbol,(double)pax->fiatoshis/COIN,(double)pax->komodoshis/COIN,(double)checktoshis/COIN);
|
||||||
//printf(" v%d %.8f k.%d ht.%d\n",pax->vout,dstr(pax->komodoshis),pax->height,pax->otherheight);
|
//printf(" v%d %.8f k.%d ht.%d\n",pax->vout,dstr(pax->komodoshis),pax->height,pax->otherheight);
|
||||||
if ( seed != 0 && checktoshis != 0 )
|
if ( seed != 0 && checktoshis != 0 )
|
||||||
{
|
{
|
||||||
@@ -419,8 +422,8 @@ int32_t komodo_pending_withdraws(char *opretstr) // todo: enforce deterministic
|
|||||||
}
|
}
|
||||||
else if ( (pax2= komodo_paxfind(pax->txid,pax->vout,'X')) != 0 )
|
else if ( (pax2= komodo_paxfind(pax->txid,pax->vout,'X')) != 0 )
|
||||||
pax->approved = pax->height;
|
pax->approved = pax->height;
|
||||||
//printf("pax %s marked.%u approved.%u validated.%llu\n",pax->symbol,pax->marked,pax->approved,(long long)pax->validated);
|
//printf("pending_withdraw: pax %s marked.%u approved.%u validated.%llu\n",pax->symbol,pax->marked,pax->approved,(long long)pax->validated);
|
||||||
if ( pax->marked == 0 && strcmp((char *)"KMD",pax->symbol) == 0 && pax->approved == 0 && pax->validated != 0 )
|
if ( pax->marked == 0 && pax->approved == 0 && pax->validated != 0 ) //strcmp((char *)"KMD",pax->symbol) == 0 &&
|
||||||
{
|
{
|
||||||
if ( n < sizeof(paxes)/sizeof(*paxes) )
|
if ( n < sizeof(paxes)/sizeof(*paxes) )
|
||||||
{
|
{
|
||||||
@@ -474,6 +477,8 @@ int32_t komodo_gateway_deposits(CMutableTransaction *txNew,char *base,int32_t to
|
|||||||
}
|
}
|
||||||
HASH_ITER(hh,PAX,pax,tmp)
|
HASH_ITER(hh,PAX,pax,tmp)
|
||||||
{
|
{
|
||||||
|
if ( pax->type != 'D' && pax->type != 'A' )
|
||||||
|
continue;
|
||||||
{
|
{
|
||||||
#ifdef KOMODO_ASSETCHAINS_WAITNOTARIZE
|
#ifdef KOMODO_ASSETCHAINS_WAITNOTARIZE
|
||||||
if ( kmdsp != 0 && (kmdsp->NOTARIZED_HEIGHT >= pax->height || kmdsp->CURRENT_HEIGHT > pax->height+30) ) // assumes same chain as notarize
|
if ( kmdsp != 0 && (kmdsp->NOTARIZED_HEIGHT >= pax->height || kmdsp->CURRENT_HEIGHT > pax->height+30) ) // assumes same chain as notarize
|
||||||
@@ -537,7 +542,7 @@ int32_t komodo_gateway_deposits(CMutableTransaction *txNew,char *base,int32_t to
|
|||||||
{
|
{
|
||||||
len += komodo_rwapproval(1,&data[len],pax);
|
len += komodo_rwapproval(1,&data[len],pax);
|
||||||
PENDING_KOMODO_TX += pax->komodoshis;
|
PENDING_KOMODO_TX += pax->komodoshis;
|
||||||
printf(" vout.%u DEPOSIT %.8f <- pax.%s pending %.8f | ",pax->vout,(double)txNew->vout[numvouts].nValue/COIN,symbol,dstr(PENDING_KOMODO_TX));
|
printf(" len.%d vout.%u DEPOSIT %.8f <- pax.%s pending %.8f | ",len,pax->vout,(double)txNew->vout[numvouts].nValue/COIN,symbol,dstr(PENDING_KOMODO_TX));
|
||||||
}
|
}
|
||||||
if ( numvouts++ >= 64 )
|
if ( numvouts++ >= 64 )
|
||||||
break;
|
break;
|
||||||
@@ -549,13 +554,18 @@ int32_t komodo_gateway_deposits(CMutableTransaction *txNew,char *base,int32_t to
|
|||||||
for (i=0; symbol[i]!=0; i++)
|
for (i=0; symbol[i]!=0; i++)
|
||||||
data[len++] = symbol[i];
|
data[len++] = symbol[i];
|
||||||
data[len++] = 0;
|
data[len++] = 0;
|
||||||
|
for (i=0; i<len; i++)
|
||||||
|
printf("%02x",data[i]);
|
||||||
|
printf(" <- data[%d]\n",len);
|
||||||
opretlen = komodo_opreturnscript(opret,opcode,data,len);
|
opretlen = komodo_opreturnscript(opret,opcode,data,len);
|
||||||
txNew->vout.resize(numvouts+1);
|
txNew->vout.resize(numvouts+1);
|
||||||
txNew->vout[numvouts].nValue = 0;
|
txNew->vout[numvouts].nValue = 0;
|
||||||
txNew->vout[numvouts].scriptPubKey.resize(opretlen);
|
txNew->vout[numvouts].scriptPubKey.resize(opretlen);
|
||||||
script = (uint8_t *)&txNew->vout[numvouts].scriptPubKey[0];
|
script = (uint8_t *)&txNew->vout[numvouts].scriptPubKey[0];
|
||||||
memcpy(script,opret,opretlen);
|
memcpy(script,opret,opretlen);
|
||||||
printf("MINER deposits.%d (%s) vouts.%d %.8f opretlen.%d\n",tokomodo,ASSETCHAINS_SYMBOL,numvouts,dstr(PENDING_KOMODO_TX),opretlen);
|
for (i=0; i<8; i++)
|
||||||
|
printf("%02x",opret[i]);
|
||||||
|
printf(" <- opret, MINER deposits.%d (%s) vouts.%d %.8f opretlen.%d\n",tokomodo,ASSETCHAINS_SYMBOL,numvouts,dstr(PENDING_KOMODO_TX),opretlen);
|
||||||
return(1);
|
return(1);
|
||||||
}
|
}
|
||||||
return(0);
|
return(0);
|
||||||
@@ -617,8 +627,10 @@ int32_t komodo_check_deposit(int32_t height,const CBlock& block) // verify above
|
|||||||
{
|
{
|
||||||
if ( pax->marked != 0 && height >= 80820 )
|
if ( pax->marked != 0 && height >= 80820 )
|
||||||
{
|
{
|
||||||
printf(">>>>>>>>>>> %c errs.%d i.%d match %.8f vs %.8f pax.%p\n",opcode,errs,i,dstr(opcode == 'I' ? pax->fiatoshis : pax->komodoshis),dstr(block.vtx[0].vout[i].nValue),pax);
|
printf(">>>>>>>>>>> %c errs.%d i.%d match %.8f vs %.8f paxmarked.%d kht.%d ht.%d\n",opcode,errs,i,dstr(opcode == 'I' ? pax->fiatoshis : pax->komodoshis),dstr(block.vtx[0].vout[i].nValue),pax->marked,pax->height,pax->otherheight);
|
||||||
errs++;
|
if ( pax->komodoshis != 0 || pax->fiatoshis != 0 )
|
||||||
|
errs++;
|
||||||
|
else matched++; // onetime init bypass
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -709,7 +721,7 @@ const char *komodo_opreturn(int32_t height,uint64_t value,uint8_t *opretbuf,int3
|
|||||||
{
|
{
|
||||||
basesp->deposited += fiatoshis;
|
basesp->deposited += fiatoshis;
|
||||||
didstats = 1;
|
didstats = 1;
|
||||||
if ( strcmp(base,ASSETCHAINS_SYMBOL) == 0 )
|
if ( 0 && strcmp(base,ASSETCHAINS_SYMBOL) == 0 )
|
||||||
printf("########### %p deposited %s += %.8f kmdheight.%d %.8f\n",basesp,base,dstr(fiatoshis),kmdheight,dstr(value));
|
printf("########### %p deposited %s += %.8f kmdheight.%d %.8f\n",basesp,base,dstr(fiatoshis),kmdheight,dstr(value));
|
||||||
} else printf("cant get stateptr.(%s)\n",base);
|
} else printf("cant get stateptr.(%s)\n",base);
|
||||||
komodo_gateway_deposit(coinaddr,value,base,fiatoshis,rmd160,txid,vout,'D',kmdheight,height,(char *)"KMD",0);
|
komodo_gateway_deposit(coinaddr,value,base,fiatoshis,rmd160,txid,vout,'D',kmdheight,height,(char *)"KMD",0);
|
||||||
@@ -726,7 +738,7 @@ const char *komodo_opreturn(int32_t height,uint64_t value,uint8_t *opretbuf,int3
|
|||||||
{
|
{
|
||||||
basesp->deposited += fiatoshis;
|
basesp->deposited += fiatoshis;
|
||||||
didstats = 1;
|
didstats = 1;
|
||||||
if ( strcmp(base,ASSETCHAINS_SYMBOL) == 0 )
|
if ( 0 && strcmp(base,ASSETCHAINS_SYMBOL) == 0 )
|
||||||
printf("########### %p deposited %s += %.8f/%.8f kmdheight.%d/%d %.8f/%.8f\n",basesp,base,dstr(fiatoshis),dstr(pax->fiatoshis),kmdheight,pax->height,dstr(value),dstr(pax->komodoshis));
|
printf("########### %p deposited %s += %.8f/%.8f kmdheight.%d/%d %.8f/%.8f\n",basesp,base,dstr(fiatoshis),dstr(pax->fiatoshis),kmdheight,pax->height,dstr(value),dstr(pax->komodoshis));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -744,7 +756,7 @@ const char *komodo_opreturn(int32_t height,uint64_t value,uint8_t *opretbuf,int3
|
|||||||
{
|
{
|
||||||
basesp->issued += pax2->fiatoshis;
|
basesp->issued += pax2->fiatoshis;
|
||||||
pax2->didstats = 1;
|
pax2->didstats = 1;
|
||||||
if ( strcmp(base,ASSETCHAINS_SYMBOL) == 0 )
|
if ( 0 && strcmp(base,ASSETCHAINS_SYMBOL) == 0 )
|
||||||
printf("########### %p issueda %s += %.8f kmdheight.%d %.8f other.%d\n",basesp,base,dstr(pax2->fiatoshis),pax2->height,dstr(pax2->komodoshis),pax2->otherheight);
|
printf("########### %p issueda %s += %.8f kmdheight.%d %.8f other.%d\n",basesp,base,dstr(pax2->fiatoshis),pax2->height,dstr(pax2->komodoshis),pax2->otherheight);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -791,7 +803,7 @@ const char *komodo_opreturn(int32_t height,uint64_t value,uint8_t *opretbuf,int3
|
|||||||
pax->didstats = 1;
|
pax->didstats = 1;
|
||||||
pax->height = pax2->height;
|
pax->height = pax2->height;
|
||||||
pax->otherheight = height;
|
pax->otherheight = height;
|
||||||
if ( strcmp(CURRENCIES[baseids[i]],ASSETCHAINS_SYMBOL) == 0 )
|
if ( 0 && strcmp(CURRENCIES[baseids[i]],ASSETCHAINS_SYMBOL) == 0 )
|
||||||
printf("########### %p issuedb %s += %.8f kmdheight.%d %.8f other.%d\n",basesp,CURRENCIES[baseids[i]],dstr(pax->fiatoshis),pax->height,dstr(pax->komodoshis),pax->otherheight);
|
printf("########### %p issuedb %s += %.8f kmdheight.%d %.8f other.%d\n",basesp,CURRENCIES[baseids[i]],dstr(pax->fiatoshis),pax->height,dstr(pax->komodoshis),pax->otherheight);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -807,6 +819,13 @@ const char *komodo_opreturn(int32_t height,uint64_t value,uint8_t *opretbuf,int3
|
|||||||
}
|
}
|
||||||
else if ( opretbuf[0] == 'W' )//&& opretlen >= 38 )
|
else if ( opretbuf[0] == 'W' )//&& opretlen >= 38 )
|
||||||
{
|
{
|
||||||
|
if ( komodo_baseid((char *)&opretbuf[opretlen-4]) >= 0 )
|
||||||
|
{
|
||||||
|
for (i=0; i<opretlen; i++)
|
||||||
|
printf("%02x",opretbuf[i]);
|
||||||
|
printf(" reject obsolete withdraw request\n");
|
||||||
|
return(typestr);
|
||||||
|
}
|
||||||
tokomodo = 1;
|
tokomodo = 1;
|
||||||
iguana_rwnum(0,&opretbuf[34],sizeof(kmdheight),&kmdheight);
|
iguana_rwnum(0,&opretbuf[34],sizeof(kmdheight),&kmdheight);
|
||||||
memset(base,0,sizeof(base));
|
memset(base,0,sizeof(base));
|
||||||
@@ -814,8 +833,7 @@ const char *komodo_opreturn(int32_t height,uint64_t value,uint8_t *opretbuf,int3
|
|||||||
bitcoin_address(coinaddr,addrtype,rmd160,20);
|
bitcoin_address(coinaddr,addrtype,rmd160,20);
|
||||||
checktoshis = PAX_fiatdest(&seed,tokomodo,destaddr,pubkey33,coinaddr,kmdheight,base,value);
|
checktoshis = PAX_fiatdest(&seed,tokomodo,destaddr,pubkey33,coinaddr,kmdheight,base,value);
|
||||||
typestr = "withdraw";
|
typestr = "withdraw";
|
||||||
if ( 0 && strcmp(base,"RUB") == 0 )
|
//printf(" [%s] WITHDRAW %s.height.%d vs height.%d check %.8f/%.8f vs %.8f tokomodo.%d %d seed.%llx -> (%s) len.%d\n",ASSETCHAINS_SYMBOL,base,kmdheight,height,dstr(checktoshis),dstr(komodoshis),dstr(value),komodo_is_issuer(),strncmp(ASSETCHAINS_SYMBOL,base,strlen(base)) == 0,(long long)seed,coinaddr,opretlen);
|
||||||
printf("RUB WITHDRAW %s.height.%d vs height.%d check %.8f/%.8f vs %.8f tokomodo.%d %d seed.%llx -> (%s) len.%d\n",ASSETCHAINS_SYMBOL,kmdheight,height,dstr(checktoshis),dstr(komodoshis),dstr(value),komodo_is_issuer(),strncmp(ASSETCHAINS_SYMBOL,base,strlen(base)) == 0,(long long)seed,coinaddr,opretlen);
|
|
||||||
didstats = 0;
|
didstats = 0;
|
||||||
//if ( komodo_paxcmp(base,kmdheight,komodoshis,checktoshis,seed) == 0 )
|
//if ( komodo_paxcmp(base,kmdheight,komodoshis,checktoshis,seed) == 0 )
|
||||||
{
|
{
|
||||||
@@ -895,8 +913,7 @@ const char *komodo_opreturn(int32_t height,uint64_t value,uint8_t *opretbuf,int3
|
|||||||
{
|
{
|
||||||
basesp->approved += values[i];
|
basesp->approved += values[i];
|
||||||
didstats = 1;
|
didstats = 1;
|
||||||
if ( strcmp(CURRENCIES[baseids[i]],ASSETCHAINS_SYMBOL) == 0 )
|
printf("pax.%p ########### %p approved %s += %.8f -> %.8f/%.8f kht.%d %d\n",pax,basesp,CURRENCIES[baseids[i]],dstr(values[i]),dstr(srcvalues[i]),dstr(checktoshis),kmdheights[i],otherheights[i]);
|
||||||
printf("pax.%p ########### %p approved %s += %.8f -> %.8f/%.8f kht.%d %d\n",pax,basesp,CURRENCIES[baseids[i]],dstr(values[i]),dstr(srcvalues[i]),dstr(checktoshis),kmdheights[i],otherheights[i]);
|
|
||||||
}
|
}
|
||||||
//printf(" i.%d (%s) <- %.8f ADDFLAG APPROVED\n",i,coinaddr,dstr(values[i]));
|
//printf(" i.%d (%s) <- %.8f ADDFLAG APPROVED\n",i,coinaddr,dstr(values[i]));
|
||||||
}
|
}
|
||||||
@@ -906,8 +923,7 @@ const char *komodo_opreturn(int32_t height,uint64_t value,uint8_t *opretbuf,int3
|
|||||||
{
|
{
|
||||||
basesp->approved += values[i];
|
basesp->approved += values[i];
|
||||||
didstats = 1;
|
didstats = 1;
|
||||||
if ( strcmp(CURRENCIES[baseids[i]],ASSETCHAINS_SYMBOL) == 0 )
|
printf("pax.%p ########### %p approved %s += %.8f -> %.8f/%.8f kht.%d %d\n",pax,basesp,CURRENCIES[baseids[i]],dstr(values[i]),dstr(srcvalues[i]),dstr(checktoshis),kmdheights[i],otherheights[i]);
|
||||||
printf("pax.%p ########### %p approved %s += %.8f -> %.8f/%.8f\n",pax,basesp,CURRENCIES[baseids[i]],dstr(values[i]),dstr(srcvalues[i]),dstr(checktoshis));
|
|
||||||
}
|
}
|
||||||
} //else printf(" i.%d of n.%d pax.%p baseids[] %d\n",i,n,pax,baseids[i]);
|
} //else printf(" i.%d of n.%d pax.%p baseids[] %d\n",i,n,pax,baseids[i]);
|
||||||
if ( (pax= komodo_paxfind(txids[i],vouts[i],'A')) != 0 )
|
if ( (pax= komodo_paxfind(txids[i],vouts[i],'A')) != 0 )
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/******************************************************************************
|
/******************************************************************************
|
||||||
* Copyright © 2014-2016 The SuperNET Developers. *
|
* Copyright © 2014-2017 The SuperNET Developers. *
|
||||||
* *
|
* *
|
||||||
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
||||||
* the top-level directory of this distribution for the individual copyright *
|
* the top-level directory of this distribution for the individual copyright *
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/******************************************************************************
|
/******************************************************************************
|
||||||
* Copyright © 2014-2016 The SuperNET Developers. *
|
* Copyright © 2014-2017 The SuperNET Developers. *
|
||||||
* *
|
* *
|
||||||
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
||||||
* the top-level directory of this distribution for the individual copyright *
|
* the top-level directory of this distribution for the individual copyright *
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/******************************************************************************
|
/******************************************************************************
|
||||||
* Copyright © 2014-2016 The SuperNET Developers. *
|
* Copyright © 2014-2017 The SuperNET Developers. *
|
||||||
* *
|
* *
|
||||||
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
||||||
* the top-level directory of this distribution for the individual copyright *
|
* the top-level directory of this distribution for the individual copyright *
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/******************************************************************************
|
/******************************************************************************
|
||||||
* Copyright © 2014-2016 The SuperNET Developers. *
|
* Copyright © 2014-2017 The SuperNET Developers. *
|
||||||
* *
|
* *
|
||||||
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
||||||
* the top-level directory of this distribution for the individual copyright *
|
* the top-level directory of this distribution for the individual copyright *
|
||||||
@@ -524,7 +524,7 @@ uint64_t PAX_fiatdest(uint64_t *seedp,int32_t tokomodo,char *destaddr,uint8_t pu
|
|||||||
*seedp = 0;
|
*seedp = 0;
|
||||||
if ( (baseid= komodo_baseid(origbase)) < 0 || baseid == MAX_CURRENCIES )
|
if ( (baseid= komodo_baseid(origbase)) < 0 || baseid == MAX_CURRENCIES )
|
||||||
{
|
{
|
||||||
printf("PAX_fiatdest illegal base.(%s)\n",origbase);
|
printf("[%s] PAX_fiatdest illegal base.(%s)\n",ASSETCHAINS_SYMBOL,origbase);
|
||||||
return(0);
|
return(0);
|
||||||
}
|
}
|
||||||
for (i=0; i<3; i++)
|
for (i=0; i<3; i++)
|
||||||
@@ -533,8 +533,7 @@ uint64_t PAX_fiatdest(uint64_t *seedp,int32_t tokomodo,char *destaddr,uint8_t pu
|
|||||||
if ( fiatoshis < 0 )
|
if ( fiatoshis < 0 )
|
||||||
shortflag = 1, fiatoshis = -fiatoshis;
|
shortflag = 1, fiatoshis = -fiatoshis;
|
||||||
komodoshis = komodo_paxprice(seedp,height,base,(char *)"KMD",(uint64_t)fiatoshis);
|
komodoshis = komodo_paxprice(seedp,height,base,(char *)"KMD",(uint64_t)fiatoshis);
|
||||||
if ( 0 && strcmp(base,"RUB") == 0 )
|
//printf("PAX_fiatdest ht.%d price %s %.8f -> KMD %.8f seed.%llx\n",height,base,(double)fiatoshis/COIN,(double)komodoshis/COIN,(long long)*seedp);
|
||||||
printf("PAX_fiatdest ht.%d price %s %.8f -> KMD %.8f seed.%llx\n",height,base,(double)fiatoshis/COIN,(double)komodoshis/COIN,(long long)*seedp);
|
|
||||||
if ( bitcoin_addr2rmd160(&addrtype,rmd160,coinaddr) == 20 )
|
if ( bitcoin_addr2rmd160(&addrtype,rmd160,coinaddr) == 20 )
|
||||||
{
|
{
|
||||||
PAX_pubkey(1,pubkey33,&addrtype,rmd160,base,&shortflag,tokomodo != 0 ? &komodoshis : &fiatoshis);
|
PAX_pubkey(1,pubkey33,&addrtype,rmd160,base,&shortflag,tokomodo != 0 ? &komodoshis : &fiatoshis);
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/******************************************************************************
|
/******************************************************************************
|
||||||
* Copyright © 2014-2016 The SuperNET Developers. *
|
* Copyright © 2014-2017 The SuperNET Developers. *
|
||||||
* *
|
* *
|
||||||
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
||||||
* the top-level directory of this distribution for the individual copyright *
|
* the top-level directory of this distribution for the individual copyright *
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/******************************************************************************
|
/******************************************************************************
|
||||||
* Copyright © 2014-2016 The SuperNET Developers. *
|
* Copyright © 2014-2017 The SuperNET Developers. *
|
||||||
* *
|
* *
|
||||||
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
||||||
* the top-level directory of this distribution for the individual copyright *
|
* the top-level directory of this distribution for the individual copyright *
|
||||||
|
|||||||
@@ -1124,8 +1124,10 @@ bool AcceptToMemoryPool(CTxMemPool& pool, CValidationState &state, const CTransa
|
|||||||
COutPoint outpoint = tx.vin[i].prevout;
|
COutPoint outpoint = tx.vin[i].prevout;
|
||||||
if (pool.mapNextTx.count(outpoint))
|
if (pool.mapNextTx.count(outpoint))
|
||||||
{
|
{
|
||||||
|
static uint32_t counter;
|
||||||
// Disable replacement feature for now
|
// Disable replacement feature for now
|
||||||
fprintf(stderr,"Disable replacement feature for now\n");
|
if ( counter++ < 100 )
|
||||||
|
fprintf(stderr,"Disable replacement feature for now\n");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
16
toolchain-info.sh
Executable file
16
toolchain-info.sh
Executable file
@@ -0,0 +1,16 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
tools=("gcc-5" "g++-5" "otool" "nm")
|
||||||
|
|
||||||
|
echo "Platform: `uname -a`"
|
||||||
|
echo "-------------------------------------"
|
||||||
|
echo "Tool info:"
|
||||||
|
echo
|
||||||
|
for tool in "${tools[@]}"
|
||||||
|
do
|
||||||
|
echo "$tool location: `which $tool`"
|
||||||
|
echo "$tool version: `$tool --version`"
|
||||||
|
echo
|
||||||
|
echo "-------"
|
||||||
|
echo
|
||||||
|
done
|
||||||
50
zcutil/build-mac.sh
Executable file
50
zcutil/build-mac.sh
Executable file
@@ -0,0 +1,50 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
export CC=gcc-5
|
||||||
|
export CXX=g++-5
|
||||||
|
export LIBTOOL=libtool
|
||||||
|
export AR=ar
|
||||||
|
export RANLIB=ranlib
|
||||||
|
export STRIP=strip
|
||||||
|
export OTOOL=otool
|
||||||
|
export NM=nm
|
||||||
|
|
||||||
|
set -eu -o pipefail
|
||||||
|
|
||||||
|
if [ "x$*" = 'x--help' ]
|
||||||
|
then
|
||||||
|
cat <<EOF
|
||||||
|
Usage:
|
||||||
|
|
||||||
|
$0 --help
|
||||||
|
Show this help message and exit.
|
||||||
|
|
||||||
|
$0 [ --enable-lcov ] [ MAKEARGS... ]
|
||||||
|
Build Zcash and most of its transitive dependencies from
|
||||||
|
source. MAKEARGS are applied to both dependencies and Zcash itself. If
|
||||||
|
--enable-lcov is passed, Zcash is configured to add coverage
|
||||||
|
instrumentation, thus enabling "make cov" to work.
|
||||||
|
EOF
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
# If --enable-lcov is the first argument, enable lcov coverage support:
|
||||||
|
LCOV_ARG=''
|
||||||
|
HARDENING_ARG='--disable-hardening'
|
||||||
|
if [ "x${1:-}" = 'x--enable-lcov' ]
|
||||||
|
then
|
||||||
|
LCOV_ARG='--enable-lcov'
|
||||||
|
HARDENING_ARG='--disable-hardening'
|
||||||
|
shift
|
||||||
|
fi
|
||||||
|
|
||||||
|
TRIPLET=`./depends/config.guess`
|
||||||
|
PREFIX="$(pwd)/depends/$TRIPLET"
|
||||||
|
|
||||||
|
make "$@" -C ./depends/ V=1 NO_QT=1
|
||||||
|
|
||||||
|
./autogen.sh
|
||||||
|
CPPFLAGS="-I$PREFIX/include -arch x86_64" LDFLAGS="-L$PREFIX/lib -arch x86_64 -Wl,-no_pie -fopenmp" \
|
||||||
|
CXXFLAGS='-arch x86_64 -I/usr/local/Cellar/gcc5/5.4.0/include/c++/5.4.0 -I$PREFIX/include -fwrapv -fno-strict-aliasing -Werror -g -Wl,-undefined -Wl,dynamic_lookup' \
|
||||||
|
./configure --prefix="${PREFIX}" --with-gui=no "$HARDENING_ARG" "$LCOV_ARG"
|
||||||
|
|
||||||
|
make "$@" V=1 NO_GTEST=1 STATIC=1
|
||||||
@@ -66,5 +66,5 @@ PREFIX="$(pwd)/depends/$BUILD/"
|
|||||||
|
|
||||||
HOST="$HOST" BUILD="$BUILD" "$MAKE" "$@" -C ./depends/ V=1 NO_QT=1
|
HOST="$HOST" BUILD="$BUILD" "$MAKE" "$@" -C ./depends/ V=1 NO_QT=1
|
||||||
./autogen.sh
|
./autogen.sh
|
||||||
CC="$CC" CXX="$CXX" ./configure --prefix="${PREFIX}" --host="$HOST" --build="$BUILD" --with-gui=no "$HARDENING_ARG" "$LCOV_ARG" "$TEST_ARG" CXXFLAGS='-fwrapv -fno-strict-aliasing -Werror -g'
|
CC="$CC" CXX="$CXX" ./configure --prefix="${PREFIX}" --host="$HOST" --build="$BUILD" --with-gui=no "$HARDENING_ARG" "$LCOV_ARG" "$TEST_ARG" CXXFLAGS='-fwrapv -fno-strict-aliasing -Werror -g -fopenmp'
|
||||||
"$MAKE" "$@" V=1
|
"$MAKE" "$@" V=1
|
||||||
|
|||||||
Reference in New Issue
Block a user