Quellcode durchsuchen

--- Merging r14224 into '.':
U compiler/ogelf.pas
C compiler/Makefile
C compiler/systems.pas
U compiler/utils/fpcfg.inc
Summary of conflicts:
Text conflicts: 2

# revisions: 14224
------------------------------------------------------------------------
r14224 | pierre | 2009-11-20 12:06:50 +0100 (Fri, 20 Nov 2009) | 1 line
Changed paths:
M /trunk/compiler/Makefile
M /trunk/compiler/ogelf.pas
M /trunk/compiler/systems.pas
M /trunk/compiler/utils/fpcfg.inc

* Accept weak for Solaris targets
------------------------------------------------------------------------

git-svn-id: branches/fixes_2_4@14730 -

marco vor 15 Jahren
Ursprung
Commit
fb3d2660b3
4 geänderte Dateien mit 84 neuen und 54 gelöschten Zeilen
  1. 30 6
      compiler/Makefile
  2. 2 0
      compiler/ogelf.pas
  3. 5 1
      compiler/systems.pas
  4. 47 47
      compiler/utils/fpcfg.inc

+ 30 - 6
compiler/Makefile

@@ -1,10 +1,10 @@
 #
-# Don't edit, this file is generated by FPCMake Version 2.0.0 [2009/08/14]
+# Don't edit, this file is generated by FPCMake Version 2.0.0 [2009/11/17]
 #
 default: all
-MAKEFILETARGETS=i386-linux i386-go32v2 i386-win32 i386-os2 i386-freebsd i386-beos i386-haiku i386-netbsd i386-solaris i386-qnx i386-netware i386-openbsd i386-wdosx i386-darwin i386-emx i386-watcom i386-netwlibc i386-wince i386-embedded i386-symbian m68k-linux m68k-freebsd m68k-netbsd m68k-amiga m68k-atari m68k-openbsd m68k-palmos m68k-embedded powerpc-linux powerpc-netbsd powerpc-amiga powerpc-macos powerpc-darwin powerpc-morphos powerpc-embedded sparc-linux sparc-netbsd sparc-solaris sparc-embedded x86_64-linux x86_64-freebsd x86_64-darwin x86_64-win64 x86_64-embedded arm-linux arm-palmos arm-darwin arm-wince arm-gba arm-nds arm-embedded arm-symbian powerpc64-linux powerpc64-darwin powerpc64-embedded avr-embedded armeb-linux armeb-embedded
+MAKEFILETARGETS=i386-linux i386-go32v2 i386-win32 i386-os2 i386-freebsd i386-beos i386-haiku i386-netbsd i386-solaris i386-qnx i386-netware i386-openbsd i386-wdosx i386-darwin i386-emx i386-watcom i386-netwlibc i386-wince i386-embedded i386-symbian m68k-linux m68k-freebsd m68k-netbsd m68k-amiga m68k-atari m68k-openbsd m68k-palmos m68k-embedded powerpc-linux powerpc-netbsd powerpc-amiga powerpc-macos powerpc-darwin powerpc-morphos powerpc-embedded sparc-linux sparc-netbsd sparc-solaris sparc-embedded x86_64-linux x86_64-freebsd x86_64-solaris x86_64-darwin x86_64-win64 x86_64-embedded arm-linux arm-palmos arm-darwin arm-wince arm-gba arm-nds arm-embedded arm-symbian powerpc64-linux powerpc64-darwin powerpc64-embedded avr-embedded armeb-linux armeb-embedded
 BSDs = freebsd netbsd openbsd darwin
-UNIXs = linux $(BSDs) solaris qnx
+UNIXs = linux $(BSDs) solaris qnx haiku
 LIMIT83fs = go32v2 os2 emx watcom
 OSNeedsComspecToRunBatch = go32v2 watcom
 FORCE:
@@ -507,6 +507,9 @@ endif
 ifeq ($(FULL_TARGET),x86_64-freebsd)
 override TARGET_DIRS+=utils
 endif
+ifeq ($(FULL_TARGET),x86_64-solaris)
+override TARGET_DIRS+=utils
+endif
 ifeq ($(FULL_TARGET),x86_64-darwin)
 override TARGET_DIRS+=utils
 endif
@@ -681,6 +684,9 @@ endif
 ifeq ($(FULL_TARGET),x86_64-freebsd)
 override TARGET_PROGRAMS+=pp
 endif
+ifeq ($(FULL_TARGET),x86_64-solaris)
+override TARGET_PROGRAMS+=pp
+endif
 ifeq ($(FULL_TARGET),x86_64-darwin)
 override TARGET_PROGRAMS+=pp
 endif
