summaryrefslogtreecommitdiff
path: root/plugins/TrafficCounter/makefile_gcc
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/TrafficCounter/makefile_gcc')
-rw-r--r--plugins/TrafficCounter/makefile_gcc24
1 files changed, 19 insertions, 5 deletions
diff --git a/plugins/TrafficCounter/makefile_gcc b/plugins/TrafficCounter/makefile_gcc
index 715a961963..692094c54c 100644
--- a/plugins/TrafficCounter/makefile_gcc
+++ b/plugins/TrafficCounter/makefile_gcc
@@ -1,12 +1,16 @@
ifndef CFG
- $(error Specify configuration: CFG=Release|Debug)
+ CFG = Release
+endif
+
+ifndef BIT
+ BIT = 32
endif
COMPILER_OPTS = -c -Wall -fmessage-length=0 -fpermissive -fno-exceptions \
-DUNICODE -D_UNICODE
INCLUDE_PATH = -I../../Include -I../../Include/msapi -I../ExternalAPI
LINKER_OPTS = -nostartfiles -nodefaultlibs -nostdlib -shared -Wl,-Map,$(OUTDIR)/$(PROJECT_NAME).map -Wl,-e,_DllMain@12
-LIBRARIES = -lgcc -lmsvcrt -lkernel32 -lshell32 -luser32 -lcomctl32 -lgdi32 -lmsimg32 -loleaut32 $(FINDIR)10/lib/mir_core.lib
+LIBRARIES = -lgcc -lmsvcrt -lkernel32 -lshell32 -luser32 -lcomctl32 -lgdi32 -lmsimg32 -loleaut32
ifeq ($(CFG), Release)
COMPILER_OPTS += -O2 -Os -DNDEBUG
@@ -19,11 +23,21 @@ else
endif
endif
+ifeq ($(BIT), 32)
+ LIBRARIES += $(FINDIR)10/lib/mir_core.lib
+else
+ ifeq ($(BIT), 64)
+ LIBRARIES += $(FINDIR)10/lib/mir_core64.lib
+ else
+ $(error Invalid bit count specfied: $(BIT))
+ endif
+endif
+
PROJECT_NAME = TrafficCounter
SRCDIR = src
OUTDIR = $(CFG)
FINDIR = ../../bin
-OUTNAME = $(FINDIR)/$(CFG)/Plugins/$(PROJECT_NAME).dll
+OUTNAME = $(FINDIR)/$(CFG)$(BIT)/Plugins/$(PROJECT_NAME).dll
COMPILER = gcc
LINKER = gcc
@@ -75,5 +89,5 @@ $(OUTDIR)/%.obj : $(SRCDIR)/%.cpp
$(OUTDIR)/%.res : res/%.rc
@echo Compiling resources...
- @cat res/*.rc > res/tmp.rc
- @$(RSC) $(INCLUDE_PATH) -i res/tmp.rc -o $@ -J RC -O COFF -c 0x4E3
+ @cat res/*.rc > res/tmp
+ @$(RSC) $(INCLUDE_PATH) -i res/tmp -o $@ -J RC -O COFF -c 0x4E3