makefile.dj 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. #***************************************************************************
  2. # _ _ ____ _
  3. # Project ___| | | | _ \| |
  4. # / __| | | | |_) | |
  5. # | (__| |_| | _ <| |___
  6. # \___|\___/|_| \_\_____|
  7. #
  8. # Copyright (C) 2003 - 2021, Gisle Vanem <gvanem@yahoo.no>.
  9. # Copyright (C) 2003 - 2020, Daniel Stenberg, <daniel@haxx.se>, et al.
  10. #
  11. # This software is licensed as described in the file COPYING, which
  12. # you should have received as part of this distribution. The terms
  13. # are also available at https://curl.se/docs/copyright.html.
  14. #
  15. # You may opt to use, copy, modify, merge, publish, distribute and/or sell
  16. # copies of the Software, and permit persons to whom the Software is
  17. # furnished to do so, under the terms of the COPYING file.
  18. #
  19. # This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
  20. # KIND, either express or implied.
  21. #
  22. #***************************************************************************
  23. #
  24. # Adapted for djgpp2 / Watt-32 / DOS
  25. #
  26. DEPEND_PREREQ = # tool_hugehelp.c
  27. TOPDIR = ..
  28. vpath %.c ../lib
  29. include ../packages/DOS/common.dj
  30. include Makefile.inc
  31. CSOURCES = $(CURL_CFILES) $(CURLX_CFILES)
  32. ifeq ($(USE_OPENSSL),1)
  33. EX_LIBS += $(OPENSSL_LIBS)
  34. endif
  35. ifeq ($(USE_ARES),1)
  36. EX_LIBS += $(ARES_ROOT)/libcares.a
  37. endif
  38. ifeq ($(USE_ZLIB),1)
  39. EX_LIBS += $(ZLIB_ROOT)/libz.a
  40. CFLAGS += -DUSE_MANUAL
  41. endif
  42. ifeq ($(USE_IDNA),1)
  43. EX_LIBS += $(LIBIDN_ROOT)/lib/dj_obj/libidn.a -liconv
  44. endif
  45. EX_LIBS += $(WATT32_ROOT)/lib/libwatt.a
  46. PROGRAM = curl.exe
  47. OBJECTS = $(addprefix $(OBJ_DIR)/, $(notdir $(CSOURCES:.c=.o)))
  48. all: $(OBJ_DIR) $(PROGRAM)
  49. @echo Welcome to curl
  50. $(PROGRAM): $(OBJECTS) ../lib/libcurl.a
  51. $(CC) -o $@ $^ $(LDFLAGS) $(EX_LIBS)
  52. #
  53. # groff 1.18+ requires "-P -c"
  54. # If 'USE_ZLIB = 1', create a compressed help-file.
  55. #
  56. ifeq ($(USE_ZLIB),1)
  57. COMPRESS_OPT = -c
  58. endif
  59. tool_hugehelp.c: ../docs/curl.1 mkhelp.pl Makefile.dj
  60. groff -Tascii -man $< | perl -w mkhelp.pl $(COMPRESS_OPT) $< > $@
  61. # clean generated files
  62. #
  63. genclean:
  64. - $(DELETE) tool_hugehelp.c
  65. # clean object files and subdir
  66. #
  67. objclean: genclean
  68. - $(DELETE) $(OBJ_DIR)$(DS)*.o
  69. - $(RMDIR) $(OBJ_DIR)
  70. # clean without removing built program
  71. #
  72. clean: objclean
  73. - $(DELETE) depend.dj
  74. # clean everything
  75. #
  76. realclean vclean: clean
  77. - $(DELETE) $(PROGRAM)
  78. -include depend.dj