Make the ranlib and ar executables configurable. Support for setting the cross-compilation tool names easily.

git-svn-id: https://matroska.svn.sourceforge.net/svnroot/matroska/trunk/libmatroska@54 a6f86f6d-0131-4f8e-9e7b-e335508773d5
This commit is contained in:
Moritz Bunkus 2010-03-23 15:09:30 +00:00
parent 44e91f4d61
commit 3676617090

View File

@ -21,9 +21,12 @@ EBML_DLL = yes
ifeq (yes,$(DEBUG))
DEBUGFLAGS=-g -DDEBUG
endif
CXX = g++.exe
LD = g++.exe
WINDRES = windres.exe
CROSS =
CXX = $(CROSS)g++
CC = $(CROSS)gcc
WINDRES = $(CROSS)windres
RANLIB = $(CROSS)ranlib
AR = $(CROSS)ar
RES =
SRC = $(wildcard ../../src/*.cpp)
OBJ = $(patsubst %.cpp,%.o,$(SRC))
@ -61,8 +64,8 @@ distclean dist-clean: clean
rm -f .depend
libmatroska.a: $(OBJ)
ar r $@ $(OBJ)
ranlib $@
$(AR) r $@ $(OBJ)
$(RANLIB) $@
libmatroska.dll: $(OBJ)
$(CXX) -shared -Wl,--export-all -Wl,--out-implib=$@.a -o $@ $(OBJ) \