From d947d8c454e496ba442b4a48e5f718e5f63ee703 Mon Sep 17 00:00:00 2001 From: michael Date: Tue, 20 Apr 1999 12:33:32 +0000 Subject: [PATCH] + Fixed GCCLIB detection. Added fpc_dirinfo target --- base/makefile.fpc | 29 ++++++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-) diff --git a/base/makefile.fpc b/base/makefile.fpc index 95b5fb7adb..004a0937b1 100644 --- a/base/makefile.fpc +++ b/base/makefile.fpc @@ -362,10 +362,10 @@ BASEINSTALLDIR=$(PREFIXINSTALLDIR) endif endif -# try to find where libgcc.a is. +# On linux, try to find where libgcc.a is. ifdef inlinux ifndef GCCLIBDIR -GCCLIBDIR:=$(shell "dirname `gcc -v | & awk -F" " ' print $4 }'`") +GCCLIBDIR:=$(shell dirname `(gcc -v 2>&1)| awk -F' ' '{ print $$4 } '`) endif endif @@ -481,6 +481,13 @@ ifdef NEEDLIBDIR override PPOPT+=$(addprefix -Fl,$(NEEDLIBDIR)) endif +# Add GCC lib path if asked +ifeq ($(NEEDGCCLIB),YES) +ifdef GCCLIBDIR +override PPOPT+=-Fl$(GCCLIBDIR) +endif +endif + # Object dirs ifdef OBJDIR override PPOPT+=$(addprefix -Fo,$(OBJDIR)) @@ -673,7 +680,8 @@ UNITOFILES=$(addsuffix $(OEXT),$(UNITOBJECTS)) fpc_staticlib fpc_sharedlib \ fpc_clean fpc_libsclean fpc_cleanall \ fpc_install fpc_staticlibinstall fpc_sharedlibinstall fpc_libinstall \ - fpc_info fpc_cfginfo fpc_objectinfo fpc_installinfo fpc_filesinfo + fpc_info fpc_cfginfo fpc_objectinfo fpc_installinfo fpc_filesinfo\ + fpc_dirinfo .SUFFIXES : $(EXEEXT) $(PPUEXT) $(PASEXT) $(OEXT) @@ -897,9 +905,17 @@ fpc_cfginfo: @$(ECHO) Basedir... $(BASEDIR) @$(ECHO) -fpc_dirinfo +fpc_dirinfo: ifdef inlinux + @$(ECHO) + @$(ECHO) == Directory info == + @$(ECHO) +ifeq ($(NEEDGCCLIB),YES) + @$(ECHO) GCC library is needed. +endif @$(ECHO) GCC library in $(GCCLIBDIR) + @$(ECHO) + endif fpc_toolsinfo: @@ -985,7 +1001,10 @@ endif # # $Log$ -# Revision 1.16 1999-04-20 12:07:49 michael +# Revision 1.17 1999-04-20 12:33:32 michael +# + Fixed GCCLIB detection. Added fpc_dirinfo target +# +# Revision 1.16 1999/04/20 12:07:49 michael # Added autodetect of gcc lib for linux # # Revision 1.15 1999/04/16 20:12:35 michael