patch-Makefile 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. --- w-tzdata-2013d-1.orig/Makefile 2013-07-05 16:38:01.000000000 +0200
  2. +++ w-tzdata-2013d-1/Makefile 2013-10-04 11:29:22.000000000 +0200
  3. @@ -231,7 +231,7 @@ GCC_DEBUG_FLAGS = -Dlint -g3 -O3 -fno-co
  4. # before the first Monday in January when a "%V" format is used and January 1
  5. # falls on a Friday, Saturday, or Sunday.
  6. -CFLAGS=
  7. +CFLAGS?=
  8. # Linker flags. Default to $(LFLAGS) for backwards compatibility
  9. # to tzcode2012h and earlier.
  10. @@ -239,7 +239,7 @@ CFLAGS=
  11. LDFLAGS= $(LFLAGS)
  12. zic= ./zic
  13. -ZIC= $(zic) $(ZFLAGS)
  14. +ZIC= ./zic_for_build $(ZFLAGS)
  15. # The name of a Posix-compliant `awk' on your system.
  16. AWK= awk
  17. @@ -330,7 +330,7 @@ ENCHILADA= $(COMMON) $(DOCS) $(SOURCES)
  18. SHELL= /bin/sh
  19. -all: tzselect zic zdump $(LIBOBJS)
  20. +all: zic_for_build tzselect zic zdump $(LIBOBJS)
  21. ALL: all date
  22. @@ -365,6 +365,14 @@ version.h:
  23. echo 'static char const TZVERSION[]="$(VERSION)";' && \
  24. echo 'static char const REPORT_BUGS_TO[]="$(BUGEMAIL)";') >$@
  25. +zic_for_build: version.h
  26. + $(CC_FOR_BUILD) -c $(CFLAGS_FOR_BUILD) zic.c -o zic_build.o
  27. + $(CC_FOR_BUILD) -c $(CFLAGS_FOR_BUILD) localtime.c -o localtime_build.o
  28. + $(CC_FOR_BUILD) -c $(CFLAGS_FOR_BUILD) asctime.c -o asctime_build.o
  29. + $(CC_FOR_BUILD) -c $(CFLAGS_FOR_BUILD) scheck.c -o scheck_build.o
  30. + $(CC_FOR_BUILD) -c $(CFLAGS_FOR_BUILD) ialloc.c -o ialloc_build.o
  31. + $(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) -o $@ zic_build.o localtime_build.o asctime_build.o scheck_build.o ialloc_build.o
  32. +
  33. zdump: $(TZDOBJS)
  34. $(CC) -o $@ $(CFLAGS) $(LDFLAGS) $(TZDOBJS) $(LDLIBS)
  35. @@ -375,10 +383,10 @@ yearistype: yearistype.sh
  36. cp yearistype.sh yearistype
  37. chmod +x yearistype
  38. -posix_only: zic $(TDATA)
  39. +posix_only: zic_for_build $(TDATA)
  40. $(ZIC) -y $(YEARISTYPE) -d $(TZDIR) -L /dev/null $(TDATA)
  41. -right_only: zic leapseconds $(TDATA)
  42. +right_only: zic_for_build leapseconds $(TDATA)
  43. $(ZIC) -y $(YEARISTYPE) -d $(TZDIR) -L leapseconds $(TDATA)
  44. # In earlier versions of this makefile, the other two directories were
  45. @@ -390,7 +398,7 @@ right_only: zic leapseconds $(TDATA)
  46. # Therefore, the other two directories are now siblings of $(TZDIR).
  47. # You must replace all of $(TZDIR) to switch from not using leap seconds
  48. # to using them, or vice versa.
  49. -other_two: zic leapseconds $(TDATA)
  50. +other_two: zic_for_build leapseconds $(TDATA)
  51. $(ZIC) -y $(YEARISTYPE) -d $(TZDIR)-posix -L /dev/null $(TDATA)
  52. $(ZIC) -y $(YEARISTYPE) \
  53. -d $(TZDIR)-leaps -L leapseconds $(TDATA)