xref: /haiku/src/system/libroot/posix/glibc/math/Jamfile (revision 00b283c04290a93c63b81aa91e2089bfd42a609f)
1a8344698SJérôme DuvalSubDir HAIKU_TOP src system libroot posix glibc math ;
2a8344698SJérôme Duval
3a8344698SJérôme DuvalSubDirCcFlags -D_GNU_SOURCE -DUSE_IN_LIBIO ;
4a8344698SJérôme Duval
5a8344698SJérôme Duvallocal architectureObject ;
6a8344698SJérôme Duvalfor architectureObject in [ MultiArchSubDirSetup ] {
7a8344698SJérôme Duval	on $(architectureObject) {
8a8344698SJérôme Duval		local architecture = $(TARGET_PACKAGING_ARCH) ;
9a8344698SJérôme Duval
10a8344698SJérôme Duval		SubDirSysHdrs $(HAIKU_TOP) src system libroot posix glibc include arch
11a8344698SJérôme Duval			$(TARGET_ARCH) ;
12a8344698SJérôme Duval		SubDirSysHdrs $(HAIKU_TOP) src system libroot posix glibc include arch
13a8344698SJérôme Duval			generic ;
14a8344698SJérôme Duval		SubDirSysHdrs $(HAIKU_TOP) src system libroot posix glibc include ;
15a8344698SJérôme Duval		SubDirSysHdrs $(HAIKU_TOP) src system libroot posix glibc math ;
16a8344698SJérôme Duval		SubDirSysHdrs $(HAIKU_TOP) src system libroot posix glibc ;
17a8344698SJérôme Duval
18a8344698SJérôme Duval		UsePrivateHeaders libroot ;
19a8344698SJérôme Duval
20*00b283c0SPulkoMandy		# ppc, m68k and arm use regular doubles as long doubles (through
21*00b283c0SPulkoMandy		# aliases), so they must be built without these files.
22*00b283c0SPulkoMandy		# FIXME: ppc should use ldbl-128ibm, and m68k should probably use
23*00b283c0SPulkoMandy		# ldbl-96 as for x86.
24bbdf4c27SFrançois Revol		local longDoubleObjects ;
25bbdf4c27SFrançois Revol		switch $(architecture) {
26bbdf4c27SFrançois Revol			case ppc : longDoubleObjects = ;
27bbdf4c27SFrançois Revol			case m68k : longDoubleObjects = ;
28*00b283c0SPulkoMandy			case arm : longDoubleObjects = ;
29bbdf4c27SFrançois Revol			case * : longDoubleObjects = cabsl.c cargl.c cimagl.c conjl.c creall.c k_casinhl.c ;
30bbdf4c27SFrançois Revol		}
31a8344698SJérôme Duval
32bbdf4c27SFrançois Revol		MergeObject <$(architecture)>posix_gnu_math.o :
33bbdf4c27SFrançois Revol			cabs.c cabsf.c
34bbdf4c27SFrançois Revol			carg.c cargf.c
35bbdf4c27SFrançois Revol			cimag.c cimagf.c
36bbdf4c27SFrançois Revol			conj.c conjf.c
37bbdf4c27SFrançois Revol			creal.c crealf.c
38bbdf4c27SFrançois Revol
39bbdf4c27SFrançois Revol			k_casinh.c k_casinhf.c
40bbdf4c27SFrançois Revol
41bbdf4c27SFrançois Revol			$(longDoubleObjects)
42a8344698SJérôme Duval			;
43a8344698SJérôme Duval	}
44a8344698SJérôme Duval}
45