summaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authornickysn <nickysn@3ad0048d-3df7-0310-abae-a5850022a9f2>2021-03-13 21:47:24 +0000
committernickysn <nickysn@3ad0048d-3df7-0310-abae-a5850022a9f2>2021-03-13 21:47:24 +0000
commitaed7424e21332198b9d11fa3ce1071a796a9e187 (patch)
treeefd91efb76959c74f5f9a55b36118a17cb8a0213 /utils
parent62c237e276fb82d4b6f2ea98b9c0014279cda9b7 (diff)
parentf4b984d2356cc47030adc7378858c428a399a589 (diff)
downloadfpc-aed7424e21332198b9d11fa3ce1071a796a9e187.tar.gz
* synchronized with trunk
git-svn-id: https://svn.freepascal.org/svn/fpc/branches/wasm@48949 3ad0048d-3df7-0310-abae-a5850022a9f2
Diffstat (limited to 'utils')
-rw-r--r--utils/Makefile8
-rw-r--r--utils/debugsvr/Makefile8
-rw-r--r--utils/dxegen/Makefile8
-rw-r--r--utils/fpcm/Makefile8
-rw-r--r--utils/fpcm/fpcmake.inc676
-rw-r--r--utils/fpcm/fpcmake.ini10
-rw-r--r--utils/fpcm/revision.inc2
-rw-r--r--utils/fpcmkcfg/Makefile8
-rw-r--r--utils/fpcres/Makefile8
-rw-r--r--utils/fpcreslipo/Makefile8
-rw-r--r--utils/fpdoc/Makefile8
-rw-r--r--utils/fpmc/Makefile8
-rw-r--r--utils/fppkg/Makefile8
-rw-r--r--utils/fprcp/Makefile8
-rw-r--r--utils/h2pas/Makefile8
-rw-r--r--utils/ihxutil/Makefile8
-rw-r--r--utils/importtl/Makefile8
-rw-r--r--utils/instantfpc/Makefile8
-rw-r--r--utils/json2pas/Makefile8
-rw-r--r--utils/mksymbian/Makefile8
-rw-r--r--utils/pas2fpm/Makefile8
-rw-r--r--utils/pas2jni/Makefile8
-rw-r--r--utils/pas2js/Makefile8
-rw-r--r--utils/pas2ut/Makefile8
-rw-r--r--utils/rmwait/Makefile8
-rw-r--r--utils/tply/Makefile8
-rw-r--r--utils/unicode/Makefile8
27 files changed, 547 insertions, 333 deletions
diff --git a/utils/Makefile b/utils/Makefile
index 01b1c01ccb..66663047f9 100644
--- a/utils/Makefile
+++ b/utils/Makefile
@@ -616,10 +616,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/debugsvr/Makefile b/utils/debugsvr/Makefile
index a3c7f6a1be..f85a359aa9 100644
--- a/utils/debugsvr/Makefile
+++ b/utils/debugsvr/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/dxegen/Makefile b/utils/dxegen/Makefile
index b796a697b2..030a2afe97 100644
--- a/utils/dxegen/Makefile
+++ b/utils/dxegen/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/fpcm/Makefile b/utils/fpcm/Makefile
index cc02fb9e37..51a11b8d4a 100644
--- a/utils/fpcm/Makefile
+++ b/utils/fpcm/Makefile
@@ -608,10 +608,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/fpcm/fpcmake.inc b/utils/fpcm/fpcmake.inc
index f897955cfd..0525342e08 100644
--- a/utils/fpcm/fpcmake.inc
+++ b/utils/fpcm/fpcmake.inc
@@ -1,7 +1,7 @@
{$ifdef Delphi}
-const fpcmakeini : array[0..255] of string[240]=(
+const fpcmakeini : array[0..256] of string[240]=(
{$else Delphi}
-const fpcmakeini : array[0..255,1..240] of char=(
+const fpcmakeini : array[0..256,1..240] of char=(
{$endif Delphi}
';'#010+
'; Templates used by fpcmake to create a Makefile from Makefile.fpc'#010+
@@ -951,32 +951,40 @@ const fpcmakeini : array[0..255,1..240] of char=(
'ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)'#010+
'FPCMAKE_CROSSGCCOPT','=-mabi=32'#010+
'else'#010+
+ 'ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)'#010+
+ 'FPCMAKE_CROSSGCCOPT=-mabi=lp64'#010+
+ 'else'#010+
+ 'ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)'#010+
+ 'FPCMAKE_CROSSGCCOPT=-mabi=ilp32'#010+
+ 'else'#010+
'FPCMAKE_CROSSGCCOPT=-m32'#010+
'endif'#010+
'endif'#010+
'endif'#010+
+ 'endif',#010+
+ 'endif'#010+
'FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-l'+
'ibgcc-file-name`)'#010+
'endif'#010+
'endif'#010+
#010+
'ifndef FPCMAKEGCCLIBDIR'#010+
- 'FPCMAKEGCCLIBDIR:=$(shell dirname `gcc -print-libgcc-file','-name`)'#010+
+ 'FPCMAKEGCCLIBDIR:=$(shell dirname `gcc -print-libgcc-file-name`)'#010+
'endif'#010+
#010+
'# Try cross gcc'#010+
'ifndef GCCLIBDIR'#010+
- 'CROSSGCC=$(strip $(wildcard $(addsuffix /$(BINUTILSPREFIX)gcc$(SRCEXEE'+
- 'XT),$(SEARCHPATH))))'#010+
+ 'CRO','SSGCC=$(strip $(wildcard $(addsuffix /$(BINUTILSPREFIX)gcc$(SRCEX'+
+ 'EEXT),$(SEARCHPATH))))'#010+
'ifneq ($(CROSSGCC),)'#010+
'GCCLIBDIR:=$(shell dirname `$(CROSSGCC) $(CROSSGCCOPT) -print-libgcc-f'+
- 'ile-name`)',#010+
+ 'ile-name`)'#010+
'endif'#010+
'endif'#010+
'endif'#010+
'#ifeq($(OS_SOURCE),linux)'#010+
#010+
- 'ifdef inUnix'#010+
+ 'ifdef',' inUnix'#010+
'ifeq ($(OS_SOURCE),netbsd)'#010+
'OTHERLIBDIR:=/usr/pkg/lib'#010+
'endif'#010+
@@ -985,10 +993,10 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
#010+
'[extensions]'#010+
- '#######################################################','#############'+
- '#'#010+
- '# Default extensions'#010+
'#####################################################################'#010+
+ '# Default extensions'#010+
+ '###############','#####################################################'+
+ '#'#010+
#010+
'# Default needed extensions (Go32v2,Linux)'#010+
'BATCHEXT=.bat'#010+
@@ -998,21 +1006,21 @@ const fpcmakeini : array[0..255,1..240] of char=(
'PPUEXT=.ppu'#010+
'OEXT=.o'#010+
'LTOEXT=.bc'#010+
- 'ASMEXT=','.s'#010+
+ 'ASMEXT=.s'#010+
'SMARTEXT=.sl'#010+
'STATICLIBEXT=.a'#010+
'SHAREDLIBEXT=.so'#010+
- 'SHAREDLIBPREFIX=libfp'#010+
+ 'SH','AREDLIBPREFIX=libfp'#010+
'STATICLIBPREFIX=libp'#010+
'IMPORTLIBPREFIX=libimp'#010+
'RSTEXT=.rst'#010+
'# external debug info for executable'#010+
'EXEDBGEXT=.dbg'#010+
- '#DEBUGSYMEXT #for debugger symbol files, define only for targ','ets whi'+
- 'ch has this'#010+
+ '#DEBUGSYMEXT #for debugger symbol files, define only for targets which'+
+ ' has this'#010+
#010+
'# Go32v1'#010+
- 'ifeq ($(OS_TARGET),go32v1)'#010+
+ 'ifeq ($(OS_TARGET),go3','2v1)'#010+
'STATICLIBPREFIX='#010+
'SHORTSUFFIX=v1'#010+
'endif'#010+
@@ -1026,11 +1034,11 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'# watcom'#010+
'ifeq ($(OS_TARGET),watcom)'#010+
- 'STATICLIBPREFIX=',#010+
+ 'STATICLIBPREFIX='#010+
'OEXT=.obj'#010+
'ASMEXT=.asm'#010+
'SHAREDLIBEXT=.dll'#010+
- 'SHORTSUFFIX=wat'#010+
+ 'SHORTSUFFI','X=wat'#010+
'IMPORTLIBPREFIX='#010+
'endif'#010+
#010+
@@ -1045,11 +1053,11 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
#010+
'# Linux'#010+
- 'ifeq ($(OS_TARG','ET),linux)'#010+
+ 'ifeq ($(OS_TARGET),linux)'#010+
'BATCHEXT=.sh'#010+
'EXEEXT='#010+
'HASSHAREDLIB=1'#010+
- 'SHORTSUFFIX=lnx'#010+
+ 'SHOR','TSUFFIX=lnx'#010+
'endif'#010+
#010+
'# DragonFly BSD'#010+
@@ -1064,12 +1072,12 @@ const fpcmakeini : array[0..255,1..240] of char=(
'ifeq ($(OS_TARGET),freebsd)'#010+
'BATCHEXT=.sh'#010+
'EXEEXT='#010+
- 'HASSHAR','EDLIB=1'#010+
+ 'HASSHAREDLIB=1'#010+
'SHORTSUFFIX=fbs'#010+
'endif'#010+
#010+
'# NetBSD'#010+
- 'ifeq ($(OS_TARGET),netbsd)'#010+
+ 'ifeq ($(OS_','TARGET),netbsd)'#010+
'BATCHEXT=.sh'#010+
'EXEEXT='#010+
'HASSHAREDLIB=1'#010+
@@ -1085,9 +1093,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
#010+
'# Win32'#010+
- 'ifeq ($(O','S_TARGET),win32)'#010+
+ 'ifeq ($(OS_TARGET),win32)'#010+
'SHAREDLIBEXT=.dll'#010+
- 'SHORTSUFFIX=w32'#010+
+ 'SHORTSUFFIX=w32'#010,
'endif'#010+
#010+
'# OS/2'#010+
@@ -1103,10 +1111,10 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'# EMX'#010+
'ifeq ($(OS_TARGET),emx)'#010+
- 'BATCHEXT=','.cmd'#010+
+ 'BATCHEXT=.cmd'#010+
'AOUTEXT=.out'#010+
'STATICLIBPREFIX='#010+
- 'SHAREDLIBEXT=.dll'#010+
+ 'SHAREDLIBEXT=.dl','l'#010+
'SHORTSUFFIX=emx'#010+
'ECHO=echo'#010+
'IMPORTLIBPREFIX='#010+
@@ -1122,12 +1130,12 @@ const fpcmakeini : array[0..255,1..240] of char=(
'# AROS'#010+
'ifeq ($(OS_TARGET),aros)'#010+
'EXEEXT='#010+
- 'SHAREDLIBE','XT=.library'#010+
+ 'SHAREDLIBEXT=.library'#010+
'SHORTSUFFIX=aros'#010+
'endif'#010+
#010+
'# MorphOS'#010+
- 'ifeq ($(OS_TARGET),morphos)'#010+
+ 'ifeq ','($(OS_TARGET),morphos)'#010+
'EXEEXT='#010+
'SHAREDLIBEXT=.library'#010+
'SHORTSUFFIX=mos'#010+
@@ -1141,13 +1149,13 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'# BeOS'#010+
'ifeq ($(OS_TARGET),beos)'#010+
- 'BATCHEXT=.sh',#010+
+ 'BATCHEXT=.sh'#010+
'EXEEXT='#010+
'SHORTSUFFIX=be'#010+
'endif'#010+
#010+
'# Haiku'#010+
- 'ifeq ($(OS_TARGET),haiku)'#010+
+ 'ifeq ($(OS_T','ARGET),haiku)'#010+
'BATCHEXT=.sh'#010+
'EXEEXT='#010+
'SHORTSUFFIX=hai'#010+
@@ -1163,12 +1171,12 @@ const fpcmakeini : array[0..255,1..240] of char=(
'# QNX'#010+
'ifeq ($(OS_TARGET),qnx)'#010+
'BATCHEXT=.sh'#010+
- 'EXEEXT','='#010+
+ 'EXEEXT='#010+
'SHORTSUFFIX=qnx'#010+
'endif'#010+
#010+
'# Netware clib'#010+
- 'ifeq ($(OS_TARGET),netware)'#010+
+ 'ifeq ($(OS_','TARGET),netware)'#010+
'EXEEXT=.nlm'#010+
'STATICLIBPREFIX='#010+
'SHORTSUFFIX=nw'#010+
@@ -1180,11 +1188,11 @@ const fpcmakeini : array[0..255,1..240] of char=(
'EXEEXT=.nlm'#010+
'STATICLIBPREFIX='#010+
'SHORTSUFFIX=nwl'#010+
- 'IMPORTLIBPRE','FIX=imp'#010+
+ 'IMPORTLIBPREFIX=imp'#010+
'endif'#010+
#010+
'# Mac OS Classic'#010+
- 'ifeq ($(OS_TARGET),macosclassic)'#010+
+ 'ifeq ($(OS_TARGET),','macosclassic)'#010+
'BATCHEXT='#010+
'EXEEXT='#010+
'DEBUGSYMEXT=.xcoff'#010+
@@ -1196,12 +1204,12 @@ const fpcmakeini : array[0..255,1..240] of char=(
'ifneq ($(findstring $(OS_TARGET),darwin iphonesim ios),)'#010+
'BATCHEXT=.sh'#010+
'EXEEXT='#010+
- 'HASSHARE','DLIB=1'#010+
+ 'HASSHAREDLIB=1'#010+
'SHORTSUFFIX=dwn'#010+
'EXEDBGEXT=.dSYM'#010+
'endif'#010+
#010+
- '# gba'#010+
+ '# gba',#010+
'ifeq ($(OS_TARGET),gba)'#010+
'EXEEXT=.gba'#010+
'SHAREDLIBEXT=.so'#010+
@@ -1215,9 +1223,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
#010+
'# NativeNT'#010+
- 'ifeq ($(OS_TARG','ET),NativeNT)'#010+
+ 'ifeq ($(OS_TARGET),NativeNT)'#010+
'SHAREDLIBEXT=.dll'#010+
- 'SHORTSUFFIX=nativent'#010+
+ 'SHORTSUFFIX=nativen','t'#010+
'endif'#010+
#010+
'# wii'#010+
@@ -1236,10 +1244,10 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
#010+
'# Java'#010+
- 'i','feq ($(OS_TARGET),java)'#010+
+ 'ifeq ($(OS_TARGET),java)'#010+
'OEXT=.class'#010+
'ASMEXT=.j'#010+
- 'SHAREDLIBEXT=.jar'#010+
+ 'SHARE','DLIBEXT=.jar'#010+
'SHORTSUFFIX=java'#010+
'endif'#010+
#010+
@@ -1254,9 +1262,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
#010+
'# MS-DOS'#010+
- 'if','eq ($(OS_TARGET),msdos)'#010+
+ 'ifeq ($(OS_TARGET),msdos)'#010+
'STATICLIBPREFIX='#010+
- 'STATICLIBEXT=.a'#010+
+ 'STATICLIBE','XT=.a'#010+
'SHORTSUFFIX=d16'#010+
'endif'#010+
#010+
@@ -1269,12 +1277,12 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'# Embedded'#010+
'ifeq ($(OS_TARGET),embedded)'#010+
- 'ifeq ($(CPU_TARGET),i8086)'#010,
+ 'ifeq ($(CPU_TARGET),i8086)'#010+
'STATICLIBPREFIX='#010+
'STATICLIBEXT=.a'#010+
'else'#010+
'EXEEXT=.bin'#010+
- 'endif'#010+
+ 'e','ndif'#010+
'ifeq ($(CPU_TARGET),z80)'#010+
'OEXT=.rel'#010+
'endif'#010+
@@ -1289,20 +1297,20 @@ const fpcmakeini : array[0..255,1..240] of char=(
'SHORTSUFFIX=w16'#010+
'endif'#010+
#010+
- '# ZX Spectru','m'#010+
+ '# ZX Spectrum'#010+
'ifeq ($(OS_TARGET),zxspectrum)'#010+
'OEXT=.rel'#010+
'endif'#010+
#010+
- #010+
+ #010,
'# For 8.3 limited OS'#039's the short suffixes'#010+
'# Otherwise use the full source/target names'#010+
'ifneq ($(findstring $(OS_SOURCE),$(LIMIT83fs)),)'#010+
'FPCMADE=fpcmade.$(SHORTSUFFIX)'#010+
- 'ZIPSUFFIX=$(SHORTSUFFI','X)'#010+
+ 'ZIPSUFFIX=$(SHORTSUFFIX)'#010+
'ZIPCROSSPREFIX='#010+
'ZIPSOURCESUFFIX=src'#010+
- 'ZIPEXAMPLESUFFIX=exm'#010+
+ 'ZIPEXAMPLESU','FFIX=exm'#010+
'else'#010+
'FPCMADE=fpcmade.$(TARGETSUFFIX)'#010+
'ZIPSOURCESUFFIX=.source'#010+
@@ -1311,19 +1319,19 @@ const fpcmakeini : array[0..255,1..240] of char=(
'ZIPSUFFIX=.$(SOURCESUFFIX)'#010+
'ZIPCROSSPREFIX=$(TARGETSUFFIX)-'#010+
'else'#010+
- 'ZIPSUFFIX','=.$(TARGETSUFFIX)'#010+
+ 'ZIPSUFFIX=.$(TARGETSUFFIX)'#010+
'ZIPCROSSPREFIX='#010+
'endif'#010+
'endif'#010+
#010+
- '[defaulttools]'#010+
+ '[def','aulttools]'#010+
'#####################################################################'#010+
'# Default Tools'#010+
'#####################################################################'#010+
#010+
- '# Names of the binuti','ls tools'#010+
+ '# Names of the binutils tools'#010+
'ASNAME=$(BINUTILSPREFIX)as'#010+
- 'LDNAME=$(BINUTILSPREFIX)ld'#010+
+ 'LDNAME=$(BINUTI','LSPREFIX)ld'#010+
'ARNAME=$(BINUTILSPREFIX)ar'#010+
'RCNAME=$(BINUTILSPREFIX)rc'#010+
'NASMNAME=$(BINUTILSPREFIX)nasm'#010+
@@ -1331,9 +1339,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'# assembler, redefine it if cross compiling'#010+
'ifndef ASPROG'#010+
'ifdef CROSSBINDIR'#010+
- 'ASPROG=$(CROSSB','INDIR)/$(ASNAME)$(SRCEXEEXT)'#010+
+ 'ASPROG=$(CROSSBINDIR)/$(ASNAME)$(SRCEXEEXT)'#010+
'else'#010+
- 'ASPROG=$(ASNAME)'#010+
+ 'ASPROG=$(ASNAME)'#010,
'endif'#010+
'endif'#010+
#010+
@@ -1347,9 +1355,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
#010+
'# Resource compiler'#010+
- 'ifndef RCPROG',#010+
+ 'ifndef RCPROG'#010+
'ifdef CROSSBINDIR'#010+
- 'RCPROG=$(CROSSBINDIR)/$(RCNAME)$(SRCEXEEXT)'#010+
+ 'RCPROG=$(CROSSBINDIR)/$(RCNAME)$','(SRCEXEEXT)'#010+
'else'#010+
'RCPROG=$(RCNAME)'#010+
'endif'#010+
@@ -1364,9 +1372,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
'endif'#010+
#010+
- '# NASM assembler, re','define it if cross compiling'#010+
+ '# NASM assembler, redefine it if cross compiling'#010+
'ifndef NASMPROG'#010+
- 'ifdef CROSSBINDIR'#010+
+ 'ifdef ','CROSSBINDIR'#010+
'NASMPROG=$(CROSSBINDIR)/$(NASMNAME)$(SRCEXEEXT)'#010+
'else'#010+
'NASMPROG=$(NASMNAME)'#010+
@@ -1379,10 +1387,10 @@ const fpcmakeini : array[0..255,1..240] of char=(
'RC=$(RCPROG)'#010+
'AR=$(ARPROG)'#010+
'NASM=$(NASMPROG)'#010+
- #010,
+ #010+
'# ppas.bat / ppas.sh'#010+
'ifdef inUnix'#010+
- 'PPAS=./ppas$(SRCBATCHEXT)'#010+
+ 'PPAS=./ppas$(SRCB','ATCHEXT)'#010+
'else'#010+
'PPAS=ppas$(SRCBATCHEXT)'#010+
'endif'#010+
@@ -1397,14 +1405,14 @@ const fpcmakeini : array[0..255,1..240] of char=(
'ifdef DATE'#010+
'DATESTR:=$(shell $(DATE) +%Y%m%d)'#010+
'else'#010+
- 'DATESTR='#010,
+ 'DATESTR='#010+
'endif'#010+
#010+
'# Zip options'#010+
'ZIPOPT=-9'#010+
'ZIPEXT=.zip'#010+
#010+
- '# Tar options'#010+
+ '# Tar o','ptions'#010+
'ifeq ($(USETAR),bz2)'#010+
'TAROPT=vj'#010+
'TAREXT=.tar.bz2'#010+
@@ -1416,17 +1424,18 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'[command_begin]'#010+
'#####################################################################'#010+
- '# Compiler ','Command Line'#010+
- '#####################################################################'#010+
+ '# Compiler Command Line'#010+
+ '######################################','##############################'+
+ '#'#010+
#010+
'# Load commandline OPTDEF and add FPC_CPU define, for compiling the'#010+
'# compiler this needs to be turned off'#010+
'ifndef NOCPUDEF'#010+
'override FPCOPTDEF=$(ARCH)'#010+
- 'endif'#010,
+ 'endif'#010+
#010+
#010+
- '# Load commandline OPT and add target and unit dir to be sure'#010+
+ '# Load commandline OPT and add target and unit di','r to be sure'#010+
'ifneq ($(OS_TARGET),$(OS_SOURCE))'#010+
'override FPCOPT+=-T$(OS_TARGET)'#010+
'endif'#010+
@@ -1436,18 +1445,18 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
#010+
'ifeq ($(OS_SOURCE),openbsd)'#010+
- 'overr','ide FPCOPT+=-FD$(NEW_BINUTILS_PATH)'#010+
- 'override FPCMAKEOPT+=-FD$(NEW_BINUTILS_PATH)'#010+
+ 'override FPCOPT+=-FD$(NEW_BINUTILS_PATH)'#010+
+ 'override FPCMAK','EOPT+=-FD$(NEW_BINUTILS_PATH)'#010+
'override FPMAKE_BUILD_OPT+=-FD$(NEW_BINUTILS_PATH)'#010+
'endif'#010+
#010+
'ifndef CROSSBOOTSTRAP'#010+
'ifneq ($(BINUTILSPREFIX),)'#010+
'override FPCOPT+=-XP$(BINUTILSPREFIX)'#010+
- 'ifneq ($(RLINK','PATH),)'#010+
+ 'ifneq ($(RLINKPATH),)'#010+
'override FPCOPT+=-Xr$(RLINKPATH)'#010+
'endif'#010+
- 'endif'#010+
+ 'endi','f'#010+
'endif'#010+
#010+
'# When BINUTILSPREFIX is given and we are not cross-compiling then use'+
@@ -1455,19 +1464,19 @@ const fpcmakeini : array[0..255,1..240] of char=(
'# it while compiling the fpmake file. (For example to build i386-freeb'+
'sd'#010+
'# with BINUTILSPREFIX=i386-)'#010+
- 'ifndef ','CROSSCOMPILE'#010+
+ 'ifndef CROSSCOMPILE'#010+
'ifneq ($(BINUTILSPREFIX),)'#010+
- 'override FPCMAKEOPT+=-XP$(BINUTILSPREFIX)'#010+
+ 'override FP','CMAKEOPT+=-XP$(BINUTILSPREFIX)'#010+
'override FPMAKE_BUILD_OPT+=-XP$(BINUTILSPREFIX)'#010+
'endif'#010+
'endif'#010+
#010+
'# User dirs should be first, so they are looked at first'#010+
'ifdef UNITDIR'#010+
- 'override FPCOPT+=$(addpref','ix -Fu,$(UNITDIR))'#010+
+ 'override FPCOPT+=$(addprefix -Fu,$(UNITDIR))'#010+
'endif'#010+
'ifdef LIBDIR'#010+
- 'override FPCOPT+=$(addprefix -Fl,$(LIBDIR))'#010+
+ 'override FPCO','PT+=$(addprefix -Fl,$(LIBDIR))'#010+
'endif'#010+
'ifdef OBJDIR'#010+
'override FPCOPT+=$(addprefix -Fo,$(OBJDIR))'#010+
@@ -1477,11 +1486,11 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
#010+
'# Smartlinking'#010+
- 'ifdef LINK','SMART'#010+
+ 'ifdef LINKSMART'#010+
'override FPCOPT+=-XX'#010+
'endif'#010+
#010+
- '# Smartlinking creation'#010+
+ '# Smartlinking cr','eation'#010+
'ifdef CREATESMART'#010+
'override FPCOPT+=-CX'#010+
'endif'#010+
@@ -1494,9 +1503,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'# Release mode'#010+
'# (strip, optimize and don'#039't load fpc.cfg)'#010+
- 'ifde','f RELEASE'#010+
+ 'ifdef RELEASE'#010+
'FPCCPUOPT:=-O2'#010+
- 'override FPCOPT+=-Ur -Xs $(FPCCPUOPT) -n'#010+
+ 'override FPCOPT+=-Ur -Xs $','(FPCCPUOPT) -n'#010+
'override FPCOPTDEF+=RELEASE'#010+
'endif'#010+
#010+
@@ -1510,68 +1519,68 @@ const fpcmakeini : array[0..255,1..240] of char=(
'override FPCOPT+=-O2'#010+
'endif'#010+
#010+
- '# Verbose settings (warning,note,inf','o)'#010+
+ '# Verbose settings (warning,note,info)'#010+
'ifdef VERBOSE'#010+
'override FPCOPT+=-vwni'#010+
'endif'#010+
#010+
- '# Needed compiler options'#010+
+ '# Ne','eded compiler options'#010+
'ifdef COMPILER_OPTIONS'#010+
'override FPCOPT+=$(COMPILER_OPTIONS)'#010+
'endif'#010+
'ifdef COMPILER_UNITDIR'#010+
'override FPCOPT+=$(addprefix -Fu,$(COMPILER_UNITDIR))'#010+
'endif'#010+
- 'ifdef COMPILER_LIB','RARYDIR'#010+
- 'override FPCOPT+=$(addprefix -Fl,$(COMPILER_LIBRARYDIR))'#010+
+ 'ifdef COMPILER_LIBRARYDIR'#010+
+ 'override FPCOPT+=$(addprefix -Fl,$(COMPILER','_LIBRARYDIR))'#010+
'endif'#010+
'ifdef COMPILER_OBJECTDIR'#010+
'override FPCOPT+=$(addprefix -Fo,$(COMPILER_OBJECTDIR))'#010+
'endif'#010+
'ifdef COMPILER_INCLUDEDIR'#010+
- 'override FPCOPT+=$(addprefix -Fi,$(COMPILER_INCLUDEDIR))',#010+
+ 'override FPCOPT+=$(addprefix -Fi,$(COMPILER_INCLUDEDIR))'#010+
'endif'#010+
#010+
'# Cross compiler utils'#010+
'ifdef CROSSBINDIR'#010+
- 'override FPCOPT+=-FD$(CROSSBINDIR)'#010+
+ 'ov','erride FPCOPT+=-FD$(CROSSBINDIR)'#010+
'endif'#010+
#010+
'# Target dirs and the prefix to use for clean/install'#010+
'ifdef COMPILER_TARGETDIR'#010+
'override FPCOPT+=-FE$(COMPILER_TARGETDIR)'#010+
- 'ifeq ($(COMPILER_TARGETDIR),','.)'#010+
+ 'ifeq ($(COMPILER_TARGETDIR),.)'#010+
'override TARGETDIRPREFIX='#010+
'else'#010+
- 'override TARGETDIRPREFIX=$(COMPILER_TARGETDIR)/'#010+
+ 'override TARGETDI','RPREFIX=$(COMPILER_TARGETDIR)/'#010+
'endif'#010+
'endif'#010+
#010+
'# Unit target dir (default is units/<cpu>-<os>/'#010+
'ifdef COMPILER_UNITTARGETDIR'#010+
'override FPCOPT+=-FU$(COMPILER_UNITTARGETDIR)'#010+
- 'ifeq ($(COMPILER_UNITT','ARGETDIR),.)'#010+
+ 'ifeq ($(COMPILER_UNITTARGETDIR),.)'#010+
'override UNITTARGETDIRPREFIX='#010+
'else'#010+
- 'override UNITTARGETDIRPREFIX=$(COMPILER_UNITTARGETDIR)/'#010+
+ 'ove','rride UNITTARGETDIRPREFIX=$(COMPILER_UNITTARGETDIR)/'#010+
'endif'#010+
'else'#010+
'ifdef COMPILER_TARGETDIR'#010+
'override COMPILER_UNITTARGETDIR=$(COMPILER_TARGETDIR)'#010+
- 'override UNITTARGETDIRPREFIX=$(TARGETDIRPREFIX',')'#010+
+ 'override UNITTARGETDIRPREFIX=$(TARGETDIRPREFIX)'#010+
'endif'#010+
'endif'#010+
#010+
'ifdef CREATESHARED'#010+
- 'override FPCOPT+=-Cg'#010+
+ 'override FPCOPT+=','-Cg'#010+
'endif'#010+
#010+
'# create always pic'#039'ed code on x86_64, mips and mipsel'#010+
'# on unix-like systems'#010+
'ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linu'+
'x solaris),)'#010+
- 'ifneq ($(findstri','ng $(CPU_TARGET),x86_64 mips mipsel),)'#010+
- 'override FPCOPT+=-Cg'#010+
+ 'ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)'#010+
+ 'over','ride FPCOPT+=-Cg'#010+
'endif'#010+
'endif'#010+
#010+
@@ -1584,8 +1593,8 @@ const fpcmakeini : array[0..255,1..240] of char=(
'# Add GCC lib path if asked'#010+
'ifdef GCCLIBDIR'#010+
'override FPCOPT+=-Fl$(GCCLIBDIR)'#010+
- 'if','def FPCMAKEGCCLIBDIR'#010+
- 'override FPCMAKEOPT+=-Fl$(FPCMAKEGCCLIBDIR)'#010+
+ 'ifdef FPCMAKEGCCLIBDIR'#010+
+ 'override FPCMAKEOPT+=-','Fl$(FPCMAKEGCCLIBDIR)'#010+
'else'#010+
'override FPCMAKEOPT+=-Fl$(GCCLIBDIR)'#010+
'endif'#010+
@@ -1596,9 +1605,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
#010+
'[command_end]'#010+
- '# Add commandline options last s','o they can override'#010+
+ '# Add commandline options last so they can override'#010+
'ifdef OPT'#010+
- 'override FPCOPT+=$(OPT)'#010+
+ 'override FPCO','PT+=$(OPT)'#010+
'endif'#010+
#010+
'# Override options to compile the fpmake-binary with command-line opti'+
@@ -1607,8 +1616,8 @@ const fpcmakeini : array[0..255,1..240] of char=(
'override FPMAKE_BUILD_OPT+=$(FPMAKEBUILDOPT)'#010+
'endif'#010+
#010+
- '# Add',' defines from FPCOPTDEF to FPCOPT'#010+
- 'ifdef FPCOPTDEF'#010+
+ '# Add defines from FPCOPTDEF to FPCOPT'#010+
+ 'ifdef FPC','OPTDEF'#010+
'override FPCOPT+=$(addprefix -d,$(FPCOPTDEF))'#010+
'endif'#010+
#010+
@@ -1618,9 +1627,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
#010+
'# Use the environment to pass commandline options?'#010+
- 'ifde','f USEENV'#010+
+ 'ifdef USEENV'#010+
'override FPCEXTCMD:=$(FPCOPT)'#010+
- 'override FPCOPT:=!FPCEXTCMD'#010+
+ 'over','ride FPCOPT:=!FPCEXTCMD'#010+
'export FPCEXTCMD'#010+
'endif'#010+
#010+
@@ -1628,20 +1637,20 @@ const fpcmakeini : array[0..255,1..240] of char=(
'override AFULL_SOURCE=$(CPU_SOURCE)-$(OS_SOURCE)'#010+
#010+
'ifneq ($(AFULL_TARGET),$(AFULL_SOURCE))'#010+
- 'override A','CROSSCOMPILE=1'#010+
+ 'override ACROSSCOMPILE=1'#010+
'endif'#010+
#010+
'ifdef ACROSSCOMPILE'#010+
- 'override FPCOPT+=$(CROSSOPT)'#010+
+ 'o','verride FPCOPT+=$(CROSSOPT)'#010+
'endif'#010+
#010+
'# Compiler commandline'#010+
'override COMPILER:=$(strip $(FPC) $(FPCOPT))'#010+
#010+
'# also call ppas if with command option -s'#010+
- '# but only if the FULL_SOURCE and FULL_TARGET are ','equal'#010+
+ '# but only if the FULL_SOURCE and FULL_TARGET are equal'#010+
'# or if -sh is used'#010+
- 'ifneq (,$(findstring -sh ,$(COMPILER)))'#010+
+ 'ifneq (,$(findstr','ing -sh ,$(COMPILER)))'#010+
'UseEXECPPAS=1'#010+
'endif'#010+
'ifneq (,$(findstring -s ,$(COMPILER)))'#010+
@@ -1652,10 +1661,10 @@ const fpcmakeini : array[0..255,1..240] of char=(
'ifneq ($(UseEXECPPAS),1)'#010+
'EXECPPAS='#010+
'else'#010+
- 'ifdef RUNBAT','CH'#010+
+ 'ifdef RUNBATCH'#010+
'EXECPPAS:=@$(RUNBATCH) $(PPAS)'#010+
'else'#010+
- 'EXECPPAS:=@$(PPAS)'#010+
+ 'EXEC','PPAS:=@$(PPAS)'#010+
'endif'#010+
'endif'#010+
#010+
@@ -1665,9 +1674,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'# Loaders'#010+
'#####################################################################'#010+
#010+
- '.PH','ONY: fpc_loaders'#010+
+ '.PHONY: fpc_loaders'#010+
#010+
- 'ifneq ($(TARGET_LOADERS),)'#010+
+ 'ifneq ($(TARGET_LOADERS),',')'#010+
'override ALLTARGET+=fpc_loaders'#010+
'override CLEANTARGET+=fpc_loaders_clean'#010+
'override INSTALLTARGET+=fpc_loaders_install'#010+
@@ -1675,8 +1684,8 @@ const fpcmakeini : array[0..255,1..240] of char=(
'override LOADEROFILES:=$(addsuffix $(OEXT),$(TARGET_LOADERS))'#010+
'endif'#010+
#010+
- '%$(OEXT):',' %$(LOADEREXT)'#010+
- 'ifdef COMPILER_UNITTARGETDIR'#010+
+ '%$(OEXT): %$(LOADEREXT)'#010+
+ 'ifdef COMPILER_UNITTARGETDIR',#010+
' $(AS) -o $(COMPILER_UNITTARGETDIR)/$*$(OEXT) $<'#010+
'else'#010+
' $(AS) -o $*$(OEXT) $<'#010+
@@ -1685,9 +1694,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'fpc_loaders: $(COMPILER_UNITTARGETDIR) $(LOADEROFILES)'#010+
#010+
'fpc_loaders_clean:'#010+
- 'ifdef COMPILER_UNITTARG','ETDIR'#010+
- ' -$(DEL) $(addprefix $(COMPILER_UNITTARGETDIR)/,$(LOADEROFILES)'+
- ')'#010+
+ 'ifdef COMPILER_UNITTARGETDIR'#010+
+ ' -$(DEL) $(addprefix $(COMPILE','R_UNITTARGETDIR)/,$(LOADEROFILE'+
+ 'S))'#010+
'else'#010+
' -$(DEL) $(LOADEROFILES)'#010+
'endif'#010+
@@ -1695,8 +1704,8 @@ const fpcmakeini : array[0..255,1..240] of char=(
'fpc_loaders_install:'#010+
' $(MKDIR) $(INSTALL_UNITDIR)'#010+
'ifdef COMPILER_UNITTARGETDIR'#010+
- ' $(INSTALL) $(addprefix $','(COMPILER_UNITTARGETDIR)/,$(LOADEROF'+
- 'ILES)) $(INSTALL_UNITDIR)'#010+
+ ' $(INSTALL) $(addprefix $(COMPILER_UNITTARGETDIR)/,$(LOADEROFIL'+
+ 'ES)) ','$(INSTALL_UNITDIR)'#010+
'else'#010+
' $(INSTALL) $(LOADEROFILES) $(INSTALL_UNITDIR)'#010+
'endif'#010+
@@ -1705,7 +1714,7 @@ const fpcmakeini : array[0..255,1..240] of char=(
'[unitrules]'#010+
'#####################################################################'#010+
'# Units'#010+
- '#####################','###############################################'+
+ '################################################################','####'+
'#'#010+
#010+
'.PHONY: fpc_units'#010+
@@ -1714,8 +1723,8 @@ const fpcmakeini : array[0..255,1..240] of char=(
'override ALLTARGET+=fpc_units'#010+
#010+
'override UNITPPUFILES=$(addsuffix $(PPUEXT),$(TARGET_UNITS))'#010+
- 'override IMPLICITUNITPPUFILES=$','(addsuffix $(PPUEXT),$(TARGET_IMPLICI'+
- 'TUNITS))'#010+
+ 'override IMPLICITUNITPPUFILES=$(addsuffix $(PPUEXT),$(TARGET_IMPLICITU'+
+ 'NITS','))'#010+
'override INSTALLPPUFILES+=$(UNITPPUFILES) $(IMPLICITUNITPPUFILES)'#010+
'override CLEANPPUFILES+=$(UNITPPUFILES) $(IMPLICITUNITPPUFILES)'#010+
'endif'#010+
@@ -1723,32 +1732,33 @@ const fpcmakeini : array[0..255,1..240] of char=(
'fpc_units: $(COMPILER_UNITTARGETDIR) $(UNITPPUFILES)'#010+
#010+
#010+
- '[e','xerules]'#010+
- '#####################################################################'#010+
+ '[exerules]'#010+
+ '##################################','##################################'+
+ '#'#010+
'# Exes'#010+
'#####################################################################'#010+
#010+
'.PHONY: fpc_exes'#010+
#010+
'# Programs are not needed for a cross installation'#010+
- 'ifndef CROSSIN','STALL'#010+
+ 'ifndef CROSSINSTALL'#010+
'ifneq ($(TARGET_PROGRAMS),)'#010+
- 'override EXEFILES=$(addsuffix $(EXEEXT),$(TARGET_PROGRAMS))'#010+
+ 'override ','EXEFILES=$(addsuffix $(EXEEXT),$(TARGET_PROGRAMS))'#010+
'override EXEOFILES:=$(addsuffix $(OEXT),$(TARGET_PROGRAMS)) $(addsuffi'+
'x $(LTOEXT),$(TARGET_PROGRAMS))$(addprefix $(STATICLIBPREFIX),$(addsuf'+
- 'fix $(','STATICLIBEXT),$(TARGET_PROGRAMS))) $(addprefix $(IMPORTLIBPREF'+
+ 'fix $(STATICLIBEXT),$(TARGET_PROGRAMS))) $(addpre','fix $(IMPORTLIBPREF'+
'IX),$(addsuffix $(STATICLIBEXT),$(TARGET_PROGRAMS)))'#010+
'override EXEDBGFILES:=$(addsuffix $(EXEDBGEXT),$(TARGET_PROGRAMS))'#010+
#010+
'override ALLTARGET+=fpc_exes'#010+
- 'override INSTALLEXEFILES+=$(','EXEFILES)'#010+
- 'override CLEANEXEFILES+=$(EXEFILES) $(EXEOFILES)'#010+
+ 'override INSTALLEXEFILES+=$(EXEFILES)'#010+
+ 'override CLEANEXEFILES+=$(EXEFILE','S) $(EXEOFILES)'#010+
'override CLEANEXEDBGFILES+=$(EXEDBGFILES)'#010+
'ifeq ($(OS_TARGET),os2)'#010+
'override CLEANEXEFILES+=$(addsuffix $(AOUTEXT),$(TARGET_PROGRAMS))'#010+
'endif'#010+
'ifeq ($(OS_TARGET),emx)'#010+
- 'override CLEANEXEF','ILES+=$(addsuffix $(AOUTEXT),$(TARGET_PROGRAMS))'#010+
+ 'override CLEANEXEFILES+=$(addsuffix $(AOUTEXT),$(TARGET_PROGR','AMS))'#010+
'endif'#010+
'endif'#010+
'endif'#010+
@@ -1758,8 +1768,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'[rstrules]'#010+
'#####################################################################'#010+
- '# Resource strings'#010,
- '#####################################################################'#010+
+ '# Resource strings'#010+
+ '###########################################','#########################'+
+ '#'#010+
#010+
'ifdef TARGET_RSTS'#010+
'override RSTFILES=$(addsuffix $(RSTEXT),$(TARGET_RSTS))'#010+
@@ -1769,33 +1780,32 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
#010+
'[examplerules]'#010+
- '###################################','#################################'+
- '#'#010+
- '# Examples'#010+
+ '#####################################################################'#010+
+ '# Exampl','es'#010+
'#####################################################################'#010+
#010+
'.PHONY: fpc_examples'#010+
#010+
'ifneq ($(TARGET_EXAMPLES),)'#010+
'HASEXAMPLES=1'#010+
- 'override EXAMPLESOURCEFILES=$(wildcard $(addsuffix .pp,$(TA','RGET_EXAM'+
- 'PLES)) $(addsuffix .pas,$(TARGET_EXAMPLES)) $(addsuffix .lpr,$(TARGET_'+
+ 'override EXAMPLESOURCEFILES=$(wildcard $(addsuffix .pp,$(TARGET_EXAMPL'+
+ 'ES)) $(addsuffix .pas,$(TARGET_E','XAMPLES)) $(addsuffix .lpr,$(TARGET_'+
'EXAMPLES)) $(addsuffix .dpr,$(TARGET_EXAMPLES)))'#010+
'override EXAMPLEFILES:=$(addsuffix $(EXEEXT),$(TARGET_EXAMPLES))'#010+
- 'override EXAMPLEOFILES:=$(addsuffix $(OEXT),$(T','ARGET_EXAMPLES)) $(ad'+
- 'dsuffix $(LTOEXT),$(TARGET_EXAMPLES)) $(addprefix $(STATICLIBPREFIX),$'+
+ 'override EXAMPLEOFILES:=$(addsuffix $(OEXT),$(TARGET_EXAMPLES)) $(adds'+
+ 'uffix $(LTOEXT),$(TA','RGET_EXAMPLES)) $(addprefix $(STATICLIBPREFIX),$'+
'(addsuffix $(STATICLIBEXT),$(TARGET_EXAMPLES))) $(addprefix $(IMPORTLI'+
'BPREFIX),$(addsuffix $(STATICLIBEXT),$(TARGET_EXAMPLES)))'#010+
- 'override EXAMPLEDBGFI','LES:=$(addsuffix $(EXEDBGEXT),$(TARGET_EXAMPLES'+
+ 'override EXAMPLEDBGFILES:=$(addsuffix $(EXEDBGEXT),$(TARGET_EXAM','PLES'+
'))'#010+
#010+
'override CLEANEXEFILES+=$(EXAMPLEFILES) $(EXAMPLEOFILES)'#010+
'override CLEANEXEDBGFILES+=$(EXAMPLEDBGFILES)'#010+
'ifeq ($(OS_TARGET),os2)'#010+
- 'override CLEANEXEFILES+=$(addsuffix $(AOUTEXT),$(TARGET_EXAMPL','ES))'#010+
+ 'override CLEANEXEFILES+=$(addsuffix $(AOUTEXT),$(TARGET_EXAMPLES))'#010+
'endif'#010+
'ifeq ($(OS_TARGET),emx)'#010+
- 'override CLEANEXEFILES+=$(addsuffix $(AOUTEXT),$(TARGET_EXAMPLES))'#010+
+ 'override',' CLEANEXEFILES+=$(addsuffix $(AOUTEXT),$(TARGET_EXAMPLES))'#010+
'endif'#010+
'endif'#010+
'ifneq ($(TARGET_EXAMPLEDIRS),)'#010+
@@ -1803,17 +1813,18 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
#010+
'fpc_examples: all $(EXAMPLEFILES) $(addsuffix _all,$(TARGET_EXAMPLEDIR'+
- 'S))'#010,
+ 'S))'#010+
#010+
#010+
'[compilerules]'#010+
- '#####################################################################'#010+
+ '##########################','##########################################'+
+ '#'#010+
'# General compile rules'#010+
'#####################################################################'#010+
#010+
- '.PHONY: fpc_all fpc_smart fpc_debug fpc_release fpc_shared',#010+
+ '.PHONY: fpc_all fpc_smart fpc_debug fpc_release fpc_shared'#010+
#010+
- '$(FPCMADE): $(ALLDEPENDENCIES) $(ALLTARGET)'#010+
+ '$(FPCMADE): $(ALLDEPENDENCIES) $(ALLTARGE','T)'#010+
' @$(ECHOREDIR) Compiled > $(FPCMADE)'#010+
#010+
'fpc_all: $(FPCMADE)'#010+
@@ -1825,19 +1836,19 @@ const fpcmakeini : array[0..255,1..240] of char=(
' $(MAKE) all DEBUG=1'#010+
#010+
'fpc_release:'#010+
- ' $(MAKE) a','ll RELEASE=1'#010+
+ ' $(MAKE) all RELEASE=1'#010+
#010+
- '# General compile rules, available for both possible .pp and .pas exte'+
- 'nsions'#010+
+ '# General compile rules, avai','lable for both possible .pp and .pas ex'+
+ 'tensions'#010+
#010+
'.SUFFIXES: $(EXEEXT) $(PPUEXT) $(OEXT) $(LTOEXT) .pas .lpr .dpr .pp .r'+
'c .res'#010+
#010+
'$(COMPILER_UNITTARGETDIR):'#010+
- ' $(MKDIRTREE) $(COMPILER_UNITTARGETD','IR)'#010+
+ ' $(MKDIRTREE) $(COMPILER_UNITTARGETDIR)'#010+
#010+
'$(COMPILER_TARGETDIR):'#010+
- ' $(MKDIRTREE) $(COMPILER_TARGETDIR)'#010+
+ ' $(MKDIR','TREE) $(COMPILER_TARGETDIR)'#010+
#010+
'%$(PPUEXT): %.pp'#010+
' $(COMPILER) $<'#010+
@@ -1849,10 +1860,10 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'%$(EXEEXT): %.pp'#010+
' $(COMPILER) $<'#010+
- ' ',' $(EXECPPAS)'#010+
+ ' $(EXECPPAS)'#010+
#010+
'%$(EXEEXT): %.pas'#010+
- ' $(COMPILER) $<'#010+
+ ' $','(COMPILER) $<'#010+
' $(EXECPPAS)'#010+
#010+
'%$(EXEEXT): %.lpr'#010+
@@ -1864,21 +1875,21 @@ const fpcmakeini : array[0..255,1..240] of char=(
' $(EXECPPAS)'#010+
#010+
'%.res: %.rc'#010+
- ' windres -i $< -o $','@'#010+
+ ' windres -i $< -o $@'#010+
#010+
- '# Search paths for .ppu, .pp, .pas, .lpr, .dpr'#010+
+ '# Search paths for .ppu, .pp, .pas, .lpr',', .dpr'#010+
'vpath %.pp $(COMPILER_SOURCEDIR) $(COMPILER_INCLUDEDIR)'#010+
'vpath %.pas $(COMPILER_SOURCEDIR) $(COMPILER_INCLUDEDIR)'#010+
'vpath %.lpr $(COMPILER_SOURCEDIR) $(COMPILER_INCLUDEDIR)'#010+
- 'vpath %.dpr $(COMPIL','ER_SOURCEDIR) $(COMPILER_INCLUDEDIR)'#010+
- 'vpath %.inc $(COMPILER_INCLUDEDIR)'#010+
+ 'vpath %.dpr $(COMPILER_SOURCEDIR) $(COMPILER_INCLUDEDIR)'#010+
+ 'vpath ','%.inc $(COMPILER_INCLUDEDIR)'#010+
'vpath %$(OEXT) $(COMPILER_UNITTARGETDIR)'#010+
'vpath %$(LTOEXT) $(COMPILER_UNITTARGETDIR)'#010+
'vpath %$(PPUEXT) $(COMPILER_UNITTARGETDIR)'#010+
#010+
'[sharedrules]'#010+
- '##########################','##########################################'+
- '#'#010+
+ '#####################################################################',
+ #010+
'# Library'#010+
'#####################################################################'#010+
#010+
@@ -1887,11 +1898,11 @@ const fpcmakeini : array[0..255,1..240] of char=(
'override INSTALLTARGET+=fpc_shared_install'#010+
#010+
'ifndef SHARED_LIBVERSION'#010+
- 'SHARED_LIBVERSION=$(FPC_VE','RSION)'#010+
+ 'SHARED_LIBVERSION=$(FPC_VERSION)'#010+
'endif'#010+
#010+
'ifndef SHARED_LIBNAME'#010+
- 'SHARED_LIBNAME=$(PACKAGE_NAME)'#010+
+ 'SHARED_','LIBNAME=$(PACKAGE_NAME)'#010+
'endif'#010+
#010+
'ifndef SHARED_FULLNAME'#010+
@@ -1900,42 +1911,43 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
#010+
'# Default sharedlib units are all unit objects'#010+
- 'i','fndef SHARED_LIBUNITS'#010+
- 'SHARED_LIBUNITS:=$(TARGET_UNITS) $(TARGET_IMPLICITUNITS)'#010+
+ 'ifndef SHARED_LIBUNITS'#010+
+ 'SHARED_LIBUNITS:=$(TA','RGET_UNITS) $(TARGET_IMPLICITUNITS)'#010+
'override SHARED_LIBUNITS:=$(filter-out $(INSTALL_BUILDUNIT),$(SHARED_L'+
'IBUNITS))'#010+
'endif'#010+
#010+
'fpc_shared:'#010+
'ifdef HASSHAREDLIB'#010+
- ' $(MAKE) all CREATESHARED=1 LINKSHAR','ED=1 CREATESMART=1'#010+
- 'ifneq ($(SHARED_BUILD),n)'#010+
+ ' $(MAKE) all CREATESHARED=1 LINKSHARED=1 CREATESMART=1'#010+
+ 'ifneq ($(SHARED_BUILD),n',')'#010+
' $(PPUMOVE) -q $(SHARED_LIBUNITS) -i$(COMPILER_UNITTARGETDIR) -'+
'o$(SHARED_FULLNAME) -d$(COMPILER_UNITTARGETDIR) -P$(BINUTILSPREFIX)'#010+
'endif'#010+
'else'#010+
- ' @$(ECHO) Shared Libraries not supporte','d'#010+
+ ' @$(ECHO) Shared Libraries not supported'#010+
'endif'#010+
#010+
'fpc_shared_install:'#010+
- 'ifneq ($(SHARED_BUILD),n)'#010+
+ 'ifneq ($(SHARE','D_BUILD),n)'#010+
'ifneq ($(SHARED_LIBUNITS),)'#010+
'ifneq ($(wildcard $(COMPILER_UNITTARGETDIR)/$(SHARED_FULLNAME)),)'#010+
' $(INSTALL) $(COMPILER_UNITTARGETDIR)/$(SHARED_FULLNAME) $(INST'+
'ALL_SHAREDDIR)'#010+
- 'endif'#010,
+ 'endif'#010+
'endif'#010+
'endif'#010+
#010+
'[installrules]'#010+
- '#####################################################################'#010+
+ '###############','#####################################################'+
+ '#'#010+
'# Install rules'#010+
'#####################################################################'#010+
#010+
- '.PHONY: fpc_install fpc_sourceinstall fpc_exampleinstal','l'#010+
+ '.PHONY: fpc_install fpc_sourceinstall fpc_exampleinstall'#010+
#010+
'ifdef INSTALL_UNITS'#010+
- 'override INSTALLPPUFILES+=$(addsuffix $(PPUEXT),$(INSTALL_UNITS))'#010+
+ 'override INSTALLPPUF','ILES+=$(addsuffix $(PPUEXT),$(INSTALL_UNITS))'#010+
'endif'#010+
#010+
'ifdef INSTALL_BUILDUNIT'#010+
@@ -1944,27 +1956,28 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
#010+
'ifdef INSTALLPPUFILES'#010+
- '# ','Avoid getting the same name twice as some install EXE fail'#010+
+ '# Avoid getting the same name twice as some i','nstall EXE fail'#010+
'# in this case, happends for instance for OS/2 target'#010+
'ifneq ($(IMPORTLIBPREFIX)-$(STATICLIBEXT),$(STATICLIBPREFIX)-$(STATICL'+
'IBEXT))'#010+
- 'override INSTALLPPULINKFILES:=$(subst $(PPUEXT),$','(OEXT),$(INSTALLPPU'+
- 'FILES)) $(subst $(PPUEXT),$(LTOEXT),$(INSTALLPPUFILES)) $(addprefix $('+
+ 'override INSTALLPPULINKFILES:=$(subst $(PPUEXT),$(OEXT),$(INSTALLPPUFI'+
+ 'LES)) $(subst $(PPUEXT','),$(LTOEXT),$(INSTALLPPUFILES)) $(addprefix $('+
'STATICLIBPREFIX),$(subst $(PPUEXT),$(STATICLIBEXT),$(INSTALLPPUFILES))'+
') $(addprefix $(IMPORTLIBPREFIX),$(subst $(PPUEXT),$(STATICLIBEXT),$(I'+
- 'NSTALLPPUFI','LES)))'#010+
+ 'NSTALLPPUFILES)))'#010+
'else'#010+
- 'override INSTALLPPULINKFILES:=$(subst $(PPUEXT),$(OEXT),$(INSTALLPPUFI'+
- 'LES)) $(subst $(PPUEXT),$(LTOEXT),$(INSTALLPPUFILES)) $(addprefix $(ST'+
- 'ATICLIBPREFIX),$(subst $(PPUEXT),$(STATICLIBEXT),$(INSTALLPPUFILES)))'#010+
+ 'override INSTALLPPULINKFILES:=$','(subst $(PPUEXT),$(OEXT),$(INSTALLPPU'+
+ 'FILES)) $(subst $(PPUEXT),$(LTOEXT),$(INSTALLPPUFILES)) $(addprefix $('+
+ 'STATICLIBPREFIX),$(subst $(PPUEXT),$(STATICLIBEXT),$(INSTALLPPUFILES))'+
+ ')'#010+
'endif'#010+
#010+
- 'ifneq ($(UN','ITTARGETDIRPREFIX),)'#010+
- 'override INSTALLPPUFILENAMES:=$(notdir $(INSTALLPPUFILES))'#010+
+ 'ifneq ($(UNITTARGETDIRPREFIX),)'#010+
+ 'override INSTALLPPUFIL','ENAMES:=$(notdir $(INSTALLPPUFILES))'#010+
'override INSTALLPPULINKFILENAMES:=$(notdir $(INSTALLPPULINKFILES))'#010+
'override INSTALLPPUFILES=$(addprefix $(UNITTARGETDIRPREFIX),$(INSTALLP'+
'PUFILENAMES))'#010+
- 'override ','INSTALLPPULINKFILES=$(wildcard $(addprefix $(UNITTARGETDIRP'+
+ 'override INSTALLPPULINKFILES=$(wildcard $(addprefix ','$(UNITTARGETDIRP'+
'REFIX),$(INSTALLPPULINKFILENAMES)))'#010+
'endif'#010+
'# Implicitly install Package.fpc'#010+
@@ -1973,7 +1986,7 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'ifdef INSTALLEXEFILES'#010+
'ifneq ($(TARGETDIRPREFIX),)'#010+
- 'override INST','ALLEXEFILES:=$(addprefix $(TARGETDIRPREFIX),$(notdir $('+
+ 'override INSTALLEXEFILES:=$(addprefix $(TARGETDIRPREFIX)',',$(notdir $('+
'INSTALLEXEFILES)))'#010+
'endif'#010+
'endif'#010+
@@ -1982,15 +1995,15 @@ const fpcmakeini : array[0..255,1..240] of char=(
'ifdef INSTALLEXEFILES'#010+
' $(MKDIR) $(INSTALL_BINDIR)'#010+
' $(INSTALLEXE) $(INSTALLEXEFILES) $(INSTALL_BINDIR)'#010+
- 'end','if'#010+
+ 'endif'#010+
'ifdef INSTALL_CREATEPACKAGEFPC'#010+
- 'ifdef FPCMAKE'#010+
+ 'ifdef FPC','MAKE'#010+
'# If the fpcpackage variable is set then create and install Package.fp'+
'c,'#010+
'# a safety check is done if Makefile.fpc is available'#010+
'ifdef PACKAGE_VERSION'#010+
'ifneq ($(wildcard Makefile.fpc),)'#010+
- ' $','(FPCMAKE) -p -T$(CPU_TARGET)-$(OS_TARGET) Makefile.fpc'#010+
+ ' $(FPCMAKE) -p -T$(CPU_TARGET)-$(OS_TARGET) M','akefile.fpc'#010+
' $(MKDIR) $(INSTALL_UNITDIR)'#010+
' $(INSTALL) Package.fpc $(INSTALL_UNITDIR)'#010+
'endif'#010+
@@ -1999,15 +2012,15 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
'ifdef INSTALLPPUFILES'#010+
' $(MKDIR) $(INSTALL_UNITDIR)'#010+
- ' $(INSTALL',') $(INSTALLPPUFILES) $(INSTALL_UNITDIR)'#010+
- 'ifneq ($(INSTALLPPULINKFILES),)'#010+
+ ' $(INSTALL) $(INSTALLPPUFILES) $(INSTALL_UNITDIR)'#010+
+ 'ifn','eq ($(INSTALLPPULINKFILES),)'#010+
' $(INSTALL) $(INSTALLPPULINKFILES) $(INSTALL_UNITDIR)'#010+
'endif'#010+
'ifneq ($(wildcard $(LIB_FULLNAME)),)'#010+
' $(MKDIR) $(INSTALL_LIBDIR)'#010+
- ' $(INSTALL) $(LIB_FULL','NAME) $(INSTALL_LIBDIR)'#010+
+ ' $(INSTALL) $(LIB_FULLNAME) $(INSTALL_LIBDIR)'#010+
'ifdef inUnix'#010+
- ' ln -sf $(LIB_FULLNAME) $(INSTALL_LIBDIR)/$(LIB_NAME)'#010+
+ ' ',' ln -sf $(LIB_FULLNAME) $(INSTALL_LIBDIR)/$(LIB_NAME)'#010+
'endif'#010+
'endif'#010+
'endif'#010+
@@ -2016,16 +2029,16 @@ const fpcmakeini : array[0..255,1..240] of char=(
' $(INSTALL) $(INSTALL_FILES) $(INSTALL_DATADIR)'#010+
'endif'#010+
#010+
- 'fpc_so','urceinstall: distclean'#010+
- ' $(MKDIR) $(INSTALL_SOURCEDIR)'#010+
+ 'fpc_sourceinstall: distclean'#010+
+ ' $(MKDIR) $(I','NSTALL_SOURCEDIR)'#010+
' $(COPYTREE) $(BASEDIR)/* $(INSTALL_SOURCEDIR)'#010+
#010+
'fpc_exampleinstall: $(EXAMPLEINSTALLTARGET) $(addsuffix _distclean,$(T'+
'ARGET_EXAMPLEDIRS))'#010+
'ifdef HASEXAMPLES'#010+
- ' $(MKDIR)',' $(INSTALL_EXAMPLEDIR)'#010+
+ ' $(MKDIR) $(INSTALL_EXAMPLEDIR)'#010+
'endif'#010+
- 'ifdef EXAMPLESOURCEFILES'#010+
+ 'ifdef EXAMPLES','OURCEFILES'#010+
' $(COPY) $(EXAMPLESOURCEFILES) $(INSTALL_EXAMPLEDIR)'#010+
'endif'#010+
'ifdef TARGET_EXAMPLEDIRS'#010+
@@ -2033,8 +2046,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'AMPLEDIR)'#010+
'endif'#010+
#010+
- '[distins','tallrules]'#010+
- '#####################################################################'#010+
+ '[distinstallrules]'#010+
+ '################################','####################################'+
+ '#'#010+
'# Dist Install'#010+
'#####################################################################'#010+
#010+
@@ -2043,14 +2057,15 @@ const fpcmakeini : array[0..255,1..240] of char=(
'fpc_distinstall: install exampleinstall'#010+
#010+
#010+
- '[zipin','stallrules]'#010+
- '#####################################################################'#010+
+ '[zipinstallrules]'#010+
+ '###############################','#####################################'+
+ '#'#010+
'# Zip'#010+
'#####################################################################'#010+
#010+
'.PHONY: fpc_zipinstall fpc_zipsourceinstall fpc_zipexampleinstall'#010+
#010+
- '# Temporary pa','th to pack a file, can only use a single deep'#010+
+ '# Temporary path to pack a file, can only use a single de','ep'#010+
'# subdir, because the deltree can'#039't see the whole tree to remove'#010+
'ifndef PACKDIR'#010+
'ifndef inUnix'#010+
@@ -2060,9 +2075,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
'endif'#010+
#010+
- '# Maybe create default zipnam','e from packagename'#010+
+ '# Maybe create default zipname from packagename'#010+
'ifndef ZIPNAME'#010+
- 'ifdef DIST_ZIPNAME'#010+
+ 'ifdef DIS','T_ZIPNAME'#010+
'ZIPNAME=$(DIST_ZIPNAME)'#010+
'else'#010+
'ZIPNAME=$(PACKAGE_NAME)'#010+
@@ -2075,8 +2090,8 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'# ZipTarget'#010+
'ifndef ZIPTARGET'#010+
- 'if','def DIST_ZIPTARGET'#010+
- 'ZIPTARGET=DIST_ZIPTARGET'#010+
+ 'ifdef DIST_ZIPTARGET'#010+
+ 'ZIPTARGET=DIST_ZIPTARGET',#010+
'else'#010+
'ZIPTARGET=install'#010+
'endif'#010+
@@ -2092,9 +2107,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'# Use a wrapper script by default for Os/2'#010+
'ifndef inUnix'#010+
'USEZIPWRAPPER=1'#010+
- 'endif',#010+
+ 'endif'#010+
#010+
- '# We need to be able to run in the current OS so fix'#010+
+ '# We need to be able to run in the curren','t OS so fix'#010+
'# the path separator'#010+
'ifdef USEZIPWRAPPER'#010+
'ZIPPATHSEP=$(PATHSEP)'#010+
@@ -2103,37 +2118,37 @@ const fpcmakeini : array[0..255,1..240] of char=(
'ZIPPATHSEP=/'#010+
'endif'#010+
#010+
- '# Create commands to create',' the zip/tar file'#010+
- 'ZIPCMD_CDPACK:=cd $(subst /,$(ZIPPATHSEP),$(PACKDIR))'#010+
+ '# Create commands to create the zip/tar file'#010+
+ 'ZIPCMD_CDPACK:=cd $(subst',' /,$(ZIPPATHSEP),$(PACKDIR))'#010+
'ZIPCMD_CDBASE:=cd $(subst /,$(ZIPPATHSEP),$(BASEDIR))'#010+
'ifdef USETAR'#010+
'ZIPDESTFILE:=$(DIST_DESTDIR)/$(FULLZIPNAME)$(TAREXT)'#010+
- 'ZIPCMD_ZIP:=$(TARPROG) c$(TAROPT)f $(ZIPDESTFILE',') *'#010+
+ 'ZIPCMD_ZIP:=$(TARPROG) c$(TAROPT)f $(ZIPDESTFILE) *'#010+
'else'#010+
- 'ZIPDESTFILE:=$(DIST_DESTDIR)/$(FULLZIPNAME)$(ZIPEXT)'#010+
+ 'ZIPDESTFILE:=$(DIST_DESTDIR)/$(FUL','LZIPNAME)$(ZIPEXT)'#010+
'ZIPCMD_ZIP:=$(subst /,$(ZIPPATHSEP),$(ZIPPROG)) -Dr $(ZIPOPT) $(ZIPDES'+
'TFILE) *'#010+
'endif'#010+
#010+
'fpc_zipinstall:'#010+
' $(MAKE) $(ZIPTARGET) INSTALL_PREFIX=$(PACKDIR) ZIPINSTALL=1'#010+
- ' ','$(MKDIR) $(DIST_DESTDIR)'#010+
- ' $(DEL) $(ZIPDESTFILE)'#010+
+ ' $(MKDIR) $(DIST_DESTDIR)'#010+
+ ' $(DEL) $(Z','IPDESTFILE)'#010+
'ifdef USEZIPWRAPPER'#010+
'# Handle gecho separate as we need to espace \ with \\'#010+
'ifneq ($(ECHOREDIR),echo)'#010+
' $(ECHOREDIR) -e "$(subst \,\\,$(ZIPCMD_CDPACK))" > $(ZIPWRAPPE'+
'R)'#010+
- ' $(E','CHOREDIR) -e "$(subst \,\\,$(ZIPCMD_ZIP))" >> $(ZIPWRAPPE'+
+ ' $(ECHOREDIR) -e "$(subst \,\\,$(ZIPCMD_ZIP))" ','>> $(ZIPWRAPPE'+
'R)'#010+
' $(ECHOREDIR) -e "$(subst \,\\,$(ZIPCMD_CDBASE))" >> $(ZIPWRAPP'+
'ER)'#010+
'else'#010+
' echo $(ZIPCMD_CDPACK) > $(ZIPWRAPPER)'#010+
' echo $(ZIPCMD_ZIP) >> $(ZIPWRAPPER)'#010+
- ' ech','o $(ZIPCMD_CDBASE) >> $(ZIPWRAPPER)'#010+
+ ' echo $(ZIPCMD_CDBASE) >> $(ZIPWRAPPER)'#010+
'endif'#010+
- 'ifdef inUnix'#010+
+ 'i','fdef inUnix'#010+
' /bin/sh $(ZIPWRAPPER)'#010+
'else'#010+
'ifdef RUNBATCH'#010+
@@ -2144,9 +2159,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
' $(DEL) $(ZIPWRAPPER)'#010+
'else'#010+
- ' $(ZIPCMD_CDPACK) ; $','(ZIPCMD_ZIP) ; $(ZIPCMD_CDBASE)'#010+
+ ' $(ZIPCMD_CDPACK) ; $(ZIPCMD_ZIP) ; $(ZIPCMD_CDBASE)'#010+
'endif'#010+
- ' $(DELTREE) $(PACKDIR)'#010+
+ ' ',' $(DELTREE) $(PACKDIR)'#010+
#010+
'fpc_zipsourceinstall:'#010+
' $(MAKE) fpc_zipinstall ZIPTARGET=sourceinstall ZIPSUFFIX=$(ZIP'+
@@ -2154,7 +2169,7 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'fpc_zipexampleinstall:'#010+
'ifdef HASEXAMPLES'#010+
- ' $(MAKE) fpc_zip','install ZIPTARGET=exampleinstall ZIPSUFFIX=$('+
+ ' $(MAKE) fpc_zipinstall ZIPTARGET=exampleinstall ZIPSUFFIX=','$('+
'ZIPEXAMPLESUFFIX)'#010+
'endif'#010+
#010+
@@ -2164,44 +2179,45 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'[cleanrules]'#010+
'#####################################################################'#010+
- '# Clean rule','s'#010+
- '#####################################################################'#010+
+ '# Clean rules'#010+
+ '#########################################','###########################'+
+ '#'#010+
#010+
'.PHONY: fpc_clean fpc_cleanall fpc_distclean'#010+
#010+
'ifdef EXEFILES'#010+
'override CLEANEXEFILES:=$(addprefix $(TARGETDIRPREFIX),$(CLEANEXEFILES'+
'))'#010+
- 'override CLEANEXEDBGFILES:=$(addp','refix $(TARGETDIRPREFIX),$(CLEANEXE'+
- 'DBGFILES))'#010+
+ 'override CLEANEXEDBGFILES:=$(addprefix $(TARGETDIRPREFIX),$(CLEANEXEDB'+
+ 'GFILES','))'#010+
'endif'#010+
#010+
'ifdef CLEAN_PROGRAMS'#010+
'override CLEANEXEFILES+=$(addprefix $(TARGETDIRPREFIX),$(addsuffix $(E'+
'XEEXT), $(CLEAN_PROGRAMS)))'#010+
- 'override CLEANEXEDBGFILES+=$(addprefix $(TARGETDIRPREFIX),$(addsuffi','x'+
- ' $(EXEDBGEXT), $(CLEAN_PROGRAMS)))'#010+
+ 'override CLEANEXEDBGFILES+=$(addprefix $(TARGETDIRPREFIX),$(addsuffix '+
+ '$(EXEDBGEXT), $(CLEAN_PROGRAMS)))'#010+
'endif'#010+
- #010+
+ #010,
'ifdef CLEAN_UNITS'#010+
'override CLEANPPUFILES+=$(addsuffix $(PPUEXT),$(CLEAN_UNITS))'#010+
'endif'#010+
#010+
'ifdef CLEANPPUFILES'#010+
'override CLEANPPULINKFILES:=$(subst $(PPUEXT),$(OEXT),$(CLEANPPUFILES)'+
- ') $(subst $(PPUEXT),','$(LTOEXT),$(CLEANPPUFILES)) $(addprefix $(STATIC'+
+ ') $(subst $(PPUEXT),$(LTOEXT),$(CLEANPPUFILES)) $(addprefix $(S','TATIC'+
'LIBPREFIX),$(subst $(PPUEXT),$(STATICLIBEXT),$(CLEANPPUFILES))) $(addp'+
'refix $(IMPORTLIBPREFIX),$(subst $(PPUEXT),$(STATICLIBEXT),$(CLEANPPUF'+
'ILES)))'#010+
'ifdef DEBUGSYMEXT'#010+
- 'override CLEANPPULINKFILES','+=$(subst $(PPUEXT),$(DEBUGSYMEXT),$(CLEAN'+
- 'PPUFILES))'#010+
+ 'override CLEANPPULINKFILES+=$(subst $(PPUEXT),$(DEBUGSYMEXT),$(CLEANP',
+ 'PUFILES))'#010+
'endif'#010+
'override CLEANPPUFILENAMES:=$(CLEANPPUFILES)'#010+
'override CLEANPPUFILES=$(addprefix $(UNITTARGETDIRPREFIX),$(CLEANPPUFI'+
'LENAMES))'#010+
'override CLEANPPULINKFILENAMES:=$(CLEANPPULINKFILES)'#010+
- 'ove','rride CLEANPPULINKFILES=$(wildcard $(addprefix $(UNITTARGETDIRPRE'+
+ 'override CLEANPPULINKFILES=$(wildcard $(addpre','fix $(UNITTARGETDIRPRE'+
'FIX),$(CLEANPPULINKFILENAMES)))'#010+
'endif'#010+
#010+
@@ -2209,9 +2225,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'ifdef CLEANEXEFILES'#010+
' -$(DEL) $(CLEANEXEFILES)'#010+
'endif'#010+
- '# DELTREE instead of DEL because on Mac OS X these ','are directories'#010+
+ '# DELTREE instead of DEL because on Mac OS X these are directories'#010+
'ifdef CLEANEXEDBGFILES'#010+
- ' -$(DELTREE) $(CLEANEXEDBGFILES)'#010+
+ ' ',' -$(DELTREE) $(CLEANEXEDBGFILES)'#010+
'endif'#010+
'ifdef CLEANPPUFILES'#010+
' -$(DEL) $(CLEANPPUFILES)'#010+
@@ -2220,7 +2236,7 @@ const fpcmakeini : array[0..255,1..240] of char=(
' -$(DEL) $(CLEANPPULINKFILES)'#010+
'endif'#010+
'ifdef CLEANRSTFILES'#010+
- ' ',' -$(DEL) $(addprefix $(UNITTARGETDIRPREFIX),$(CLEANRSTFILES))'+
+ ' -$(DEL) $(addprefix $(UNITTARGETDIRPRE','FIX),$(CLEANRSTFILES))'+
#010+
'endif'#010+
'ifdef CLEAN_FILES'#010+
@@ -2229,18 +2245,17 @@ const fpcmakeini : array[0..255,1..240] of char=(
'ifdef LIB_NAME'#010+
' -$(DEL) $(LIB_NAME) $(LIB_FULLNAME)'#010+
'endif'#010+
- ' -$(DEL) $(FPCMADE) *$(FULL_TARGET).fpm P','ackage.fpc *$(ASMEXT'+
- ')'#010+
- ' -$(DEL) $(FPCEXTFILE) $(REDIRFILE) script*.res link*.res *_scr'+
- 'ipt.res *_link.res'#010+
+ ' -$(DEL) $(FPCMADE) *$(FULL_TARGET).fpm Package.fpc *$(ASMEXT)'#010+
+ ' -$(DEL) $(FPC','EXTFILE) $(REDIRFILE) script*.res link*.res *_s'+
+ 'cript.res *_link.res'#010+
' -$(DEL) $(PPAS) *_ppas$(BATCHEXT) ppas$(BATCHEXT) ppaslink$(BA'+
'TCHEXT)'#010+
#010+
'fpc_cleanall: $(CLEANTARGET)'#010+
'ifdef CLEANEXEFILES'#010+
- ' ',' -$(DEL) $(CLEANEXEFILES)'#010+
+ ' -$(DEL) $(CLEANEXEFILES)'#010+
'endif'#010+
- 'ifdef COMPILER_UNITTARGETDIR'#010+
+ 'ifdef',' COMPILER_UNITTARGETDIR'#010+
'ifdef CLEANPPUFILES'#010+
' -$(DEL) $(CLEANPPUFILES)'#010+
'endif'#010+
@@ -2248,7 +2263,7 @@ const fpcmakeini : array[0..255,1..240] of char=(
' -$(DEL) $(CLEANPPULINKFILES)'#010+
'endif'#010+
'ifdef CLEANRSTFILES'#010+
- ' -$(DEL) $(add','prefix $(UNITTARGETDIRPREFIX),$(CLEANRSTFILES))'+
+ ' -$(DEL) $(addprefix $(UNITTARGETDIRPREFIX),$(CLEANRSTFIL','ES))'+
#010+
'endif'#010+
'endif'#010+
@@ -2258,16 +2273,16 @@ const fpcmakeini : array[0..255,1..240] of char=(
' -$(DELTREE) units'#010+
' -$(DELTREE) bin'#010+
' -$(DEL) *$(OEXT) *$(LTOEXT) *$(PPUEXT) *$(RSTEXT) *$(ASMEXT) *'+
- '$(STA','TICLIBEXT) *$(SHAREDLIBEXT) *$(PPLEXT)'#010+
- 'ifneq ($(PPUEXT),.ppu)'#010+
+ '$(STATICLIBEXT) *$(SHAREDLIBEXT) *$(PPLEXT)'#010+
+ 'ifne','q ($(PPUEXT),.ppu)'#010+
' -$(DEL) *.o *.ppu *.a'#010+
'endif'#010+
' -$(DELTREE) *$(SMARTEXT)'#010+
' -$(DEL) fpcmade.* Package.fpc *.fpm'#010+
- ' -$(DEL) $(FPCEXTFILE) $(REDIRFILE) script*.res link*.res ','*_s'+
- 'cript.res *_link.res'#010+
- ' -$(DEL) $(PPAS) *_ppas$(BATCHEXT) ppas$(BATCHEXT) ppaslink$(BA'+
- 'TCHEXT)'#010+
+ ' -$(DEL) $(FPCEXTFILE) $(REDIRFILE) script*.res link*.res *_scr'+
+ 'ipt.res *_link.res'#010+
+ ' -$(DEL) $(P','PAS) *_ppas$(BATCHEXT) ppas$(BATCHEXT) ppaslink$('+
+ 'BATCHEXT)'#010+
'ifdef AOUTEXT'#010+
' -$(DEL) *$(AOUTEXT)'#010+
'endif'#010+
@@ -2275,8 +2290,8 @@ const fpcmakeini : array[0..255,1..240] of char=(
' -$(DEL) *$(DEBUGSYMEXT)'#010+
'endif'#010+
'ifdef LOCALFPMAKEBIN'#010+
- ' -$(DE','L) $(LOCALFPMAKEBIN)'#010+
- ' -$(DEL) $(FPMAKEBINOBJ)'#010+
+ ' -$(DEL) $(LOCALFPMAKEBIN)'#010+
+ ' -$(DEL) $(FPMA','KEBINOBJ)'#010+
'endif'#010+
#010+
'fpc_distclean: cleanall'#010+
@@ -2285,108 +2300,107 @@ const fpcmakeini : array[0..255,1..240] of char=(
'[baseinforules]'#010+
'#####################################################################'#010+
'# Base info rules'#010+
- '##################################################','##################'+
- '#'#010+
+ '#####################################################################'#010+
#010+
'.PHONY: fpc_baseinfo'#010+
- #010+
+ #010,
'override INFORULES+=fpc_baseinfo'#010+
#010+
'fpc_baseinfo:'#010+
' @$(ECHO)'#010+
' @$(ECHO) == Package info =='#010+
' @$(ECHO) Package Name..... $(PACKAGE_NAME)'#010+
- ' @$(ECHO) Package Version.. $(PACKA','GE_VERSION)'#010+
+ ' @$(ECHO) Package Version.. $(PACKAGE_VERSION)'#010+
' @$(ECHO)'#010+
- ' @$(ECHO) == Configuration info =='#010+
+ ' @$(ECH','O) == Configuration info =='#010+
' @$(ECHO)'#010+
' @$(ECHO) FPC.......... $(FPC)'#010+
' @$(ECHO) FPC Version.. $(FPC_VERSION)'#010+
' @$(ECHO) Source CPU... $(CPU_SOURCE)'#010+
- ' @$(ECHO) T','arget CPU... $(CPU_TARGET)'#010+
- ' @$(ECHO) Source OS.... $(OS_SOURCE)'#010+
+ ' @$(ECHO) Target CPU... $(CPU_TARGET)'#010+
+ ' @$(ECHO)',' Source OS.... $(OS_SOURCE)'#010+
' @$(ECHO) Target OS.... $(OS_TARGET)'#010+
' @$(ECHO) Full Source.. $(FULL_SOURCE)'#010+
' @$(ECHO) Full Target.. $(FULL_TARGET)'#010+
- ' @$(ECHO) SourceSuffi','x. $(SOURCESUFFIX)'#010+
- ' @$(ECHO) TargetSuffix. $(TARGETSUFFIX)'#010+
+ ' @$(ECHO) SourceSuffix. $(SOURCESUFFIX)'#010+
+ ' @$(ECHO) Target','Suffix. $(TARGETSUFFIX)'#010+
' @$(ECHO) FPC fpmake... $(FPCFPMAKE)'#010+
' @$(ECHO)'#010+
' @$(ECHO) == Directory info =='#010+
' @$(ECHO)'#010+
- ' @$(ECHO) Required pkgs... $(REQUIRE_PACKAGES)'#010,
+ ' @$(ECHO) Required pkgs... $(REQUIRE_PACKAGES)'#010+
' @$(ECHO)'#010+
- ' @$(ECHO) Basedir......... $(BASEDIR)'#010+
+ ' @$(ECHO) Basedir.','........ $(BASEDIR)'#010+
' @$(ECHO) FPCDir.......... $(FPCDIR)'#010+
' @$(ECHO) CrossBinDir..... $(CROSSBINDIR)'#010+
' @$(ECHO) UnitsDir........ $(UNITSDIR)'#010+
- ' @$(ECHO) PackagesDir..... ','$(PACKAGESDIR)'#010+
+ ' @$(ECHO) PackagesDir..... $(PACKAGESDIR)'#010+
' @$(ECHO)'#010+
- ' @$(ECHO) GCC library..... $(GCCLIBDIR)'#010+
+ ' @$(','ECHO) GCC library..... $(GCCLIBDIR)'#010+
' @$(ECHO) Other library... $(OTHERLIBDIR)'#010+
' @$(ECHO)'#010+
' @$(ECHO) == Tools info =='#010+
' @$(ECHO)'#010+
' @$(ECHO) As........ $(AS)'#010+
- ' ',' @$(ECHO) Ld........ $(LD)'#010+
- ' @$(ECHO) Ar........ $(AR)'#010+
+ ' @$(ECHO) Ld........ $(LD)'#010+
+ ' @$(ECH','O) Ar........ $(AR)'#010+
' @$(ECHO) Rc........ $(RC)'#010+
' @$(ECHO)'#010+
' @$(ECHO) Mv........ $(MVPROG)'#010+
' @$(ECHO) Cp........ $(CPPROG)'#010+
' @$(ECHO) Rm........ $(RMPROG)'#010+
- ' ',' @$(ECHO) GInstall.. $(GINSTALL)'#010+
- ' @$(ECHO) Echo...... $(ECHO)'#010+
+ ' @$(ECHO) GInstall.. $(GINSTALL)'#010+
+ ' @','$(ECHO) Echo...... $(ECHO)'#010+
' @$(ECHO) Shell..... $(SHELL)'#010+
' @$(ECHO) Date...... $(DATE)'#010+
' @$(ECHO) FPCMake... $(FPCMAKE)'#010+
' @$(ECHO) PPUMove... $(PPUMOVE)'#010+
- ' @$(ECH','O) Zip....... $(ZIPPROG)'#010+
- ' @$(ECHO)'#010+
+ ' @$(ECHO) Zip....... $(ZIPPROG)'#010+
+ ' @$(ECHO)'#010,
' @$(ECHO) == Object info =='#010+
' @$(ECHO)'#010+
' @$(ECHO) Target Loaders........ $(TARGET_LOADERS)'#010+
' @$(ECHO) Target Units.......... $(TARGET_UNITS)'#010+
- ' @$(ECHO) Target Imp','licit Units. $(TARGET_IMPLICITUNITS)'#010+
- ' @$(ECHO) Target Programs....... $(TARGET_PROGRAMS)'#010+
+ ' @$(ECHO) Target Implicit Units. $(TARGET_IMPLICITUNITS)'#010+
+ ' ',' @$(ECHO) Target Programs....... $(TARGET_PROGRAMS)'#010+
' @$(ECHO) Target Dirs........... $(TARGET_DIRS)'#010+
' @$(ECHO) Target Examples....... $(TARGET_EXAMPLES)'#010+
- ' @$(ECHO) Target Ex','ampleDirs.... $(TARGET_EXAMPLEDIRS)'#010+
- ' @$(ECHO)'#010+
+ ' @$(ECHO) Target ExampleDirs.... $(TARGET_EXAMPLEDIRS)'#010+
+ ' ',' @$(ECHO)'#010+
' @$(ECHO) Clean Units......... $(CLEAN_UNITS)'#010+
' @$(ECHO) Clean Files......... $(CLEAN_FILES)'#010+
' @$(ECHO)'#010+
' @$(ECHO) Install Units....... $(INSTALL_UNITS)'#010+
- ' ',' @$(ECHO) Install Files....... $(INSTALL_FILES)'#010+
+ ' @$(ECHO) Install Files....... $(INSTALL_','FILES)'#010+
' @$(ECHO)'#010+
' @$(ECHO) == Install info =='#010+
' @$(ECHO)'#010+
' @$(ECHO) DateStr.............. $(DATESTR)'#010+
' @$(ECHO) ZipName.............. $(ZIPNAME)'#010+
- ' @$(ECHO) ',' ZipPrefix............ $(ZIPPREFIX)'#010+
- ' @$(ECHO) ZipCrossPrefix....... $(ZIPCROSSPREFIX)'#010+
+ ' @$(ECHO) ZipPrefix............ $(ZIPPREFIX)'#010+
+ ' ',' @$(ECHO) ZipCrossPrefix....... $(ZIPCROSSPREFIX)'#010+
' @$(ECHO) ZipSuffix............ $(ZIPSUFFIX)'#010+
' @$(ECHO) FullZipName.......... $(FULLZIPNAME)'#010+
- ' @$(ECHO) Install FPC Package.','. $(INSTALL_FPCPACKAGE)'#010+
+ ' @$(ECHO) Install FPC Package.. $(INSTALL_FPCPACKAGE)'#010+
' @$(ECHO)'#010+
- ' @$(ECHO) Install base dir..... $(INSTALL_BASEDIR)'#010+
+ ' ',' @$(ECHO) Install base dir..... $(INSTALL_BASEDIR)'#010+
' @$(ECHO) Install binary dir... $(INSTALL_BINDIR)'#010+
' @$(ECHO) Install library dir.. $(INSTALL_LIBDIR)'#010+
- ' @$(ECHO) Instal','l units dir.... $(INSTALL_UNITDIR)'#010+
- ' @$(ECHO) Install source dir... $(INSTALL_SOURCEDIR)'#010+
+ ' @$(ECHO) Install units dir.... $(INSTALL_UNITDIR)'#010+
+ ' ','@$(ECHO) Install source dir... $(INSTALL_SOURCEDIR)'#010+
' @$(ECHO) Install doc dir...... $(INSTALL_DOCDIR)'#010+
' @$(ECHO) Install example dir.. $(INSTALL_EXAMPLEDIR)'#010+
- ' @$(ECHO) Instal','l data dir..... $(INSTALL_DATADIR)'#010+
- ' @$(ECHO)'#010+
+ ' @$(ECHO) Install data dir..... $(INSTALL_DATADIR)'#010+
+ ' ','@$(ECHO)'#010+
' @$(ECHO) Dist destination dir. $(DIST_DESTDIR)'#010+
' @$(ECHO) Dist zip name........ $(DIST_ZIPNAME)'#010+
' @$(ECHO)'#010+
#010+
'[inforules]'#010+
- '##############################################','######################'+
- '#'#010+
- '# Info rules'#010+
'#####################################################################'#010+
+ '# Info rules'#010+
+ '######','##############################################################'+
+ '#'#010+
#010+
'.PHONY: fpc_info'#010+
#010+
@@ -2394,36 +2408,37 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'[makefilerules]'#010+
'#####################################################################'#010+
- '# Re','build Makefile'#010+
- '#####################################################################'#010+
+ '# Rebuild Makefile'#010+
+ '############################','########################################'+
+ '#'#010+
#010+
'.PHONY: fpc_makefile fpc_makefiles fpc_makefile_sub1 fpc_makefile_sub2'+
' \'#010+
' fpc_makefile_dirs'#010+
#010+
'fpc_makefile:'#010+
- ' $(FPCMAKE) -w -T$(OS_TARGET) Mak','efile.fpc'#010+
+ ' $(FPCMAKE) -w -T$(OS_TARGET) Makefile.fpc'#010+
#010+
'fpc_makefile_sub1:'#010+
- 'ifdef TARGET_DIRS'#010+
+ 'ifdef TARGET_','DIRS'#010+
' $(FPCMAKE) -w -T$(OS_TARGET) $(addsuffix /Makefile.fpc,$(TARGE'+
'T_DIRS))'#010+
'endif'#010+
'ifdef TARGET_EXAMPLEDIRS'#010+
' $(FPCMAKE) -w -T$(OS_TARGET) $(addsuffix /Makefile.fpc,$(TARGE'+
- 'T_EXAMPLEDIR','S))'#010+
+ 'T_EXAMPLEDIRS))'#010+
'endif'#010+
#010+
- 'fpc_makefile_sub2: $(addsuffix _makefile_dirs,$(TARGET_DIRS) $(TARGET_'+
- 'EXAMPLEDIRS))'#010+
+ 'fpc_makefile_sub2: $(addsuffix _','makefile_dirs,$(TARGET_DIRS) $(TARGE'+
+ 'T_EXAMPLEDIRS))'#010+
#010+
'fpc_makefile_dirs: fpc_makefile_sub1 fpc_makefile_sub2'#010+
#010+
'fpc_makefiles: fpc_makefile fpc_makefile_dirs'#010+
#010+
'[localmakefile]'#010+
- '#########################','###########################################'+
- '#'#010+
+ '####################################################################','#'+
+ #010+
'# Local Makefile'#010+
'#####################################################################'#010+
#010+
@@ -2433,16 +2448,15 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
#010+
'[userrules]'#010+
- '##################################','##################################'+
- '#'#010+
- '# Users rules'#010+
+ '#####################################################################'#010+
+ '# Users',' rules'#010+
'#####################################################################'#010+
#010+
'[lclrules]'#010+
'#####################################################################'#010+
'# LCL Rules'#010+
- '##########################','##########################################'+
- '#'#010+
+ '#####################################################################',
+ #010+
#010+
'# LCL Platform'#010+
'ifndef LCL_PLATFORM'#010+
@@ -2454,9 +2468,9 @@ const fpcmakeini : array[0..255,1..240] of char=(
'endif'#010+
'export LCL_PLATFORM'#010+
#010+
- '# Check if the specified LCLDIR is cor','rect'#010+
+ '# Check if the specified LCLDIR is correct'#010+
'ifdef LCLDIR'#010+
- 'override LCLDIR:=$(subst \,/,$(LCLDIR))'#010+
+ 'override LCLDIR:=$(subst ','\,/,$(LCLDIR))'#010+
'ifeq ($(wildcard $(LCLDIR)/units/$(LCL_PLATFORM)),)'#010+
'override LCLDIR=wrong'#010+
'endif'#010+
@@ -2466,16 +2480,16 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'# Check if the default LCLDIR is correct'#010+
'ifdef DEFAULT_LCLDIR'#010+
- 'overri','de LCLDIR:=$(subst \,/,$(DEFAULT_LCLDIR))'#010+
- 'ifeq ($(wildcard $(LCLDIR)/units/$(LCL_PLATFORM)),)'#010+
+ 'override LCLDIR:=$(subst \,/,$(DEFAULT_LCLDIR))'#010+
+ 'i','feq ($(wildcard $(LCLDIR)/units/$(LCL_PLATFORM)),)'#010+
'override LCLDIR=wrong'#010+
'endif'#010+
'endif'#010+
#010+
'# Check for development version'#010+
'ifeq ($(LCLDIR),wrong)'#010+
- 'override LCLDIR=$(subst /units/$(LCL_PLATFORM),,$(firstw','ord $(wildca'+
- 'rd $(addsuffix /units/$(LCL_PLATFORM),$(BASEDIR)/lcl $(BASEDIR)))))'#010+
+ 'override LCLDIR=$(subst /units/$(LCL_PLATFORM),,$(firstword $(wildcard'+
+ ' $(addsuffix /units/$(LCL_PLA','TFORM),$(BASEDIR)/lcl $(BASEDIR)))))'#010+
'ifeq ($(LCLDIR),)'#010+
'override LCLDIR=wrong'#010+
'endif'#010+
@@ -2483,8 +2497,8 @@ const fpcmakeini : array[0..255,1..240] of char=(
#010+
'# Check for release version'#010+
'ifeq ($(LCLDIR),wrong)'#010+
- 'override LCLDIR=$(subst /units/$(LCL_PLATFORM),,$(firstw','ord $(wildca'+
- 'rd $(addsuffix /lib/lazarus/units/$(LCL_PLATFORM),/usr/local /usr))))'#010+
+ 'override LCLDIR=$(subst /units/$(LCL_PLATFORM),,$(firstword $(wildcard'+
+ ' $(addsuffix /lib/lazarus/uni','ts/$(LCL_PLATFORM),/usr/local /usr))))'#010+
'ifeq ($(LCLDIR),)'#010+
'override LCLDIR=wrong'#010+
'endif'#010+
@@ -2493,16 +2507,17 @@ const fpcmakeini : array[0..255,1..240] of char=(
'# Generate dirs'#010+
'override LCLUNITDIR=$(wildcard $(LCLDIR)/units/$(LCL_PLATFORM) $(LCLDI'+
'R)/units)'#010+
- 'override ','LCLCOMPONENTDIR=$(wildcard $(LCLDIR)/.. $(LCLDIR)/../compon'+
+ 'override LCLCOMPONENTDIR=$(wildcard $(LCLDIR)/.. $(L','CLDIR)/../compon'+
'ents $(LCLDIR)/components)'#010+
'export LCLDIR LCLUNITDIR LCLCOMPONENTDIR'#010+
#010+
'# Add LCL dirs to paths'#010+
'override REQUIRE_PACKAGESDIR+=$(LCLCOMPONENTDIR)'#010+
- 'override COMPILER_UNITDIR+=$(LCLUNITDIR',')'#010+
+ 'override COMPILER_UNITDIR+=$(LCLUNITDIR)'#010+
#010+
'[lclinforules]'#010+
- '#####################################################################'#010+
+ '#########################','###########################################'+
+ '#'#010+
'# LCL Info rules'#010+
'#####################################################################'#010+
'override INFORULES+=lclinfo'#010+
@@ -2510,20 +2525,20 @@ const fpcmakeini : array[0..255,1..240] of char=(
'.PHONY: lclinfo'#010+
#010+
'lclinfo:'#010+
- ' @$','(ECHO) == LCL info =='#010+
+ ' @$(ECHO) == LCL info =='#010+
' @$(ECHO)'#010+
- ' @$(ECHO) Platform............. $(LCL_PLATFORM)'#010+
+ ' ',' @$(ECHO) Platform............. $(LCL_PLATFORM)'#010+
' @$(ECHO) LCLDIR............... $(LCLDIR)'#010+
' @$(ECHO) LCL Unit dir......... $(LCLUNITDIR)'#010+
- ' @$(ECHO) LCL Component dir.... ','$(LCLCOMPONENTDIR)'#010+
+ ' @$(ECHO) LCL Component dir.... $(LCLCOMPONENTDIR)'#010+
' @$(ECHO)'#010+
#010+
- '[fpmakeprerules]'#010+
+ '[fpmak','eprerules]'#010+
'#####################################################################'#010+
'# fpmake prerules'#010+
'#####################################################################'#010+
- 'FPMAKEBIN=fpmake$(SRCEXEEXT)',#010+
- 'FPMAKEBINOBJ=fpmake$(OEXT) fpmake$(LTOEXT)'#010+
+ 'FPMAKEBIN=fpmake$(SRCEXEEXT)'#010+
+ 'FPMAKEBINOBJ=fpmake$(OEXT) fpmake$(LTOEXT)',#010+
'LOCALFPMAKEBIN=.$(PATHSEP)$(FPMAKEBIN)'#010+
#010+
'# Convert the OS_TARGET and CPU_TARGET options to fpmake'#039's --os an'+
@@ -2531,53 +2546,52 @@ const fpcmakeini : array[0..255,1..240] of char=(
'ifdef OS_TARGET'#010+
'FPC_TARGETOPT+=--os=$(OS_TARGET)'#010+
'endif'#010+
- 'ifdef CPU_TARGET',#010+
+ 'ifdef CPU_TARGET'#010+
'FPC_TARGETOPT+=--cpu=$(CPU_TARGET)'#010+
'endif'#010+
- #010+
+ #010,
'# Get the location of the bootstrap-fpmkunit units'#010+
'PACKAGEDIR_FPMKUNIT:=$(firstword $(subst /Makefile.fpc,,$(strip $(wild'+
'card $(addsuffix /fpmkunit/Makefile.fpc,$(PACKAGESDIR))))))'#010+
- 'ifneq ($(PACKAGE','DIR_FPMKUNIT),)'#010+
- 'UNITDIR_FPMAKE_FPMKUNIT=$(PACKAGEDIR_FPMKUNIT)/units_bs/$(SOURCESUFFIX'+
- ')'#010+
+ 'ifneq ($(PACKAGEDIR_FPMKUNIT),)'#010+
+ 'UNITDIR_FPMAKE_FPMKUNIT=$(P','ACKAGEDIR_FPMKUNIT)/units_bs/$(SOURCESUFF'+
+ 'IX)'#010+
'override COMPILER_FPMAKE_UNITDIR=$(UNITDIR_FPMAKE_FPMKUNIT)'#010+
'FPMKUNIT_SRC=$(PACKAGEDIR_FPMKUNIT)/src/fpmkunit.pp'#010+
- 'FPMKUNIT_PPU=$(UNITDIR_FPMAKE_FPMKUNIT)/','fpmkunit.ppu'#010+
+ 'FPMKUNIT_PPU=$(UNITDIR_FPMAKE_FPMKUNIT)/fpmkunit.ppu'#010+
'endif'#010+
#010+
- 'ifdef FPMAKE_SKIP_CONFIG'#010+
+ 'ifdef FPMAKE_SKIP_CONFI','G'#010+
'override FPMAKE_BUILD_OPT+=$(FPMAKE_SKIP_CONFIG)'#010+
'endif'#010+
#010+
'[fpmakerules]'#010+
'#####################################################################'#010+
'# fpmake rules'#010+
- '########################################','############################'+
- '#'#010+
- '.PHONY: fpc_fpmake fpc_fpmake_clean fpc_fpmake_install fpc_fpmake_exam'+
- 'pleinstall'#010+
+ '#####################################################################'#010+
+ '.PHONY: fpc_f','pmake fpc_fpmake_clean fpc_fpmake_install fpc_fpmake_ex'+
+ 'ampleinstall'#010+
#010+
'# Do not pass the Makefile'#039's unit and binary target locations. fpm'+
'ake uses it'#039's own.'#010+
- 'override FPCOPT:=$(filter-out -FU%,$(FPCOPT','))'#010+
- 'override FPCOPT:=$(filter-out -FE%,$(FPCOPT))'#010+
+ 'override FPCOPT:=$(filter-out -FU%,$(FPCOPT))'#010+
+ 'override FPCOPT:=$(filter-out -FE%,$(FPC','OPT))'#010+
'# Compose general fpmake-parameters'#010+
'ifdef FPMAKEOPT'#010+
'FPMAKE_OPT+=$(FPMAKEOPT)'#010+
'endif'#010+
'FPMAKE_OPT+=--localunitdir=$(FPCDIR)'#010+
'FPMAKE_OPT+=--globalunitdir=$(FPCDIR)/packages'#010+
- 'FPMAKE_OPT+=$(FPC_TARGET','OPT)'#010+
- 'FPMAKE_OPT+=$(addprefix -o ,$(FPCOPT))'#010+
+ 'FPMAKE_OPT+=$(FPC_TARGETOPT)'#010+
+ 'FPMAKE_OPT+=$(addprefix -o ,$(FPCOPT))',#010+
'FPMAKE_OPT+=--compiler=$(FPC)'#010+
'FPMAKE_OPT+=-bu'#010+
#010+
'FPMAKE_INSTALL_OPT+=--unitinstalldir=$(INSTALL_UNITDIR)'#010+
'ifdef UNIXHier'#010+
'FPMAKE_INSTALL_OPT+=--prefix=$(INSTALL_PREFIX)'#010+
- 'FPMAKE_INSTALL_OPT+=--baseinsta','lldir=$(INSTALL_LIBDIR)/fpc/$(FPC_VER'+
- 'SION)'#010+
+ 'FPMAKE_INSTALL_OPT+=--baseinstalldir=$(INSTALL_LIBDIR)/fpc/$(FPC_VERSI'+
+ 'ON)'#010,
'else'#010+
'FPMAKE_INSTALL_OPT+=--prefix=$(INSTALL_BASEDIR)'#010+
'endif'#010+
@@ -2585,21 +2599,21 @@ const fpcmakeini : array[0..255,1..240] of char=(
'override ALLTARGET+=fpc_fpmake'#010+
'override INSTALLTARGET+=fpc_fpmake_install'#010+
'override EXAMPLEINSTALLTARGET+=fpc_fpmake_exampleinstall'#010+
- '# If n','o fpmake exists and (dist)clean is called, do not try to build'+
+ '# If no fpmake exists and (dist)clean is called, ','do not try to build'+
' fpmake, it will'#010+
'# most often fail because the dependencies are cleared.'#010+
'# In case of a clean, simply do nothing'#010+
'ifneq ($(wildcard $(LOCALFPMAKEBIN)),)'#010+
- 'override CLEANTARGET+=fpc_','fpmake_clean'#010+
+ 'override CLEANTARGET+=fpc_fpmake_clean'#010+
'endif'#010+
#010+
- '$(FPMKUNIT_PPU): $(FPMKUNIT_SRC)'#010+
+ '$(FPMKUNIT_PPU): $(FPMK','UNIT_SRC)'#010+
' $(MAKE) -C $(PACKAGEDIR_FPMKUNIT) bootstrap $(addprefix OP'+
'T=,$(FPMAKE_BUILD_OPT))'#010+
#010+
'$(FPMAKEBIN): fpmake.pp $(FPMKUNIT_PPU)'#010+
- ' $(FPCFPMAKE) fpmake.pp $(addprefix -Fu,$(COM','PILER_FPMAKE_UNI'+
- 'TDIR)) $(FPMAKE_BUILD_OPT)'#010+
+ ' $(FPCFPMAKE) fpmake.pp $(addprefix -Fu,$(COMPILER_FPMAKE_UNITD'+
+ 'IR)) $(FPMAKE_BUILD_OPT)'#010,
#010+
'fpc_fpmake: $(FPMAKEBIN)'#010+
' $(LOCALFPMAKEBIN) compile $(FPMAKE_OPT)'#010+
@@ -2608,14 +2622,14 @@ const fpcmakeini : array[0..255,1..240] of char=(
' $(LOCALFPMAKEBIN) clean $(FPMAKE_OPT)'#010+
#010+
'fpc_fpmake_install: $(FPMAKEBIN)'#010+
- ' ',' $(LOCALFPMAKEBIN) install $(FPMAKE_OPT) $(FPMAKE_INSTALL'+
+ ' $(LOCALFPMAKEBIN) install $(FPMAKE','_OPT) $(FPMAKE_INSTALL'+
'_OPT)'#010+
#010+
'# This is not completely valid. Exampleinstall should only install the'+
' examples, while'#010+
'# fpmake -ie installs everything, including the examples. This also me'+
- 'ans that on',#010+
- '# a distinstall fpmake install wil be called twice.'#010+
+ 'ans that on'#010+
+ '# a distinstall fpmake install wil be call','ed twice.'#010+
'fpc_fpmake_exampleinstall: $(FPMAKEBIN)'#010+
' $(LOCALFPMAKEBIN) install -ie $(FPMAKE_OPT) $(FPMAKE_INSTA'+
'LL_OPT)'#010
diff --git a/utils/fpcm/fpcmake.ini b/utils/fpcm/fpcmake.ini
index f78782fe29..8af5b1ce10 100644
--- a/utils/fpcm/fpcmake.ini
+++ b/utils/fpcm/fpcmake.ini
@@ -898,10 +898,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -1509,7 +1517,7 @@ endif
# create always pic'ed code on x86_64, mips and mipsel
# on unix-like systems
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/fpcm/revision.inc b/utils/fpcm/revision.inc
index 877a2cb79b..f0692a17cb 100644
--- a/utils/fpcm/revision.inc
+++ b/utils/fpcm/revision.inc
@@ -1 +1 @@
-'2021-01-24 rev 48368'
+'2021-03-10 rev 48929'
diff --git a/utils/fpcmkcfg/Makefile b/utils/fpcmkcfg/Makefile
index 8ed4345c57..18a20eba1e 100644
--- a/utils/fpcmkcfg/Makefile
+++ b/utils/fpcmkcfg/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/fpcres/Makefile b/utils/fpcres/Makefile
index 89d3fdbab3..0f72608c6c 100644
--- a/utils/fpcres/Makefile
+++ b/utils/fpcres/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/fpcreslipo/Makefile b/utils/fpcreslipo/Makefile
index 058493a967..ce5a2fddc0 100644
--- a/utils/fpcreslipo/Makefile
+++ b/utils/fpcreslipo/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/fpdoc/Makefile b/utils/fpdoc/Makefile
index e16917fdfc..21b676c8f2 100644
--- a/utils/fpdoc/Makefile
+++ b/utils/fpdoc/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/fpmc/Makefile b/utils/fpmc/Makefile
index 8efbda7db5..a557db1cca 100644
--- a/utils/fpmc/Makefile
+++ b/utils/fpmc/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/fppkg/Makefile b/utils/fppkg/Makefile
index 1dd7590db4..31ebc6905c 100644
--- a/utils/fppkg/Makefile
+++ b/utils/fppkg/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/fprcp/Makefile b/utils/fprcp/Makefile
index b9d3a75f6a..958dc19021 100644
--- a/utils/fprcp/Makefile
+++ b/utils/fprcp/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/h2pas/Makefile b/utils/h2pas/Makefile
index 4204d75746..192aecc114 100644
--- a/utils/h2pas/Makefile
+++ b/utils/h2pas/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/ihxutil/Makefile b/utils/ihxutil/Makefile
index 111586ae3a..6a2d4f52ea 100644
--- a/utils/ihxutil/Makefile
+++ b/utils/ihxutil/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/importtl/Makefile b/utils/importtl/Makefile
index 2c07a323a9..02b6368191 100644
--- a/utils/importtl/Makefile
+++ b/utils/importtl/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/instantfpc/Makefile b/utils/instantfpc/Makefile
index e1c8eb93b1..1b3e0c6bd8 100644
--- a/utils/instantfpc/Makefile
+++ b/utils/instantfpc/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/json2pas/Makefile b/utils/json2pas/Makefile
index c4736c659e..e9fb7c3fa9 100644
--- a/utils/json2pas/Makefile
+++ b/utils/json2pas/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/mksymbian/Makefile b/utils/mksymbian/Makefile
index bea6b44b90..3d1ea44503 100644
--- a/utils/mksymbian/Makefile
+++ b/utils/mksymbian/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/pas2fpm/Makefile b/utils/pas2fpm/Makefile
index 26efb90654..c82e0769ee 100644
--- a/utils/pas2fpm/Makefile
+++ b/utils/pas2fpm/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/pas2jni/Makefile b/utils/pas2jni/Makefile
index 2b106f2b4f..4afc9d107e 100644
--- a/utils/pas2jni/Makefile
+++ b/utils/pas2jni/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/pas2js/Makefile b/utils/pas2js/Makefile
index b1a9bee0f7..14ba173fa0 100644
--- a/utils/pas2js/Makefile
+++ b/utils/pas2js/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/pas2ut/Makefile b/utils/pas2ut/Makefile
index 469b016b0f..3ce10ece7e 100644
--- a/utils/pas2ut/Makefile
+++ b/utils/pas2ut/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/rmwait/Makefile b/utils/rmwait/Makefile
index d708ad2700..125f783870 100644
--- a/utils/rmwait/Makefile
+++ b/utils/rmwait/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/tply/Makefile b/utils/tply/Makefile
index ca9b2d5bc0..eda5dd4074 100644
--- a/utils/tply/Makefile
+++ b/utils/tply/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
diff --git a/utils/unicode/Makefile b/utils/unicode/Makefile
index de30ab14fc..845490910a 100644
--- a/utils/unicode/Makefile
+++ b/utils/unicode/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif