diff options
-rw-r--r-- | system/mediaextract/compilefix.diff | 33 | ||||
-rw-r--r-- | system/mediaextract/mediaextract.SlackBuild | 9 |
2 files changed, 42 insertions, 0 deletions
diff --git a/system/mediaextract/compilefix.diff b/system/mediaextract/compilefix.diff new file mode 100644 index 0000000000..f2f4101793 --- /dev/null +++ b/system/mediaextract/compilefix.diff @@ -0,0 +1,33 @@ +diff -Naur mediaextract-v1.1.1/source/src/riff.c mediaextract-v1.1.1.patched/source/src/riff.c +--- mediaextract-v1.1.1/source/src/riff.c 2021-06-25 10:54:31.000000000 -0400 ++++ mediaextract-v1.1.1.patched/source/src/riff.c 2022-03-19 13:19:13.506696806 -0400 +@@ -217,28 +217,7 @@ + CHUNK('V','P','8','X', 0) + ); + +-#define MAX_CHUNK_SPEC_COUNT \ +- MAX(CHUNK_SPEC_COUNT(riff_empty_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_wav_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_avi_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_ani_fram_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_ani_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_pal_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_aud_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_dmbd_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_dmpr_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_dmcn_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_dsbc_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_dsfx_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_dmsc_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_sgt_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_sty_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_dmtl_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_dmtg_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_dmtk_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_dmbt_body), \ +- MAX(CHUNK_SPEC_COUNT(riff_dmpt_body), \ +- CHUNK_SPEC_COUNT(riff_webp_body))))))))))))))))))))) ++#define MAX_CHUNK_SPEC_COUNT 9 + + static const struct riff_file_spec riff_file_specs[] = { + { RIFF('W','A','V','E', riff_wav_body ), "wav" }, diff --git a/system/mediaextract/mediaextract.SlackBuild b/system/mediaextract/mediaextract.SlackBuild index bb8e9aada8..d61caa732f 100644 --- a/system/mediaextract/mediaextract.SlackBuild +++ b/system/mediaextract/mediaextract.SlackBuild @@ -57,6 +57,15 @@ chown -R root:root . find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \ \! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} \+ +# 20220319 bkw: gcc and clang were both hitting the 4GB per-process +# memory limit, due to ridiculous preprocessor abuse in riff.c. The +# thing was doing a bunch of nested macro expansions, to determine +# the maximum size for an array... turns out the size it calculated +# was 9. The patch just hardcodes it to 9 and gets rid of the nested +# macro calls. This should be revisited when/if there's a new +# version of mediaextract. +patch -p1 < $CWD/compilefix.diff + cd source mkdir -p build-linux32 build-linux64 |