mirror of
https://github.com/twisterarmy/twister-core.git
synced 2025-01-09 14:28:22 +00:00
Add support to makefile.unix for the same parameters used by bitcoin-qt.pro, dynamic linking unless STATIC=1 is passed
This commit is contained in:
parent
4db9705dd8
commit
b4d0588d06
@ -53,7 +53,7 @@ script: |
|
|||||||
cp $OUTDIR/src/COPYING $OUTDIR
|
cp $OUTDIR/src/COPYING $OUTDIR
|
||||||
cd src
|
cd src
|
||||||
sed 's/$(DEBUGFLAGS)//' -i makefile.unix
|
sed 's/$(DEBUGFLAGS)//' -i makefile.unix
|
||||||
PATH=$INSTDIR/bin:$PATH make -f makefile.unix CXX="g++ -I$INSTDIR/include -L$INSTDIR/lib" $MAKEOPTS bitcoin USE_UPNP=1
|
PATH=$INSTDIR/bin:$PATH make -f makefile.unix STATIC=1 CXX="g++ -I$INSTDIR/include -L$INSTDIR/lib" $MAKEOPTS bitcoin USE_UPNP=1
|
||||||
PATH=$INSTDIR/bin:$PATH make -f makefile.unix CXX="g++ -I$INSTDIR/include -L$INSTDIR/lib" $MAKEOPTS bitcoind USE_UPNP=0
|
PATH=$INSTDIR/bin:$PATH make -f makefile.unix STATIC=1 CXX="g++ -I$INSTDIR/include -L$INSTDIR/lib" $MAKEOPTS bitcoind USE_UPNP=0
|
||||||
mkdir -p $OUTDIR/bin/$GBUILD_BITS
|
mkdir -p $OUTDIR/bin/$GBUILD_BITS
|
||||||
install -s bitcoin bitcoind $OUTDIR/bin/$GBUILD_BITS
|
install -s bitcoin bitcoind $OUTDIR/bin/$GBUILD_BITS
|
||||||
|
@ -65,14 +65,16 @@ If using Boost 1.37, append -mt to the boost libraries in the makefile.
|
|||||||
|
|
||||||
Dependency Build Instructions: Gentoo
|
Dependency Build Instructions: Gentoo
|
||||||
-------------------------------------
|
-------------------------------------
|
||||||
emerge -av boost openssl sys-libs/db
|
|
||||||
|
Note: If you just want to install bitcoind on Gentoo, you can add the Bitcoin
|
||||||
|
overlay and use your package manager:
|
||||||
|
layman -a bitcoin && emerge bitcoind
|
||||||
|
|
||||||
|
emerge -av1 --noreplace boost glib openssl sys-libs/db:4.8
|
||||||
|
|
||||||
Take the following steps to build (no UPnP support):
|
Take the following steps to build (no UPnP support):
|
||||||
cd ${BITCOIN_DIR}/src
|
cd ${BITCOIN_DIR}/src
|
||||||
sed -i 's/<db_cxx.h>/<db4.8\/db_cxx.h>/' *.h # path fix
|
make -f makefile.unix USE_UPNP= BDB_INCLUDE_PATH='/usr/include/db4.8'
|
||||||
sed -i 's/-Bstatic/-Bdynamic/' makefile.unix # dynamic linking
|
|
||||||
sed -i 's/^USE_UPNP:=0$/USE_UPNP:=/' makefile.unix # disable UPnP
|
|
||||||
make -f makefile.unix
|
|
||||||
strip bitcoind
|
strip bitcoind
|
||||||
|
|
||||||
|
|
||||||
|
@ -6,26 +6,45 @@ CXX=g++
|
|||||||
|
|
||||||
USE_UPNP:=0
|
USE_UPNP:=0
|
||||||
|
|
||||||
DEFS=-DNOPCH -DUSE_SSL
|
DEFS=-DNOPCH
|
||||||
|
|
||||||
|
DEFS += $(addprefix -I,$(BOOST_INCLUDE_PATH) $(BDB_INCLUDE_PATH) $(OPENSSL_INCLUDE_PATH))
|
||||||
|
LIBS += $(addprefix -l,$(BOOST_LIB_PATH) $(BDB_LIB_PATH) $(OPENSSL_LIB_PATH))
|
||||||
|
|
||||||
|
LMODE = dynamic
|
||||||
|
LMODE2 = dynamic
|
||||||
|
ifdef STATIC
|
||||||
|
LMODE = static
|
||||||
|
ifeq (${STATIC}, all)
|
||||||
|
LMODE2 = static
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
# for boost 1.37, add -mt to the boost libraries
|
# for boost 1.37, add -mt to the boost libraries
|
||||||
LIBS= \
|
LIBS= \
|
||||||
-Wl,-Bstatic \
|
-Wl,-B$(LMODE) \
|
||||||
-l boost_system \
|
-l boost_system$(BOOST_LIB_SUFFIX) \
|
||||||
-l boost_filesystem \
|
-l boost_filesystem$(BOOST_LIB_SUFFIX) \
|
||||||
-l boost_program_options \
|
-l boost_program_options$(BOOST_LIB_SUFFIX) \
|
||||||
-l boost_thread \
|
-l boost_thread$(BOOST_LIB_SUFFIX) \
|
||||||
-l db_cxx \
|
-l db_cxx$(BDB_LIB_SUFFIX) \
|
||||||
-l ssl \
|
-l ssl \
|
||||||
-l crypto
|
-l crypto
|
||||||
|
|
||||||
ifdef USE_UPNP
|
ifndef USE_UPNP
|
||||||
|
override USE_UPNP = -
|
||||||
|
endif
|
||||||
|
ifneq (${USE_UPNP}, -)
|
||||||
LIBS += -l miniupnpc
|
LIBS += -l miniupnpc
|
||||||
DEFS += -DUSE_UPNP=$(USE_UPNP)
|
DEFS += -DUSE_UPNP=$(USE_UPNP)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifneq (${USE_SSL}, 0)
|
||||||
|
DEFS += -DUSE_SSL
|
||||||
|
endif
|
||||||
|
|
||||||
LIBS+= \
|
LIBS+= \
|
||||||
-Wl,-Bdynamic \
|
-Wl,-B$(LMODE2) \
|
||||||
-l gthread-2.0 \
|
-l gthread-2.0 \
|
||||||
-l z \
|
-l z \
|
||||||
-l dl \
|
-l dl \
|
||||||
|
Loading…
Reference in New Issue
Block a user