index : packages | |
Archlinux32 package modifications | gitolite user |
summaryrefslogtreecommitdiff |
-rw-r--r-- | core/linux-lts/PKGBUILD | 18 | ||||
-rw-r--r-- | core/linux/PKGBUILD | 18 |
diff --git a/core/linux-lts/PKGBUILD b/core/linux-lts/PKGBUILD index 208b66b7..b3fff1ab 100644 --- a/core/linux-lts/PKGBUILD +++ b/core/linux-lts/PKGBUILD @@ -17,11 +17,19 @@ eval "$( )" _get_gcc_version_from_config() { - sed ' - s/^CONFIG_CC_VERSION_TEXT="gcc (GCC) \([0-9.]\+\)"$/\1/ - t - d - ' "$srcdir/$_srcname/.config" + if [ -z "$srcdir" ]; then + gcc --version \ + | sed ' + s@^.* @@ + 1!d + ' + else + sed ' + s/^CONFIG_CC_VERSION_TEXT="gcc (GCC) \([0-9.]\+\)"$/\1/ + t + d + ' "$srcdir/$_srcname/.config" + fi } # avoid using zstd compression in ultra mode (exhausts virtual memory) diff --git a/core/linux/PKGBUILD b/core/linux/PKGBUILD index 6eea3bd4..cbe8ed7c 100644 --- a/core/linux/PKGBUILD +++ b/core/linux/PKGBUILD @@ -34,11 +34,19 @@ eval "$( )" _get_gcc_version_from_config() { - sed ' - s/^CONFIG_CC_VERSION_TEXT="gcc (GCC) \([0-9.]\+\)"$/\1/ - t - d - ' "$srcdir/$_srcname/.config" + if [ -z "$srcdir" ]; then + gcc --version \ + | sed ' + s@^.* @@ + 1!d + ' + else + sed ' + s/^CONFIG_CC_VERSION_TEXT="gcc (GCC) \([0-9.]\+\)"$/\1/ + t + d + ' "$srcdir/$_srcname/.config" + fi } # use our tarballer instead of cloning from git |