mirror of
https://github.com/jezhiggins/arabica
synced 2025-01-30 08:38:15 +01:00
Changed the way the parsers are configured. This is now done when compiling the
library, and it is no longer necessary for client application to specify it.
This commit is contained in:
parent
cfb464ec53
commit
13d4953da9
1 changed files with 12 additions and 5 deletions
17
SAX/Makefile
17
SAX/Makefile
|
@ -53,10 +53,12 @@ DYNAMIC_LIBS =
|
||||||
#//////////////////////////////////////////////
|
#//////////////////////////////////////////////
|
||||||
|
|
||||||
# Source files
|
# Source files
|
||||||
|
PARSER_OPTS = -DUSE_EXPAT
|
||||||
|
# define any or all of USE_EXPAT, USE_XERCES, USE_LIBXML2, USE_GARDEN to pull in support
|
||||||
|
# for those parsers.
|
||||||
|
|
||||||
SRCS = wrappers/saxexpat.cpp helpers/InputSourceResolver.cpp ../Utils/utf16utf8_codecvt.cpp
|
|
||||||
# substitute wrappers/saxlibxml2.cpp if appropriate, or omit completely
|
SRCS = saxlib.cpp helpers/InputSourceResolver.cpp ../Utils/utf16utf8_codecvt.cpp
|
||||||
# if using saxxerces
|
|
||||||
|
|
||||||
HDRS = $(patsubst %.c,%.h,$(patsubst %.cpp,%.h,$(SRCS)))
|
HDRS = $(patsubst %.c,%.h,$(patsubst %.cpp,%.h,$(SRCS)))
|
||||||
OBJS = $(patsubst %.c,%.o,$(patsubst %.cpp,%.o,$(SRCS)))
|
OBJS = $(patsubst %.c,%.o,$(patsubst %.cpp,%.o,$(SRCS)))
|
||||||
|
@ -77,7 +79,6 @@ libSAX.a : $(OBJS)
|
||||||
ar r $@ $(OBJS)
|
ar r $@ $(OBJS)
|
||||||
cp libSAX.a ../bin
|
cp libSAX.a ../bin
|
||||||
|
|
||||||
|
|
||||||
#/////////////////////////////////////////////////////////////////////////
|
#/////////////////////////////////////////////////////////////////////////
|
||||||
#//////////////////////////////////////////////
|
#//////////////////////////////////////////////
|
||||||
|
|
||||||
|
@ -86,6 +87,12 @@ libSAX.a : $(OBJS)
|
||||||
%.o : %.cpp
|
%.o : %.cpp
|
||||||
$(CPP) $(COMPILE_FLAGS) $(INCS_DIRS) -o $@ $<
|
$(CPP) $(COMPILE_FLAGS) $(INCS_DIRS) -o $@ $<
|
||||||
|
|
||||||
|
saxlib.cpp : saxlib.tpl ParserConfig.h
|
||||||
|
$(CPP) -x c++ -E $(PARSER_OPTS) saxlib.tpl -o saxlib.cpp
|
||||||
|
|
||||||
|
ParserConfig.h: ParserConfig.tpl
|
||||||
|
$(CPP) -x c++ -E $(PARSER_OPTS) ParserConfig.tpl -o ParserConfig.h
|
||||||
|
|
||||||
|
|
||||||
#/////////////////////////////////////////////////////////////////////////
|
#/////////////////////////////////////////////////////////////////////////
|
||||||
#//////////////////////////////////////////////
|
#//////////////////////////////////////////////
|
||||||
|
@ -106,7 +113,7 @@ depend : .depend
|
||||||
# Cleaning up
|
# Cleaning up
|
||||||
|
|
||||||
clean :
|
clean :
|
||||||
$(REMOVE) .depend *.o helpers/*.o wrappers/*.o ../Utils/*.o libSAX* *~ helpers/*~ core ../bin/libSAX*
|
$(REMOVE) .depend *.o helpers/*.o wrappers/*.o ../Utils/*.o libSAX* *~ helpers/*~ core ../bin/libSAX* saxlib.cpp ParserConfig.h
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue