pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/mk/compiler



Module Name:    pkgsrc
Committed By:   nia
Date:           Sat May 21 09:04:50 UTC 2022

Modified Files:
        pkgsrc/mk/compiler: gcc.mk

Log Message:
gcc.mk: Force USE_GCC_RUNTIME (etc.) on older NetBSD versions that
request a newer compiler. Stop selecting gcc6, it receives very
limited testing due to NetBSD 9 having gcc7, and probably doesn't
work due to some newer hardening checks stopping it from building.


To generate a diff of this commit:
cvs rdiff -u -r1.239 -r1.240 pkgsrc/mk/compiler/gcc.mk

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/mk/compiler/gcc.mk
diff -u pkgsrc/mk/compiler/gcc.mk:1.239 pkgsrc/mk/compiler/gcc.mk:1.240
--- pkgsrc/mk/compiler/gcc.mk:1.239     Thu Apr  7 12:12:02 2022
+++ pkgsrc/mk/compiler/gcc.mk   Sat May 21 09:04:50 2022
@@ -1,4 +1,4 @@
-# $NetBSD: gcc.mk,v 1.239 2022/04/07 12:12:02 adam Exp $
+# $NetBSD: gcc.mk,v 1.240 2022/05/21 09:04:50 nia Exp $
 #
 # This is the compiler definition for the GNU Compiler Collection.
 #
@@ -94,7 +94,7 @@ _DEF_VARS.gcc=        \
        _IS_BUILTIN_GCC \
        _LANGUAGES.gcc \
        _LINKER_RPATH_FLAG \
-       _NEED_GCC6 _NEED_GCC7 _NEED_GCC8 _NEED_GCC9 \
+       _NEED_GCC7 _NEED_GCC8 _NEED_GCC9 \
        _NEED_GCC10 \
        _NEED_GCC_AUX _NEED_NEWER_GCC \
        _PKGSRC_GCC_VERSION \
@@ -125,7 +125,7 @@ _USE_VARS.gcc=      \
        _PKGSRC_USE_FORTIFY _PKGSRC_USE_RELRO _PKGSRC_USE_STACK_CHECK \
        _OPSYS_INCLUDE_DIRS _OPSYS_LIB_DIRS
 _IGN_VARS.gcc= \
-       _GCC6_PATTERNS _GCC7_PATTERNS _GCC8_PATTERNS _GCC9_PATTERNS \
+       _GCC7_PATTERNS _GCC8_PATTERNS _GCC9_PATTERNS \
        _GCC10_PATTERNS _GCC_AUX_PATTERNS
 _LISTED_VARS.gcc= \
        MAKEFLAGS IMAKEOPTS LDFLAGS PREPEND_PATH
@@ -154,11 +154,8 @@ _GCC_DIST_NAME:=   gcc10
 .include "../../lang/${_GCC_DIST_NAME}/version.mk"
 _GCC_DIST_VERSION:=    ${${_GCC_DIST_NAME:tu}_DIST_VERSION}
 
-# _GCC6_PATTERNS matches N s.t. N < 7.
-_GCC6_PATTERNS= 5 6 [0-6].*
-
 # _GCC7_PATTERNS matches N s.t. 7.0 <= N < 8.
-_GCC7_PATTERNS= 7 7.*
+_GCC7_PATTERNS= 5 6 [0-6].* 7 7.*
 
 # _GCC8_PATTERNS matches N s.t. 8.0 <= N < 9.
 _GCC8_PATTERNS= 8 8.*
@@ -272,33 +269,43 @@ _GCC_STRICTEST_REQD=      ${_version_}
 _GCC_REQD=     ${_GCC_STRICTEST_REQD}
 
 # Determine which GCC version is required by examining _GCC_REQD.
-_NEED_GCC6?=   no
-.for _pattern_ in ${_GCC6_PATTERNS}
-.  if !empty(_GCC_REQD:M${_pattern_})
-_NEED_GCC6=    yes
-.  endif
-.endfor
 _NEED_GCC7?=   no
 .for _pattern_ in ${_GCC7_PATTERNS}
 .  if !empty(_GCC_REQD:M${_pattern_})
+.    if ${OPSYS} == "NetBSD"" && ${OPSYS_VERSION} < 089937
+USE_PKGSRC_GCC=                yes
+USE_PKGSRC_GCC_RUNTIME=        yes
+.    endif
 _NEED_GCC7=    yes
 .  endif
 .endfor
 _NEED_GCC8?=   no
 .for _pattern_ in ${_GCC8_PATTERNS}
 .  if !empty(_GCC_REQD:M${_pattern_})
+.    if ${OPSYS} == "NetBSD"" && ${OPSYS_VERSION} < 099917
+USE_PKGSRC_GCC=                yes
+USE_PKGSRC_GCC_RUNTIME=        yes
+.    endif
 _NEED_GCC8=    yes
 .  endif
 .endfor
 _NEED_GCC9?=   no
 .for _pattern_ in ${_GCC9_PATTERNS}
 .  if !empty(_GCC_REQD:M${_pattern_})
+.    if ${OPSYS} == "NetBSD"" && ${OPSYS_VERSION} < 099976
+USE_PKGSRC_GCC=                yes
+USE_PKGSRC_GCC_RUNTIME=        yes
+.    endif
 _NEED_GCC9=    yes
 .  endif
 .endfor
 _NEED_GCC10?=  no
 .for _pattern_ in ${_GCC10_PATTERNS}
 .  if !empty(_GCC_REQD:M${_pattern_})
+.    if ${OPSYS} == "NetBSD"" && ${OPSYS_VERSION} < 099982
+USE_PKGSRC_GCC=                yes
+USE_PKGSRC_GCC_RUNTIME=        yes
+.    endif
 _NEED_GCC10=   yes
 .  endif
 .endfor
@@ -309,7 +316,7 @@ _NEED_GCC_AUX=      yes
 _NEED_NEWER_GCC=NO
 .  endif
 .endfor
-.if !empty(_NEED_GCC6:M[nN][oO]) && !empty(_NEED_GCC7:M[nN][oO]) && \
+.if !empty(_NEED_GCC7:M[nN][oO]) && \
     !empty(_NEED_GCC8:M[nN][oO]) && !empty(_NEED_GCC9:M[nN][oO]) && \
     !empty(_NEED_GCC10:M[nN][oO]) && \
     !empty(_NEED_GCC_AUX:M[nN][oO])
@@ -320,7 +327,6 @@ _NEED_GCC8= yes
 .if !empty(MACHINE_PLATFORM:MNetBSD-*-earm*) && \
     ${OPSYS_VERSION} < 099900 && \
     (${_NEED_GCC8:tl} == "yes" || ${_NEED_GCC9:tl} == "yes")
-_NEED_GCC6=    no
 _NEED_GCC7=    no
 _NEED_GCC8=    no
 _NEED_GCC9=    no
@@ -329,9 +335,7 @@ _NEED_GCC10=        yes
 
 # Assume by default that GCC will only provide a C compiler.
 LANGUAGES.gcc?=        c
-.if !empty(_NEED_GCC6:M[yY][eE][sS])
-LANGUAGES.gcc= c c++ fortran fortran77 go java objc obj-c++
-.elif !empty(_NEED_GCC7:M[yY][eE][sS])
+.if !empty(_NEED_GCC7:M[yY][eE][sS])
 LANGUAGES.gcc= c c++ fortran fortran77 go java objc obj-c++
 .elif !empty(_NEED_GCC8:M[yY][eE][sS])
 LANGUAGES.gcc= c c++ fortran fortran77 go java objc obj-c++
@@ -426,28 +430,7 @@ CFLAGS+=   -Wno-import
 CFLAGS+=       ${_GCC_CFLAGS}
 FCFLAGS+=      ${_GCC_FCFLAGS}
 
-.if !empty(_NEED_GCC6:M[yY][eE][sS])
-#
-# We require gcc-6.x in the lang/gcc6-* directory.
-#
-_GCC_PKGBASE=          gcc6
-.  if ${PKGPATH} == lang/gcc6
-_IGNORE_GCC=           yes
-MAKEFLAGS+=            _IGNORE_GCC=yes
-.  endif
-.  if !defined(_IGNORE_GCC) && !empty(_LANGUAGES.gcc)
-_GCC_PKGSRCDIR=                ../../lang/gcc6
-_GCC_DEPENDENCY=       gcc6>=${_GCC_REQD}:../../lang/gcc6
-.    if !empty(_LANGUAGES.gcc:Mc++) || \
-        !empty(_LANGUAGES.gcc:Mfortran) || \
-        !empty(_LANGUAGES.gcc:Mfortran77) || \
-        !empty(_LANGUAGES.gcc:Mgo) || \
-        !empty(_LANGUAGES.gcc:Mobjc) || \
-        !empty(_LANGUAGES.gcc:Mobj-c++)
-_USE_GCC_SHLIB?=       yes
-.    endif
-.  endif
-.elif !empty(_NEED_GCC7:M[yY][eE][sS])
+.if !empty(_NEED_GCC7:M[yY][eE][sS])
 #
 # We require gcc-7.x in the lang/gcc7-* directory.
 #
@@ -846,9 +829,7 @@ PREPEND_PATH+=      ${_GCC_DIR}/bin
 .  if ${PKGPATH} != devel/libtool-base && ${PKGPATH} != devel/binutils && \
       empty(PKGPATH:Mlang/gcc4?) && empty(PKGPATH:Mlang/gcc[5-9]) && \
       empty(PKGPATH:Mlang/gcc10)
-.    if !empty(_GCC_PKGBASE:Mgcc6)
-.      include "../../lang/gcc6-libs/buildlink3.mk"
-.    elif !empty(_GCC_PKGBASE:Mgcc7)
+.    if !empty(_GCC_PKGBASE:Mgcc7)
 .      include "../../lang/gcc7-libs/buildlink3.mk"
 .    elif !empty(_GCC_PKGBASE:Mgcc8)
 .      include "../../lang/gcc8-libs/buildlink3.mk"



Home | Main Index | Thread Index | Old Index