libgd: readd macros used by php

This commit is contained in:
Juergen Daubert 2021-09-25 11:30:05 +02:00
parent edbaa85d38
commit 37fbc00f70
3 changed files with 34 additions and 4 deletions

View File

@ -1,5 +1,6 @@
untrusted comment: verify with /etc/ports/opt.pub
RWSE3ohX2g5d/QSSDQZ8erHKtMB+JLgdqasE98BfchMri6NLni8m6Px50S7We6RR4tF4O5lCTPjBsofn18PxWzP9p7NJYyx/lQU=
SHA256 (Pkgfile) = 950d30fb5a61c877ac2dfb0b2d1209a903df59598c4a33617c9cbc23fd2378d4
RWSE3ohX2g5d/Z7sz1m/ytpjM+2irJ2ef1/EfKp/ZumGlYc+FsT0arUJ1d4VHgwAgffWK5G0t3uR8X5onFn9jALhadB66zAZYwI=
SHA256 (Pkgfile) = 8265db8d3cca9f8b7bf8a51038c217055eb431a49d2feb2f9c65c1b43f5344d4
SHA256 (.footprint) = a7451ec23132bfbaed312ff3256c14b89312f513753c19e870a9736c1db2d512
SHA256 (libgd-2.3.3.tar.xz) = 3fe822ece20796060af63b7c60acb151e5844204d289da0ce08f8fdf131e5a61
SHA256 (remove_gd_flip_macros.patch) = 2ae91e3e018440c74c1628bac5deed2851234f2b5bfea49bf805312c64d0115e

View File

@ -5,11 +5,14 @@
name=libgd
version=2.3.3
release=1
source=(https://github.com/libgd/libgd/releases/download/gd-$version/$name-$version.tar.xz)
release=2
source=(https://github.com/libgd/libgd/releases/download/gd-$version/$name-$version.tar.xz
remove_gd_flip_macros.patch)
build () {
cd $name-$version
# macros are used in php
patch -p1 -R -i $SRC/remove_gd_flip_macros.patch
./configure --prefix=/usr
make DESTDIR=$PKG install
}

View File

@ -0,0 +1,26 @@
From bdc281eadb1d58d5c0c7bbc1125ee4674256df08 Mon Sep 17 00:00:00 2001
From: Pierre Joye <pierre.php@gmail.com>
Date: Wed, 25 Aug 2021 15:28:32 +0700
Subject: [PATCH] Fix #318, these macros are not used as planed, we have
separate functions for each
---
src/gd.h | 5 -----
1 file changed, 5 deletions(-)
diff --git a/src/gd.h b/src/gd.h
index 5728a25e..51b96610 100644
--- a/src/gd.h
+++ b/src/gd.h
@@ -1604,11 +1604,6 @@ BGD_DECLARE(void) gdImageFlipHorizontal(gdImagePtr im);
BGD_DECLARE(void) gdImageFlipVertical(gdImagePtr im);
BGD_DECLARE(void) gdImageFlipBoth(gdImagePtr im);
-#define GD_FLIP_HORINZONTAL 1 /* typo, kept for BC */
-#define GD_FLIP_HORIZONTAL 1
-#define GD_FLIP_VERTICAL 2
-#define GD_FLIP_BOTH 3
-
/**
* Group: Crop
*