Tue Oct 31 13:47:57 2023 UTC ()
mk/compiler/fortran.mk: Adjust comments slightly


(gdt)
diff -r1.24 -r1.25 pkgsrc/mk/compiler/gfortran.mk

cvs diff -r1.24 -r1.25 pkgsrc/mk/compiler/gfortran.mk (expand / switch to unified diff)

--- pkgsrc/mk/compiler/gfortran.mk 2023/10/31 13:45:30 1.24
+++ pkgsrc/mk/compiler/gfortran.mk 2023/10/31 13:47:56 1.25
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1# $NetBSD: gfortran.mk,v 1.24 2023/10/31 13:45:30 gdt Exp $ 1# $NetBSD: gfortran.mk,v 1.25 2023/10/31 13:47:56 gdt Exp $
2# 2#
3# Copyright (c) 2005 The NetBSD Foundation, Inc. 3# Copyright (c) 2005 The NetBSD Foundation, Inc.
4# All rights reserved. 4# All rights reserved.
5# 5#
6# This code is derived from software contributed to The NetBSD Foundation 6# This code is derived from software contributed to The NetBSD Foundation
7# by Johnny C. Lam. 7# by Johnny C. Lam.
8# 8#
9# Redistribution and use in source and binary forms, with or without 9# Redistribution and use in source and binary forms, with or without
10# modification, are permitted provided that the following conditions 10# modification, are permitted provided that the following conditions
11# are met: 11# are met:
12# 1. Redistributions of source code must retain the above copyright 12# 1. Redistributions of source code must retain the above copyright
13# notice, this list of conditions and the following disclaimer. 13# notice, this list of conditions and the following disclaimer.
14# 2. Redistributions in binary form must reproduce the above copyright 14# 2. Redistributions in binary form must reproduce the above copyright
@@ -24,29 +24,28 @@ @@ -24,29 +24,28 @@
24# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 24# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
25# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 25# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
26# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 26# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
27# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 27# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
28# POSSIBILITY OF SUCH DAMAGE. 28# POSSIBILITY OF SUCH DAMAGE.
29# 29#
30 30
31.if !defined(COMPILER_GFORTRAN_MK) 31.if !defined(COMPILER_GFORTRAN_MK)
32COMPILER_GFORTRAN_MK= defined 32COMPILER_GFORTRAN_MK= defined
33 33
34.include "../../mk/bsd.prefs.mk" 34.include "../../mk/bsd.prefs.mk"
35 35
36# If the pkgsrc base compiler is GCC, define POSSIBLE_GORTRAN_VERSION 36# If the pkgsrc base compiler is GCC, define POSSIBLE_GORTRAN_VERSION
37# (meaning a candidate we would like) to match, and try to use that if 37# (meaning a candidate we would like) to match. If that version is
38# possible, unless known to be problematic. Otherwise, pick a 38# known to be problematic on a platform, pick a better one.
39# mainstream version and hope for the best. 
40# \todo If the base compiler is clang, we probably should use flang 39# \todo If the base compiler is clang, we probably should use flang
41# rather than gfortran, but this is gfortran.mk. 40# rather than gfortran, but this is gfortran.mk.
42POSSIBLE_GFORTRAN_VERSION?= ${CC_VERSION:S/gcc-//:C/.[0-9].[0-9]$//} 41POSSIBLE_GFORTRAN_VERSION?= ${CC_VERSION:S/gcc-//:C/.[0-9].[0-9]$//}
43 42
44.if ${MACHINE_PLATFORM:MDarwin-*-*} 43.if ${MACHINE_PLATFORM:MDarwin-*-*}
45# \todo For parallel structure this should set POSSIBLE_GFORTRAN_VERSION instead. 44# \todo For parallel structure this should set POSSIBLE_GFORTRAN_VERSION instead.
46GFORTRAN_VERSION?= 12 45GFORTRAN_VERSION?= 12
47.endif 46.endif
48 47
49# pkgsrc gcc9 is missing NetBSD patches for aarch64, so if 9 is 48# pkgsrc gcc9 is missing NetBSD patches for aarch64, so if 9 is
50# selected (historical current only?), advance to 10. 49# selected (historical current only?), advance to 10.
51.if !empty(POSSIBLE_GFORTRAN_VERSION:M9) && \ 50.if !empty(POSSIBLE_GFORTRAN_VERSION:M9) && \
52 !empty(MACHINE_PLATFORM:MNetBSD-*-aarch64*) 51 !empty(MACHINE_PLATFORM:MNetBSD-*-aarch64*)