1
0

patch-Makefile 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. --- tinyxml.orig/Makefile 2013-07-30 15:47:47.000000000 +0200
  2. +++ tinyxml/Makefile 2013-07-30 15:47:46.000000000 +0200
  3. @@ -15,13 +15,13 @@ PROFILE := NO
  4. # TINYXML_USE_STL can be used to turn on STL support. NO, then STL
  5. # will not be used. YES will include the STL files.
  6. -TINYXML_USE_STL := NO
  7. +TINYXML_USE_STL := YES
  8. #****************************************************************************
  9. -CC := gcc
  10. -CXX := g++
  11. -LD := g++
  12. +CC ?= gcc
  13. +CXX ?= g++
  14. +LD := $(CXX)
  15. AR := ar rc
  16. RANLIB := ranlib
  17. @@ -41,9 +41,9 @@ ifeq (YES, ${DEBUG})
  18. CXXFLAGS := ${DEBUG_CXXFLAGS}
  19. LDFLAGS := ${DEBUG_LDFLAGS}
  20. else
  21. - CFLAGS := ${RELEASE_CFLAGS}
  22. - CXXFLAGS := ${RELEASE_CXXFLAGS}
  23. - LDFLAGS := ${RELEASE_LDFLAGS}
  24. + CFLAGS ?= ${RELEASE_CFLAGS}
  25. + CXXFLAGS ?= ${RELEASE_CXXFLAGS}
  26. + LDFLAGS ?= ${RELEASE_LDFLAGS}
  27. endif
  28. ifeq (YES, ${PROFILE})
  29. @@ -81,7 +81,7 @@ CXXFLAGS := ${CXXFLAGS} ${DEFS}
  30. # Targets of the build
  31. #****************************************************************************
  32. -OUTPUT := xmltest
  33. +OUTPUT := libtinyxml.so.2.6.2
  34. all: ${OUTPUT}
  35. @@ -90,7 +90,7 @@ all: ${OUTPUT}
  36. # Source files
  37. #****************************************************************************
  38. -SRCS := tinyxml.cpp tinyxmlparser.cpp xmltest.cpp tinyxmlerror.cpp tinystr.cpp
  39. +SRCS := tinyxml.cpp tinyxmlparser.cpp tinyxmlerror.cpp tinystr.cpp
  40. # Add on the sources for libraries
  41. SRCS := ${SRCS}
  42. @@ -102,7 +102,8 @@ OBJS := $(addsuffix .o,$(basename ${SRCS
  43. #****************************************************************************
  44. ${OUTPUT}: ${OBJS}
  45. - ${LD} -o $@ ${LDFLAGS} ${OBJS} ${LIBS} ${EXTRA_LIBS}
  46. + ${CXX} -shared -Wl,-soname,libtinyxml.so.2.6.2 -o $@ ${OBJS} ${LDFLAGS} ${LIBS} ${EXTRA_LIBS}
  47. + ln -sf libtinyxml.so.2.6.2 libtinyxml.so
  48. #****************************************************************************
  49. # common rules