Browse Source

link with miniupnp

pull/536/head
orignal 9 years ago
parent
commit
0a4888a18f
  1. 94
      Makefile.mingw

94
Makefile.mingw

@ -1,47 +1,47 @@
USE_WIN32_APP=yes USE_WIN32_APP=yes
CXX = g++ CXX = g++
WINDRES = windres WINDRES = windres
CXXFLAGS = -Os -D_MT -DWIN32 -D_WINDOWS -DWIN32_LEAN_AND_MEAN CXXFLAGS = -Os -D_MT -DWIN32 -D_WINDOWS -DWIN32_LEAN_AND_MEAN
NEEDED_CXXFLAGS = -std=c++11 NEEDED_CXXFLAGS = -std=c++11
BOOST_SUFFIX = -mt BOOST_SUFFIX = -mt
INCFLAGS = -I/usr/include/ -I/usr/local/include/ INCFLAGS = -I/usr/include/ -I/usr/local/include/
LDFLAGS = -Wl,-rpath,/usr/local/lib \ LDFLAGS = -Wl,-rpath,/usr/local/lib \
-L/usr/local/lib \ -L/usr/local/lib
-L/c/dev/openssl \
-L/c/dev/boost/lib # UPNP Support
LDLIBS = \ ifeq ($(USE_UPNP),1)
-Wl,-Bstatic -lboost_system$(BOOST_SUFFIX) \ CXXFLAGS += -DUSE_UPNP -DMINIUPNP_STATICLIB
-Wl,-Bstatic -lboost_date_time$(BOOST_SUFFIX) \ LDLIBS = -Wl,-Bstatic -lminiupnpc
-Wl,-Bstatic -lboost_filesystem$(BOOST_SUFFIX) \ endif
-Wl,-Bstatic -lboost_program_options$(BOOST_SUFFIX) \
-Wl,-Bstatic -lssl \ LDLIBS += \
-Wl,-Bstatic -lcrypto \ -Wl,-Bstatic -lboost_system$(BOOST_SUFFIX) \
-Wl,-Bstatic -lz \ -Wl,-Bstatic -lboost_date_time$(BOOST_SUFFIX) \
-Wl,-Bstatic -lwsock32 \ -Wl,-Bstatic -lboost_filesystem$(BOOST_SUFFIX) \
-Wl,-Bstatic -lws2_32 \ -Wl,-Bstatic -lboost_program_options$(BOOST_SUFFIX) \
-Wl,-Bstatic -lgdi32 \ -Wl,-Bstatic -lssl \
-Wl,-Bstatic -liphlpapi \ -Wl,-Bstatic -lcrypto \
-static-libgcc -static-libstdc++ \ -Wl,-Bstatic -lz \
-Wl,-Bstatic -lstdc++ \ -Wl,-Bstatic -lwsock32 \
-Wl,-Bstatic -lpthread -Wl,-Bstatic -lws2_32 \
-Wl,-Bstatic -lgdi32 \
ifeq ($(USE_WIN32_APP), yes) -Wl,-Bstatic -liphlpapi \
CXXFLAGS += -DWIN32_APP -static-libgcc -static-libstdc++ \
LDFLAGS += -mwindows -s -Wl,-Bstatic -lstdc++ \
DAEMON_RC += Win32/Resource.rc -Wl,-Bstatic -lpthread
DAEMON_OBJS += $(patsubst %.rc,obj/%.o,$(DAEMON_RC))
endif ifeq ($(USE_WIN32_APP), yes)
CXXFLAGS += -DWIN32_APP
# UPNP Support LDFLAGS += -mwindows -s
ifeq ($(USE_UPNP),1) DAEMON_RC += Win32/Resource.rc
CXXFLAGS += -DUSE_UPNP DAEMON_OBJS += $(patsubst %.rc,obj/%.o,$(DAEMON_RC))
endif endif
ifeq ($(USE_AESNI),1) ifeq ($(USE_AESNI),1)
CPU_FLAGS = -maes -DAESNI CPU_FLAGS = -maes -DAESNI
else else
CPU_FLAGS = -msse CPU_FLAGS = -msse
endif endif
obj/%.o : %.rc obj/%.o : %.rc
$(WINDRES) -i $< -o $@ $(WINDRES) -i $< -o $@

Loading…
Cancel
Save