libcaca: bump version

This commit is contained in:
Jérôme Duval
2026-02-02 19:09:13 +01:00
parent 052c1b2313
commit e73c47dd60
2 changed files with 59 additions and 26 deletions

View File

@@ -10,19 +10,19 @@ COPYRIGHT="1998, 1999, 2001 Jan Hubicka
2007-2008 Pascal Terjan"
LICENSE="WTFPL
GNU GPL v2"
REVISION="7"
SOURCE_URI="http://caca.zoy.org/raw-attachment/wiki/libcaca/libcaca-$portVersion.tar.gz"
CHECKSUM_SHA256="128b467c4ed03264c187405172a4e83049342cc8cc2f655f53a2d0ee9d3772f4"
REVISION="1"
SOURCE_URI="https://github.com/cacalabs/libcaca/archive/v$portVersion.tar.gz"
CHECKSUM_SHA256="3edb8763a8f888ed4d4b85b3a056e81c840d5d27f79bdebc0b991688b23084f2"
SOURCE_DIR="libcaca-$portVersion"
PATCHES="libcaca-${portVersion}.patchset"
ARCHITECTURES="all"
SECONDARY_ARCHITECTURES="x86_gcc2 x86"
SECONDARY_ARCHITECTURES="x86"
PROVIDES="
libcaca$secondaryArchSuffix = $portVersion compat >= 0
lib:libcaca$secondaryArchSuffix = 0.99.19 compat >= 0
lib:libcaca++$secondaryArchSuffix = 0.99.19 compat >= 0
lib:libcaca$secondaryArchSuffix = 0.99.20 compat >= 0
lib:libcaca++$secondaryArchSuffix = 0.99.20 compat >= 0
"
if [ -z "$secondaryArchSuffix" ]; then
PROVIDES="$PROVIDES
@@ -43,8 +43,8 @@ REQUIRES="
PROVIDES_devel="
libcaca${secondaryArchSuffix}_devel = $portVersion compat >= 0
devel:libcaca$secondaryArchSuffix = $portVersion compat >= 0
devel:libcaca++$secondaryArchSuffix = $portVersion compat >= 0
devel:libcaca$secondaryArchSuffix = 0.99.20 compat >= 0
devel:libcaca++$secondaryArchSuffix = 0.99.20 compat >= 0
cmd:caca_config$secondaryArchSuffix = $portVersion compat >= 0
"
REQUIRES_devel="

View File

