|
@@ -1,5 +1,5 @@
|
|
|
#
|
|
|
-# Makefile generated by fpcmake v0.99.13 [2000/01/28]
|
|
|
+# Makefile generated by fpcmake v0.99.13 [2000/02/08]
|
|
|
#
|
|
|
|
|
|
defaultrule: all
|
|
@@ -166,6 +166,7 @@ override DIROBJECTS+=$(wildcard fake text)
|
|
|
|
|
|
# Install
|
|
|
|
|
|
+PACKAGENAME=ide
|
|
|
ZIPTARGET=install
|
|
|
|
|
|
# Defaults
|
|
@@ -180,6 +181,147 @@ ZIPTARGET=install
|
|
|
# Libraries
|
|
|
|
|
|
|
|
|
+#####################################################################
|
|
|
+# Shell tools
|
|
|
+#####################################################################
|
|
|
+
|
|
|
+# echo
|
|
|
+ifndef ECHO
|
|
|
+ECHO:=$(strip $(wildcard $(addsuffix /gecho$(EXEEXT),$(SEARCHPATH))))
|
|
|
+ifeq ($(ECHO),)
|
|
|
+ECHO:=$(strip $(wildcard $(addsuffix /echo$(EXEEXT),$(SEARCHPATH))))
|
|
|
+ifeq ($(ECHO),)
|
|
|
+ECHO:=echo
|
|
|
+ECHOE:=echo
|
|
|
+else
|
|
|
+ECHO:=$(firstword $(ECHO))
|
|
|
+ECHOE=$(ECHO) -E
|
|
|
+endif
|
|
|
+else
|
|
|
+ECHO:=$(firstword $(ECHO))
|
|
|
+ECHOE=$(ECHO) -E
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+# To copy pograms
|
|
|
+ifndef COPY
|
|
|
+COPY:=cp -fp
|
|
|
+endif
|
|
|
+
|
|
|
+# Copy a whole tree
|
|
|
+ifndef COPYTREE
|
|
|
+COPYTREE:=cp -rfp
|
|
|
+endif
|
|
|
+
|
|
|
+# To move pograms
|
|
|
+ifndef MOVE
|
|
|
+MOVE:=mv -f
|
|
|
+endif
|
|
|
+
|
|
|
+# Check delete program
|
|
|
+ifndef DEL
|
|
|
+DEL:=rm -f
|
|
|
+endif
|
|
|
+
|
|
|
+# Check deltree program
|
|
|
+ifndef DELTREE
|
|
|
+DELTREE:=rm -rf
|
|
|
+endif
|
|
|
+
|
|
|
+# To install files
|
|
|
+ifndef INSTALL
|
|
|
+ifdef inlinux
|
|
|
+INSTALL:=install -m 644
|
|
|
+else
|
|
|
+INSTALL:=$(COPY)
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+# To install programs
|
|
|
+ifndef INSTALLEXE
|
|
|
+ifdef inlinux
|
|
|
+INSTALLEXE:=install -m 755
|
|
|
+else
|
|
|
+INSTALLEXE:=$(COPY)
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+# To make a directory.
|
|
|
+ifndef MKDIR
|
|
|
+ifdef inlinux
|
|
|
+MKDIR:=install -m 755 -d
|
|
|
+else
|
|
|
+MKDIR:=ginstall -m 755 -d
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+export ECHO ECHOE COPY COPYTREE MOVE DEL DELTREE INSTALL INSTALLEXE MKDIR
|
|
|
+
|
|
|
+#####################################################################
|
|
|
+# Default Tools
|
|
|
+#####################################################################
|
|
|
+
|
|
|
+# assembler, redefine it if cross compiling
|
|
|
+ifndef AS
|
|
|
+AS=as
|
|
|
+endif
|
|
|
+
|
|
|
+# linker, but probably not used
|
|
|
+ifndef LD
|
|
|
+LD=ld
|
|
|
+endif
|
|
|
+
|
|
|
+# ppas.bat / ppas.sh
|
|
|
+ifdef inlinux
|
|
|
+PPAS=ppas.sh
|
|
|
+else
|
|
|
+ifdef inOS2
|
|
|
+PPAS=ppas.cmd
|
|
|
+else
|
|
|
+PPAS=ppas.bat
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+# ldconfig to rebuild .so cache
|
|
|
+ifdef inlinux
|
|
|
+LDCONFIG=ldconfig
|
|
|
+else
|
|
|
+LDCONFIG=
|
|
|
+endif
|
|
|
+
|
|
|
+# ZipProg, you can't use Zip as the var name (PFV)
|
|
|
+ifndef ZIPPROG
|
|
|
+ZIPPROG:=$(strip $(wildcard $(addsuffix /zip$(EXEEXT),$(SEARCHPATH))))
|
|
|
+ifeq ($(ZIPPROG),)
|
|
|
+ZIPPROG=
|
|
|
+else
|
|
|
+ZIPPROG:=$(firstword $(ZIPPROG))
|
|
|
+endif
|
|
|
+endif
|
|
|
+export ZIPPROG
|
|
|
+
|
|
|
+ZIPOPT=-9
|
|
|
+ZIPEXT=.zip
|
|
|
+
|
|
|
+# Tar
|
|
|
+ifndef TARPROG
|
|
|
+TARPROG:=$(strip $(wildcard $(addsuffix /tar$(EXEEXT),$(SEARCHPATH))))
|
|
|
+ifeq ($(TARPROG),)
|
|
|
+TARPROG=
|
|
|
+else
|
|
|
+TARPROG:=$(firstword $(TARPROG))
|
|
|
+endif
|
|
|
+endif
|
|
|
+export TARPROG
|
|
|
+
|
|
|
+ifeq ($(USETAR),bz2)
|
|
|
+TAROPT=vI
|
|
|
+TAREXT=.tar.bz2
|
|
|
+else
|
|
|
+TAROPT=vz
|
|
|
+TAREXT=.tar.gz
|
|
|
+endif
|
|
|
+
|
|
|
|
|
|
|
|
|
#####################################################################
|
|
@@ -202,6 +344,71 @@ DESTZIPDIR:=$(BASEDIR)
|
|
|
endif
|
|
|
export DESTZIPDIR
|
|
|
|
|
|
+#####################################################################
|
|
|
+# Install Directories
|
|
|
+#####################################################################
|
|
|
+
|
|
|
+# set the base directory where to install everything
|
|
|
+ifndef BASEINSTALLDIR
|
|
|
+ifdef inlinux
|
|
|
+BASEINSTALLDIR=$(PREFIXINSTALLDIR)/lib/fpc/$(FPC_VERSION)
|
|
|
+else
|
|
|
+BASEINSTALLDIR=$(PREFIXINSTALLDIR)
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+# set the directory where to install the binaries
|
|
|
+ifndef BININSTALLDIR
|
|
|
+ifdef inlinux
|
|
|
+BININSTALLDIR=$(PREFIXINSTALLDIR)/bin
|
|
|
+else
|
|
|
+BININSTALLDIR=$(BASEINSTALLDIR)/bin/$(OS_TARGET)
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+# set the directory where to install the units.
|
|
|
+ifndef UNITINSTALLDIR
|
|
|
+UNITINSTALLDIR=$(BASEINSTALLDIR)/units/$(OS_TARGET)
|
|
|
+ifdef UNITSUBDIR
|
|
|
+UNITINSTALLDIR:=$(UNITINSTALLDIR)/$(UNITSUBDIR)
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+# Where to install shared libraries
|
|
|
+ifndef LIBINSTALLDIR
|
|
|
+ifdef inlinux
|
|
|
+LIBINSTALLDIR=$(PREFIXINSTALLDIR)/lib
|
|
|
+else
|
|
|
+LIBINSTALLDIR=$(UNITINSTALLDIR)
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+# Where the source files will be stored
|
|
|
+ifndef SOURCEINSTALLDIR
|
|
|
+ifdef inlinux
|
|
|
+SOURCEINSTALLDIR=$(PREFIXINSTALLDIR)/src/fpc-$(FPC_VERSION)
|
|
|
+else
|
|
|
+SOURCEINSTALLDIR=$(BASEINSTALLDIR)/source
|
|
|
+endif
|
|
|
+ifdef SOURCESUBDIR
|
|
|
+SOURCEINSTALLDIR:=$(SOURCEINSTALLDIR)/$(SOURCESUBDIR)
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+# Where the doc files will be stored
|
|
|
+ifndef DOCINSTALLDIR
|
|
|
+ifdef inlinux
|
|
|
+DOCINSTALLDIR=$(PREFIXINSTALLDIR)/doc/fpc-$(FPC_VERSION)
|
|
|
+else
|
|
|
+DOCINSTALLDIR=$(BASEINSTALLDIR)/doc
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+# Where the some extra (data)files will be stored
|
|
|
+ifndef DATAINSTALLDIR
|
|
|
+DATAINSTALLDIR=$(BASEINSTALLDIR)
|
|
|
+endif
|
|
|
+
|
|
|
#####################################################################
|
|
|
# Redirection
|
|
|
#####################################################################
|
|
@@ -233,11 +440,15 @@ smart: $(addsuffix _smart,$(DIROBJECTS))
|
|
|
|
|
|
shared: $(addsuffix _shared,$(DIROBJECTS))
|
|
|
|
|
|
-showinstall: $(addsuffix _showinstall,$(DIROBJECTS))
|
|
|
+showinstall: $(addsuffix _showinstall,text)
|
|
|
+
|
|
|
+install: $(addsuffix _install,text)
|
|
|
|
|
|
-install: $(addsuffix _install,$(DIROBJECTS))
|
|
|
+sourceinstall: fpc_sourceinstall
|
|
|
|
|
|
-sourceinstall: $(addsuffix _sourceinstall,$(DIROBJECTS))
|
|
|
+zipinstall: fpc_zipinstall
|
|
|
+
|
|
|
+zipsourceinstall: fpc_zipsourceinstall
|
|
|
|
|
|
clean: $(addsuffix _clean,$(DIROBJECTS))
|
|
|
|
|
@@ -247,7 +458,82 @@ cleanall: $(addsuffix _cleanall,$(DIROBJECTS))
|
|
|
|
|
|
require: $(addsuffix _require,$(DIROBJECTS))
|
|
|
|
|
|
-.PHONY: debug examples test smart shared showinstall install sourceinstall clean distclean cleanall require
|
|
|
+.PHONY: debug examples test smart shared showinstall install sourceinstall zipinstall zipsourceinstall clean distclean cleanall require
|
|
|
+
|
|
|
+#####################################################################
|
|
|
+# SourceInstall rules
|
|
|
+#####################################################################
|
|
|
+
|
|
|
+.PHONY: fpc_sourceinstall
|
|
|
+
|
|
|
+ifndef SOURCETOPDIR
|
|
|
+SOURCETOPDIR=$(BASEDIR)
|
|
|
+endif
|
|
|
+
|
|
|
+fpc_sourceinstall: clean
|
|
|
+ $(MKDIR) $(SOURCEINSTALLDIR)
|
|
|
+ $(COPYTREE) $(SOURCETOPDIR) $(SOURCEINSTALLDIR)
|
|
|
+
|
|
|
+#####################################################################
|
|
|
+# Zip
|
|
|
+#####################################################################
|
|
|
+
|
|
|
+.PHONY: fpc_zipinstall
|
|
|
+
|
|
|
+# Create suffix to add
|
|
|
+ifndef PACKAGESUFFIX
|
|
|
+PACKAGESUFFIX=$(OS_TARGET)
|
|
|
+ifeq ($(OS_TARGET),go32v2)
|
|
|
+PACKAGESUFFIX=go32
|
|
|
+endif
|
|
|
+ifeq ($(OS_TARGET),win32)
|
|
|
+PACKAGESUFFIX=w32
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+# Temporary path to pack a file
|
|
|
+ifndef PACKDIR
|
|
|
+ifndef inlinux
|
|
|
+PACKDIR=$(BASEDIR)/pack_tmp
|
|
|
+else
|
|
|
+PACKDIR=/tmp/fpc-pack
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+# Maybe create default zipname from packagename
|
|
|
+ifndef ZIPNAME
|
|
|
+ifdef PACKAGENAME
|
|
|
+ZIPNAME=$(PACKAGEPREFIX)$(PACKAGENAME)$(PACKAGESUFFIX)
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+# Use tar by default under linux
|
|
|
+ifndef USEZIP
|
|
|
+ifdef inlinux
|
|
|
+USETAR=1
|
|
|
+endif
|
|
|
+endif
|
|
|
+
|
|
|
+fpc_zipinstall:
|
|
|
+ifndef ZIPNAME
|
|
|
+ @$(ECHO) "Please specify ZIPNAME!"
|
|
|
+ @exit 1
|
|
|
+else
|
|
|
+ $(MAKE) $(ZIPTARGET) PREFIXINSTALLDIR=$(PACKDIR)
|
|
|
+ifdef USETAR
|
|
|
+ $(DEL) $(DESTZIPDIR)/$(ZIPNAME)$(TAREXT)
|
|
|
+ cd $(PACKDIR) ; $(TARPROG) c$(TAROPT) --file $(DESTZIPDIR)/$(ZIPNAME)$(TAREXT) * ; cd $(BASEDIR)
|
|
|
+else
|
|
|
+ $(DEL) $(DESTZIPDIR)/$(ZIPNAME)$(ZIPEXT)
|
|
|
+ cd $(PACKDIR) ; $(ZIPPROG) -Dr $(ZIPOPT) $(DESTZIPDIR)/$(ZIPNAME)$(ZIPEXT) * ; cd $(BASEDIR)
|
|
|
+endif
|
|
|
+ $(DELTREE) $(PACKDIR)
|
|
|
+endif
|
|
|
+
|
|
|
+.PHONY: fpc_zipsourceinstall
|
|
|
+
|
|
|
+fpc_zipsourceinstall:
|
|
|
+ $(MAKE) fpc_zipinstall ZIPTARGET=sourceinstall PACKAGESUFFIX=src
|
|
|
|
|
|
#####################################################################
|
|
|
# Directories
|
|
@@ -394,4 +680,4 @@ fullgdb:
|
|
|
# Misc
|
|
|
#
|
|
|
clean_compiler:
|
|
|
- make -C ../../compiler clean
|
|
|
+ $(MAKE) -C ../compiler clean
|