1 SubDir HAIKU_TOP src system libroot ;
3 UsePrivateHeaders libroot runtime_loader ;
5 local architectureObject ;
6 for architectureObject in [ MultiArchSubDirSetup ] {
7 on $(architectureObject) {
8 local architecture = $(TARGET_PACKAGING_ARCH) ;
10 UsePrivateSystemHeaders ;
12 local libgccAsSingleObject ;
13 if $(architecture) = x86_gcc2 {
15 = <$(architecture)>libroot_libgcc_$(TARGET_ARCH).o ;
16 # One object to link them all...
17 TARGET_LDFLAGS_$(TARGET_PACKAGING_ARCH) on
18 <$(architecture)>libroot_libgcc_$(TARGET_ARCH).o =
19 [ on <$(architecture)>libroot_libgcc_$(TARGET_ARCH).o
20 return $(TARGET_LDFLAGS_$(TARGET_PACKAGING_ARCH)) ]
22 MergeObject $(libgccAsSingleObject) : : [ TargetLibgcc ] ;
25 local librootObjects =
26 $(libgccAsSingleObject)
29 os_arch_$(TARGET_ARCH).o
31 posix_arch_$(TARGET_ARCH).o
38 posix_gnu_arch_$(TARGET_ARCH).o
53 posix_string_arch_$(TARGET_ARCH).o
59 librootObjects = $(librootObjects:G=$(architecture)) ;
61 local librootDebugObjects =
64 librootDebugObjects = $(librootDebugObjects:G=$(architecture)) ;
66 local librootNoDebugObjects =
69 librootNoDebugObjects = $(librootNoDebugObjects:G=$(architecture)) ;
71 local libroot = [ MultiArchDefaultGristFiles libroot.so ] ;
72 local librootDebug = $(libroot:B=libroot_debug) ;
74 DONT_LINK_AGAINST_LIBROOT on $(libroot) = true ;
75 DONT_LINK_AGAINST_LIBROOT on $(librootDebug) = true ;
77 SetVersionScript $(libroot) : libroot_versions ;
78 SetVersionScript $(librootDebug) : libroot_versions ;
80 SharedLibrary $(libroot)
85 $(librootNoDebugObjects)
86 [ TargetStaticLibsupc++ ]
90 # Use the standard libroot.so soname, so when the debug version is
91 # pre-loaded it prevents the standard version to be loaded as well.
92 HAIKU_SONAME on $(librootDebug) = libroot.so ;
94 SharedLibrary $(librootDebug)
99 $(librootDebugObjects)
100 [ TargetStaticLibsupc++ ]
104 StaticLibrary [ MultiArchDefaultGristFiles libm.a ] : empty.c ;
105 StaticLibrary [ MultiArchDefaultGristFiles libpthread.a ] : empty.c ;
107 # Copy libroot.so and update the copy's revision section. We link
108 # everything against the original, but the copy will end up on the disk
109 # image (this way we avoid unnecessary dependencies). The copy will be
110 # located in a subdirectory.
111 if $(TARGET_PLATFORM) = haiku {
112 local targetDir = [ FDirName $(TARGET_DEBUG_$(DEBUG)_LOCATE_TARGET)
114 local revisionedLibroot = [ MultiArchDefaultGristFiles
115 libroot.so : revisioned ] ;
116 local revisionedLibrootDebug
117 = $(librootDebug:G=$(revisionedLibroot:G)) ;
119 MakeLocate $(revisionedLibroot) : $(targetDir) ;
120 CopySetHaikuRevision $(revisionedLibroot) : $(libroot) ;
122 MakeLocate $(revisionedLibrootDebug) : $(targetDir) ;
123 CopySetHaikuRevision $(revisionedLibrootDebug) : $(librootDebug) ;
128 SubInclude HAIKU_TOP src system libroot add-ons ;
129 SubInclude HAIKU_TOP src system libroot os ;
130 SubInclude HAIKU_TOP src system libroot posix ;
131 SubInclude HAIKU_TOP src system libroot stubbed ;