@@ -1,15 +1,15 @@
From fb47040266da2f0e74cc36cdf407afe2d8fa6ee8 Mon Sep 17 00:00:00 2001
From d36239a61aebcf3fbc3e1f290dfa4db75fd98038 Mon Sep 17 00:00:00 2001
From: Timothy Gu <timothygu99@gmail.com>
Date: Thu, 18 Dec 2014 23:45:35 +0000
Subject: [PATCH 1/3] Fix network detection
Subject: Fix network detection
Signed-off-by: Timothy Gu <timothygu99@gmail.com>
diff --git a/configure.ac b/configure.ac
index 641dd17..e06cb74 100644
index dfc9d8a..355dfda 100644
--- a/configure.ac
+++ b/configure.ac
@@ -491,8 +491,12 @@ fi
@@ -522,8 +522,12 @@ fi
# Build cacaserver?
ac_cv_my_have_network="no"
@@ -25,21 +25,21 @@ index 641dd17..e06cb74 100644
# Use Imlib2?
--
1.8.3.4
2.51.0
From b4a3afb4b37257e6f18aa31511df9615ea39418e Mon Sep 17 00:00:00 2001
From 5badbaec7cc2285bb0c15896b1d51a5391306266 Mon Sep 17 00:00:00 2001
From: Timothy Gu <timothygu99@gmail.com>
Date: Fri, 19 Dec 2014 02:19:19 +0000
Subject: [PATCH 2/3] doc: use standard PDF and HTML installation directories
Subject: doc: use standard PDF and HTML installation directories
Signed-off-by: Timothy Gu <timothygu99@gmail.com>
diff --git a/doc/Makefile.am b/doc/Makefile.am
index 5598ce3..77720e7 100644
index be8aa42..c0f2b05 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -7,11 +7,9 @@ doxygen_DOX = libcaca.dox user.dox migrating.dox tutorial.dox canvas.dox font.do
@@ -9,11 +9,9 @@ doxygen_DOX = libcaca.dox user.dox migrating.dox tutorial.dox canvas.dox font.do
man_MANS = caca-config.1 cacafire.1 cacaview.1 cacaserver.1 img2txt.1 cacaplay.1
if BUILD_DOCUMENTATION
@@ -53,7 +53,7 @@ index 5598ce3..77720e7 100644
endif
endif
@@ -42,10 +40,10 @@ clean-local:
@@ -41,10 +39,10 @@ clean-local:
install-data-local:
if BUILD_DOCUMENTATION
@@ -68,18 +68,18 @@ index 5598ce3..77720e7 100644
for man in $$(find man -name '*.3caca'); do \
sed -e 's/man3caca/man3/g' -e "s/fC'\([a-zA-Z0-9]*\)'/fC\"\1\"/g" \
--
1.8.3.4
2.51.0
From 28016da0b3e6c2d001455bb49b0b24fde3e9edc5 Mon Sep 17 00:00:00 2001
From 4512e6ac005d158a9bad7e8358e3e4ef0ee7411b Mon Sep 17 00:00:00 2001
From: Scott McCreary <scottmc2@gmail.com>
Date: Thu, 18 Dec 2014 22:46:50 -0800
Subject: [PATCH 3/3] Fix gcc2 issues in 3 files
Subject: Fix gcc2 issues in 3 files
Signed-off-by: Timothy Gu <timothygu99@gmail.com>
diff --git a/caca/file.c b/caca/file.c
index 27e4e83..51e127b 100644
index f9d83c6..3171111 100644
--- a/caca/file.c
+++ b/caca/file.c
@@ -63,6 +63,10 @@ struct caca_file
@@ -103,10 +103,10 @@ index 27e4e83..51e127b 100644
fp->gz = gzopen(path, fp->readonly ? "rb" : "wb");
if(!fp->gz)
diff --git a/examples/trifiller.c b/examples/trifiller.c
index 5a06f23..fab3cd7 100644
index 0a32f80..785c00d 100644
--- a/examples/trifiller.c
+++ b/examples/trifiller.c
@@ -45,6 +45,7 @@ int main(int argc, char *argv[])
@@ -34,6 +34,7 @@ int main(int argc, char *argv[])
int quit = 0;
int update = 1;
int px, py;
@@ -114,7 +114,7 @@ index 5a06f23..fab3cd7 100644
float angle = 0;
@@ -198,7 +199,6 @@ int main(int argc, char *argv[])
@@ -187,7 +188,6 @@ int main(int argc, char *argv[])
/* 2D Rotation around screen center */
@@ -160,5 +160,38 @@ index 3a405ea..63b35af 100644
caca_blit(cv, x, y, figcv, NULL);
caca_refresh_display(dp);
--
1.8.3.4
2.51.0
From aff446d0ca0fcacc73c3a6c2ceecf8685a074bee Mon Sep 17 00:00:00 2001
From: Pascal Terjan <pterjan@mageia.org>
Date: Mon, 27 Oct 2025 21:53:54 +0000
Subject: Redefine _caca_alloc2d in src/common-image.c
This is an internal function that can not be used in this sample code.
Easiest is to duplicate it.
Fixes https://github.com/cacalabs/libcaca/issues/67
diff --git a/src/common-image.c b/src/common-image.c
index 7059bf4..461879a 100644
--- a/src/common-image.c
+++ b/src/common-image.c
@@ -29,6 +29,14 @@
static unsigned int u32fread(caca_file_t *);
static unsigned int u16fread(caca_file_t *);
static unsigned int u8fread(caca_file_t *);
+
+static void *_caca_alloc2d(size_t width, size_t height, size_t elem_size)
+{
+ if (width == 0 || height == 0 || elem_size == 0 || SIZE_MAX / width / height < elem_size)
+ return NULL;
+ return malloc(width * height * elem_size);
+}
+
#endif
struct image * load_image(char const * name)
--
2.51.0