libtheora: fetch a patch instead of storing it in Spack (#20620)

This commit is contained in:
Rémi Lacroix 2021-01-06 10:44:05 +01:00 committed by GitHub
parent d30f9e5806
commit 89b94d968d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 20 deletions

View file

@ -1,19 +0,0 @@
diff --git a/examples/png2theora.c b/examples/png2theora.c
index 71a0d0f..ed24c2a 100644
--- a/examples/png2theora.c
+++ b/examples/png2theora.c
@@ -462,9 +462,9 @@ png_read(const char *pathname, unsigned int *w, unsigned int *h, unsigned char *
png_set_strip_alpha(png_ptr);
row_data = (png_bytep)png_malloc(png_ptr,
- 3*height*width*png_sizeof(*row_data));
+ 3*height*width*sizeof(*row_data));
row_pointers = (png_bytep *)png_malloc(png_ptr,
- height*png_sizeof(*row_pointers));
+ height*sizeof(*row_pointers));
for(y = 0; y < height; y++) {
row_pointers[y] = row_data + y*(3*width);
}
--
2.7.4

View file

@ -21,9 +21,11 @@ class Libtheora(AutotoolsPackage):
depends_on('m4', type='build') depends_on('m4', type='build')
depends_on('doxygen', type='build') depends_on('doxygen', type='build')
depends_on('libogg') depends_on('libogg')
depends_on('libpng')
patch('exit-prior-to-running-configure.patch', when='@1.1.1') patch('exit-prior-to-running-configure.patch', when='@1.1.1')
patch('dont_use_png_sizeof.patch', when='@1.1.1') patch('https://gitlab.xiph.org/xiph/theora/-/commit/7288b539c52e99168488dc3a343845c9365617c8.patch',
sha256='2e4f891f6880386d9391f3e4eaf4a23493de4eea532f9b5cb8a04b5f7cd09301', when='^libpng@1.6:')
def autoreconf(self, spec, prefix): def autoreconf(self, spec, prefix):
sh = which('sh') sh = which('sh')