Skip to content

Commit 6329a9c

Browse files
introduce "quadmath" set tag and HAVE_QUADMATH variable for others.
will be used for gfortran.
1 parent 5892c36 commit 6329a9c

3 files changed

Lines changed: 20 additions & 4 deletions

File tree

distrib/sets/mkvars.mk

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $NetBSD: mkvars.mk,v 1.47 2025/05/13 21:36:26 nia Exp $
1+
# $NetBSD: mkvars.mk,v 1.48 2026/01/18 08:29:48 mrg Exp $
22

33
#
44
# Extra variables to print.
@@ -14,6 +14,7 @@ MKEXTRAVARS= \
1414
HAVE_GCC \
1515
HAVE_GDB \
1616
HAVE_LIBGCC_EH \
17+
HAVE_QUADMATH \
1718
HAVE_MESA_VER \
1819
HAVE_NVMM \
1920
HAVE_OPENSSL \

distrib/sets/sets.subr

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $NetBSD: sets.subr,v 1.212 2025/07/21 01:46:05 dholland Exp $
1+
# $NetBSD: sets.subr,v 1.213 2026/01/18 08:29:48 mrg Exp $
22
#
33

44
#
@@ -258,7 +258,7 @@ SUBST="${SUBST};s#@MACHINE@#${MACHINE}#g"
258258
# In each file, a record consists of a path and a System Package name,
259259
# separated by whitespace. E.g.,
260260
#
261-
# # $NetBSD: sets.subr,v 1.212 2025/07/21 01:46:05 dholland Exp $
261+
# # $NetBSD: sets.subr,v 1.213 2026/01/18 08:29:48 mrg Exp $
262262
# . base-sys-root [keyword[,...]]
263263
# ./altroot base-sys-root
264264
# ./bin base-sys-root
@@ -295,6 +295,7 @@ SUBST="${SUBST};s#@MACHINE@#${MACHINE}#g"
295295
# mesa_ver=<n> <n> = value of ${HAVE_MESA_VER}
296296
# nvmm ${HAVE_NVMM} != no
297297
# openssl=<n> <n> = value of ${HAVE_OPENSSL}
298+
# quadmath ${HAVE_QUADMATH} != no
298299
# uefi ${HAVE_UEFI} != no
299300
# efi_rt ${HAVE_EFI_RT} != no
300301
# xorg_server_ver=<n> <n> = value of ${HAVE_XORG_SERVER_VER}
@@ -450,6 +451,9 @@ list_set_files()
450451
if ("efi_rt" in wanted) {
451452
wanted["efi_rt=" "'"${HAVE_EFI_RT}"'"] = 1
452453
}
454+
if ("quadmath" in wanted) {
455+
wanted["quadmath=" "'"${HAVE_QUADMATH}"'"] = 1
456+
}
453457
if (("man" in wanted) && ("catpages" in wanted))
454458
wanted[".cat"] = 1
455459
if (("man" in wanted) && ("manpages" in wanted))

share/mk/bsd.own.mk

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $NetBSD: bsd.own.mk,v 1.1462 2026/01/10 22:05:08 jmcneill Exp $
1+
# $NetBSD: bsd.own.mk,v 1.1463 2026/01/18 08:29:48 mrg Exp $
22

33
# This needs to be before bsd.init.mk
44
.if defined(BSD_MK_COMPAT_FILE)
@@ -132,6 +132,17 @@ MKGCCCMDS?= no
132132
NOGCCISL= # defined
133133
.endif
134134

135+
#
136+
# Build GCC with libquadmath.
137+
# Eg: grep '#define HAVE_FLOAT128 1' lib/libgfortran/arch/*/config.h
138+
#
139+
.if ${MACHINE_ARCH} == "i386" || \
140+
${MACHINE_ARCH} == "x86_64" || \
141+
${MACHINE_ARCH} == "ia64"
142+
HAVE_QUADMATH?= yes
143+
.endif
144+
HAVE_QUADMATH?= no
145+
135146
#
136147
# What binutils is used?
137148
#

0 commit comments

Comments
 (0)