diff options
Diffstat (limited to 'app-text/blahtexml/files/blahtexml-0.9-Makefile.patch')
-rw-r--r-- | app-text/blahtexml/files/blahtexml-0.9-Makefile.patch | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/app-text/blahtexml/files/blahtexml-0.9-Makefile.patch b/app-text/blahtexml/files/blahtexml-0.9-Makefile.patch new file mode 100644 index 000000000000..1402c9c80109 --- /dev/null +++ b/app-text/blahtexml/files/blahtexml-0.9-Makefile.patch @@ -0,0 +1,53 @@ +Use pkg-config for xerces-c +Respect CXX and CC +Replace CFLAGS with CXXFLAGS where needed +Add LDFLAGS +--- makefile.old 2010-04-07 18:45:30.000000000 +0200 ++++ makefile 2012-08-15 23:48:03.218394478 +0200 +@@ -93,35 +93,39 @@ + + $(BINDIR_XMLIN)/InputSymbolTranslation.o: InputSymbolTranslation.cpp InputSymbolTranslation.inc + +-CFLAGS = -O2 ++CFLAGS ?= -O2 + + VPATH = Source:Source/BlahtexCore:Source/BlahtexXMLin + + INCLUDES=-I. -ISource -ISource/BlahtexCore -ISource/BlahtexXMLin + ++CXXFLAGS += $(shell pkg-config --cflags xerces-c) ++ ++XERCES_LIB = $(shell pkg-config --libs xerces-c) ++ + $(BINDIR)/%.o:%.cpp +- $(CXX) $(INCLUDES) $(CFLAGS) -c $< -o $@ ++ $(CXX) $(INCLUDES) $(CXXFLAGS) -c $< -o $@ + + $(BINDIR)/%.o:%.c + $(CC) $(INCLUDES) $(CFLAGS) -c $< -o $@ + + $(BINDIR_XMLIN)/%.o:%.cpp +- $(CXX) $(INCLUDES) $(CFLAGS) -DBLAHTEXML_USING_XERCES -c $< -o $@ ++ $(CXX) $(INCLUDES) $(CXXFLAGS) -DBLAHTEXML_USING_XERCES -c $< -o $@ + + $(BINDIR_XMLIN)/%.o:%.c + $(CC) $(INCLUDES) $(CFLAGS) -DBLAHTEXML_USING_XERCES -c $< -o $@ + + blahtex-linux: $(BINDIR) $(OBJECTS) $(HEADERS) +- $(CXX) $(CFLAGS) -o blahtex $(OBJECTS) ++ $(CXX) $(CXXFLAGS) $(LDFLAGS) -o blahtex $(OBJECTS) $(LIBS) + + blahtex-mac: $(BINDIR) $(OBJECTS) $(HEADERS) +- $(CXX) $(CFLAGS) -o blahtex -liconv $(OBJECTS) ++ $(CXX) $(CXXFLAGS) $(LDFLAGS) -o blahtex -liconv $(OBJECTS) $(LIBS) + + blahtexml-linux: $(BINDIR_XMLIN) $(OBJECTS_XMLIN) $(HEADERS_XMLIN) +- $(CXX) $(CFLAGS) -o blahtexml $(OBJECTS_XMLIN) -lxerces-c ++ $(CXX) $(CXXFLAGS) $(LDFLAGS) -o blahtexml $(OBJECTS_XMLIN) $(LIBS) $(XERCES_LIB) + + blahtexml-mac: $(BINDIR_XMLIN) $(OBJECTS_XMLIN) $(HEADERS_XMLIN) +- $(CXX) $(CFLAGS) -o blahtexml -liconv $(OBJECTS_XMLIN) -lxerces-c ++ $(CXX) $(CXXFLAGS) $(LDFLAGS) -o blahtexml -liconv $(OBJECTS_XMLIN) $(LIBS) $(XERCES_LIB) + + clean: + rm -f blahtex $(OBJECTS) blahtexml $(OBJECTS_XMLIN) |