@@ -856,6 +862,9 @@ endif
 ifeq ($(FULL_TARGET),x86_64-freebsd)
 override COMPILER_INCLUDEDIR+=$(CPC_TARGET)
 endif
+ifeq ($(FULL_TARGET),x86_64-solaris)
+override COMPILER_INCLUDEDIR+=$(CPC_TARGET)
+endif
 ifeq ($(FULL_TARGET),x86_64-darwin)
 override COMPILER_INCLUDEDIR+=$(CPC_TARGET)
 endif
@@ -1030,6 +1039,9 @@ endif
 ifeq ($(FULL_TARGET),x86_64-freebsd)
 override COMPILER_UNITDIR+=$(COMPILERSOURCEDIR)
 endif
+ifeq ($(FULL_TARGET),x86_64-solaris)
+override COMPILER_UNITDIR+=$(COMPILERSOURCEDIR)
+endif
 ifeq ($(FULL_TARGET),x86_64-darwin)
 override COMPILER_UNITDIR+=$(COMPILERSOURCEDIR)
 endif
@@ -1204,6 +1216,9 @@ endif
 ifeq ($(FULL_TARGET),x86_64-freebsd)
 override COMPILER_TARGETDIR+=.
 endif
+ifeq ($(FULL_TARGET),x86_64-solaris)
+override COMPILER_TARGETDIR+=.
+endif
 ifeq ($(FULL_TARGET),x86_64-darwin)
 override COMPILER_TARGETDIR+=.
 endif
@@ -1378,6 +1393,9 @@ endif
 ifeq ($(FULL_TARGET),x86_64-freebsd)
 override COMPILER_UNITTARGETDIR+=$(CPU_UNITDIR)/units/$(FULL_TARGET)
 endif
+ifeq ($(FULL_TARGET),x86_64-solaris)
+override COMPILER_UNITTARGETDIR+=$(CPU_UNITDIR)/units/$(FULL_TARGET)
+endif
 ifeq ($(FULL_TARGET),x86_64-darwin)
 override COMPILER_UNITTARGETDIR+=$(CPU_UNITDIR)/units/$(FULL_TARGET)
 endif
@@ -2319,6 +2337,9 @@ endif
 ifeq ($(FULL_TARGET),x86_64-freebsd)
 REQUIRE_PACKAGES_RTL=1
 endif
+ifeq ($(FULL_TARGET),x86_64-solaris)
+REQUIRE_PACKAGES_RTL=1
+endif
 ifeq ($(FULL_TARGET),x86_64-darwin)
 REQUIRE_PACKAGES_RTL=1
 endif
@@ -2379,9 +2400,9 @@ else
 UNITDIR_RTL=$(PACKAGEDIR_RTL)
 endif
 ifdef CHECKDEPEND
-$(PACKAGEDIR_RTL)/$(FPCMADE):
-	$(MAKE) -C $(PACKAGEDIR_RTL) $(FPCMADE)
-override ALLDEPENDENCIES+=$(PACKAGEDIR_RTL)/$(FPCMADE)
+$(PACKAGEDIR_RTL)/$(OS_TARGET)/$(FPCMADE):
+	$(MAKE) -C $(PACKAGEDIR_RTL)/$(OS_TARGET) $(FPCMADE)
+override ALLDEPENDENCIES+=$(PACKAGEDIR_RTL)/$(OS_TARGET)/$(FPCMADE)
 endif
 else
 PACKAGEDIR_RTL=
@@ -3096,6 +3117,9 @@ endif
 ifeq ($(FULL_TARGET),x86_64-freebsd)
 TARGET_DIRS_UTILS=1
 endif
+ifeq ($(FULL_TARGET),x86_64-solaris)
+TARGET_DIRS_UTILS=1
+endif
 ifeq ($(FULL_TARGET),x86_64-darwin)
 TARGET_DIRS_UTILS=1
 endif

+ 2 - 0
compiler/ogelf.pas

@@ -857,6 +857,8 @@ implementation
                   end;
                 AB_EXTERNAL :
                   elfsym.st_info:=STB_GLOBAL shl 4;
+                AB_WEAK_EXTERNAL :
+                  elfsym.st_info:=STB_WEAK shl 4;
                 AB_GLOBAL :
                   begin
                     elfsym.st_value:=objsym.address;

+ 5 - 1
compiler/systems.pas

@@ -404,6 +404,10 @@ interface
                          system_powerpc64_darwin,system_x86_64_darwin,
                          system_arm_darwin];
 
