mirror of
https://github.com/GOSTSec/gostcoin
synced 2025-01-19 19:20:02 +00:00
Merge branch 'master' of https://github.com/GOSTSec/gostcoin
This commit is contained in:
commit
82cbad7979
@ -374,6 +374,7 @@ isEmpty(BOOST_THREAD_LIB_SUFFIX) {
|
|||||||
|
|
||||||
isEmpty(BDB_LIB_PATH) {
|
isEmpty(BDB_LIB_PATH) {
|
||||||
macx:BDB_LIB_PATH = /opt/local/lib/db48
|
macx:BDB_LIB_PATH = /opt/local/lib/db48
|
||||||
|
win32:BDB_LIB_PATH = /usr/local/lib
|
||||||
}
|
}
|
||||||
|
|
||||||
isEmpty(BDB_LIB_SUFFIX) {
|
isEmpty(BDB_LIB_SUFFIX) {
|
||||||
@ -382,6 +383,7 @@ isEmpty(BDB_LIB_SUFFIX) {
|
|||||||
|
|
||||||
isEmpty(BDB_INCLUDE_PATH) {
|
isEmpty(BDB_INCLUDE_PATH) {
|
||||||
macx:BDB_INCLUDE_PATH = /opt/local/include/db48
|
macx:BDB_INCLUDE_PATH = /opt/local/include/db48
|
||||||
|
win32:BDB_INCLUDE_PATH = /usr/local/include
|
||||||
}
|
}
|
||||||
|
|
||||||
isEmpty(BOOST_LIB_PATH) {
|
isEmpty(BOOST_LIB_PATH) {
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
#############################################################################
|
#############################################################################
|
||||||
# Makefile for building: libi2psam.a
|
# Makefile for building: libi2psam.a
|
||||||
# make -f makefile.unix
|
# make -f makefile.mingw
|
||||||
#############################################################################
|
#############################################################################
|
||||||
|
|
||||||
####### Compiler, tools and options
|
####### Compiler, tools and options
|
||||||
|
@ -35,13 +35,13 @@ namespace Checkpoints
|
|||||||
// + Contains no strange transactions
|
// + Contains no strange transactions
|
||||||
static MapCheckpoints mapCheckpoints =
|
static MapCheckpoints mapCheckpoints =
|
||||||
boost::assign::map_list_of
|
boost::assign::map_list_of
|
||||||
( 1, uint256("0x0000086f3bfd2ca98fa3f912c41d1c4482ed1f5399c289f4cae4420c9c3a3fda"))
|
(1, uint256("0x0000086f3bfd2ca98fa3f912c41d1c4482ed1f5399c289f4cae4420c9c3a3fda"))
|
||||||
( 7, uint256("0x00000ae8c47fc4e0498d1c569eeaa05a4c2214ef95cbef2c2906e2daf78c2c6b"))
|
(7, uint256("0x00000ae8c47fc4e0498d1c569eeaa05a4c2214ef95cbef2c2906e2daf78c2c6b"))
|
||||||
( 777, uint256("0x0000062829795a3ffc0ae5e0f7fe5327fb134c9844b3d3755a1619f378be2de4"))
|
(777, uint256("0x0000062829795a3ffc0ae5e0f7fe5327fb134c9844b3d3755a1619f378be2de4"))
|
||||||
( 7777, uint256("0x0000003182844de51e83b4daa24a874c551bab3ca7d6df3722d126a81f9402b9"))
|
(7777, uint256("0x0000003182844de51e83b4daa24a874c551bab3ca7d6df3722d126a81f9402b9"))
|
||||||
(15417, uint256("0x0000000960989066e7b49fe2057a7c4e0f9371818d0de4767a2735f9fea0e1be"))
|
(15417, uint256("0x0000000960989066e7b49fe2057a7c4e0f9371818d0de4767a2735f9fea0e1be"))
|
||||||
/*(16000, uint256("0x683517a8cae8530f39e636f010ecd1750665c3d91f57ba71d6556535972ab328"))
|
(21578, uint256("0x0000000197f21c5455310f0eb87059fcf695383165e76e7eac0f0535c6912015"))
|
||||||
(77777, uint256("0xf5c98062cb1ad75c792a1851a388447f0edd7cb2271b67ef1241a03c673b7735"))
|
/*(77777, uint256("0xf5c98062cb1ad75c792a1851a388447f0edd7cb2271b67ef1241a03c673b7735"))
|
||||||
(77778, uint256("0xd13f93f9fdac82ea26ed8f90474ed2449c8c24be50a416e43c323a38573c30e5"))
|
(77778, uint256("0xd13f93f9fdac82ea26ed8f90474ed2449c8c24be50a416e43c323a38573c30e5"))
|
||||||
(100000, uint256("0xcc4f0b11e9e17f7a406ac4a71e6e192b9b43e32b300ddecba229c789392497eb"))
|
(100000, uint256("0xcc4f0b11e9e17f7a406ac4a71e6e192b9b43e32b300ddecba229c789392497eb"))
|
||||||
(106000, uint256("0xbe27545eb8ea31c74878b54d500161873ed035afc2fa1f4e7cfa7e84a232b8f9"))
|
(106000, uint256("0xbe27545eb8ea31c74878b54d500161873ed035afc2fa1f4e7cfa7e84a232b8f9"))
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
CXX ?= g++
|
CXX ?= g++
|
||||||
|
|
||||||
USE_IPV6:=1
|
USE_IPV6:=1
|
||||||
USE_DEBUG:=no
|
USE_DEBUG:=0
|
||||||
|
|
||||||
DEPSDIR?=/usr/local
|
DEPSDIR?=/usr/local
|
||||||
BOOST_SUFFIX?=-mt
|
BOOST_SUFFIX?=-mt
|
||||||
@ -48,7 +48,7 @@ LIBS= \
|
|||||||
|
|
||||||
DEFS=-D_MT -DWIN32 -D_WINDOWS -DWIN32_LEAN_AND_MEAN -DBOOST_THREAD_USE_LIB -DBOOST_SPIRIT_THREADSAFE
|
DEFS=-D_MT -DWIN32 -D_WINDOWS -DWIN32_LEAN_AND_MEAN -DBOOST_THREAD_USE_LIB -DBOOST_SPIRIT_THREADSAFE
|
||||||
|
|
||||||
ifneq (${USE_DEBUG}, no)
|
ifneq (${USE_DEBUG}, 0)
|
||||||
DEBUGFLAGS=-g
|
DEBUGFLAGS=-g
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@ -58,21 +58,17 @@ LDFLAGS=-Wl,--dynamicbase -Wl,--nxcompat -Wl,--large-address-aware -Wl,-Bstatic
|
|||||||
|
|
||||||
TESTDEFS = -DTEST_DATA_DIR=$(abspath test/data)
|
TESTDEFS = -DTEST_DATA_DIR=$(abspath test/data)
|
||||||
|
|
||||||
|
|
||||||
ifneq (${USE_IPV6}, -)
|
ifneq (${USE_IPV6}, -)
|
||||||
DEFS += -DUSE_IPV6=$(USE_IPV6)
|
DEFS += -DUSE_IPV6=$(USE_IPV6)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
LIBS += -l stdc++ -l mingwthrd -l kernel32 -l user32 -l gdi32 -l comdlg32 -l winspool -l winmm -l shell32 -l comctl32 -l ole32 -l oleaut32 -l uuid -l rpcrt4 -l advapi32 -l ws2_32 -l mswsock -l shlwapi -l pthread
|
LIBS += -l stdc++ -l mingwthrd -l kernel32 -l user32 -l gdi32 -l comdlg32 -l winspool -l winmm -l shell32 -l comctl32 -l ole32 -l oleaut32 -l uuid -l rpcrt4 -l advapi32 -l ws2_32 -l mswsock -l shlwapi -l pthread
|
||||||
|
|
||||||
# I2P Support
|
|
||||||
DEFS += -DUSE_NATIVE_I2P -I"../i2psam"
|
|
||||||
LIBS += -L"../i2psam"
|
|
||||||
|
|
||||||
# TODO: make the mingw builds smarter about dependencies, like the linux/osx builds are
|
# TODO: make the mingw builds smarter about dependencies, like the linux/osx builds are
|
||||||
HEADERS = $(wildcard *.h)
|
HEADERS = $(wildcard *.h)
|
||||||
|
|
||||||
OBJS= \
|
OBJS= \
|
||||||
|
../i2psam/libi2psam.a \
|
||||||
leveldb/libleveldb.a \
|
leveldb/libleveldb.a \
|
||||||
obj/alert.o \
|
obj/alert.o \
|
||||||
obj/version.o \
|
obj/version.o \
|
||||||
@ -105,7 +101,7 @@ OBJS= \
|
|||||||
obj/noui.o \
|
obj/noui.o \
|
||||||
obj/leveldb.o \
|
obj/leveldb.o \
|
||||||
obj/txdb.o \
|
obj/txdb.o \
|
||||||
obj/Gost.o
|
obj/Gost.o
|
||||||
|
|
||||||
ifdef USE_SSE2
|
ifdef USE_SSE2
|
||||||
DEFS += -DUSE_SSE2
|
DEFS += -DUSE_SSE2
|
||||||
@ -127,6 +123,18 @@ DEFS += $(addprefix -I,$(CURDIR)/leveldb/helpers)
|
|||||||
leveldb/libleveldb.a:
|
leveldb/libleveldb.a:
|
||||||
cd leveldb && $(MAKE) CC=$(CC) CXX=$(CXX) OPT="$(CFLAGS)" TARGET_OS=NATIVE_WINDOWS libleveldb.a libmemenv.a && cd ..
|
cd leveldb && $(MAKE) CC=$(CC) CXX=$(CXX) OPT="$(CFLAGS)" TARGET_OS=NATIVE_WINDOWS libleveldb.a libmemenv.a && cd ..
|
||||||
|
|
||||||
|
# I2P Support
|
||||||
|
DEFS += -DUSE_NATIVE_I2P
|
||||||
|
|
||||||
|
../i2psam/libi2psam.a:
|
||||||
|
cd ../i2psam && $(MAKE) -f makefile.mingw && cd ../src
|
||||||
|
|
||||||
|
obj/build.h: FORCE
|
||||||
|
/bin/sh ../share/genbuild.sh obj/build.h
|
||||||
|
version.cpp: obj/build.h
|
||||||
|
DEFS += -DHAVE_BUILD_INFO
|
||||||
|
INCLUDEPATHS += -I"obj"
|
||||||
|
|
||||||
obj/%-sse2.o: %-sse2.cpp
|
obj/%-sse2.o: %-sse2.cpp
|
||||||
$(CXX) -c $(CFLAGS) -msse2 -mstackrealign -o $@ $<
|
$(CXX) -c $(CFLAGS) -msse2 -mstackrealign -o $@ $<
|
||||||
|
|
||||||
@ -149,5 +157,6 @@ clean:
|
|||||||
rm -f obj/*
|
rm -f obj/*
|
||||||
rm -f obj-test/*
|
rm -f obj-test/*
|
||||||
cd leveldb && $(MAKE) TARGET_OS=NATIVE_WINDOWS clean && cd ..
|
cd leveldb && $(MAKE) TARGET_OS=NATIVE_WINDOWS clean && cd ..
|
||||||
|
cd ../i2psam && $(MAKE) -f makefile.mingw clean && cd ../src
|
||||||
|
|
||||||
FORCE:
|
FORCE:
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
# :=1 --> Enable IPv6 support
|
# :=1 --> Enable IPv6 support
|
||||||
# :=0 --> Disable IPv6 support
|
# :=0 --> Disable IPv6 support
|
||||||
USE_IPV6:=1
|
USE_IPV6:=1
|
||||||
|
USE_DEBUG:=0
|
||||||
|
|
||||||
LINK:=$(CXX)
|
LINK:=$(CXX)
|
||||||
|
|
||||||
@ -42,20 +43,16 @@ TESTLIBS += \
|
|||||||
-l boost_unit_test_framework$(BOOST_LIB_SUFFIX)
|
-l boost_unit_test_framework$(BOOST_LIB_SUFFIX)
|
||||||
|
|
||||||
ifneq (${USE_IPV6}, -)
|
ifneq (${USE_IPV6}, -)
|
||||||
DEFS += -DUSE_IPV6=$(USE_IPV6)
|
DEFS += -DUSE_IPV6=$(USE_IPV6)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
LIBS+= \
|
LIBS += \
|
||||||
-Wl,-B$(LMODE2) \
|
-Wl,-B$(LMODE2) \
|
||||||
-l z \
|
-l z \
|
||||||
-l dl \
|
-l dl \
|
||||||
-l pthread \
|
-l pthread \
|
||||||
-l i2psam
|
-l i2psam
|
||||||
|
|
||||||
# I2P Support
|
|
||||||
DEFS += -DUSE_NATIVE_I2P -I"../i2psam"
|
|
||||||
LIBS += -L"../i2psam"
|
|
||||||
|
|
||||||
# Hardening
|
# Hardening
|
||||||
# Make some classes of vulnerabilities unexploitable in case one is discovered.
|
# Make some classes of vulnerabilities unexploitable in case one is discovered.
|
||||||
#
|
#
|
||||||
@ -89,19 +86,21 @@ LIBS += -L"../i2psam"
|
|||||||
HARDENING+=-D_FORTIFY_SOURCE=2
|
HARDENING+=-D_FORTIFY_SOURCE=2
|
||||||
#
|
#
|
||||||
|
|
||||||
|
ifneq (${USE_DEBUG}, 0)
|
||||||
DEBUGFLAGS=-g
|
DEBUGFLAGS=-g
|
||||||
|
endif
|
||||||
|
|
||||||
# CXXFLAGS can be specified on the make command line, so we use xCXXFLAGS that only
|
# CXXFLAGS can be specified on the make command line, so we use xCXXFLAGS that only
|
||||||
# adds some defaults in front. Unfortunately, CXXFLAGS=... $(CXXFLAGS) does not work.
|
# adds some defaults in front. Unfortunately, CXXFLAGS=... $(CXXFLAGS) does not work.
|
||||||
xCXXFLAGS=-std=c++11 -O2 -pthread -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameter \
|
xCXXFLAGS = -std=c++11 -O2 -pthread -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameter \
|
||||||
$(DEBUGFLAGS) $(DEFS) $(HARDENING) $(CXXFLAGS)
|
$(DEBUGFLAGS) $(DEFS) $(HARDENING) $(CXXFLAGS)
|
||||||
|
|
||||||
# LDFLAGS can be specified on the make command line, so we use xLDFLAGS that only
|
# LDFLAGS can be specified on the make command line, so we use xLDFLAGS that only
|
||||||
# adds some defaults in front. Unfortunately, LDFLAGS=... $(LDFLAGS) does not work.
|
# adds some defaults in front. Unfortunately, LDFLAGS=... $(LDFLAGS) does not work.
|
||||||
xLDFLAGS=$(LDHARDENING) $(LDFLAGS)
|
xLDFLAGS=$(LDHARDENING) $(LDFLAGS)
|
||||||
|
|
||||||
OBJS= \
|
OBJS = \
|
||||||
|
../i2psam/libi2psam.a \
|
||||||
leveldb/libleveldb.a \
|
leveldb/libleveldb.a \
|
||||||
obj/alert.o \
|
obj/alert.o \
|
||||||
obj/version.o \
|
obj/version.o \
|
||||||
@ -114,7 +113,7 @@ OBJS= \
|
|||||||
obj/init.o \
|
obj/init.o \
|
||||||
obj/keystore.o \
|
obj/keystore.o \
|
||||||
obj/i2p.o \
|
obj/i2p.o \
|
||||||
obj/Gost.o \
|
obj/Gost.o \
|
||||||
obj/main.o \
|
obj/main.o \
|
||||||
obj/net.o \
|
obj/net.o \
|
||||||
obj/protocol.o \
|
obj/protocol.o \
|
||||||
@ -158,6 +157,12 @@ DEFS += $(addprefix -I,$(CURDIR)/leveldb/helpers)
|
|||||||
leveldb/libleveldb.a:
|
leveldb/libleveldb.a:
|
||||||
@echo "Building LevelDB ..." && cd leveldb && $(MAKE) CC=$(CC) CXX=$(CXX) OPT="$(xCXXFLAGS)" libleveldb.a libmemenv.a && cd ..
|
@echo "Building LevelDB ..." && cd leveldb && $(MAKE) CC=$(CC) CXX=$(CXX) OPT="$(xCXXFLAGS)" libleveldb.a libmemenv.a && cd ..
|
||||||
|
|
||||||
|
# I2P Support
|
||||||
|
LIBS += -L"../i2psam"
|
||||||
|
DEFS += -DUSE_NATIVE_I2P -I"../i2psam"
|
||||||
|
../i2psam/libi2psam.a:
|
||||||
|
@echo "Building libi2psam ..." && cd ../i2psam && $(MAKE) -f makefile.unix && cd ../src
|
||||||
|
|
||||||
# auto-generated dependencies:
|
# auto-generated dependencies:
|
||||||
-include obj/*.P
|
-include obj/*.P
|
||||||
-include obj-test/*.P
|
-include obj-test/*.P
|
||||||
@ -182,7 +187,6 @@ obj/%.o: %.cpp
|
|||||||
rm -f $(@:%.o=%.d)
|
rm -f $(@:%.o=%.d)
|
||||||
|
|
||||||
gostcoind: $(OBJS:obj/%=obj/%)
|
gostcoind: $(OBJS:obj/%=obj/%)
|
||||||
@(cd ../i2psam; make -f makefile.unix )
|
|
||||||
$(LINK) $(xCXXFLAGS) -o $@ $^ $(xLDFLAGS) $(LIBS)
|
$(LINK) $(xCXXFLAGS) -o $@ $^ $(xLDFLAGS) $(LIBS)
|
||||||
|
|
||||||
TESTOBJS := $(patsubst test/%.cpp,obj-test/%.o,$(wildcard test/*.cpp))
|
TESTOBJS := $(patsubst test/%.cpp,obj-test/%.o,$(wildcard test/*.cpp))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user