diff options
author | M.Dinslage <daedra1980@gmail.com> | 2021-01-30 12:51:42 +0100 |
---|---|---|
committer | Robby Workman <rworkman@slackbuilds.org> | 2021-04-17 23:52:21 -0500 |
commit | c3483321438120b140eda63da373f43b7fdbaa49 (patch) | |
tree | 01a91d98c232e3f711bf1345aeed7a8438c5d6b4 /system | |
parent | 614b01391423f0438ab3e6fb6b889a0542df592d (diff) |
system/p7zip: Patch for gcc >= 10.x.
Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
Diffstat (limited to 'system')
-rw-r--r-- | system/p7zip/gcc10.patch | 22 | ||||
-rw-r--r-- | system/p7zip/p7zip.SlackBuild | 8 |
2 files changed, 27 insertions, 3 deletions
diff --git a/system/p7zip/gcc10.patch b/system/p7zip/gcc10.patch new file mode 100644 index 0000000000000..d9571cc230753 --- /dev/null +++ b/system/p7zip/gcc10.patch @@ -0,0 +1,22 @@ +https://sourceforge.net/p/p7zip/bugs/226/ + +--- a/CPP/Windows/ErrorMsg.cpp 2020-05-28 00:35:02.729896917 +0200 ++++ b/CPP/Windows/ErrorMsg.cpp 2020-05-28 00:40:01.676442629 +0200 +@@ -13,7 +13,7 @@ + const char * txt = 0; + AString msg; + +- switch(errorCode) { ++ switch(HRESULT(errorCode)) { + case ERROR_NO_MORE_FILES : txt = "No more files"; break ; + case E_NOTIMPL : txt = "E_NOTIMPL"; break ; + case E_NOINTERFACE : txt = "E_NOINTERFACE"; break ; +@@ -43,7 +43,7 @@ + const char * txt = 0; + AString msg; + +- switch(messageID) { ++ switch(HRESULT(messageID)) { + case ERROR_NO_MORE_FILES : txt = "No more files"; break ; + case E_NOTIMPL : txt = "E_NOTIMPL"; break ; + case E_NOINTERFACE : txt = "E_NOINTERFACE"; break ; diff --git a/system/p7zip/p7zip.SlackBuild b/system/p7zip/p7zip.SlackBuild index ec9cbda5ed288..10a5ff1a7a0f5 100644 --- a/system/p7zip/p7zip.SlackBuild +++ b/system/p7zip/p7zip.SlackBuild @@ -29,7 +29,7 @@ TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then case "$( uname -m )" in - i?86) ARCH=i486 ;; + i?86) ARCH=i586 ;; arm*) ARCH=arm ;; *) ARCH=$( uname -m ) ;; esac @@ -40,8 +40,8 @@ TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM OUTPUT=${OUTPUT:-/tmp} -if [ "$ARCH" = "i486" ]; then - SLKCFLAGS="-O2 -march=i486 -mtune=i686" +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -mtune=i686" LIBDIRSUFFIX="" elif [ "$ARCH" = "i686" ]; then SLKCFLAGS="-O2 -march=i686 -mtune=i686" @@ -72,6 +72,8 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; +patch -p1 < $CWD/gcc10.patch + make all3 \ OPTFLAGS="$SLKCFLAGS" \ DEST_HOME=/usr \ |