+       {all solaris systems }
+       systems_solaris = [system_sparc_solaris, system_i386_solaris,
+			  system_x86_64_solaris];
+
        { all embedded systems }
        systems_embedded = [system_i386_embedded,system_m68k_embedded,
                            system_alpha_embedded,system_powerpc_embedded,
@@ -422,7 +426,7 @@ interface
                                          system_ia64_win64]+system_linux;
 
        { all systems for which weak linking has been tested/is supported }
-       system_weak_linking = systems_darwin;
+       system_weak_linking = systems_darwin + systems_solaris;
 
        system_internal_sysinit = [system_i386_linux,system_i386_win32];
 

+ 47 - 47
compiler/utils/fpcfg.inc

@@ -3,51 +3,51 @@ const fpcfg : array[0..3] of string[240]=(
 {$else Delphi}
 const fpcfg : array[0..3,1..240] of char=(
 {$endif Delphi}
-  '#IFDEF NORMAL'#013#010+
-  ' -Ci'#013#010+
-  ' -XS'#013#010+
-  ' -T%fpctargetos%'#013#010+
-  ' -Sg'#013#010+
-  ' -O1'#013#010+
-  ' -Oppentium3'#013#010+
-  ' -Ratt'#013#010+
-  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%'#013#010+
-  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%\*'#013#010+
-  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%\rtl'#013#010+
-  ' -g-'#013#010+
-  ' -p-'#013,#010+
-  ' -b-'#013#010+
-  '#ENDIF'#013#010+
-  #013#010+
-  '#IFDEF DEBUG'#013#010+
-  ' -Ci'#013#010+
-  ' -XS'#013#010+
-  ' -T%fpctargetos%'#013#010+
-  ' -Sg'#013#010+
-  ' -Cr'#013#010+
-  ' -Co'#013#010+
-  ' -Oppentium3'#013#010+
-  ' -Ratt'#013#010+
-  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%'#013#010+
-  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%\*'#013#010+
-  ' -Fu%basepath%\units\%fpctarget%-%fpctarg','etos%\rtl'#013#010+
-  ' -g'#013#010+
-  ' -p-'#013#010+
-  ' -b-'#013#010+
-  '#ENDIF'#013#010+
-  #013#010+
-  '#IFDEF RELEASE'#013#010+
-  ' -XS'#013#010+
-  ' -T%fpctargetos%'#013#010+
-  ' -Sg'#013#010+
-  ' -O2'#013#010+
-  ' -Oppentium3'#013#010+
-  ' -Ratt'#013#010+
-  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%'#013#010+
-  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%\*'#013#010+
-  ' -Fu%basepath%\units\%fpctarge','t%-%fpctargetos%\rtl'#013#010+
-  ' -g-'#013#010+
-  ' -p-'#013#010+
-  ' -b-'#013#010+
-  '#ENDIF'#013#010
+  '#IFDEF NORMAL'#010+
+  ' -Ci'#010+
+  ' -XS'#010+
+  ' -T%fpctargetos%'#010+
+  ' -Sg'#010+
+  ' -O1'#010+
+  ' -Oppentium3'#010+
+  ' -Ratt'#010+
+  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%'#010+
+  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%\*'#010+
+  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%\rtl'#010+
+  ' -g-'#010+
+  ' -p-'#010+
+  ' -b-'#010+
+  '#ENDIF'#010,
+  #010+
+  '#IFDEF DEBUG'#010+
+  ' -Ci'#010+
+  ' -XS'#010+
+  ' -T%fpctargetos%'#010+
+  ' -Sg'#010+
+  ' -Cr'#010+
+  ' -Co'#010+
+  ' -Oppentium3'#010+
+  ' -Ratt'#010+
+  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%'#010+
+  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%\*'#010+
+  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%\rtl'#010+
+  ' -g'#010+
+  ' -p-'#010+
+  ' -b-'#010+
+  '#EN','DIF'#010+
+  #010+
+  '#IFDEF RELEASE'#010+
+  ' -XS'#010+
+  ' -T%fpctargetos%'#010+
+  ' -Sg'#010+
+  ' -O2'#010+
+  ' -Oppentium3'#010+
+  ' -Ratt'#010+
+  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%'#010+
+  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%\*'#010+
+  ' -Fu%basepath%\units\%fpctarget%-%fpctargetos%\rtl'#010+
+  ' -g-'#010+
+  ' -p-'#010+
+  ' -b-'#010+
+  '#ENDIF',#010
 );