Makefile.fpc 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. #
  2. # Makefile.fpc for Free Pascal Netware RTL (Libc)
  3. #
  4. [package]
  5. main=rtl
  6. [target]
  7. loaders=nwplibc nwl_main nwl_dlle
  8. units=$(SYSTEMUNIT) $(UUCHARUNIT) $(OBJPASUNIT) $(MACPASUNIT) $(ISO7185UNIT) $(EXTPASUNIT) $(STRINGSUNIT) \
  9. $(LINEINFOUNIT) $(LNFODWRFUNIT) $(HEAPTRCUNIT) \
  10. nwsnut libc $(DOSUNIT) $(SYSCONSTUNIT) \
  11. $(INITCUNIT) $(SYSUTILSUNIT) $(TYPESUNIT) $(TYPINFOUNIT) $(SORTBASEUNIT) $(FGLUNIT) $(CLASSESUNIT) \
  12. $(CPUUNIT) $(MMXUNIT) $(GETOPTSUNIT) \
  13. $(CHARSETUNIT) $(CPALLUNIT) \
  14. $(RTLCONSTSUNIT) $(MATHUNIT) \
  15. $(DYNLIBSUNIT) $(CMEMUNIT) $(CTYPESUNIT) \
  16. $(SOFTFPUUNIT) $(SFPUX80UNIT) $(UFLOATX80UNIT) $(SFPU128UNIT) $(UFLOAT128UNIT)
  17. rsts=$(MATHUNIT) $(TYPINFOUNIT) $(CLASSESUNIT) $(SYSCONSTUNIT) $(RTLCONSTSUNIT) system
  18. implicitunits=$(EXEINFOUNIT) $(CP_UNITS)
  19. [require]
  20. nortl=y
  21. [install]
  22. fpcpackage=y
  23. [default]
  24. target=netwlibc
  25. [compiler]
  26. includedir=$(INC) $(PROCINC)
  27. sourcedir=$(INC) $(PROCINC) $(COMMON)
  28. [prerules]
  29. RTL=..
  30. INC=$(RTL)/inc
  31. COMMON=$(RTL)/common
  32. PROCINC=$(RTL)/$(CPU_TARGET)
  33. UNITPREFIX=rtl
  34. IMPFILES=nwsnut.imp ws2_32.imp ws2nlm.imp libc.imp netware.imp \
  35. libcclib.imp
  36. # nwplibc.o
  37. SYSUTILS_DEPS_OS = $(DOSUNIT)$(PPUEXT) libc.pp
  38. #debug, -a: dont delete asm, -al include lines
  39. #override FPCOPT+=-a
  40. #override FPCOPT+=-al
  41. # for netware always use multithread
  42. override FPCOPT+=-dMT
  43. # and alway use smartlinking
  44. CREATESMART=1
  45. # Paths
  46. OBJPASDIR=$(RTL)/objpas
  47. # binutils are the same for targets netware and netwlibc
  48. override BINUTILSPREFIX=$(CPU_TARGET)-netware-
  49. [rules]
  50. .NOTPARALLEL:
  51. SYSTEMPPU=$(addsuffix $(PPUEXT),$(SYSTEMUNIT))
  52. # Get the system independent include file names.
  53. # This will set the following variables :
  54. # SYSINCNAMES
  55. include $(INC)/makefile.inc
  56. SYSINCDEPS=$(addprefix $(INC)/,$(SYSINCNAMES))
  57. # Get the processor dependent include file names.
  58. # This will set the following variables :
  59. # CPUINCNAMES
  60. include $(PROCINC)/makefile.cpu
  61. SYSCPUDEPS=$(addprefix $(PROCINC)/,$(CPUINCNAMES))
  62. # Put system unit dependencies together.
  63. SYSDEPS = libc.pp $(SYSINCDEPS) $(SYSCPUDEPS)
  64. copyimpfiles:
  65. $(COPY) $(IMPFILES) $(COMPILER_UNITTARGETDIR)
  66. #
  67. # Loaders
  68. #
  69. #nwpre$(OEXT) : nwpre.as
  70. # $(AS) -o nwpre$(OEXT) nwpre.as
  71. #prelude$(OEXT) : prelude.as
  72. # $(AS) -o prelude$(OEXT) prelude.as
  73. # for now use the gcc pre
  74. nwplibc$(OEXT) :
  75. cp pre/libcpre.gcc.o $(UNITTARGETDIRPREFIX)nwplibc$(OEXT)
  76. nwl_main$(OEXT) : nwl_main.as
  77. $(AS) -o $(UNITTARGETDIRPREFIX)nwl_main$(OEXT) nwl_main.as
  78. nwl_dlle$(OEXT) : nwl_dlle.as
  79. $(AS) -o $(UNITTARGETDIRPREFIX)nwl_dlle$(OEXT) nwl_dlle.as
  80. #
  81. # System Dependent Units
  82. #
  83. netware$(PPUEXT) : netware.pp $(SYSTEMUNIT)$(PPUEXT)
  84. $(COMPILER) -I$(WININC) netware.pp
  85. nwsnut$(PPUEXT) : nwsnut.pp ../netware/nwsnut.pp libc$(PPUEXT) $(SYSTEMUNIT)$(PPUEXT)
  86. #
  87. # Other system-dependent RTL Units
  88. #
  89. aio$(PPUEXT) : aio.pp $(SYSTEMUNIT)$(PPUEXT)
  90. #
  91. # Netware-.imp files need to be installed in the unit-dir
  92. #
  93. override INSTALLPPUFILES+=$(IMPFILES)
  94. override CLEANPPUFILES+=$(addprefix $(COMPILER_UNITTARGETDIR)/,$(IMPFILES))